1 | Authority indicator | Output | Char(1) |
2 | User profile name | Input | Char(10) |
3 | Special authority | Input | Char(*) |
4 | Number of authorities | Input | Binary(4) |
5 | Call level | Input | Binary(4) |
6 | Error code | I/O | Char(*) |
The Check User Special Authorities (QSYCUSRS) API provides an indication of whether the user has the specified special authorities.
When the API checks for special authorities and the user profile name parameter is *CURRENT or the user who is currently running, the special authorities available to the user include any special authorities the user or the group has, and any program adopted special authorities. If the user profile specified is not the user currently running, then the special authorities available to the user are only the special authorities the user and his group have.
If previous programs in the program stack adopt their owner's authority, the adopted authority for the current program is the accumulated adopted authority from all other programs in the program stack that adopt authority.
Whether the user has the specified special authorities.
This parameter contains one of the following:
Y | The user has the specified special authorities. |
N | The user does not have the specified special authorities. |
The name of the user whose special authorities are checked.
You can specify the following special value:
*CURRENT | The special authorities for the user currently running are checked. |
The special authorities checked for the user. This parameter can contain up
to eight 10-character fields.
Each of the 10-character fields can contain one of the following special
values.
*ALLOBJ | All object special authority. |
*AUDIT | Audit special authority. |
*IOSYSCFG | Input/output system configuration special authority. |
*JOBCTL | Job control special authority. |
*SAVSYS | Save system special authority. |
*SECADM | Security administrator special authority. |
*SERVICE | Service special authority. |
*SPLCTL | Spool control special authority. |
The number of special authorities specified in the special authority parameter. You can specify 1 through 8.
The number of call levels to back up in the program stack to do the authority check. For example, if the program that calls this API adopts authority, you would probably not want the authority check to use the adopted authority. Therefore, the authority check should be done at the call level previous to the current level. This parameter should then contain a 1. You can check the authority at the various call levels by signifying a numeric equivalent to the call level. For example, to check the authority at the current call level, specify a 0; to check the authority at the previous call level, specify a 1.
This parameter is only used if the user profile name parameter is *CURRENT, or the current user name for the job.
The structure in which to return error information. For the format of the structure, see Error Code Parameter.
Message ID | Error Message Text |
---|---|
CPF22F7 E | Number of authorities must be between 1 and &1. |
CPF22F8 E | Special authority value &1 not valid. |
CPF22F9 E | Call level &1 not valid. |
CPF2203 E | User profile &1 not correct. |
CPF2225 E | Not able to allocate internal system object. |
CPF3C90 E | Literal value cannot be changed. |
CPF3CF1 E | Error code parameter not valid. |
CPF8122 E | &8 damage on library &4. |
CPF9801 E | Object &2 in library &3 not found. |
CPF9802 E | Not authorized to object &2 in &3. |
CPF9803 E | Cannot allocate object &2 in library &3. |
CPF9807 E | One or more libraries in library list deleted. |
CPF9808 E | Cannot allocate one or more libraries on library list. |
CPF9810 E | Library &1 not found. |
CPF9820 E | Not authorized to use library &1. |
CPF9830 E | Cannot assign library &1. |
CPF9872 E | Program or service program &1 in library &2 ended. Reason code &3. |
Top | Security APIs | APIs by category |