Answered by:
logon script mapping network data by domain group membership

Question
-
I have a simple logon script (net use M:\\servername\financing) to map network share drive for Financing Dept and I set permissions at folders level. Group A can access Group A folder only, Group B can only access Group B folder only, and so on.. but all groups can see the other groups folders. Group A can see there are group B folder, group C folder, etc but Group A cannot access other group folders - "Access Denied".
My bosses (yes, plural) don't like that idea. They want standard drive letter M for all departments but they want each group will map only to the group data folder. In brief, Group A mapping to M drive and only see Group A folder listed - nothing else. Like M:\\servername\GroupA. Howver, the idea is that the share is at the root level (Financing), all subfolders are not shared out (Group A, Group B, Group C) to eliminate to many shares to manage.
How do I do that in a bat file (if possible)? Please no script which I have no knowledge about it. I can try PowerShell. Thanks.
Thang MoFriday, March 4, 2011 6:47 PM
Answers
-
See # 11 in this FAQ:
http://www.rlmueller.net/LogonScriptFAQ.htm
There is no way I know, without third party tools, to check for group membership in a batch file. Otherwise, you can use VBScript or PowerShell. However, PowerShell requires .NET Framework 2.0 (or above) and PowerShell on all clients. If are just starting with VBScript logon scripts, this link might help:
http://www.rlmueller.net/LogonScriptGuidelines.htm
The link discusses several methods to check group membership. An example VBScript program that maps drives according to group membership is linked here:
http://www.rlmueller.net/Logon3.htm
Richard Mueller
MVP ADSI- Marked as answer by Dale Qiao Thursday, March 10, 2011 2:20 AM
Friday, March 4, 2011 7:45 PM -
The best practices is use Group Policy preference.The script is poor variant.
- Marked as answer by Dale Qiao Thursday, March 10, 2011 2:20 AM
Friday, March 4, 2011 8:59 PM
All replies
-
See # 11 in this FAQ:
http://www.rlmueller.net/LogonScriptFAQ.htm
There is no way I know, without third party tools, to check for group membership in a batch file. Otherwise, you can use VBScript or PowerShell. However, PowerShell requires .NET Framework 2.0 (or above) and PowerShell on all clients. If are just starting with VBScript logon scripts, this link might help:
http://www.rlmueller.net/LogonScriptGuidelines.htm
The link discusses several methods to check group membership. An example VBScript program that maps drives according to group membership is linked here:
http://www.rlmueller.net/Logon3.htm
Richard Mueller
MVP ADSI- Marked as answer by Dale Qiao Thursday, March 10, 2011 2:20 AM
Friday, March 4, 2011 7:45 PM -
The best practices is use Group Policy preference.The script is poor variant.
- Marked as answer by Dale Qiao Thursday, March 10, 2011 2:20 AM
Friday, March 4, 2011 8:59 PM