isInRole Problem

A

arjun

Hi All,
I am developing a A webpage to be seen in a page viewer
webpart(Sharepoint 2003).
The page is supposed to check for the current user name and then check
the user membership in some local group membership.But here I am
failing .The isinRole call on the Principal object is returning true
for buitin groups and some local groups but not ALL.
I read in one of the previous threads that this was a bug in Framework
1 in which all groups are not retrieved.SP3 takes care of it.
However I have Framework 1.1 ...So the patches are not working...
Can anyone tell me if this bug is fixed in v1.1?
The code I am using is hereis something like this
HttpContext.Current.User.IsInRole("<machinename>\<group name>")
Please do point out if something is amiss?
If This thing does not work can anyone give any pointers to a similar
code that achieves this in Visual Basic 6.0
Thanks in Advance,
Arjun
 
G

Guest

HI arjun,,
I don't know if there was a BUG i use IsinRole with the Active
Directory and it works!what i'm thinking you are dong wrong is that i think
its CASE SENSITIVE!
Your code should be good since you said it works for some users..
Try checking for case senstitve and post back if you have more questions.
Patrick
 
A

arjun

Hi Patrik,

The bug I was referring to is the following:
http://support.microsoft.com/default.aspx?scid=kb;en-us;q321562

I have tried nearly all combo of the local group names every time for
some select groups isInRole is false.Even if a purticular syntax works
for others it fails in question of these groups.I think my prob is
this bug.

My box is in an active directory domain.The configuration of my box is
:
Windows Server 2003,.net Framework v1.1,Windows SharePoint Services
2.0,SharePoint Portal Server 2003

Can you do a chk with your config. so that if this problem is due to
some software config then we can resolve it?

If you have any other ideas to make this thing work do mention
those...I need this issue resolved on a very critical basis...

Thanks in Advance,
Arjun
 
G

Guest

Hi Arjun,
I went through the Page and it says it fails if the user belong to
many GROUPS does that happen in your case?This problem occurs if the combined
length of these group names is greater than 2,048 bytes.
What i noticed in my case was that i tried using forms auth and anytime i
try getting GROUP names it fails and doesn't Authenticate and after removing
my GETGROUP function it authenticates.But i haven't came across such problem
when using Windows Auth...
Try seeing if it returns falls if a particular user belong to too many
GROUPS!!
There should be a workaround for this !!
Keep me posted
Patrick
 
G

Guest

Arjun,
Also try posting your code to :-
the FORUM :- dotnet.framework.aspnet.security
Patrick
 

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,995
Messages
2,570,228
Members
46,816
Latest member
nipsseyhussle

Latest Threads

Top