"Mandatory" methods in custom membership/roleproviders?

Erik Lidälv
Member since: 2007
 

Hi! I would like to know which methods and properties you must implement from the RoleProvider and MembershipProvider abstract classes if you're building a custom membership/roleprovider and want to be able to use all built-in user/role functionality in EPiServer CMS 5 R2 (create, delete, update user, etc).

Thanks!

Erik Lidälv

#28492
Mar 11, 2009 13:46
Per Bjurström
Member since: 1999
 

You have to use the EPiServer.Security.ProviderCapabilities class to let us know which capabilites your provider has:

ProviderCapabilities.AddProvider(typeof(MyMembershipProvider), new ProviderCapabilitySettings(Action.Create | Action.Delete | Action.Update, "email", "comment"));

ProviderCapabilities.AddProvider(typeof(MyRoleProvider), new ProviderCapabilitySettings(Action.Create | Action.Delete | Action.Update));

 

#28507
Mar 12, 2009 12:21
Erik Lidälv
Member since: 2007
 

Hi! Thank you for your replay! The thing is that I haven't made my providers yet, I'm just researching how I will implement them i.e. which methods I must create. I implemented the RoleProvider and MembershipProvider abstract classes letting all methods throwing a NotImplementedException trying to find out which methods that was actually needed to make everthing work in EPiServer edit/admin. I found a whole bunch but it would be great if anyone had made this before and could tell me, cause I'm sure I haven't found them all.. Smile

Erik

#28508
Mar 12, 2009 13:31