Secured Pages

Posted by Community Admin on 03-Aug-2018 03:21

Secured Pages

All Replies

Posted by Community Admin on 12-Sep-2011 00:00

It used to be when you created a page, you could set a property to require the page to be seen only when logged in and if someone tried to access it, it would go to the 401 error.  Now (in 4.2), I have pages that I want to be visible on when logged in, but I have no idea how to route to a login page. I have set security on the pages for the correct roles, but users trying to access the page when not logged in, get a "this type of page is not served" error. What is the correct way to handle secured pages in 4.2?

Posted by Community Admin on 15-Sep-2011 00:00

Hi Allen,

I am not sure if I understand you, but I guess that you need a way to redirect user from "this type of page is not served" error page to login page. This can be done by inserting few lines in web.config:

<system.webServer>
    <httpErrors errorMode="Custom" existingResponse="Replace">
      <clear />
      <error statusCode="404" path="404page.aspx" responseMode="Redirect"/>
      <error statusCode="403" path="403page.aspx" responseMode="Redirect"/>
    </httpErrors>
...
You can also read this article: http://tedgustaf.com/en/blog/2011/5/custom-404-and-error-pages-for-asp-net-and-static-files/ 
If you have any other questions feel free to ask.

Greetings,
Bonny
the Telerik team
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

This thread is closed