Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > Retrieving Roles

Reply
Thread Tools

Retrieving Roles

 
 
Prashant K
Guest
Posts: n/a
 
      10-03-2005
Hi Experts,

I am using C# / ADSI in my ASP.Net application. I want to implement role
based security in my application. I want to make restrictions in my
application based on the groups which the user belongs. I am using a custom
Login page and not windows integrated authentication. The user enters a
valid userid and password to login.

Can anyone tell me how to get the roles of the logged in user.

Thanx in Advance
Regards

 
Reply With Quote
 
 
 
 
Jas
Guest
Posts: n/a
 
      10-05-2005

If you are using Froms auth. and this is pre 2.0 your application probably
stores the roles somewhere in the database. Along with every user, you
should have a list of all the roles he/she belongs to. Once you retrieve
this you can use the GenericPrincipal object.

jas

> Hi Experts,
>
> I am using C# / ADSI in my ASP.Net application. I want to implement role
> based security in my application. I want to make restrictions in my
> application based on the groups which the user belongs. I am using a custom
> Login page and not windows integrated authentication. The user enters a
> valid userid and password to login.
>
> Can anyone tell me how to get the roles of the logged in user.
>
> Thanx in Advance
> Regards
>

 
Reply With Quote
 
 
 
 
Dominick Baier [DevelopMentor]
Guest
Posts: n/a
 
      10-05-2005
Hello JAS,

is you mention ADSI - i assume your users a stored in AD/ADAM??

you can retrieve the roles of the user by using LDAP - wait until Joe Kaplan
jumps on that thread - he is the LDAP man!

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

> If you are using Froms auth. and this is pre 2.0 your application
> probably stores the roles somewhere in the database. Along with every
> user, you should have a list of all the roles he/she belongs to. Once
> you retrieve this you can use the GenericPrincipal object.
>
> jas
>
>> Hi Experts,
>>
>> I am using C# / ADSI in my ASP.Net application. I want to implement
>> role based security in my application. I want to make restrictions in
>> my application based on the groups which the user belongs. I am
>> using a custom Login page and not windows integrated authentication.
>> The user enters a valid userid and password to login.
>>
>> Can anyone tell me how to get the roles of the logged in user.
>>
>> Thanx in Advance
>> Regard



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Retrieving the list of security roles from EJB deployment descriptor tremalnaik@gmail.com Java 0 04-18-2007 09:55 AM
Application level roles + Item level roles... how to do it? Jéjé ASP .Net Security 0 09-26-2005 11:06 PM
ARCHITECTURE : Enabling and disabling functionality in ASP.NET based on roles. VSK ASP .Net 0 10-23-2003 02:57 AM
Get FSMO Roles ? JerryP ASP .Net 1 09-13-2003 09:18 AM
Newbie Q on roles Justin Dutoit ASP .Net 1 08-18-2003 09:27 AM



Advertisments