ASP.net Membership + Protecting Pages (Public Access)
I've created my own membership provider and I want to protect certain pages. I've implemented by own role provider and can set access using "public access".
From what I understand when a page is accessed in the front end umbraco.library.hasaccess is called to make sure the user has access.
In umbraco 4.5 the method looks like
[Obsolete("This method is no longer supported. Use the ASP.NET MemberShip methods instead", true)]
publicstaticbool HasAccess(int DocumentId, cms.businesslogic.member.Member Member)
{
I guess my question is how can I protect pages with a customised provider? In my roleprovider I have set break points on IsUserInRole and GetRolesForUser and neither get hit when accessing a protected page.
ASP.net Membership + Protecting Pages (Public Access)
I've created my own membership provider and I want to protect certain pages. I've implemented by own role provider and can set access using "public access".
From what I understand when a page is accessed in the front end umbraco.library.hasaccess is called to make sure the user has access.
In umbraco 4.5 the method looks like
I guess my question is how can I protect pages with a customised provider? In my roleprovider I have set break points on IsUserInRole and GetRolesForUser and neither get hit when accessing a protected page.
Thanks in advance,
Matthew
Ignore me! Hadn't implemented a couple of provider methods...All good now :)
Hi Skiltz
I am experiencing exactly the same issue you posted here.
Could you please post which provider methods you had to implement to get it to work.
Every liitle help is appreciated.
Thanks.
make sure these two methods are implemented in your role provider.
public override bool IsUserInRole(string username, string roleName)
public override string[] GetRolesForUser(string username)
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.