Trusted Solaris Administrator's Procedures

To List All Roles

Once the SMC is initialized, users or roles can use the smrole(1M) command described below to see a list of all roles.

  1. Assume the Security or System Administrator role.

  2. To list the roles in a name service domain, use the smrole list command with the -D option to specify the name_service_type:/server_name/domain_name. Provide a password when prompted.

    The following screen example lists the roles that are defined in the NIS+ domain tropics.example.com whose NIS+ master server is toucan. The command is being executed on the tern system:


    $ /usr/sadm/bin/smrole list -D nisplus:/toucan/tropics.example.com --
    Authenticating as user: admin
    
    Type /? for help, pressing <enter> accepts the default denoted by [ ]
    Please enter a string value for: password ::  rolePassword
    Loading Tool: usermgr.cli.role.UserMgrRoleCli from tern
    Login to tern as user janez, role admin was successful.
    Download of usermgr.cli.role.UserMgrRoleCli from tern was successful.
    admin           100             System Admin
    secadmin        101             Security Admin
    oper            102             Operator
    primaryadmin    104             Primary Administrator Role
    root            0               Super-User
  3. To list the roles defined in the local system, use the smrole list command followed by the double dash --.


    $ /usr/sadm/bin/smrole list --
    

    To list all roles defined in local files on a system named tern:


    /usr/sadm/bin/smrole list  -- -h tern