NT Groups 
Author Message
 NT Groups

I am gertting a users NT Logon name using a server variable is there any way
that I can get what group they are a member of from an ASP page even if I
have to call a DLL.

Neil



Tue, 15 Apr 2003 17:27:34 GMT  
 NT Groups
If you know their username then you can use ADSI to get the group name that
they belong to

ie something like this might work (haven't checked the syntax but it'll get
you in the right direction)

UserObj = GetObject("WinNT://YOUR_DOMAIN/Username,users")
UserObj.Filter = Array("group")
For Each group In UserObj
    response.write group.Name
Next


Quote:
> I am gertting a users NT Logon name using a server variable is there any
way
> that I can get what group they are a member of from an ASP page even if I
> have to call a DLL.

> Neil



Sat, 19 Apr 2003 12:40:05 GMT  
 NT Groups
You can use ADSI to get user account information.
see: http://www.asptoday.com/articles/20000417.htm

Example code fragment:

<%
      sUser = "WinNT://" & Request.ServerVariables("AUTH_USER")

      'Retrieve User Info
      Set oUser = GetObject(sUser )

      ' Retrieve the Groups the user is a member of
      Set oGroups = oUser.Groups()

      For Each mGroup in oGroups
 Request.Write "Group: " & mGroup.Name
      Next
%>


Quote:
> I am gertting a users NT Logon name using a server variable is there any
way
> that I can get what group they are a member of from an ASP page even if I
> have to call a DLL.

> Neil



Thu, 24 Apr 2003 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. NT Group detection - help please

2. NT Group

3. How to check NT Group in VBScript

4. Testing for NT Group membership within VB Script

5. error when checking for NT group membership

6. verify nt group without using ADSI

7. Compare NT groups & users function

8. NT Group detection - help please

9. Checking NT Group Membership

10. Deleting a user from NT Groups

11. Get NT Groups for Users

12. Nt Group from macintosh

 

 
Powered by phpBB® Forum Software