473,397 Members | 1,949 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

NullUser and WindowsIdentity (ImpersonateAnonymousToken) has no groups


I create a user token for the windows anonymous user ("NT AUTHORITY\ANONYMOUS
LOGON") using ImpersonateAnonymousToken. I successfully create a WindowsIdentity
from that token, but the Groups property always reports zero groups, even
though I have added the "NT AUTHORITY\ANONYMOUS LOGON" user to groups manually.

What am I doing wrong?
May 30 '06 #1
2 1775
I don't think that "Anonymous Logon" can be added to any group...

I had the same problem sometime back... I had to create another user and
assign groups to the new user.

Not sure if I missed some information then or I am still missing something
now....
--
Happy Hacking,
Gaurav Vaish
http://www.mastergaurav.org
http://webservices.edujini.in
-------------------
"Eric Pearson" <re***@newsgrouponly.please> wrote in message
news:e3*************************@msnews.microsoft. com...

I create a user token for the windows anonymous user ("NT
AUTHORITY\ANONYMOUS LOGON") using ImpersonateAnonymousToken. I
successfully create a WindowsIdentity from that token, but the Groups
property always reports zero groups, even though I have added the "NT
AUTHORITY\ANONYMOUS LOGON" user to groups manually.

What am I doing wrong?

May 30 '06 #2
Yes, as I said "even though I have added the "NT AUTHORITY\ANONYMOUS LOGON"
user to groups manually.".

go to add a user to any group, type "ANONYMOUS LOGON" for the user, and it
should resolve to "NT AUTHORITY\Anonymous Logon". It's just through code
those groups don't get associated.
I don't think that "Anonymous Logon" can be added to any group...

I had the same problem sometime back... I had to create another user
and assign groups to the new user.

Not sure if I missed some information then or I am still missing
something now....

"Eric Pearson" <re***@newsgrouponly.please> wrote in message
news:e3*************************@msnews.microsoft. com...
I create a user token for the windows anonymous user ("NT
AUTHORITY\ANONYMOUS LOGON") using ImpersonateAnonymousToken. I
successfully create a WindowsIdentity from that token, but the Groups
property always reports zero groups, even though I have added the "NT
AUTHORITY\ANONYMOUS LOGON" user to groups manually.

What am I doing wrong?

May 30 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: BLiTZWiNG | last post by:
After playing with the code shown and utilising Willy Denyottes' help, I have come to the conclusion that there is some form of difference between the managed WindowsIdentity.Impersonate() over the...
3
by: diephouse | last post by:
I seem to be having a problem accessing networks shares. For example, I try the following code: File.Exists(@"\\SERVER\share"); always returns false! Or even if I map the drive ...
3
by: Kevin Burton | last post by:
This is more of a solution that raised a question. I have a Web service that does not allow anonymous users. For debugging I put in the following lines in my Web Service: WindowsIdentity wi =...
8
by: Razak | last post by:
Hi, I have a class which basically do Impersonation in my web application. From MS KB sample:- ++++++++++++++++++++code starts Dim impersonationContext As...
3
by: Derek Martin | last post by:
Does anyone know how to get the current logged on NAME from AD? I can get the username domain\username, but I would like to actually get John W. Doe from the currently logged in person. Anyone? ...
13
by: ALI-R | last post by:
I know how to authenticate to a webservice using either of these ways(Assuming that rService represents the webservice): 1) rService.Credentials = new...
1
by: Raghu | last post by:
If a company has windows machines but the directory services is not active directory (say novell's eDirectory for whatever reason and users are authenticated against this non-AD directory...
2
by: gary.comstock | last post by:
We have setup 4 NT groups - Executive, Manager, Employee and Contractor. The premise is that an Executive has all of the privileges of Itself plus Manager plus Employee plus Contractor while an...
10
by: Jeff Williams | last post by:
How can I get a list of the Groups both Local and Domain groups a User belongs to.
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.