Previous Topic: MAP CommandNext Topic: MDSKSCAN Command


MAY Command

Use the MAY command to query the AUTHORIZ CONFIG file.

MAY [userid [authword ...]]

Definitions

userid

Specifies the user ID whose authorizations you want CA VM:Director to query. You can specify a user ID by name if you are authorized to query that user ID, or any of the variable user IDs described under the LISTAUTH command.

The default user ID is I.

authword ...

Specifies a list of authority words that describe the authorization to query. You can specify any authority, or any of the authority variables described under the LISTAUTH command.

The default for each authority word is ANYWRD.

Note: The default authority word for the MAY command is ANYWRD, while the default authority word for the LISTAUTH command is EVERYWRD. These different default values can produce different results for the LISTAUTH and MAY commands, even though their functions are similar.

Description

The MAY command lets you query the AUTHORIZ CONFIG file to determine whether a user ID has a specific authorization. This command always returns a code of 0 or 8. It does not stack any data. You can use this command in programs that check CA VM:Director authorizations.

Return Codes

The following table describes the return codes:

Return Code

Meaning

0

User ID is authorized to perform the function

8

User ID is not authorized to perform the function

Examples

Note: For information about how to find all authorizations a user ID has for a command or function, see LISTAUTH Command.