Storefront: Citrix Storeweb URL should have custom error page

Storefront: Citrix Storeweb URL should have custom error page

book

Article ID: CTX691120

calendar_today

Updated On:

Description

Redirect StoreFront users to a custom error page, if a page is inaccessible for some reason.

Example: If a user tries to access "StoreURL/<>Script", it will trigger an unhandled exception and User will get a generic page which suggests steps to add a custom error page. This may be considered a risk by security auditors.


Instructions

1. On the StoreFront server, go to C:\inetpub\wwwroot\Citrix\StoreWeb, and create a backup of the existing web.config file

2. Open web.config using notepad and search for customErrors, by default it is set to RemoteOnly, with no error page assigned. We can add an error page to it, like,  

<customErrors mode="RemoteOnly" defaultRedirect="~/ErrorPages/GeneralError.html"/>

3. Here we are redirecting to "ErrorPages/GeneralError.html", but there is no such page by default, so we need to create the html file manually, and add the error message. 

Since the custom errors are set to Remote only, we will see the custom error page on Clients. But if we access the page locally on the StoreFront server, it will show the actual error. If we want to see the same customer error page on StoreFront as well, then we need to set customErrors to On, instead on RemoteOnly. Keeping it to RemoteOnly, makes troubleshooting easier as StoreFront will show the actual error message.