Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nick 20 posts 161 karma points notactivated
    Mar 12, 2022 @ 11:58
    Nick
    0

    Restrict public access prevents an Umbraco admin from accessing the page

    I've implemented a member login for pages that need to be protected. However, the site owner also needs to be able to access these pages but when visited they are also displayed with the login form despite being logged in to the Umbraco backoffice as an admin.

    Does anyone have any suggestions how to bypass this or will the site admin also need to have a member login too?

    Thanks!

  • Ambert van Unen 175 posts 818 karma points c-trib
    Mar 13, 2022 @ 16:18
    Ambert van Unen
    100

    This is by design yes, as Members (front end) and Users (back office users) are seperated.

    Ofcourse you can make something to make this work, but it could expose extra security issues whilst doing so.. Keeping it seperate is always safer.

  • Nick 20 posts 161 karma points notactivated
    Mar 13, 2022 @ 18:10
    Nick
    0

    Hi Ambert, thank you for your reply!

    Out of interest, do you know how I might go about/find where I can intercept the middleware that handles access to the restricted pages?

  • Ambert van Unen 175 posts 818 karma points c-trib
    Mar 14, 2022 @ 07:16
    Ambert van Unen
    1

    I'm not 100% sure what you are looking for, but I do know here is the code that does the checks and redirects you or not.

    https://github.com/umbraco/Umbraco-CMS/blob/v9/contrib/src/Umbraco.Web.Website/Routing/PublicAccessRequestHandler.cs

    Hope it helps :-)

Please Sign in or register to post replies

Write your reply to:

Draft