A. On the resource kit for NT you'll find a program called IFMEMBER, this is what you'll have to base your login script upon. Important safety tip, IFMEMBER works by checking for membership in a group and returning an ERRORLEVEL hence you'll have a bunch of IF THENS..

Ifmember sets errorlevel to the number of groups in the list that the user is actually a member of, for example:

  groupa groupb groupc
savillj Y Y N

If you typed command

ifmember  group1 group2

an errorlevel of 2 would be returned.

ifmember groupa 
if %errorlevel%==1