Allow anonymous access to SharePoint application pages in the _layouts directory
By default, the page is inherited from “LayoutsPageBase”. Change the inheritance
from “LayoutsPageBase” to “UnsecuredLayoutsPageBase”.
public partial class HelloWorld : UnsecuredLayoutsPageBase
Next, we need to override a property of the UnsecuredLayoutsPageBase, to allow the
anonymous access. Be sure to change the ‘getter’ to return true
protected override bool AllowAnonymousAccess { get { return true; } }
Comments
Post a Comment