Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


group membership

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,29966
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> group membership
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 group membership - 1/16/2006 9:28:29 PM   
  Bezerk

 

Posts: 22
Score: 0
Joined: 6/20/2005
From: Netherlands
Status: offline
I have an export from a database which i use to create the users in AD.
I can add the users to groups etc.
The groups are what we call roles, which means that a role has access to resources in the infrastructure.

The users change from role quit often, management want to automatically update group membership
What is a good logic to do that, the export that is get does not change.

This is a code snippet what i use to add users to groups. This is done the first time in the script if the user does not exists.
You can see i had to create a case statement, because the cn and ldap path are not specified in the database only the role name.

I want to use almost the same logic to update the user groepmembership.
This means i have to remove users from roles they no longer need and add them to new roles.

What is the best logic to do that.


      
 
 
Post #: 1
 
 RE: group membership - 1/16/2006 10:36:25 PM   
  ginolard


Posts: 1068
Score: 21
Joined: 8/10/2005
Status: offline
Would it not simply be best practice to create separate OUs for each role?  

(in reply to Bezerk)
 
 
Post #: 2
 
 RE: group membership - 1/16/2006 10:42:15 PM   
  Bezerk

 

Posts: 22
Score: 0
Joined: 6/20/2005
From: Netherlands
Status: offline
Not possible, because users can have more then one role.
There are not much roles, so i think the best way is to delete the user from all the roles and then add them back to the roles according to the export sheet.

(in reply to ginolard)
 
 
Post #: 3
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> group membership Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts