Forms Authentication - Active Directory

O

oriol.ardevol

Hi,

I have an asp.net 2.0 application with forms authentication. I am
authenticating the users to an Active Directory Server with
ActiveDirectoryMembershipProvider which works as expected and users
get authenticated.

What I am trying to do is to get also the role information from the
Active Directory Server with the groups where the users belong to.

Is there any way to achieve it ? Can it be done by enabling some
provider in the role manager section of the web.config file ?

any help will be appreciated, thx in advance,
ori
 
G

Guest

Hi,

I have an asp.net 2.0 application with forms authentication. I am
authenticating the users to an Active Directory Server with
ActiveDirectoryMembershipProvider which works as expected and users
get authenticated.

What I am trying to do is to get also the role information from the
Active Directory Server with the groups where the users belong to.

Is there any way to achieve it ? Can it be done by enabling some
provider in the role manager section of the web.config file ?

any help will be appreciated, thx in advance,
ori

You would need a role provider.

WindowsTokenRoleProvider for using Active Directory groups as roles
AuthorizationStoreProvider - for Windows 2003 and ADAM
SqlRoleProvider for storing roles in SQL Server

More about WindowsTokenRoleProvider
http://msdn2.microsoft.com/en-us/library/system.web.security.windowstokenroleprovider.aspx
 
D

Dominick Baier

They are all not very helpful in your situation.

The WindowsTokenRoleProvider only works with windows auth - not forms.

Ryan an me have written an ActiveDirectoryRoleProvider - which seems to work
for most people...

i can send you the code if you are interested...
 
O

oriol.ardevol

I had already tried those solutions.

WindowsTokenAuthenticationProvider does'nt works for Forms
Authentication as Dominick pointed, and I couldn't managed to get
AuthorizationStoreProvider to work (ended up getting some weird
COMException error which I already posted in this group last week)

Finally, I developed my own role provider which accesed the active
directory and got the role information.

Thanks for everything,
ori
 
G

Guest

I had already tried those solutions.

WindowsTokenAuthenticationProvider does'nt works for Forms
Authentication as Dominick pointed, and I couldn't managed to get
AuthorizationStoreProvider to work (ended up getting some weird
COMException error which I already posted in this group last week)

Finally, I developed my own role provider which accesed the active
directory and got the role information.

Thanks for everything,
ori

Ah, yes, Dominick and you were right, I've missed that you asked about
the Forms Authentication. Sorry!
 
J

Joe Kaplan

FYI, Ryan's LDAP-based AD/ADAM Role Provider is posted on Code Plex now in
case anyone wants it or wishes to contribute.

Joe K.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,968
Messages
2,570,150
Members
46,697
Latest member
AugustNabo

Latest Threads

Top