(username, shadow_name)
Creates a shadow user account.
Creates a shadow user account.
Creates a shadow user account .
def CreateShadowAccount(username, shadow_name):
  """Creates a shadow user account."""
  shadow_account = {'PrimaryGID': '80', 'UniqueID': '497',
                    'RealName': '%s Admin' % username,
                    'AuthenticationAuthority': ';ShadowHash;',
                    'NFSHomeDirectory': '/var/empty', 'UserShell': '/bin/bash'}

  DSSet('user', shadow_name)

  for key in shadow_account:
    DSSet('user', shadow_name, key, shadow_account[key])

  AddUserToLocalGroup(shadow_name, 'admin')
  AddUserToLocalGroup(shadow_name, '_appserveradm')
  AddUserToLocalGroup(shadow_name, '_lpadmin')
def CreateShadowAccount ( username , shadow_name ) : shadow_account = { 'PrimaryGID' : '80' , 'UniqueID' : '497' , 'RealName' : '%s Admin' % username , 'AuthenticationAuthority' : ';ShadowHash;' , 'NFSHomeDirectory' : '/var/empty' , 'UserShell' : '/bin/bash' } DSSet ( 'user' , shadow_name ) for key in shadow_account : DSSet ( 'user' , shadow_name , key , shadow_account [ key ] ) AddUserToLocalGroup ( shadow_name , 'admin' ) AddUserToLocalGroup ( shadow_name , '_appserveradm' ) AddUserToLocalGroup ( shadow_name , '_lpadmin' )