Callable Services
Callable Services
SA23-2293-30
Note
Before using this information and the product it supports, read the information in “Notices” on page 463.
This edition applies to Version 2 Release 3 of z/OS (5650-ZOS) and to all subsequent releases and modifications
until otherwise indicated in new editions.
Last updated: July 17, 2017
© Copyright IBM Corporation 1994, 2017.
US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract
with IBM Corp.
Contents
Figures . . . . . . . . . . . . . . . ix Parameters . . . . . . . . . . . . . 17
Return and reason codes . . . . . . . . . 17
Tables . . . . . . . . . . . . . . . xi Usage notes . . . . . . . . . . . . . 17
Related services . . . . . . . . . . . . 17
ck_IPC_access (IRRSKI00): Check IPC access . . . 18
About this document . . . . . . . . xv Function . . . . . . . . . . . . . . 18
Intended audience . . . . . . . . . . . . xv Requirements . . . . . . . . . . . . . 18
Where to find more information . . . . . . . xv RACF authorization . . . . . . . . . . 18
RACF courses . . . . . . . . . . . . xv Format . . . . . . . . . . . . . . . 19
Other sources of information . . . . . . . . xv Parameters . . . . . . . . . . . . . 19
Internet sources. . . . . . . . . . . . xvi Return and reason codes . . . . . . . . . 20
Usage notes . . . . . . . . . . . . . 20
How to send your comments to IBM xvii Related services . . . . . . . . . . . . 20
If you have a technical problem . . . . . . . xvii ck_owner_two_files (IRRSC200): Check owner of
two files . . . . . . . . . . . . . . . 20
Summary of changes . . . . . . . . xix Function . . . . . . . . . . . . . . 20
Summary of changes for z/OS Version 2 Release 3 xix Requirements . . . . . . . . . . . . . 20
Summary of changes for z/OS Version 2 Release 2 RACF authorization . . . . . . . . . . 21
(V2R2) as updated March 2017. . . . . . . . xix Format . . . . . . . . . . . . . . . 21
Summary of changes for z/OS Version 2 Release 2 Parameters . . . . . . . . . . . . . 21
(V2R2) as updated June 2016 . . . . . . . . xx Return and reason codes . . . . . . . . . 22
Summary of changes made in z/OS Version 2 Usage notes . . . . . . . . . . . . . 22
Release 2 . . . . . . . . . . . . . . . xx Related services . . . . . . . . . . . . 22
z/OS Version 2 Release 1 summary of changes . . xxii ck_priv (IRRSKP00): Check privilege . . . . . . 23
Function . . . . . . . . . . . . . . 23
Requirements . . . . . . . . . . . . . 23
Chapter 1. Using the RACF callable
RACF authorization . . . . . . . . . . 23
services. . . . . . . . . . . . . . . 1 Format . . . . . . . . . . . . . . . 24
Linkage conventions for the callable services . . . 1 Parameters . . . . . . . . . . . . . 24
Working with return and reason codes. . . . . . 1 Return and reason codes . . . . . . . . . 24
Work area (WORK) . . . . . . . . . . . . 1 Usage notes . . . . . . . . . . . . . 25
File security packet (IFSP) . . . . . . . . . . 2 Related services . . . . . . . . . . . . 25
Security credentials (CRED) . . . . . . . . . 2 ck_process_owner (IRRSKO00): Check process
File identifiers . . . . . . . . . . . . . . 4 owner . . . . . . . . . . . . . . . . 25
File type and file mode values . . . . . . . . 4 Function . . . . . . . . . . . . . . 25
IPC security packet (IISP) . . . . . . . . . . 5 Requirements . . . . . . . . . . . . . 25
Interprocess communications permission RACF authorization . . . . . . . . . . 25
(BPXYIPCP) . . . . . . . . . . . . . 6 Format . . . . . . . . . . . . . . . 26
IPC security credentials (CREI) . . . . . . . . 7 Parameters . . . . . . . . . . . . . 26
Return and reason codes . . . . . . . . . 27
Chapter 2. Callable services Usage notes . . . . . . . . . . . . . 27
descriptions . . . . . . . . . . . . . 9 Related services . . . . . . . . . . . . 27
ck_access (IRRSKA00): Check access . . . . . . 11 clear_setid (IRRSCS00): Clear set ID . . . . . . 27
Function . . . . . . . . . . . . . . 11 Function . . . . . . . . . . . . . . 27
Requirements . . . . . . . . . . . . . 11 Requirements . . . . . . . . . . . . . 28
RACF authorization . . . . . . . . . . 12 RACF authorization . . . . . . . . . . 28
Format . . . . . . . . . . . . . . . 14 Format . . . . . . . . . . . . . . . 28
Parameters . . . . . . . . . . . . . 14 Parameters . . . . . . . . . . . . . 28
Return and reason codes . . . . . . . . . 15 Return and reason codes . . . . . . . . . 29
Usage notes . . . . . . . . . . . . . 15 Usage notes . . . . . . . . . . . . . 29
Related services . . . . . . . . . . . . 15 Related services . . . . . . . . . . . . 29
ck_file_owner (IRRSKF00): Check file owner . . . 15 deleteUSP (IRRSDU00): Delete USP . . . . . . 29
Function . . . . . . . . . . . . . . 15 Function . . . . . . . . . . . . . . 29
Requirements . . . . . . . . . . . . . 16 Requirements . . . . . . . . . . . . . 29
RACF authorization . . . . . . . . . . 16 RACF authorization . . . . . . . . . . 30
Format . . . . . . . . . . . . . . . 16 Format . . . . . . . . . . . . . . . 30
Contents v
Usage notes . . . . . . . . . . . . . 231 Parameter usage . . . . . . . . . . . 267
Related services . . . . . . . . . . . 232 Related services . . . . . . . . . . . 268
R_GenSec (IRRSGS00 or IRRSGS64): Generic R_Password (IRRSPW00): Evaluate or encrypt a
security API interface. . . . . . . . . . . 232 clear-text password or password phrase . . . . 268
Function . . . . . . . . . . . . . . 232 Function . . . . . . . . . . . . . . 268
Requirements . . . . . . . . . . . . 232 Requirements . . . . . . . . . . . . 268
Linkage conventions . . . . . . . . . . 233 RACF authorization . . . . . . . . . . 268
RACF authorization . . . . . . . . . . 233 Format . . . . . . . . . . . . . . 269
Format . . . . . . . . . . . . . . 234 Parameters . . . . . . . . . . . . . 269
Parameters . . . . . . . . . . . . . 234 Return and reason codes . . . . . . . . 271
Return and reason codes . . . . . . . . 245 Usage notes . . . . . . . . . . . . . 272
Usage notes . . . . . . . . . . . . . 247 Related services . . . . . . . . . . . 272
Related services . . . . . . . . . . . 247 R_PgmSignVer (IRRSPS00): Program Sign and
R_getgroups (IRRSGG00): Get/Set supplemental Verify . . . . . . . . . . . . . . . . 272
groups . . . . . . . . . . . . . . . 247 Function . . . . . . . . . . . . . . 272
Function . . . . . . . . . . . . . . 247 Requirements . . . . . . . . . . . . 273
Requirements . . . . . . . . . . . . 247 Linkage conventions . . . . . . . . . . 273
RACF authorization . . . . . . . . . . 248 RACF authorization . . . . . . . . . . 274
Format . . . . . . . . . . . . . . 248 Format . . . . . . . . . . . . . . 274
Parameters . . . . . . . . . . . . . 248 Parameters . . . . . . . . . . . . . 274
Return and reason codes . . . . . . . . 249 Return and reason codes . . . . . . . . 281
Usage note . . . . . . . . . . . . . 250 Usage notes . . . . . . . . . . . . . 286
Related services . . . . . . . . . . . 250 Related services . . . . . . . . . . . 289
R_getgroupsbyname (IRRSUG00): Get groups by R_PKIServ (IRRSPX00 or IRRSPX64): Request
name . . . . . . . . . . . . . . . . 250 public key infrastructure (PKI) services . . . . . 289
Function . . . . . . . . . . . . . . 250 Function . . . . . . . . . . . . . . 289
Requirements . . . . . . . . . . . . 250 Requirements . . . . . . . . . . . . 289
RACF authorization . . . . . . . . . . 250 Linkage conventions . . . . . . . . . . 289
Format . . . . . . . . . . . . . . 251 RACF authorization . . . . . . . . . . 289
Parameters . . . . . . . . . . . . . 251 Format . . . . . . . . . . . . . . 291
Return and reason codes . . . . . . . . 252 Parameters . . . . . . . . . . . . . 292
Usage notes . . . . . . . . . . . . . 252 Return and reason codes . . . . . . . . 332
Related services . . . . . . . . . . . 252 Usage notes . . . . . . . . . . . . . 338
R_GetInfo (IRRSGI00): Get security server fields 252 R_proxyserv (IRRSPY00): LDAP interface . . . . 343
Function . . . . . . . . . . . . . . 252 Function . . . . . . . . . . . . . . 343
Requirements . . . . . . . . . . . . 252 Requirements . . . . . . . . . . . . 344
Linkage conventions . . . . . . . . . . 253 Linkage conventions . . . . . . . . . . 344
RACF authorization . . . . . . . . . . 253 RACF authorization . . . . . . . . . . 344
Format . . . . . . . . . . . . . . 253 Format . . . . . . . . . . . . . . 345
Parameters . . . . . . . . . . . . . 254 Parameters . . . . . . . . . . . . . 345
Return and reason codes . . . . . . . . 256 Return and reason codes . . . . . . . . 349
Parameter usage . . . . . . . . . . . 257 Parameter usage . . . . . . . . . . . 351
Usage notes . . . . . . . . . . . . . 258 Usage notes . . . . . . . . . . . . . 351
R_IPC_ctl (IRRSCI00): Perform IPC control . . . 258 Related services . . . . . . . . . . . 352
Function . . . . . . . . . . . . . . 258 R_ptrace (IRRSPT00): Ptrace authority check . . . 352
Requirements . . . . . . . . . . . . 258 Function . . . . . . . . . . . . . . 352
RACF authorization . . . . . . . . . . 259 Requirements . . . . . . . . . . . . 352
Format . . . . . . . . . . . . . . 260 RACF authorization . . . . . . . . . . 352
Parameters . . . . . . . . . . . . . 260 Format . . . . . . . . . . . . . . 353
Return and reason codes . . . . . . . . 261 Parameters . . . . . . . . . . . . . 353
Usage notes . . . . . . . . . . . . . 261 Return and reason codes . . . . . . . . 353
Related services . . . . . . . . . . . 261 Usage notes . . . . . . . . . . . . . 354
R_kerbinfo (IRRSMK00): Retrieve or set security Related services . . . . . . . . . . . 354
server network authentication service fields . . . 262 | R_SecMgtOper (IRRSMO00): Security Management
Function . . . . . . . . . . . . . . 262 | Operations . . . . . . . . . . . . . . 354
Requirements . . . . . . . . . . . . 262 | Function . . . . . . . . . . . . . . 354
Linkage conventions . . . . . . . . . . 263 | Requirements . . . . . . . . . . . . 354
Format . . . . . . . . . . . . . . 263 | Linkage conventions . . . . . . . . . . 355
Parameters . . . . . . . . . . . . . 263 | RACF Authorization . . . . . . . . . . 355
Return and reason codes . . . . . . . . 266 | Format . . . . . . . . . . . . . . 356
Usage notes . . . . . . . . . . . . . 267 | Parameters . . . . . . . . . . . . . 356
Contents vii
Access list administration . . . . . . . . . 451 IBM Online Privacy Statement. . . . . . . . 466
SETROPTS administration . . . . . . . . . 452 Policy for unsupported hardware. . . . . . . 466
Minimum supported hardware . . . . . . . 466
Appendix C. Accessibility . . . . . . 459 Programming interface information . . . . . . 467
Accessibility features . . . . . . . . . . . 459 RSA Secure code . . . . . . . . . . . . 467
Consult assistive technologies . . . . . . . . 459 Trademarks . . . . . . . . . . . . . . 467
Keyboard navigation of the user interface . . . . 459
Dotted decimal syntax diagrams . . . . . . . 459 Index . . . . . . . . . . . . . . . 469
Notices . . . . . . . . . . . . . . 463
Terms and conditions for product documentation 465
Tables xiii
xiv z/OS Security Server RACF Callable Services
About this document
This document supports z/OS® (5650-ZOS) and contains information about the
Resource Access Control Facility (RACF®), which is part of z/OS Security Server.
Intended audience
This document is intended for system programmers who are familiar with RACF
concepts and terminology. They should also be familiar with MVS™ systems and
with z/OS UNIX.
To find the complete z/OS library, including the z/OS Knowledge Center, see the
z/OS Internet library (www.ibm.com/systems/z/os/zos/library/bkserv).
RACF courses
The following RACF classroom courses are available in the United States:
ES191 Basics of z/OS RACF Administration
BE870 Effective RACF Administration
ES885 Exploiting the Advanced Features of RACF
IBM® provides various educational offerings for RACF. For more information about
classroom courses and other offerings, do any of the following:
v See your IBM representative
v Call 1-800-IBM-TEACH (1-800-426-8322)
Important: If your comment regards a technical problem, see instead “If you have
a technical problem.”
v Send an email to [email protected].
v Send an email from the Contact z/OS web page (www.ibm.com/systems/z/os/
zos/webqs.html).
IBM or any other organizations use the personal information that you supply to
contact you only about the issues that you submit.
New
v A new callable service (R_SecMgtOper) has been added. See “R_SecMgtOper
(IRRSMO00): Security Management Operations” on page 354 for more
information.
v For R_usermap (IRRSIM00), “Function” on page 405, “RACF authorization” on
page 406, “Parameters” on page 406, “Return and reason codes” on page 408,
“Parameter usage” on page 409, “Usage notes” on page 410 are all updated to
provide mapping services from a user ID to an e-mail address and from an
e-mail address to a user ID.
v The update-user and the extract-user function in “User administration” on page
425 is updated to support the WAEMAIL field.
v The ICSF segment field has been updated to include the new segment field for
SCPRET. See “General resource administration” on page 439 for more
information
v The DFP segment field has been updated to include the new segment field for
DATAKEY. See “Data set administration” on page 448 for more information.
v The base segment field has been updated to include the new segment field for
WHENSMS. See “Access list administration” on page 451 for more information.
Changed
v New offsets have been added to R_Admin. See “R_admin (IRRSEQ00): RACF
administration API” on page 72.
v A new usage note for FIPS level support has been added to R_Gensec
(IRRSGS00 or IRRSGS64): Generic security API interface. See “Usage notes” on
page 247.
v The ticket_area parameter and the usage notes of R_Ticketserv (IRRSPK00):
Parse or extract have been updated to include FIPS level support. See
“Parameters” on page 398 and “Usage notes” on page 401.
v The reference documentation tables have a new column for SAF field name and
they have moved out of the chapter for the R_admin reference information now
that they apply to both R_admin and R_SecMgtOper. See Appendix B,
“Reference documentation tables,” on page 425 for more information.
New information
v R_Factor (IRRSFA64) has been updated to include new information about "get
policy data". See “R_factor (IRRSFA64): Authentication Factor Service” on page
220 for more information.
Changed information
Deleted information
New information
v A new callable service has been added to support Multi-factor Authentication
(MFA). For more information, see “R_factor (IRRSFA64): Authentication Factor
Service” on page 220.
v The update-user functions and extract-user functions have been updated to
support the new MFA fields in the BASE segment. See “User administration” on
page 425.
Changed information
v The initACEE callable service has been updated to support authentication of
Multi-factor Authentication (MFA). For more information, see “Function” on
page 39.
New information
v A new function code, ADMN_XTR_RRSF, was added to the “R_admin
(IRRSEQ00): RACF administration API” on page 72 callable service to extract
RRSF information.
v The following callable services have been updated for read-only auditor:
– “ck_access (IRRSKA00): Check access” on page 11
– “R_admin (IRRSEQ00): RACF administration API” on page 72
v Additionally “User administration” on page 425 of Appendix A, “R_admin
reference information,” on page 421is updated for ROAUDIT.
v File System Name in “Security credentials (CRED)” on page 2 has been updated.
Changed information
v The following topics in “R_admin (IRRSEQ00): RACF administration API” on
page 72 have been updated:
– “Function” on page 72
– “RACF authorization” on page 73
– “Function code values” on page 77
– “Reference documentation by function code” on page 78
– “Return and reason codes” on page 79
– “Usage notes” on page 81
v The “R_PKIServ (IRRSPX00 or IRRSPX64): Request public key infrastructure
(PKI) services” on page 289 callable service has been updated to benefit PKI
Services customers who need to have multiple administrators to approve the
issuance of a certificate. These updates affect the following topics:
– “Parameters” on page 292:
- The Table 127 on page 302 table
- The Table 129 on page 306 table
v File System Name in “Security credentials (CRED)” on page 2 has been updated.
v “RACF authorization” on page 12 in “ck_access (IRRSKA00): Check access” on
page 11 has been updated with additional information.
v The “R_datalib (IRRSDL00 or IRRSDL64): OCSF data library” on page 166
callable service has been updated to provide a programmable interface to
manage certificates and key rings in RACF through the R_datalib Callable
Service. These updates affect the following topics:
– The “RACF authorization” on page 166 for the DataPut function.
– The “Format” on page 177 for 64 bit invocation has been updated to eliminate
an extraneous '('.
For the mapping of the work area, see z/OS Security Server RACF Data Areas in the
z/OS Internet library (www.ibm.com/systems/z/os/zos/library/bkserv). For
information about IRRSXT00, see Chapter 3, “Installation exits,” on page 417.
The IFSP is a fixed-size 64-byte area. It is written to storage as part of the PFAR for
the file and its size cannot be changed.
The file system manages the storage for the IFSP. The makeFSP service fills in the
data, and other callable services use or modify the data in the area provided by the
file system.
The IFSP data can be examined by users other than the security product. The IFSP
is mapped by macro IRRPIFSP. Others should not use this mapping to create or
directly modify the IFSP, and should not make their own security or audit
decisions based on the contents of the IFSP.
For the mapping of the file security packet, see z/OS Security Server RACF Data
Areas in the z/OS Internet library (www.ibm.com/systems/z/os/zos/library/
bkserv).
The CRED is built by the LFS, and is created for each system call entry to the LFS.
The CRED is used for all vm_ops called (and most RACF callable service calls by
the PFS) for the system call. The CRED is not kept across multiple LFS system
calls.
For the mapping of the CRED, see z/OS Security Server RACF Data Areas in the
z/OS Internet library (www.ibm.com/systems/z/os/zos/library/bkserv).
File identifiers
Programming Interface Information
Part of the audit data for file access is a file identifier. The file identifier is a
16-byte token that uniquely identifies a file while it is mounted on the system.
>If the file system is unmounted and remounted, that file identifier may change. A
change in file identifiers can be detected in the audit trail by matching the mount
audit records with the same file system name and comparing the file identifiers for
the root directory.
A mode value is input to z/OS UNIX chmod, open, creat, mkdir, and umask, and
output by z/OS UNIX stat and fstat. The mode value is defined as a mode_t data
type and consists of a one-byte file type and three bytes for the file modes. The file
mode specifies the permission bits and the S_ISUID, S_ISGID, and S_ISVTX bits for
a file.
The z/OS UNIX macro BPXYMODE defines the mode_t values as:
v Bits 0–7: file type, mapped by z/OS UNIX macro BPXYFTYP
v Bits 8–13: reserved
v Bits 14–31: available to the security product:
– Bits 14–19: reserved
The system call services pass the mode parameter from the caller of the system call
to the RACF callable service or from the RACF callable service to the caller of the
system call. The system call service can change the file type but does not change
the file mode bits.
Some RACF callable services test the file type to determine if the file is a directory.
The makeFSP service sets the file type to “directory” if the file is a directory and
sets it to zero otherwise.
The IPC security packet (IISP) contains data needed to make security decisions. It
is built when a new ID for an IPC key is created and is saved in memory by the
kernel. The IISP is used in place of a profile in the RACF database to contain
information about the IPC key's owner and access rights.
The ck_IPC_access service determines whether the current process has the
requested access to an IPC key. The IISP of the key is passed with this request. The
ck_IPC_access service is called separately for each IPC key.
For the z/OS UNIX IPC_SET command, the R_IPC_ctl service modifies the
owner's UID, owner's GID, and mode bits in the IISP for the IPC key if the
authority is correct. For the z/OS UNIX IPC_RMID command, the R_IPC_ctl
service checks the authority of the current process to determine whether the
resource can be removed.
The IISP consists of two parts, the root and the extension. The root is mapped by
macro IRRPIISP. The root contains a pointer to the extension, which is mapped by
the z/OS UNIX mapping macro BPXYIPCP. Other products can read the IISP for
reporting purposes using the IRRPIISP and BPXYIPCP mapping macros.
For the mapping of the IPC security packet, see z/OS Security Server RACF Data
Areas in the z/OS Internet library (www.ibm.com/systems/z/os/zos/library/
bkserv).
The CREI is built by the kernel, and is created for each system call entry to RACF.
For the mapping of the CREI, see z/OS Security Server RACF Data Areas in the
z/OS Internet library (www.ibm.com/systems/z/os/zos/library/bkserv).
Note: In a server environment, work can be processed for more than one user in
an address space. Callable services marked for use by z/OS UNIX servers provide
task-level support for server applications. Callable services marked as having
support for task-level processes use task-level support when z/OS UNIX has
indicated in the task's ACEE that this is a task-level process. All other callable
services assume that there is only one user per address space and provide only
address-space-level support.
Function
The ck_access service determines whether the current process has the requested
access to the element (directory or file) of a pathname whose IFSP, and ACL if it
exists, is passed. It is called separately for each element.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user or any task if system user type is specified
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. If the audit function code in the CRED is access, the real z/OS UNIX user
identifier (UID) and z/OS UNIX group identifier (GID) of the calling process
are used on the authority checks. Otherwise, the effective UID and GID for
the calling process are used.
2. If the calling user has either auditor or read-only auditor authority and the
access requested is search, or the access requested is read for a directory,
access is allowed. Security label checking is bypassed in this case. This lets an
auditor set the auditor audit options on any file without requiring that the
auditor be given search access rights to all directories.
3. If the CRED user type is system, IRRSKA00 allows any access except when
the requested access is execute and no execute permission bits are set for the
file. No UIDs are used in this case, because no process exists. If the user is not
system, the security label is checked and the security label authorization
checking will be performed. If the SECLABEL class is active, and both a
system CRED and a directory FSP are received, and the system CRED
contains a security label, the access request will fail with a security label
failure if the directory's SECLABEL is not SYSMULTI. No other security label
authorization checking is done when a system CRED is passed. No security
label checking is performed for a system CRED, with the exception that if the
SECLABEL class is active, and both a system CRED and a directory FSP are
received, and the system CRED contains a security label, the access request
will fail with a security label failure if the directory's SECLABEL is not
SYSMULTI.
4. If the user does not have either the RACF AUDITOR or ROAUDIT
(Read-Only Auditor) attribute, and a file system name was specified in the
CRED, and the FSACCESS class is active and RACLISTed, RACF will check
for a profile in the FSACCESS class that covers the file system name. If a
matching profile is found and the user does not have at least UPDATE
authority, access is denied. Otherwise, authorization is determined by
subsequent checks.
5. For a file execution request, if a file system name was specified in the CRED
and the FSEXEC class is active and RACLISTed, RACF will check for a profile
in the FSEXEC class that covers the file system name. If a matching profile is
found and the user does not have at least UPDATE authority, access is denied.
Otherwise, authorization is determined by subsequent checks.
6. If the SECLABEL class is active, security label checking is performed for any
file or directory with a security label. The security label of the process will be
evaluated by ck_access against the security label in the FSP of the object being
accessed, according to the hierarchical security model used for mandatory
access control. If MLFSOBJ is active, a failure will occur if the file or directory
does not have a security label, unless the CRED contains a security label in
the ROSeclabel field. This value is used to pass the resource security label for
read-only file systems.
7. If the caller is not a superuser, the permission bits did not allow the requested
access, and the audit function code is listed in Table 2 on page 13, an
authorization check is performed on the corresponding resource in the
UNIXPRIV class. If the authorization check is successful, the caller is treated
as a superuser.
If Table 2 does not result in a UNIXPRIV authorization check, the caller is not
a superuser, the permission bits did not allow the requested access, the file is
a directory, and requested access is search, a read authorization check is
performed on the SUPERUSER.FILESYS.DIRSRCH resource in the UNIXPRIV
class. If the authorization check is successful, the caller is treated as a
8. If the user being checked is a superuser, IRRSKA00 allows any access except
when the requested access is execute and no execute permission bits are set
for the file. The user is considered a superuser if the selected UID is 0 or if the
ACEE indicates trusted or privileged authority. The superuser that has UID 0
will not automatically pass the security label check, however, the trusted or
privileged will.
9. If the user is not system and is not a superuser, the permission bits and ACL
(if one exists, and if the FSSEC class is active) for the file are checked to see if
the access requested is allowed. If the selected UID matches the owner UID of
the file, the owner permission bits are checked. If the UIDs don't match, the
user ACL entries are checked. If the selected UID matches an ACL entry, the
ACL entry bits are checked. If a matching ACL entry was not found for the
user, the group bits and the group ACL entries are checked. The selected GID
and supplemental GID are checked against the file owner GID and the group
ACL entries, until a match is found which grants the requested access, or until
all the GIDs have been checked. If no match was found, the other permission
bits are checked, unless the user has the RESTRICTED attribute, the
UNIXPRIV class is active, the resource named RESTRICTED.FILESYS.ACCESS
is protected, and the user does not have at least READ access.
10. If the real, effective, and saved UID are the same, and if the real, effective, and
saved GID are the same, UNIXPRIV will be checked for AFC_ACCESS.
11. For a detailed list of authorization steps for z/OS UNIX files and directories,
see Appendix F, in the z/OS Security Server RACF Security Administrator's
Guide.
Format
CALL IRRSKA00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Requested_access_code,
ALET, FSP,
ALET, File_identifier,
ALET, CRED,
ALET, Name_flag
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Requested_access_code
The name of a 1-byte field containing the requested access. The defined codes
are:
X'00' no access
X'01' Execute access
X'02' Write access
X'03' Write and execute access
X'04' Read access
X'05' Read and execute access
X'06' Read and write access
X'07' Read, write, and execute access
X'81' Search access (against a directory)
X'87' Any access
FSP
The name of the IFSP for the file being accessed.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See the
z/OS Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv). The CRED contains a
pointer to the ACL, if one exists.
Name_flag
The name of a byte indicating which pathname and file name is being checked.
The byte contains one of these values:
0 Use the CRED_name_flag to determine pathname being checked.
1 The old (or only) name is being checked.
2 The new name is being checked.
SAF return code RACF return code RACF reason code Explanation
0 0 0 The service was
successful.
4 0 0 RACF is not
installed.
8 8 4 The user is not
authorized to access
the file.
8 8 32 The CRED user type
is not supported.
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. The access checks performed are POSIX file permission checks defined in
POSIX 1003.1.
3. If the audit function code in the CRED is access or eaccess, no audit record is
written. Access checking only tests whether a process would have access if it
were running with its real UID. Eaccess checking only tests whether a process
would have access with its effective UID. Neither gives access to the file.
4. If the calling syscall is not access (for real or effective UID), an audit record is
optionally written, depending on the audit options in effect for the system.
5. The caller must pass in the address of the object's access ACL in the CredAclPtr
field.
Related services
R_chmod, R_chown, R_setfacl
Function
The ck_file_owner service checks whether the calling process is a superuser or is
the owner of the file represented by the input.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. The ck_file_owner service checks whether the calling process is a superuser.
2. The ck_file_owner service checks whether the calling process is the owner of
the file represented by the input IFSP. A process is the owner of a file if the
effective UID of the process is equal to the file's owner UID.
3. If the SECLABEL class is active and the file or directory has a security label,
then the current security label of the process must be greater than or equal to
the security label of the resource or the security label of the resource must be
greater than or equal to the current security label of the process, that is, the
security labels are not disjoint. If MLFSOBJ is active, a failure will occur if the
resource does not have a security label. Security label checking is bypassed if
the ACEE indicates trusted or privileged authority or if the service is passed a
system CRED.
Format
CALL IRRSKF00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, FSP,
ALET, File_identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space. ALETs
must be passed for all parameters except the work area. The words containing
the ALETs must be in the primary address space.
SAF_return_code
The name of a full word in which the SAF router returns the SAF return code.
RACF_return_code
The name of a full word in which the service routine stores the return code.
RACF_reason_code
The name of a full word in which the service routine stores the reason code.
FSP
The name of the IFSP for the file to be checked.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
None
Function
The ck_IPC_access service determines whether the current process has the
requested access to the interprocess communication (IPC) key or identifier whose
IPC security packet (IISP) is passed.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user/any task if system user type is specified
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
None
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. The access checks performed are XPG4 IPC permission checks defined in XPG4
System Interfaces and Headers, as follows:
v The effective z/OS UNIX user identifier (UID) and z/OS UNIX group
identifier (GID) for the calling process is used for all access checks.
v If the CREI user type is system, IRRSKI00 allows any access. No UIDs or
GIDs are used in this case because no process exists.
v If the user being checked is a superuser, IRRSKI00 allows any access. The
user is considered a superuser if the selected UID is 0 or if the ACEE
indicates trusted or privileged authority.
v If the user is not system and is not a superuser, the permission bits for the
IPC key are checked to see if the access requested is allowed. If the effective
UID matches either the owner UID or creator's UID of the IPC key, the USER
permission bits are checked. If the UIDs do not match, the owner GID and
creator's GID of the IPC key are checked against the user's effective GID and
the user's supplemental group list GIDs. If any one matches, the GROUP
permission bits are checked. If the UIDs and GIDs don't match, the OTHER
permission bits are checked.
v If the SECLABEL class is active and the ISP contains a security label, the
accessing process must have an equivalent security label. With MLIPCOBJ
active, requests will be failed if either the accessing process or the ISP does
not contain a security label.
Format
CALL IRRSKI00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Requested_access_code,
ALET, ISP,
ALET, CREDIPC
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Requested_access_code
The name of a one-byte field containing the requested access. The defined
codes are:
X'00' No access
X'02' Write access (or alter access)
X'04' Read access
X'06' Read and write access
ISP
The name of the IISP for the key being accessed.
CREDIPC
The name of the CREI structure for the current IPC system callable service. Use
the CREI to determine the IPC identifier and IPC key being used. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended for use only by the MVS BCP.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
If the audit function code in the CREDIPC is AFC_WGETIPC, no audit record
is written.
3. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
makeISP, R_IPC_ctl
Function
The ck_owner_two_files service checks whether the calling process is a superuser
or is the owner of either of the file/directory, or directory/directory entry pair
represented by input values FSP1 and FSP2.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. A process is the owner of the file if the process's effective OS/390® UNIX user
identifier (UID) is equal to the file's owner UID.
2. If the caller is not superuser nor the owner, and the audit function code is
listed in Table 3, an authorization check is performed on the corresponding
resource name in the UNIXPRIV class. If the authorization check is successful,
the caller is treated as a superuser.
Table 3. UNIXPRIV class resource names used in ck_owner_two_files
Audit function code Resource name Access required
RENAME, RMDIR, UNLINK SUPERUSER.FILESYS CONTROL
3. If the SECLABEL class is active and the file or directory has a security label,
then the current security label of the process must be greater than or equal to
the security label of the resource or the security label of the resource must be
greater than or equal to the process's current security label, that is, the security
labels are not disjoint. If MLFSOBJ is active, a failure will occur if the resource
does not have a security label. Security label checking is bypassed if the ACEE
indicates trusted or privileged authority or if the service is passed a system
CRED.
Format
CALL IRRSC200 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, FSP1,
ALET, FSP2,
ALET, File_identifier_1,
ALET, File_identifier_2,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
FSP1
The name of the IFSP for the first file, directory, or directory entry to be
checked. If FSP1 is a file, FSP2 must be a directory. If FSP1 is a directory entry,
FSP2 must be a directory.
FSP2
The name of the IFSP for the second file, directory, or directory to be checked.
If FSP2 is a file, FSP1 must be a directory. If FSP2 is a directory entry, FSP1
must be a directory.
File_identifier_1
The name of a 16-byte area containing a unique identifier of the first file to be
checked.
File_identifier_2
The name of a 16-byte area containing a unique identifier of the second file to
be checked.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
None
Function
The ck_priv service checks whether the calling process is a superuser.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. A superuser is a user whose process has an effective UID of 0 or has RACF
trusted or privileged authority.
2. If the caller is not superuser and the audit function code is listed in Table 4, an
authorization check is performed on the corresponding resource name in the
UNIXPRIV class. If the authorization check is successful, the caller is treated as
a superuser.
Table 4. UNIXPRIV class resource names used in ck_priv
Audit function code Resource name Access required
MOUNT(nosetuid), SUPERUSER.FILESYS.MOUNT READ
MOUNT_NA (nosetuid),
UNMOUNT(nosetuid),
CHMOUNT(nosetuid)
MOUNT_U, MOUNT_UNA SUPERUSER.FILESYS.USERMOUNT READ
UNMOUNT_U
UNMOUNT_UNA
MOUNTSETUID, SUPERUSER.FILESYS.MOUNT UPDATE
UNMOUNTSETU,
CHMOUNT(setuid)
Format
CALL IRRSKP00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Audit_function_code
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Audit_function_code
The name of a fullword containing a function code identifying the system call
function being processed. See z/OS Security Server RACF Data Areas in the z/OS
Internet library (www.ibm.com/systems/z/os/zos/library/bkserv) for a list of
the defined codes.
Usage notes
1. This service is intended for use only by the MVS BCP, a z/OS UNIX file
system, and by z/OS UNIX servers. The service contains support for z/OS
UNIX servers, but cannot be directly invoked by a z/OS UNIX server.
2. An audit record is written.
Related services
None
Function
The ck_process_owner service checks whether the calling process is the owner of
the target process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. For request types 2, 3, and 4, IRRSKO00 checks whether the caller has
superuser authority or is the owner of the target process, and returns a return
and reason code indicating the result. For request type 5, if the SECLABEL class
is active, IRRSKO00 also checks if the caller's security label is equivalent to the
security label of the target process, unless the ACEE indicates trusted or
privileged authority.
2. The caller is an owner of a process if either the real or effective z/OS UNIX
user identifier (UID) of the calling process is equal to either the real or saved
UID passed in the Target_process_UIDs parameter area.
3. If the caller is not superuser nor the process owner, and the request type is
listed in Table 5, an authorization check is performed on the corresponding
resource name in the UNIXPRIV class. If the authorization check is successful,
the caller is treated as a superuser.
Table 5. UNIXPRIV class resource names used in ck_process_owner
Request type Resource name Access required
2, 5 SUPERUSER.PROCESS.KILL READ
3 SUPERUSER.PROCESS.GETPSENT READ
Format
CALL IRRSKO00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Request_type,
ALET, Target_process_UIDs,
ALET, Target_PID,
ALET, Signal_code
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Request_type
The address of a byte containing a request type. The defined types are:
v 1 - audit-only request from kill. It is used when a SIGCONT signal is being
sent to a process in the same session as the signalling process.
v 2 - kill request
v 3 - getpsent request
v 4 - open_tty request
v 5 - sigqueue request
Target_process_UIDs
For request types 1 through 4, the address of a 3-word area containing the real,
effective, and saved z/OS UNIX user identifiers (UIDs) (in that order) for the
target process . For request type 5, the address of a 5-word area containing the
real, effective, and saved z/OS UNIX user identifiers, and the 8-byte security
label for the target process.
Target_PID
The name of a fullword containing the PID of the target process.
Signal_code
The address of a word containing a code that identifies the type of signal being
sent. This code is used only for auditing. The signal code values are defined in
the z/OS UNIX macro BPXYSIGH. This parameter is ignored for request type
3.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
If the request type is 3 for getpsent, then PROCACT class auditing for SETR
LOGOPTIONS(FAILURES) and LOGOPTIONS(SUCCESSES) will be ignored.
Use LOGOPTIONS(ALWAYS), if auditing is required, however, this may result
in an excessive amount of auditing.
3. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
None
Function
The clear_setid service clears the S_ISUID, S_ISGID, and S_ISVTX bits for the file
passed as input.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSCS00 (Work_area,
ALET,SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, FSP,
ALET, File_identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
FSP
The name of the IFSP in which the S_ISUID, S_ISGID, and S_ISVTX bits are to
be cleared.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by an z/OS UNIX System Services file
system and by z/OS UNIX System Services servers. The service contains
support for z/OS UNIX System Services servers, but cannot be directly invoked
by an z/OS UNIX System Services server.
2. The caller is responsible for preserving the updated IFSP.
3. If either bit was on, an audit record is optionally written.
Related services
R_chmod, R_exec
Function
The deleteUSP service deletes the security environment for the calling process. The
caller can continue as an MVS user, but is no longer an z/OS UNIX process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSDU00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Usage notes
1. This service is intended only for use by the MVS BCP and by z/OS UNIX
System Services servers. This service can be directly invoked by an z/OS UNIX
System Services server.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
initUSP
Function
The getGMAP service returns the z/OS UNIX group identifier (GID) or group
name corresponding to the input group name or GID, based on the setting of an
input lookup flag.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSGM00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Flag,
ALET, GID,
ALET, group_name
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Flag
The name of a word containing the lookup option:
X'00000000'
search by z/OS UNIX group identifier (GID), return group name
X'00000001'
search by group name, return GID
X'00000002'
search by group name, return z/OS UNIX group identifier (GID), but
do not create a new GID even if BPX.UNIQUE.USER is defined.
GID
The name of a fullword for a z/OS UNIX group identifier (GID). The GID is
either input or output in this word, depending on the flag parameter.
Group_name
The name of an 8-byte area for the group name. The group name is
left-justified and padded with blanks and is either input or output in the area,
depending on the flag parameter.
Usage notes
v This service is intended only for use by the MVS BCP.
v If getGMAP is given a group name and flag X'00000001' as input, and the
corresponding GROUP profile has no OMVS segment, getGMAP checks for the
existence of the FACILITY class profile BPX.UNIQUE.USER and, if the
corresponding FACILITY class profile BPX.NEXT.USER defines a valid GID
value or range, the service generates and returns a unique GID. The new GID is
saved in the group profile.
getGmap generates an SMF type 80 record (event 88) when a new GID is
assigned and SETROPTS AUDIT(GROUP) is in effect.
v Check if any logrec entry has been created to ensure getGMAP service was
being run successfully. Refer to z/OS Security Server RACF Diagnosis Guide for
detailed logrec information.
Related services
None
Function
The get_uid_gid_supgrps service gets the real, effective, and saved z/OS UNIX
user identifiers (UIDs) and z/OS UNIX group identifiers (GIDs), and the
supplemental groups from the USP.
Because the size of the supplemental group list varies, IRRSGE00 checks the input
group count before putting supplemental GIDs in the grouplist area. See
Group_count under “Parameters” on page 34 for more information.
The GIDs are not explicitly added to or deleted from the supplemental group list.
A GID is in this list if the user was a member of the group when the user's ACEE
was created through a RACROUTE REQUEST=VERIFY request and if the GID was
assigned to the group before the initUSP service was performed for the process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSGE00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, RACF_work_area,
ALET, User_key,
ALET, Group_count,
ALET, Grouplist,
ALET, Number_of_GIDs,
ALET, Output_UIDs,
ALET, Output_GIDs
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
RACF_work_area
The name of a 1024-byte work area for RACF use.
User_key
The name of a byte containing the user's key. This key is used to store into the
output grouplist area. The key is in the four high-order bits of the byte.
Group_count
The name of a word containing the number of z/OS UNIX group identifier
(GID) entries that can be stored in the Grouplist area. If Group_count is:
1. 0, the Grouplist area is not used. IRRSGE00 returns the total supplemental
GID count of the current process in the Number_of_GIDs parameter.
2. Less than the total supplemental GID count:
a. An error code is returned.
b. The GIDs of the supplemental groups for the current process are put
into the Grouplist area, which can only accommodate the number of
GIDs specified in the Group_count parameter.
c. The count of the supplemental GIDs actually placed in the Grouplist area
is returned in the Number_of_GIDs parameter.
d. The Group_count field is set to the total supplemental GID count of the
current process.
The supplemental groups in the Grouplist area are listed in the same
order as the group connections shown in the output of the LISTUSER
command.
3. Greater than or equal to the total supplemental z/OS UNIX group
identifier (GID) count:
a. The GIDs of the supplemental groups for the current process are put
into the Grouplist area.
b. The supplemental GID count of the current process is put into the
Number_of_GIDs parameter.
Grouplist
The name of an area in which the GIDs of the supplemental groups for a
process are returned. The Group_count parameter indicates the number of
entries this area can contain. The GIDs are returned as consecutive 4-byte
entries.
Number_of_GIDs
The name of a word in which the number of GIDs put in the Grouplist area is
returned.
Output_UIDs
The name of a 3-word area in which, respectively, the real, effective, and saved
z/OS UNIX user identifiers (UIDs) are returned.
Output_GIDs
The name of a 3-word area in which, respectively, the real, effective, and saved
z/OS UNIX group identifiers (GIDs) are returned.
Usage notes
v This service is intended only for use by z/OS UNIX. The service which executes
in the primary address space contains support that accesses the home address
space task control block and address space control block for the requested data.
v In order to support multiple processes in one address space, this function needs
to return the requested data from either the task control area or the address
space control area. The task control area is accessed before the address space
control area.
Related services
None.
Function
The getUMAP service returns the z/OS UNIX user identifier (UID) or user ID
corresponding to the input user ID or UID, based on the setting of an input lookup
flag.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSUM00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Flag,
ALET, UID,
ALET, Userid
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Flag
The name of a word containing the lookup option:
X'00000000'
search by z/OS UNIX user identifier (UID), return user ID
X'00000001'
search by user ID, return z/OS UNIX user identifier (UID)
X'00000002'
search by user ID, return z/OS UNIX user identifier (UID), but do not
create a new UID even if BPX.UNIQUE.USER is defined.
UID
The name of a fullword for a z/OS UNIX user identifier (UID). The UID is
either input or output in this word, depending on the flag parameter.
Userid
The name of an 8-byte area for the user ID. The user ID is left-justified and
padded with blanks, and is either input or output in the area depending on the
flag parameter.
Usage notes
v This service is intended only for use by the MVS BCP.
v If getUMAP is given a user ID and flag X'00000001' as input, and the
corresponding USER profile has no OMVS segment, getUMAP checks for the
existence of the FACILITY class profile BPX.UNIQUE.USER and, if the
corresponding FACILITY class profile BPX.NEXT.USER defines a valid UID
value or range, the service generates and returns a unique UID. The new UID is
saved in the user profile, along with any OMVS field information copied from
the profile of a user if specified in the application data field of the
BPX.UNIQUE.USER profile.
getUmap generates an SMF type 80 record (event 88) when a new UID is
assigned and SETROPTS AUDIT(USER) is in effect.
v Check if any logrec entry has been created to ensure getUMAP service was
being run successfully. Refer to z/OS Security Server RACF Diagnosis Guide for
detailed logrec information.
Related services
None.
Function
The initACEE service provides an interface for creating and managing RACF
security contexts through the z/OS UNIX System Services pthread_security_np
service, __login service, or by other MVS server address spaces that do not use
z/OS UNIX services. This service also provides an interface for registering and
deregistering certificates through the z/OS UNIX System Services __security
service. It also provides an interface for querying a certificate to determine if it is
associated with a user ID.
When initACEE calls RACINIT to create an ACEE for an MFA user, a new bit in
the ACEE will be set to indicate that the user was authenticated with MFA.
InitACEE will not copy an MFA authenticated ACEE in the managed cache. This
will cause initACEE to call RACINIT and perform MFA authentication on
subsequent initACEE calls for the same user. RACINIT may still use its VLF cache
for MFA authenticated users when called by initACEE.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the last word in the parameter list
must have a 1 in the high-order (sign) bit.
RACF authorization
1. If the function_code indicates that a certificate is to be registered or
deregistered, initACEE will perform the following authority checks:
v To register a certificate with the current user ID, the caller must be RACF
SPECIAL or have at least READ authority to the IRR.DIGTCERT.ADD
resource in the FACILITY class.
v To deregister a certificate with the current user ID, the caller must be RACF
SPECIAL or have at least READ authority to the IRR.DIGTCERT.DELETE
resource in the FACILITY class.
v To register a certificate as a CERTAUTH certificate, the caller must be RACF
SPECIAL or have at least CONTROL authority to the IRR.DIGTCERT.ADD
resource in the FACILITY class.
2. If the function_code indicates that an ACEE is to be created or a certificate is to
be queried and the service determines that the user ID to use is specified in the
hostIdMappings extension of the input certificate, the caller's authority to the
IRR.HOST.(host-name) resource in the SERVAUTH class is checked. (The value
for host-name is specified in the hostIdMappings extension.) The resource must
exist and the caller must have READ authority to it, otherwise the extension is
ignored.
Note: To determine the caller, the current TCB is checked for an ACEE. If one is
found, the authority of that user is checked. If there is no ACEE associated with
the current TCB, the ACEE associated with the address space is used to locate the
user ID.
Format
CALL IRRSIA00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_code,
Attributes,
RACF_userid,
ACEE_ptr,
APPL_id,
Password,
Logstring,
Certificate,
ENVR_in,
ENVR_out,
Output_area,
X500 name,
Variable_list,
Security_label,
SERVAUTH_name,
Password_phrase,
IDID_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
ALET can be different. The words containing the ALETs must be in the
primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area containing the function code.
X'01' Create an ACEE.
X'02' Delete an ACEE.
X'03' Purge all managed ACEEs.
X'04' Register a certificate
X'05' Deregister a certificate
X'06' Query a certificate
Attributes
The name of a 4-byte area containing information about the function to be
performed. Zero or more attributes can be set. (See Table 7 on page 45 for the
values allowed for the Attributes parameter.)
RACF_userid
The name of a 9-byte area that consists of a 1-byte length field followed by up
to 8 characters. It must be specified in uppercase. If not specified, the length
must equal 0.
ACEE_ptr
The name of a 4-byte area that contains the ACEE address.
APPL_id
The name of a 9-byte area that consists of a 1-byte length field followed by the
name of the application to be used if verifying the user's authority to access
the application. This saves the application from having to do a separate
authorization check. When using certificate mapping profiles, the application
name is also used as part of the additional criteria in determining a user ID
when a certificate is passed to initACEE. It must be specified in uppercase. If
not specified, the length must equal zero.
Password
The name of a 9-byte area that consists of a 1-byte length field followed by the
password or PassTicket provided by the user. If not specified, the length must
equal zero.
Logstring
The name of an area that consists of a 1-byte length field followed by character
data to be written to the system-management-facilities (SMF) data set, together
with any RACF audit information, if logged. If not specified, the length must
equal zero.
Certificate
The name of an area that consists of a 4-byte length field followed by a digital
certificate. If not specified, the length must equal 0; or the end of the parameter
list must be indicated by the setting of the high order bit in the address of the
previous parameter. The certificate must be a single DER encoded X.509
certificate. For the registration and deregistration functions, PKCS #7, PEM, or
Base64 encoded certificates are also allowed.
ENVR_in
The name of the data structure that contains the information necessary to
re-create a security environment. The data structure must have the format
shown in Table 8 on page 46. See the ENVR_out parameter for additional
information about this data structure and the ENVR object to which it points.
The structure must reside on a doubleword boundary.
While the format of the data structure pointed to by ENVR_in is known to the
initACEE invokers, the content of the object itself is determined by the external
security product.
The input for this parameter can be the output from a previous initACEE with
the ENVR_out parameter specified, or from RACROUTE REQUEST=VERIFY or
REQUEST=EXTRACT, with the ENVROUT parameter specified.
If ENVR_in is not specified, the ENVR object length must equal 0, or the end
of the parameter list must be indicated by the setting of the high order bit in
the address of a previous parameter. ENVR_in should not be specified when
requesting that an ENVR object be returned (INTA_ENVR_RET).
For more information about the ENVR data structure, see z/OS Security Server
RACROUTE Macro Reference.
ENVR_out
The name of the data structure to contain the security environment that was
just created. The data structure must have the format shown in Table 8 on page
46. This data structure describes the storage location for the ENVR object that
is created as part of this initACEE create request.
While the format of the data structure pointed to by ENVR_out itself is known
to the initACEE invokers, the content of the object itself is determined by the
external security product.
The ENVR object storage area can be supplied by the caller or obtained by
RACF. If supplied by the caller, it must be on a doubleword boundary and be
associated with the job step task. If RACF obtains the storage area, it is on a
doubleword boundary and is associated with the job step task. The storage is
allocated based on the mode of the caller (LOC=ANY for 31-bit callers and
LOC=24 for 24-bit callers).
Storage for the ENVR object is obtained and freed in the subpool and key
specified by the caller in the ENVR_out data structure. For additional details
on specifying the ENVR object storage area length and address, see Table 9 on
page 46.
Since the ENVR object length is returned to the caller, the ENVR object can be
moved from one storage area to another. It is intended for use on subsequent
initACEEs with the ENVR_in parameter, or on RACROUTE
REQUEST=VERIFY with the ENVRIN parameter, as input when rebuilding a
user's security environment. It should not be saved for a long period or passed
to another system that does not share the same RACF database.
If the Attributes parameter indicates that an ENVR object should be returned
(INTA_ENVR_RET), then this parameter must be specified with at a minimum
the values for the subpool and key fields.
For more information about the ENVR data structure, see z/OS Security Server
RACROUTE Macro Reference.
Output_area
The name of a fullword in which the service routine stores the address of an
area containing data about the user. The output area is obtained in the primary
address space, in subpool 229, and must be freed by the caller of initACEE.
The following data is returned; the area returned is mapped by macro
IRRPOUSP (OUSP):
v TSO user ID
v z/OS UNIX user identifier (UID) of user
v z/OS UNIX group identifier (GID) of current group
v Home directory path name
v Initial program path name
v User limits (when OUSP version is greater than 0)
If the Attributes parameter indicates that an OUSP should be returned
(INTA_USP and INTA_OUSP_RET), then this parameter must be specified. If
the Attributes do not indicate that an OUSP should be returned, then the
fullword must equal 0, or the end of the parameter list must be indicated by
the setting of the high order bit in the address of a previous parameter.
X500name
The name of a fullword in which the service routine stores the address of the
X500 name pair data structure if the function code indicates a certificate is
being queried, and the attributes indicate that an X500 name pair should be
returned. The X500 name pair data structure is obtained in the primary address
space, in subpool 229, and must be freed by the caller of initACEE.
If the function code indicates that an ACEE is to be created, and the
RACF_userid parameter is specified, X500name can supply the name of a
fullword containing the address of the X500 name pair to be associated with
the ACEE. The X500 name pair should previously have been obtained, along
with the RACF user ID, by querying a certificate using initACEE. Both the
issuer's name and subject's name must be supplied, and the length of each
must be in the range 1 to 255 to prevent a parameter list error. If a valid X500
name pair is supplied, the ACEE created will point to a copy of the name pair,
and it will subsequently be used in auditing.
Variable_list
The name of the data structure that contains the additional criteria to be used
to determine the user ID associated with the certificate supplied to initACEE.
The variable list data structure is a 4-byte number of value entries, followed by
that number of entries. Each value entry consists of an 8-byte value name, a
4-byte value length, and the value. The value name must be padded on the
right with blanks if it is less than 8-bytes. The value length must be in the
range of 1 to 255. If it is outside of this range, a parameter list error will result.
A maximum of 10 values may be specified. If the number of values is greater
than 10, a parameter list error will result.
Variable names should be meaningful to the caller of initACEE. Making the 3
character prefix associated with the product calling initACEE part of the
variable name will ensure that it is unique. For example, assume RACF
implemented a server that calls initACEE for its clients. It will pass a variable,
IRRSLVL, which has 2 values. The values are LOW and HIGH. LOW is if the
user is accessing the server from the internet and HIGH is if the user is
accessing the server from the intranet. The variable_list containing the variable
name and its value, LOW or HIGH, is passed to initACEE, along with the
certificate supplied by the user. The value of the variable will be used as
additional criteria in selecting which user ID the certificate maps to. All callers
of initACEE should document their variable names, and the values they pass
for each name, in their product documentation.
All value names and values should be uppercase. Do not specify the APPLID
or SYSID criteria values in the variable_list. These are determined from the
APPL_id parameter and MVS control; blocks, respectively. If they are specified
in the variable_list, that specification will be ignored.
This parameter is ignored unless the certificate parameter is specified, and the
function code indicates that an ACEE is to be created, or that the certificate is
to be queried to find a user ID. If the certificate is defined to RACF in the
DIGTCERT class, additional criteria will not be used, and the variable_list
values will be ignored. If the certificate is not defined in the DIGTCERT class,
the values in the variable list will be used along with APPL_id and SYSID to
look for an associated user ID using the DIGTNMAP and DIGTCRIT classes if
these classes are active and have been RACLISTed with SETROPTS.
Security_label
The name of a 9-byte area that consists of a 1-byte length field followed by the
name of the security label that defines the security classification of the
environment to be created. It must be specified in uppercase. If not specified,
the length must be zero.
SERVAUTH_name
The name of an area that consists of a 1-byte length field followed by the name
of a resource in the SERVAUTH class to be used if verifying the user's
authority to access this server. This resource is the network access security
zone name that contains the IP address of the user. It must be specified in
uppercase, and cannot exceed 64 bytes in length. If not specified, the length
must be zero.
Password_phrase
The name of an area that consists of a 1-byte length field followed by the
password phrase provided by the user. If the length is not specified, it must
equal zero. If the length is specified, the length field must be 9-100 characters
to prevent a parameter list error.
IDID_area
The name of a fullword containing the address of a distributed identity data
structure (IDID). If the function code parameter indicates that an ACEE is to be
created, no user ID parameter is specified, and the IDIDMAP class is active
and RACLISTed, information in the IDID is used to determine a RACF user ID.
If the IDIDMAP class is inactive or the information in the IDID does not map
to a RACF user ID, the initACEE service will fail. If a RACF_userid parameter
is specified on the initACEE call, the IDID_area parameter can supply the
name of an IDID to be associated with the ACEE; the IDIDMAP class is not
used. When the IDID_area parameter is specified, the distributed identity
information in the IDID should have been previously authenticated. If an IDID
is supplied and an ACEE is successfully created, the ACEE will point to a copy
of the IDID, and it will subsequently be used in auditing.
Table 6. Parameter usage
Reg/Dereg
Parameter Create ACEE Delete ACEE Purge ACEE certificate Query certificate
SAF_return_code Output Output Output Output Output
Usage notes
1. This service is only intended for use by the z/OS UNIX kernel or by other
MVS servers that do not use z/OS UNIX.
immediately following.
If transmitted from an ASCII system, PEM and Base64 encoded certificates
must be translated from ASCII to EBCDIC before being passed to initACEE.
20. If the function_code indicates that a certificate is to be queried, the caller is
expected to supply a 9-byte area for the RACF_userid parameter. If a user ID
is associated with the certificate, initACEE updates this area with the length
and value of the user ID.
21. If the function_code indicates that an ACEE is to be created or that a
certificate is to be queried, and the certificate supplied by the caller is defined
to RACF with a status of NOTRUST, initACEE will return a RACF return code
8 and a RACF reason code 40, indicating that no user ID is defined to use this
certificate.
22. If the function_code and attributes indicate that an ACEE is to be created and
an ENVR object is to be returned, then the ENVR_out parameter must point
to a data structure for the ENVR object. The caller receives a parameter list
error if the high order bit of a previous parameter indicates the end of the
parameter list.
23. If the attributes indicate that an ENVR object is to be returned, it is the caller's
responsibility to free the ENVR object storage. The caller should check the
storage area length and address to determine if storage needs to be freed, not
the initACEE return code. In some cases, an error may be encountered after
creation of the ENVR object, resulting in a non-zero return code. The caller is
still responsible for freeing the ENVR object in these cases.
24. If the function_code indicates that an ACEE is to be created, and the ENVR_in
parameter points to an ENVR object data structure, the length of the
RACF_userid, IDID_area, password phrase, password, and certificate
parameters must all be 0. The caller receives a parameter list error if a
RACF_userid, IDID_area, password phrase, password, or certificate is
supplied with the ENVR_in parameter.
25. If the function_code indicates that an ACEE is to be deleted or that managed
ACEEs should be purged, and the ENVR_in or ENVR_out parameter is
specified, then the caller receives a parameter list error.
26. When an ENVR object is supplied with the ENVR_in parameter and an ACEE
creation is requested, the attribute bits that affect the ACEE
HostIdMapping::= SEQUENCE{
hostName IMPLICIT[1] IA5String,
subjectId IMPLICIT[2] IA5String,
proofOfIdPossession IdProof OPTIONAL
}
IdProof::= SEQUENCE{
secret OCTET STRING,
encryptionAlgorithm OBJECT IDENTIFIER
}
Related services
None
Function
The initUSP service verifies that the user is authorized to use z/OS UNIX and, if
so, establishes security attributes for the calling process. The initUSP service also
returns any z/OS UNIX limits that have been set on a user basis.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSIU00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space and start on a word boundary.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Output_area
The name of a fullword in which the service routine stores the address of an
area containing data about the user. IRRSIU00 uses the high-order bit of this
fullword to determine if z/OS UNIX requested default processing for failures
that occur under certain circumstances (as described in Note 1). If the
high-order bit is on, an initUSP that would normally fail because of missing
information completes successfully and builds a default USP. With current
default processing (described for the getUMAP and getGMAP callable services
and in usage notes for this service) even without the high-order bit turned on
under the circumstances described in Notes 4 and 5, an initUSP that would
previously fail is now completed successfully.
For all successful initUSP requests, the output area is obtained in the primary
address space and must be freed by the caller of initUSP. The following data is
returned:
v TSO/E user ID
v z/OS UNIX user identifier (UID) of user
v z/OS UNIX group identifier (GID) of current group
v Home directory path name
v Initial program path name
v User limits (when OUSP version is greater than 0)
The length of a limit entry in the limits array will continue to be 5 bytes.
However, when the limit type is 7 (OUSP_Memlimit) or 8 (OUSP_ShmemMax)
the format of that entry will be different (as displayed in the following table).
In this case, the returned limit value will be a 3-byte value, rather than 4 bytes,
and a new 1-byte units identifier will be provided. The units specification will
be set to:
M megabytes
G gigabytes
T terabytes
P petabyte
Usage notes
1. This service is intended only for use by z/OS UNIX servers and the MVS BCP.
It can be directly invoked by a z/OS UNIX server. The high-order bit of the
output_area is set on by the caller when initUSP is called to establish the
security attributes for critical z/OS UNIX address spaces such as the kernel.
When the bit is on, initUSP builds a default z/OS UNIX security environment
in certain cases when it would normally fail. InitUSP sets a SAF return code of
0, RACF return code of 0, RACF reason code of 0, and builds a default USP for
the following cases:
v The user ID is not defined to RACF
v There is no OMVS segment in the user's profile
v There is no UID in the OMVS segment of the user's profile
v There is no GID in the OMVS segment of the current group's profile
The default USP returned to the caller (mapped by IRRPOUSP) contains a
z/OS UNIX user identifier (UID) and z/OS UNIX group identifier (GID) of 0.
The lengths for initial program and home directory path names is 0. If the user
ID is defined to RACF, the user ID is returned as an TSO/E user ID. If the user
ID is not defined to RACF, the TSO/E user ID is set to an asterisk in the
returned USP.
2. The address space or task must have an ACEE when this service is called.
3. A RACF user can be connected to more than NGROUPS_MAX groups, but only
up to the first NGROUPS_MAX groups will be associated with the process
when the process is created.
The first NGROUPS_MAX z/OS UNIX groups to which a user is connected (as
shown by a LISTUSER command) get associated with the process.
4. If no OMVS segment is found in the user's profile, the initUSP service checks
for the existence of the FACILITY class profile BPX.UNIQUE.USER and, if the
corresponding FACILITY class profile BPX.NEXT.USER defines a valid UID
value or range, the service generates and stores a unique UID in the USP. If the
application data field of the BPX.UNIQUE.USER profile contains the name of a
user, initUSP also copies any other OMVS field information from that user
profile into the USP. This information along with the new UID is saved in the
new OMVS segment for the current user.
5. If no OMVS segment is found in the group profile of the user's current connect
group, the initUSP service checks for the existence of the FACILITY class profile
BPX.UNIQUE.USER and, if the corresponding FACILITY class profile
BPX.NEXT.USER defines a valid GID value or range, the service generates and
stores a unique GID in the USP. The new GID is saved in the new OMVS
segment for the current group.
See z/OS Security Server RACF Security Administrator's Guide for information
about APPLDATA in the FACILITY class.
Related services
deleteUSP
Function
The makeFSP service builds an IFSP in the area provided by the caller.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
PASN = HASN or PASN not = HASN
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSMF00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Mode,
ALET, Output_FSP,
ALET, Owning_directory_FSP,
ALET, File_Identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Mode
The name of a word containing the mode values (the filetype, the permission
bits, and the S_ISUID, S_ISGID, and S_ISVTX bits) to be set for the file.
See “File type and file mode values” on page 4 for a definition of the security
bits in the mode parameter.
Output_FSP
The name of a 64-byte area in which the new IFSP is built.
Owning_directory_FSP
The name of an area containing the IFSP for the owning directory.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is only intended for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. If the CRED user type is system, IRRSMF00 allows the operation, and sets the
owning z/OS UNIX user identifier (UID) to zero.
3. IRRSMF00 builds the IFSP in the output_FSP area provided by the caller. The
caller must save the IFSP as part of the attributes for the object.
4. IRRSMF00 builds the IFSP with the S_ISUID bit set to zero and the S_ISVTX bit
set to the value in the mode byte. If the new object is a directory, and the
FILE.GROUPOWNER.SETGID profile exists in the UNIXPRIV class, the
S_ISGID bit is inherited from the parent directory. Otherwise, the S_ISGID bit is
set to zero.
5. The new object's owning UID is set to the effective UID of the process. By
default, the owning GID is set to that of the parent directory. However, if the
FILE.GROUPOWNER.SETGID profile exists in the UNIXPRIV class, then the
owning GID is determined by the set-gid bit of the parent directory as follows:
v If the parent's set-gid bit is on, then the owning GID is set to that of the
parent directory.
v If the parent's set-gid bit is off, then the owning GID is set to the effective
GID of the process.
6. If the parent directory has a directory model ACL, and the new object is a
directory, then the parent's directory model ACL is copied as the new
directory's access ACL and directory model ACL. The caller must pass in the
address of the parent's directory model ACL in the CredPDirModelAcl field.
The caller must pass in the length and address of buffers to contain both the
new directory's access ACL and directory model ACL. The buffers must be
large enough to contain the copied ACL. The address of the new directory's
directory model ACL buffer must be passed in using the CredDirModelAcl
field, and its length must be passed in using the CredDirModelAclLen field.
The address of the new directory's access ACL buffer must be passed in using
the CredAccAcl field, and its length must be passed in using the
CredAccAclLen field.
7. If the parent directory has a file model ACL, and the new object is a directory,
then the parent's file model ACL is copied as the new directory's file model
ACL. The caller must pass in the address of the parent's file model ACL in the
CredPFileModelAcl field. The caller must pass in the length and address of a
buffer to contain the new directory's file model ACL. The buffer must be large
enough to contain the copied ACL. The address of the new directory's file
model ACL buffer must be passed in using the CredFileModelAcl field, and its
length must be passed in using the CredFileModelAclLen field.
8. If the parent directory has a file model ACL, and the new object is a file, then
the parent's file model ACL is copied as the new file's access ACL. The caller
must pass in the address of the parent's file model ACL in the
CredPFileModelAcl field. The caller must pass in the length and address of a
buffer to contain the new file's access ACL. The buffer must be large enough to
contain the copied ACL. The address of the new file's access ACL buffer must
be passed in using the CredAccAcl field, and its length must be passed in
using the CredAccAclLen field.
9. If the SECLABEL class is active, the security label from the owning directory
will be propagated to the output FSP unless the security label is SYSMULTI. If
the owning directory's security label is SYSMULTI, the security label of the
output FSP will be set to that of the requesting address space, unless a system
CRED is passed containing a security label. If a system CRED containing a
security label is passed when the owning directory's security label is
SYSMULTI, the security label from the CRED will be used in the output FSP
instead of the address space security label.
Related services
ck_access, R_umask
Function
The makeISP service builds an IISP in the area provided by the caller.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
PASN = HASN or PASN not = HASN
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSMI00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Mode_Permissions,
ALET, Output_ISP,
ALET, Output_IPCP,
ALET, CREDIPC
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Mode_Permissions
The name of a word containing the mode permission flags to be set for this
IPC key. The following is a list of defined permission bits mapped by
BPXYMODE:
S_IRUSR
Permits the process that owns the IPC member to read it.
S_IWUSR
Permits the process that owns the IPC member to alter it.
S_IRGRP
Permits the group associated with the IPC member to read it.
S_IWGRP
Permits the group associated with the IPC member to alter it.
S_IROTH
Permits others to read the IPC member.
S_IWOTH
Permits others to alter the IPC member.
Alter and write have the same meaning for access checks. Alter applies to
semaphores and write applies to message queueing and shared memory
segments.
Output_ISP
The name of a 64-byte area in which the new IISP is built. The name is set by
the kernel. See z/OS Security Server RACF Data Areas in the z/OS Internet
library (www.ibm.com/systems/z/os/zos/library/bkserv).
Output_IPCP
The name of a 20-byte area in which the new IPCP is built. The name is set by
the kernel.
CREDIPC
The name of the CREI structure for the current IPC system callable service. The
CREI contains the IPC identifier and IPC key. See z/OS Security Server RACF
Data Areas in the z/OS Internet library (www.ibm.com/systems/z/os/zos/
library/bkserv).
Usage notes
1. This service is only intended for use by the MVS BCP.
2. The CREI user type must be local (that is, 1).
3. IRRSMI00 builds the IISP in the output_ISP area and the output_IPCP areas
provided by the caller. The caller must save the IISP as part of the attributes
for the key.
4. The IPCP ALET and address are retrieved from the parameters and set into
the output_ISP by RACF.
5. The effective z/OS UNIX user identifier (UID) and z/OS UNIX group
identifier (GID) are retrieved from the USP and set into the owner and creator
fields of the output_IPCP by RACF.
6. The mode is retrieved from the parameters and set into the output_IPCP by
RACF.
7. The IPC Key and IPC ID are retrieved from the CREI and set into the
output_ISP by RACF.
8. An audit record is optionally written, depending on the audit options in effect
for the system.
9. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
10. If the SECLABEL class is active, the security label from the creating process
will be propagated to the ISP. If the creating process has no security label and
MLIPCOBJ is active, the request will fail with an authorization failure.
Related services
ck_IPC_access, R_IPC_ctl
Function
The make_root_FSP service initializes an IFSP for the root directory of a new file
system being initialized in a shared file system data set.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSMR00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Mode,
ALET, Output_FSP,
ALET, File_Identifier,
ALET, Data_set_name
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Mode
The name of a word containing the mode value (the file type, the permission
bits, and the S_ISUID, S_ISGID, and S_ISVTX bits) to be set for the file.
See “File type and file mode values” on page 4 for a definition of the security
bits in the mode parameter.
Output_FSP
The name of a 64-byte area in which the new IFSP is built.
File_Identifier
The name of a 16-byte area containing a unique identifier of the root directory.
Data_set_name
The name of an area containing the data set name of the shared file system
data set being created. This is a 44-byte area padded with blanks.
Usage notes
1. This service is only intended for use by DFSMS/MVS, during allocation of an
shared file system data set, and by z/OS UNIX System Services servers. The
service contains support for z/OS UNIX System Services servers, but cannot be
directly invoked by an z/OS UNIX System Services server.
2. IRRSMR00 may be called from a non-z/OS UNIX address space.
3. These are the default attributes set for the root directory:
v The file's owner z/OS UNIX user identifier (UID) and z/OS UNIX group
identifier (GID) are initialized as follows:
– If the caller is a z/OS UNIX process:
- owner UID = effective UID of the process
- owner GID = effective GID of the process
5. If the SECLABEL class is active, and the containing data set has a security
label, the security label will be propagated into the root FSP. If the data set has
no security label and MLFSOBJ is active, the security label of the output FSP
will be set to that of the requesting address space. Note that only the data set
name is available to make_root_FSP, and not the setting of the RACF indicator
bit or the volume serial number. Make_root_FSP will look for a discrete profile
with the same name as the containing data set. If one is found, the security
label from that profile will be used. If no discrete is found, make_root_FSP will
look for a covering generic profile. If more than one discrete profile is found
with the same name, RACF will return an internal error since it does not know
the volume serial number of the data set.
Related services
makeFSP
Function
The query_file_security_options service returns the value of the requested file
system option.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
None
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSQF00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Option_code,
ALET, Output_value
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Option_code
The name of a word containing a code identifying the requested option. The
code value 1 identifies the _POSIX_CHOWN_RESTRICTED option. Option
code value 2 is sent as input to IRRSQF00 to determine if the system supports
Access Control Lists (ACLs) or not.
Output_value
The name of a word in which the value of the requested option is returned.
v Option_code value 1
For option code value 1, the following may be returned:
0 _POSIX_CHOWN_RESTRICTED is in effect
-1 _POSIX_CHOWN_RESTRICTED is not in effect
Note:
Usage note
1. This service is intended only for use by a z/OS UNIX file system.
Related services
None
Function
The query_system_security_options service returns the value of the requested
system options. The only supported options are NGROUPS_MAX and
_POSIX_SAVED_IDS.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
None
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. RACF returns the following values for the requested system options:
v NGROUPS_MAX: 300
v _POSIX_SAVED_IDS: 0
Format
CALL IRRSQS00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Option_code,
ALET, Output_value
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Option_code
The name of a word containing a code identifying the requested option. The
supported values are:
1 NGROUPS_MAX
2 _POSIX_SAVED_IDS
Usage note
v This service is intended only for use by the MVS BCP.
Related services
None
Function
The R_admin callable service provides an interface with which to manage and
retrieve RACF profile and SETROPTS data, and to retrieve RACF Remote Sharing
configuration data. Several function codes are available for use, depending on
what profile type you want to manage, and which operation you want to perform.
The available functions are:
v Input functions:
– Run-command: Accepts a command image and executes this command in the
RACF subsystem address space.
– Update functions: Accepts tokenized input from which a RACF command
image is constructed, and executed in the RACF subsystem address space.
These functions shield the programmer from the details of RACF command
syntax. The following RACF information can be managed using the update
functions:
- USER profiles
- GROUP profiles
- User-to-group connections
- General resource profiles
- Data set profiles
- General resource and data set profile access lists
- SETROPTS options
v Output functions:
– Profile extract functions: Return tokenized, formatted data for RACF profiles
in all classes except the DATASET class.
– SETROPTS retrieval - returns SETROPTS data in either of two formats:
- SMF Unload
- The same tokenized structure used as input to the SETROPTS update
function
– Password and password phrase envelope retrieval - Retrieves an encrypted
password or password phrase envelope for a specified user.
Most, but not all, of these function codes require the RACF subsystem address
space to be up and running. Some function codes require that the caller be in
supervisor state, but some are also available for problem state callers. Usually,
problem state callers require additional RACF profile authorization and certain
options are not available to them (for example, the ability to run the request under
a different identity).
The IRRPCOMP mapping macro contains the definitions for the function codes
and structure mappings used by R_admin. The relevant fields start with prefix
ADMN_.
A REXX interface to the profile extract functions is available. This program, named
IRRXUTIL, is designed to be invoked by REXX in problem state, and converts the
output of an R_admin extract request to a set of REXX stem variables. For more
information, refer to z/OS Security Server RACF Macros and Interfaces.
Requirements
Authorization:
Any PSW key in supervisor or problem state, depending on the function
code
Dispatchable unit mode:
Any task
Cross memory mode:
PASN = HASN = SASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary only
Recovery mode:
Recovery must be provided by caller
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space.
RACF authorization
The authorization requirements differ among the R_admin functions. For the
functions which send requests to the RACF subsystem address space (all of the
input functions, and password or password phrase envelope retrieval), a user ID is
passed to the RACF address space where an ACEE is created under which to
execute the RACF command. For the profile extract functions, which run in the
caller's address space, the actual ACEE, if present, will be used for authority
checking. If a user ID is provided, an ACEE will be created for this purpose. Only
a supervisor state caller can directly specify the user ID or ACEE as a parameter to
R_admin. The following list shows the possible sources of the user ID or ACEE, in
the order in which they are searched:
v The RACF_userID parameter (supervisor state callers only)
v The ACEE_ptr parameter (supervisor state callers only)
v The user ID associated with the current task control block (TCB)
v The user ID associated with the current address space (ASXB)
Where appropriate, see the Authorization Required section for the relevant RACF
command, in the z/OS Security Server RACF Command Language Reference.
The following table summarizes the authorization required for the function codes:
Problem
state Command authority
Function code allowed? enforced? FACILITY class authorization
ADMN_RUN_COMD Yes Yes For problem state callers only, READ access
to IRR.RADMIN.command-name. The
resource must be defined using the full
command name even if the abbreviated
version of the command name is used with
R_Admin. (For example, 'LU JOEUSER'
would require READ authority to
IRR.RADMIN.LISTUSER.)
Update function codes No Yes N/A
(X'01'-X'04' and X'06'- X'15')
ADMN_XTR_RRSF Yes Yes, Authorization is READ access to
determined by OPERCMDS IRR.RADMIN.EXTRACT.RRSF With
resources FACILITY authorization, the subsystem
subsystem-name.SET.LIST name, prefix, and user ID (with the
and subsystem- TRUSTED and PRIVILEGED indicators) are
name.TARGET.LIST. always returned, even if OPERCMDS
authorization is denied.
ADMN_XTR_SETR Yes Yes (optionally for a For problem state callers, and for supervisor
supervisor state caller). The state callers who request it, READ access to
authorization rules of the IRR.RADMIN.SETROPTS.LIST
SETROPTS LIST command
are applied.
ADMN_UNL_SETR No No N/A
ADMN_XTR_PPENV No N/A READ access to
IRR.RADMIN.EXTRACT.PPENV (If this
access check is being audited, the logstring
will identify the user ID whose password
phrase envelope was extracted.)
ADMN_XTR_PWENV No N/A READ access to
IRR.RADMIN.EXTRACT.PWENV (If this
access check is being audited, the logstring
will identify the user ID whose password
envelope was extracted.)
Problem
state Command authority
Function code allowed? enforced? FACILITY class authorization
Profile extract functions (X'19' Yes Yes. Each function code For problem state callers and for supervisor
- X'1D', X'1F', X'20') maps to a RACF listing state callers who request it:
command (For example, the v Extract user, extract next user, and extract
authorization rules of the connect - READ access to
LISTGRP command). This IRR.RADMIN.LISTUSER
authority can be skipped for
v Extract group and extract next group -
a supervisor state caller if
READ access to IRR.RADMIN.LISTGRP
requested in the input
parameter list. v Extract resource and extract next resource
- READ access to IRR.RADMIN.RLIST
Note:
1. Generic FACILITY class profiles can be used.
2. For the profile extract functions, it is possible that the caller is only authorized
to see a subset of the profile information. In this case, only this subset of
information is returned. If any information is returned, the caller receives a 0
return code, and no indication that information has been suppressed. Following
are some situations in which information is suppressed (for problem state
callers, and for supervisor state callers who have not requested that the
command authority checks be bypassed). These situations are identical to the
corresponding RACF command (e.g. LISTUSER, LISTGRP, and RLIST).
v Only a user with the AUDITOR attribute (at either the group or system level)
or the ROAUDIT attribute can view the UAUDIT setting of a USER profile,
or the AUDITOR-related audit settings in a general resource profile.
v Users can be authorized to view the BASE segment, but no additional
segments.
v With the use of field-level access checking (using the FIELD class), users can
be authorized to view certain non-BASE segment information without having
authority to view the BASE segment.
v When certain SECLABEL-related SETROPTS options are in effect, the
installation data field of the USER profile is suppressed for all but system
SPECIAL users.
v When a non-privileged user has at least READ, but not ALTER access to a
general resource profile, the access list is not returned.
3. For the SETROPTS extract function, it is possible that the caller is authorized to
see only a subset of the SETROPTS information. In this case, only this subset of
information is returned. If any information is returned, the caller receives a 0
return code, and no indication that information has been suppressed. For any
caller who does not have the AUDITOR or ROAUDIT attribute, or the
group-AUDITOR attribute in any of their groups, the auditing related fields are
suppressed.
Format
CALL IRRSEQ00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_code,
Parm_list,
RACF_userID,
ACEE_ptr,
Out_message_subpool,
Out_message_strings
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
These return codes are found in Table 19 on page 79.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
These return codes are found in Table 19 on page 79.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
These reason codes are found in Table 19 on page 79.
Function_code
The name of a 1-byte field that specifies the function (administration request)
that RACF is to perform. The function code may have one of the values found
in Table 17 on page 77.
Parm_list
The name of a variable marking the start of the input parameter list. The
mapping macro IRRPCOMP contains a definition of the parameter list for each
of the values of Function_code. To find parameter list mappings for the values
of Function_code, see Table 17 on page 77.
RACF_userID
The name of a 9-byte area that consists of a 1-byte length field followed by the
userID, which can be up to eight characters. If not specified, the length must
equal zero. Otherwise, the user ID must be specified in uppercase. If specified,
the RACF command executed through R_admin will run under the authority
of this userID. Ignored for problem state callers.
ACEE_ptr
The name of a fullword containing the address of the ACEE of the user under
whose identity the RACF administrative request runs. The user ID is extracted
from the ACEEUSER field. The ACEE itself is not used for subsequent
authority checking for the request, except for the extract user/group/connect
function codes. If the caller does not specify an ACEE, this area must contain
binary zeros. If both an ACEE and a user ID are passed into this service, the
user ID is used. Ignored for problem state callers.
Out_message_subpool
The name of a 1-byte field that specifies the subpool used to obtain storage for
output that is returned. Problem state callers are limited to subpools 1 thru
127.
Out_message_strings
The name of a fullword in which the service routine stores the address of
output data, if applicable. It is the responsibility of the caller to free the output
storage. See the appropriate mappings of the output data for each function
code in “Reference documentation by function code” on page 78.
Usage notes
1. You must link edit the IRRSEQ00 callable service stub into your application
code to resolve the entry point address at run time.
2. For the Out_message_subpool parameter, select a subpool carefully. z/OS
makes certain assumptions about subpool usage and characteristics. Using
subpool 0 or 250 or any subpool documented in z/OS MVS Programming:
Authorized Assembler Services Guide as having a storage key of USER (for
example, 227-231 and 241) may give unpredictable results.
3. All requests are processed synchronously. Control is not returned to the caller
until RACF has processed the administration request and output, if any has
been returned to the caller.
4. For the ADMN_RUN_COMD function code, the following RACF commands
are not supported through this interface:
v BLKUPD
v RACLINK
v RVARY
v RACF operator commands (DISPLAY, RESTART, SET, SIGNOFF, STOP, and
TARGET)
RACF TSO administrative commands may not be directed to other RACF
remote sharing facility (RRSF) nodes. The command image passed by the
caller cannot contain the keywords AT or ONLYAT. These keywords cause the
command to fail with SAF return code 8, RACF return code 16, RACF reason
code 8.
These messages are returned as command output:
IRRV013I subsystem-name SUBSYSTEM racf-command COMMAND FROM THE
IRRSEQ00 CALLABLE SERVICE WAS NOT PROCESSED.
IRRV014I subsystem-name SUBSYSTEM AT() OR ONLYAT() KEYWORDS
MAY NOT BE SPECIFIED WITH COMMANDS FROM THE IRRSEQ00
CALLABLE SERVICE.
Any update to the RACF database caused by this service is subject to
automatic direction and password synchronization as implemented by the
installation.
Related services
None
Reference documentation
The following information describes how to use the various functions of R_admin:
Output, if any, which resulted from RACF's processing of the command is returned
to the caller in virtual storage. There is a maximum of 4096 lines (not bytes) of
output which will be returned by R_admin.
Run-command does not support all RACF commands. For a list of the commands
that are not allowed by this service, see “Usage notes” on page 81.
The exact format (spacing and order) of the data in the command output or
messages does not constitute a programming interface. No programs should
depend on the exact format of this data. The R_admin extract functions, described
in “Profile extract functions” on page 102, provide a programming interface with
which to retrieve RACF profile data for some profile types. The extract functions
are not subject to the 4096 limit on output lines.
The output from run-command is either command output or error messages. The
output format is shared with the R_admin update functions and is documented in
“Command output message block mapping” on page 101.
Note: When listing profiles, you are getting RACF command output, which is not
a programming interface. The extract functions are the preferred method for
retrieving RACF profile information for those profile types which are supported.
For more information about extract functions, see “Profile extract functions” on
page 102.
These functions can only be invoked by supervisor state callers. The following
describes the supported segments and fields for the various profile types.
The header identifies the name of the profile being managed (for user and group
operations), and the number of segment entries contained in the parameter list.
Each segment entry contains the segment name, and the number of fields provided
for that segment. Each field entry identifies a field in a RACF profile, and provides
the new value to be set for the field. A field entry can also be used to delete the
field. For general resource, data set, and group connection operations, a field entry
in the BASE segment is used to identify the profile being manipulated.
Parameter list construction is simpler for the list and delete functions because the
listing functions only accept optional segment entries, and the delete functions do
not require any segment entries at all. For listing and deleting, it may be simpler to
construct your own command image and use the run-command function. See
“Segment and field entry mappings” on page 421 for detailed information about
segment and field entries.
The request header mapping varies slightly depending on what profile type you
are managing. Individual sections for each profile type will document the request
header mapping for that function, along with a list of the supported fields, and
their characteristics.
The concepts of profiles, segments and fields will be familiar to anyone with some
knowledge of the RACF commands, classes and templates. In order to provide a
common view of the data, R_admin stretches this concept slightly in a few cases.
v SETROPTS information can be manipulated using R_admin. By convention, all
SETROPTS fields reside within a BASE segment entry, even though SETROPTS
information does not actually reside within a RACF profile.
v Group connections are managed not by updating fields for a user or group
profile, but rather by managing fields within a BASE segment entry for a logical
"CONNECT" profile. Only one connection can be managed per request.
v Profile access lists are managed by updating fields within a logical BASE
segment entry for a general resource or data set profile. Only one access list
entry can be managed per request, and this is a separate request type than the
standard add and alter functions for general resources and data sets.
See “Segment and field entry mappings” on page 421 for segment and field entry
information.
The output from these functions, except for password and password phrase
envelope retrieval, is either command output or error messages. See “Command
output message block mapping” on page 101 for the output format.
For tables defining the field names and their usage, see “User administration” on
page 425.
Examples: The following examples are not coding samples, rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Add user BRUCE with some BASE segment fields and some OMVS
segment fields.
Function code = ADMN_ADD_USER
Note: For fields which take quoted data (for example, user name), the
quotes must be included as part of the data.
* First, define the request header
HEADER DS 0H
DC AL1(5) Length of user
DC CL8’BRUCE’ User name
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(2) Number of segments (BASE+OMVS)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC CL1’Y’ Flag byte - Y - create segment
DC AL2(3) Field count - 3
* First BASE segment field entry
BFLD1 DC CL8’NAME’ Name field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(13) Length of field data
DC CL13’’’BRUCE WELLS’’’ Field data
* Second BASE segment field entry
BFLD2 DC CL8’OWNER’ Owner field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(7) Length of field data
DC CL7’RACFDEV’ Field data
* Third BASE segment field entry
BFLD3 DC CL8’SPECIAL’ Special field
List user BRUCE, displaying the OMVS and TSO segments (and not the
BASE segment).
Function code = ADMN_LST_USER
HEADER DC AL1(5),CL8’BRUCE’,AL1(0),AL2(0),AL2(2)
OSEG DC CL8’OMVS’,CL1’Y’,AL2(0)
TSEG DC CL8’TSO’,CL1’Y’,AL2(0)
Example 6
Delete user BRUCE.
Function code = ADMN_DEL_USER
HEADER DC AL1(5),CL8’BRUCE’,AL1(0),AL2(0),AL2(0)
Example 7
Retrieve the password envelope for user BRUCE.
Function code = ADMN_XTR_PWENV
HEADER DC AL1(5),CL8’BRUCE’,AL1(0),AL2(0),AL2(0)
Table 23. Parameter list format for group administration (continued). This is a table with
three columns to describe the offset, length, and description of the parameter list format for
group administration.
Offset Length Description
10 2 Output offset to the segment or field
entry in error in relation to the start of
the Parm_list. Only applied to
ADMN_ADD_GROUP and
ADMN_ALT_GROUP requests when an
"invalid 'request" error is returned to the
caller.
12 2 Number of RACF profile segments
14 * Start of first segment entry
See “Segment and field entry mappings” on page 421 for segment and field entry
information.
The output from these functions is either command output or error messages. See
“Command output message block mapping” on page 101 for the output format.
For tables defining the field names and their usage, see “Group administration” on
page 436.
Examples: The following examples are not coding samples, rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Add group FINANCE with some BASE segment fields and an OMVS
segment.
Function code = ADMN_ADD_GROUP
Note: For fields which take quoted data (for example, installation data),
the quotes must be included as part of the data.
* First, define the request header
HEADER DS 0H
DC AL1(7) Length of group
DC CL8’FINANCE’ Group name
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(2) Number of segments (BASE+OMVS)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC CL1’Y’ Flag byte - Y - create segment
DC AL2(4) Field count - 4
* First BASE segment field entry
BFLD1 DC CL8’DATA’ Data field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(20) Length of field data
DC CL20’’’FINANCE DEPARTMENT’’’ Field data
* Second BASE segment field entry
BFLD2 DC CL8’OWNER’ Owner field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(4) Length of field data
DC CL4’CORP’ Field data
Note: The request header identifies the user, but not the group, in which the
connection applies. Set up a field entry for the GROUP field in the BASE segment
in order to specify the group name to R_admin.
See “Segment and field entry mappings” on page 421 for segment and field entry
information.
See “Group connection administration” on page 438 for tables defining the field
names and their usage.
The output from these functions is either command output or error messages. See
“Command output message block mapping” on page 101 for the output format.
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Connect user JOSEPH to the FINANCE group with various authorities.
Function code = ADMN_CONNECT
* First, define the request header
HEADER DS 0H
DC AL1(6) Length of user
Note:
1. Specify DATASET as the class name when using the data set functions.
2. The request header identifies the class name, but not the resource name itself.
You should set up a field entry for the PROFILE field in the BASE segment in
order to specify the resource name to R_admin.
The BASE segment is used to specify field information for ADMN_PERMIT. You
should also use the BASE segment to specify certain keywords for the delete and
list functions. For example, you may need to specify the GENERIC keyword when
deleting a data set. Also, for example, when using a list function, you can specify
the NORACF field if you do not want the BASE segment listed.
See “Segment and field entry mappings” on page 421 for segment and field entry
information.
The output from these functions is either command output or error messages. See
“Command output message block mapping” on page 101 for the output format.
The general resource, data set, and permit functions each utilize a separate set of
field definitions. Table 26 shows where to find the field definitions for the resource
related function codes.
Table 26. Resource related field definitions
For Field Definitions See
ADMN_ADD_GESRES “General resource administration” on page
ADMN_ALT_GENRES 439
ADMN_LST_GENRES
Note: For ADMN_DEL_GENRES, specify only the PROFILE field in the BASE
segment.
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Define the IRR.RADMIN.EXTRACT.PWENV profile in the FACILITY class
with universal access of NONE, notify user who is also the owner, and
some installation data.
Note:
v The profile name is identified as a (required) field in the BASE segment.
v For fields which take quoted data (for example, installation data), the
quotes must be included as part of the data.
v When altering fields in RACLISTed classes, the class must be refreshed
after making the update. See “SETROPTS administration” on page 99 for
examples.
Function code = ADMN_ADD_GENRES
* First, define the request header
HEADER DS 0H
DC AL1(8) Length of class
DC CL8’FACILITY’ Class name
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(1) Number of segments (BASE only)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC CL1’Y’ Flag byte - Y - create segment
DC AL2(5) Field count - 5
* First BASE segment field entry
BFLD1 DC CL8’PROFILE’ Profile name - required!
DC CL1’Y’ Flag byte - Y - create field
DC AL2(24) Length of field data
DC CL24’IRR.RADMIN.EXTRACT.PWENV’ Field data
* Second BASE segment field entry
BFLD2 DC CL8’OWNER’ Owner field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(6) Length of field data
DC CL6’SHERID’ Field data
* Third BASE segment field entry
BFLD3 DC CL8’NOTIFY’ Notify field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(6) Length of field data
DC CL6’SHERID’ Field data
* Fourth BASE segment field entry
BFLD4 DC CL8’UACC’ Universal access field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(4) Length of field data
DC CL4’NONE’ Field data
* Fifth BASE segment field entry
BFLD5 DC CL8’DATA’ Installation data field
Example 6
List the profile in the previous example, showing all of the BASE segment
information, and the information in the CDTINFO segment.
Function code = ADMN_LST_GENRES
HEADER DC AL1(3),CL8’CDT’,AL1(0),AL2(0),AL2(2)
BSEG DC CL8’BASE’,CL1’Y’,AL2(2)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(7),CL7’MYCLASS’
BFLD2 DC CL8’ALL’,CL1’Y’,AL2(0)
CSEG DC CL8’CDTINFO’,CL1’Y’,AL2(0)
Example 7
List the profile in the previous example, but suppress the BASE segment
information.
Function code = ADMN_LST_GENRES
HEADER DC AL1(3),CL8’CDT’,AL1(0),AL2(0),AL2(2)
BSEG DC CL8’BASE’,CL1’Y’,AL2(2)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(7),CL7’MYCLASS’
BFLD2 DC CL8’NORACF’,CL1’Y’,AL2(0)
CSEG DC CL8’CDTINFO’,CL1’Y’,AL2(0)
Example 8
Delete the profile in the previous example.
Function code = ADMN_DEL_GENRES
HEADER DC AL1(3),CL8’CDT’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(1)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(7),CL7’MYCLASS’
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Define a discrete data set profile with a security label of SECRET and a
DFP segment.
Note:
v The profile name is identified as a (required) field in the BASE segment.
v For fields which take quoted data (for example, installation data), the
quotes must be included as part of the data.
v Since the data set name is not quoted, it will be prefixed with the
creator's user ID.
Function code = ADMN_ADD_DS
* First, define the request header
HEADER DS 0H
DC AL1(7) Length of class
DC CL8’DATASET’ Class name - optional for DATASET
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(2) Number of segments (BASE+DFP)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC CL1’Y’ Flag byte - Y - create segment
DC AL2(4) Field count - 4
* First BASE segment field entry
BFLD1 DC CL8’PROFILE’ Profile name - required!
DC CL1’Y’ Flag byte - Y - create field
DC AL2(9) Length of field data
BFLD3 DC CL8’OWNER’,CL1’Y’,AL2(5),CL5’MIKEO’
BFLD4 DC CL8’SECLABEL’,CL1’N’,AL2(0)
BFLD5 DC CL8’WARNING’,CL1’Y’,AL2(0)
DSEG DC CL8’DFP’,CL1’N’,AL2(0)
Example 5
Display the contents of a generic data set profile and list the catalogued
data set names for which it offers protection. Also, display the DFP
segment.
Function code = ADMN_LST_DS
HEADER DC AL1(7),CL8’DATASET’,AL1(0),AL2(0),AL2(2)
BSEG DC CL8’BASE’,CL1’Y’,AL2(2)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(11),CL11’’’IBMUSER.*’’’
BFLD2 DC CL8’DSNS’,CL1’Y’,AL2(0)
DSEG DC CL8’DFP’,CL1’Y’,AL2(0)
Example 6
Delete the data set profile from example 4.
Function code = ADMN_DEL_DS
HEADER DC AL1(7),CL8’DATASET’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(2)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(18),CL18’’’DEPT06.TEST.DATA’’’
BFLD2 DC CL8’GENERIC’,CL1’Y’,AL2(0)
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Permit group FINANCE to the DATASET profile named 'CORP.SALES.*'
with READ access.
* First, define the request header
HEADER DS 0H
DC AL1(7) Length of class
DC CL8’DATASET’ Class name
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(1) Number of segments (BASE only)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC CL1’Y’ Flag byte - Y - create segment
DC AL2(3) Field count - 3
* First BASE segment field entry
BFLD1 DC CL8’PROFILE’ Profile name - required!
DC CL1’Y’ Flag byte - Y - create field
DC AL2(14) Length of field data
DC CL14’’’CORP.SALES.*’’’ Field data
* Second BASE segment field entry
BFLD2 DC CL8’ID’ Id field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(7) Length of field data
DC CL7’FINANCE’ Field data
* Third BASE segment field entry
BFLD3 DC CL8’ACCESS’ Access field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(4) Length of field data
DC CL4’READ’ Field data
Example 2
This is the same as example 1, but is shown in "rows", where a single line
represents the request header, and individual segment and field entries.
This convention will be used from this point on.
Function code = ADMN_PERMIT
HEADER DC AL1(7),CL8’DATASET’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(3)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(14),CL14’’’CORP.SALES.*’’’
BFLD2 DC CL8’ID’,CL1’Y’,AL2(7),CL7’FINANCE’
BFLD3 DC CL8’ACCESS’,CL1’Y’,AL2(4),CL4’READ’
Example 3
Permit the SALES group with UPDATE access to the DATASET in the
previous example, but only when logged on to a specific terminal.
Function code = ADMN_PERMIT
HEADER DC AL1(7),CL8’DATASET’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(4)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(14),CL14’’’CORP.SALES.*’’’
BFLD2 DC CL8’ID’,CL1’Y’,AL2(5),CL5’SALES’
BFLD3 DC CL8’ACCESS’,CL1’Y’,AL2(6),CL6’UPDATE’
BFLD4 DC CL8’WHENTERM’,CL1’Y’,AL2(8),CL8’TERMID01’
Example 4
Remove the access list entry for the FINANCE group.
Function code = ADMN_PERMIT
HEADER DC AL1(7),CL8’DATASET’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(3)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(14),CL14’’’CORP.SALES.*’’’
BFLD2 DC CL8’ID’,CL1’Y’,AL2(7),CL7’FINANCE’
BFLD3 DC CL8’DELETE’,CL1’Y’,AL2(0)
Example 5
Reset the access list for the BPX.SUPERUSER profile in the FACILITY class.
Function code = ADMN_PERMIT
HEADER DC AL1(7),CL8’FACILITY’,AL1(0),AL2(0),AL2(1)
BSEG DC CL8’BASE’,CL1’Y’,AL2(2)
BFLD1 DC CL8’PROFILE’,CL1’Y’,AL2(13),CL13’BPX.SUPERUSER’
BFLD2 DC CL8’RESET’,CL1’Y’,AL2(0)
See “Segment and field entry mappings” on page 421 for segment and field entry
information.
The output from this function is either command output or error messages. See
“Command output message block mapping” on page 101 for the output format.
For tables defining the field names and their usage, see “SETROPTS
administration” on page 452.
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Set various password policy controls.
Function code = ADMN_ALT_SETR
* First, define the request header
HEADER DS 0H
DC CL9’’ Unused
| DC AL1(0) No option flags set
DC AL2(0) Not used on input
DC AL2(1) Number of segments (BASE only)
* First segment entry - BASE
BSEG DC CL8’BASE’ BASE segment entry
DC AL1(0) Flag byte - ignored
DC AL2(4) Field count - 4
* First BASE segment field entry
BFLD1 DC CL8’HISTORY’ Password history field
DC CL1’Y’ Flag byte - Y - create field
DC AL2(2) Length of field data
If a RACF command runs and does not return any output, the
Out_message_strings parameter will be zero. Otherwise, R_admin will set
Out_message_strings with a pointer to a command output structure. This structure
consists of a linked list of blocks, each of which consists of a block header followed
by one or more message entries. A single message entry corresponds to a line of
RACF command output.
The following mappings can be found in the IRRPCOMP mapping macro. Also,
see the ADMN DSECT within the COMP data area in z/OS Security Server RACF
Data Areas in the z/OS Internet library (www.ibm.com/systems/z/os/zos/library/
bkserv).
Table 28. Mapping of output message block
Offset Length Description
0 4 Next output messages block, or zero if no additional
blocks follow
| 4 4 Eye catcher.
This set of function codes allows you to extract RACF profile information from
USER, GROUP, CONNECT, and general resource profiles. Note that CONNECT is
a logical class that returns the details of a specific user-to-group connection. The
extract functions return the entire profile; you cannot specify a list of segments, or
fields, to be returned. You can, however, request that only the BASE segment be
returned , or that the profile name only be returned.
Note: These segment and field descriptors are not the same format as the segment
and field entries described in the preceding for the update functions and
SETROPTS extract. The term descriptor is used in order to highlight this
distinction.
The header identifies the total length and subpool of the output block, the profile
and class name of the data being returned, and the number of segments (and
hence segment descriptors) which exist for the profile. Each segment descriptor
contains the number of field descriptors being returned for that segment, and an
offset to the first field descriptor for that segment. Each field descriptor contains
the length of, and offset to, the data for the field. All of the field descriptors for a
given segment will be contiguous. The mappings for this structure can be found in
the IRRPCOMP macro.
The field descriptors return character data, not the raw data as it exists within the
RACF database. The data is returned exactly as it is expected on input to a RACF
command, or to the R_admin update functions. Also, data is returned for some
profile fields even though they cannot be directly altered by a RACF command.
For most of these fields, the data is returned in the same format which is displayed
by the associated RACF listing command. The exception is for date fields. All dates
are returned in mm/dd/yy format, to maintain consistency with the way dates are
expected as input to commands.
See Table 35 on page 110 for the fields associated with each profile type. For details
on RACF profiles, segments, and fields, see z/OS Security Server RACF Macros and
Interfaces. Only a subset of the defined fields are returned, as is detailed within the
following field tables. Mostly, the RACF command keywords map to database
fields. See the z/OS Security Server RACF Command Language Reference for syntax
rules regarding the format of the data expected by the commands, and the format
of the data returned by the R_admin extract functions.
For extract user, extract group, and extract resource, there is a corresponding
extract-next function code. These allow you to iteratively retrieve all RACF profiles
of a given type for which you are authorized (this can be viewed as a hybrid
between the LISTUSER * command, for example, and RACROUTE
REQUEST=EXTRACT,TYPE=EXTRACTN). For each request, RACF extracts and
returns the next profile that contains at least one field that the caller is authorized
to see (using the rules applied by the LISTUSER, LISTGRP, or RLIST command)
after the profile that was specified in the parameter list header.
Note:
1. When using extract-next to return all general resource profiles for a given class,
all the discrete profiles are returned, followed by the generic profiles. An
output flag indicates if the returned profile is generic. A flag can be specified in
the parameter list to request only the generic profiles in a given class. If only
the discrete profiles are desired, check the output flag indicating whether the
returned profile is generic. If it is, ignore the entry and terminate your
extract-next processing.
2. For a caller with little RACF authority, a large amount of I/O may be
performed against the RACF database until such a profile is located. This is no
different from the LISTUSER *, LISTGRP *, or RLIST class-name * command.
The IRR.RADMIN.LISTUSER, IRR.RADMIN.LISTGRP, and IRR.RADMIN.RLIST
resources in the FACILITY class can be used to limit which users are allowed to
use the extract and extract-next interfaces.
3. The following are characteristics of the extract functions:
v Are not subject to the 4096 limit on output lines like the list functions
described.
v Provide similar functions as ICHEINTY LOCATE and RACROUTE
REQUEST=EXTRACT, but do not provide all of the functions provided by
those interfaces.
v Run in the caller's address space, not in the RACF address space. Therefore,
are faster than the R_admin list functions and do not contend with other
functions, such as the RACF Remote Sharing Facility, for RACF subsystem
address space resources.
v Are available to problem state callers, and require the same authority as do
the corresponding RACF commands (e.g. LISTUSER), plus the FACILITY
class check enforced by R_admin. Supervisor state callers can choose to
bypass command authorization checking. The FACILITY check is not
enforced for supervisor state callers by default. However, the caller can
request that the check be performed.
The following header mapping is used both as input, for the caller to identify the
requested profile, and as output, for RACF to return the profile data.
Note: These are two separate pieces of storage and RACF will not modify the
caller's input storage.
Note: All offsets are relative to the start of the extract output block.
Table 30. Profile extract parameter list (input and output)
Offset Length Description
0 4 Eye catcher to aid in virtual storage dumps: 'PXTR'
4 4 Total length of the output buffer
8 1 Subpool of output buffer (specified by caller in
Out_message_subpool parameter )
9 1 Parameter list version
10 2 Reserved
12 8 Class name (uppercase and padded with blanks). Class
names cannot be abbreviated.
20 4 Length of profile name (maximum of 8 for users and
groups; maximum of 17 for connects; maximum of 246 for
general resources)
24 8 Reserved
32 4 Reserved
36 4 Flag word
Note: RACF only propagates the "generic" flag
(X'10000000') into the output version of the parameter list.
When using extract-next, the caller must set the other flags
as appropriate in the parameter list before calling R_admin
for the next iteration.
x'80000000' Bypass command processor (e.g. LISTUSER) authorization
checking. Available for supervisor state callers only.
x'40000000' Extract BASE segment only. By default, RACF will extract
all profile segments, resulting in an I/O operation for each
segment.
Table 30. Profile extract parameter list (input and output) (continued)
Offset Length Description
x'20000000' For supervisor state callers, enforce the FACILITY class
authorization check. By default, the FACILITY check is
bypassed for supervisor state callers.
X'10000000' For general resource requests only.
On input:
v For extract requests: return the profile which covers the
input profile name if there is no exact match. By default,
if there is no exact match on profile name, a "not found"
return code combination (4/4/4) will be returned. Note
that the class must be active, and SETROPTS GENERIC
must be in effect for the class, in order for a generic
match to be found.
v For extract-next requests: return the next alphabetic
generic profile in the class with respect to the input
name (regardless of whether the profile is generic or
discrete). To retrieve the first generic profile in a class,
the caller can provide a resource name consisting of a
single blank (X'40').
The caller then places the profile name after the header.
For the extract-next functions, the caller can invoke RACF iteratively, using as
input the block which RACF previously returned as output. For example:
1. Construct an input parameter list, as previously described, where the profile
name consists of a single blank character (X'40').
2. Set the Parm_list parameter to the address of the header just created.
3. Call IRRSEQ00.
4. Process the output returned by RACF in the Out_message_strings parameter.
The output header, using the profile name offset, length, and value fields, will
identify the profile which was extracted.
On output: The output storage is obtained in the subpool specified by the caller
in the Out_message_subpool parameter. It is the responsibility of the caller to free
this storage.
Note: Even though the profile name and the subpool are specified by the caller on
input, that information, along with the class name, is also contained in the output
block so that it is as self-descriptive as possible.
Segment and field descriptors will be returned as shown in the preceding diagram,
following the header. Segment descriptors will only be returned for segments
which exist within the profile, and which the requester is authorized to see.
For each segment descriptor, a set of field descriptors will be returned. There is no
defined order in which fields are returned. The types of fields are:
v Boolean - A flag in the descriptor indicates whether the value is TRUE or FALSE.
There is no data returned and the offset value will be 0.
v Character - A simple character string.
v Repeat - An array of character strings and/or booleans. “Repeat fields” on page
109descibes these in more detail.
Field data will only be returned if the requester is authorized to read the field.
Also, if a field does not have a value in a given profile, usually no field descriptor
will be returned. The exception to this rule is for multidimensional repeat fields as
described. The number of field descriptors must be the same for each occurrence of
the repeat field, so that the entire field may be quickly skipped if you want,
described as follows. Therefore, if a given subfield within a repeat field occurrence
has no value, for example, the revoke or resume date of a group connection in a
USER profile, then a field descriptor will be present but the length of the data will
be zero. A robust application should be written to expect this condition for any
field descriptor, however, in case this behavior changes in the future.
Repeat fields: A repeat field, also known as a list field, is a multi-valued field.
For repeat fields, a special field descriptor exists to act as a header to the
subsequent repeating data. Such a field descriptor can be recognized by its field
type value of '1000'x. This descriptor does not 'point' to field data, but, it indicates
how many occurrences of the repeat group exist, and how many 'subfields'
comprise a single repeat group occurrence. The information in this descriptor can
be used to completely bypass the entire repeat field if the field is not of interest to
the caller. Following this header are individual field descriptors for each subfield of
each occurrence. These descriptors contain offsets to the actual data. For
multidimensional repeat fields, the order of the subfields will be constant for every
occurrence of the repeat field. See Table 34.
Table 33, is an example of a 1-dimensional repeat group, the user's class authority
(CLAUTH). The user has CLAUTH for the FACILITY, UNIXPRIV, and OPERCMDS
classes. The following is a schematic representation of how such a field would be
represented:
Table 33. Repeat example 1
Total number of Dimension of repeat
Field name Value occurrences group
CLCNT N/A 3 1
CLAUTH FACILITY N/A N/A
CLAUTH UNIXPRIV N/A N/A
CLAUTH OPERCMDS N/A N/A
a field descriptor, for each subfield of a repeat group occurrence, times the number
of subfields in an occurrence, 2 in this example, times the number of occurrences, 4
in this example.
A repeat field is treated as a single logical field. That is, the field count within a
segment descriptor is only taking the list header field into account, regardless of
the dimension of the field, or the number of occurrences within it. If you are
iterating through the fields associated with a given segment, and are decrementing
the count field in order to determine when that segment's fields have been
exhausted, decrement the count by only 1 for any list field which you encounter.
Table 35. Field tables by profile type
Profile type Field tables
USER User field tables in “User administration” on
page 425
GROUP Group field tables in “Group
administration” on page 436
CONNECT Connect field tables in “Group connection
administration” on page 438
General resource General resource tables in “General resource
administration” on page 439
Examples: The following examples are not coding samples. Rather, they
demonstrate how to construct the input parameter list for a number of requests.
Example 1
Extract the contents of the IBMUSER profile. Request only the base
segment, and request that authorization be bypassed (caller is in supervisor
state).
Function code = ADMN_XTR_USER
HEADER DS 0H
DC CL20’’ Unused (note class name optional)
DC AL4(7) Length of user ID
DC CL12’’ Unused
DC XL4’C0000000’ Flag word - BASE only+skip auth
DC CL20’’ More unused
NAME DC CL7’IBMUSER’ User ID name
Example 2
Start an iterative extract by using extract-next starting with a profile name
of blank.
Function code = ADMN_XTR_NEXT_USER
HEADER DS 0H
DC CL20’’ Unused (note class name optional)
DC AL4(1) Length of "user ID"
DC CL12’’ Unused
DC XL4’00000000’ Flag word - none specified
DC CL20’’ More unused
NAME DC CL1’ ’ "User ID" name of 1 blank
Example 3
Extract group profile FINANCE. Take the defaults of returning all existing
segments and performing LISTGRP authorization.
Function code = ADMN_XTR_GROUP
HEADER DS 0H
DC CL20’’ Unused (note class name optional)
DC AL4(7) Length of group name
DC CL12’’ Unused
DC XL4’00000000’ Flag word - none specified
DC CL20’’ More unused
NAME DC CL7’FINANCE’ Group name
Example 4
Extract the connection information for user BRUSCHI in group PATRIOTS.
Function code = ADMN_XTR_CONNECT
HEADER DS 0H
DC CL20’’ Unused (note class name optional)
DC AL4(16) Length of connect name
DC CL12’’ Unused
DC XL4’00000000’ Flag word - none specified
DC CL20’’ More unused
NAME DC CL16’BRUSCHI.PATRIOTS’ Connect name
Note:
a. Although conceptually similar, this is a different format from the output
produced by the profile extract functions.
b. The IRRXUTIL program provides a REXX interface to the SETROPTS extract
format. The IRRXUTIL program is designed to be invoked by REXX in
problem state, and converts the output of an R_admin extract request to a
set of REXX stem variables. For more information, refer to z/OS Security
Server RACF Macros and Interfaces.
The unload format is available only to supervisor state callers. The extract format
is available to both supervisor and problem state callers.
The mapping of the output message block returned by R_admin for the
ADMN_XTR_SETR and ADMN_UNL_SETR function codes is as follows. The
output storage is obtained in the subpool specified by the caller in the
Out_message_subpool parameter of IRRSEQ00, and is returned in the
Out_message_strings parameter. It is the responsibility of the caller to free this
storage:
Table 37. Output message block
Offset Length Description
0 4 Eye catcher to aid in virtual storage dumps: 'RXTR' or
'RUNL'
4 4 Total length of the output buffer
8 4 Reserved
12 2 Number of segment entries for ADMN_XTR_SETR
(always 1 for the BASE segment), or number of record
types returned for ADMN_UNL_SETR
14 0 Start of the BASE segment entry (for extract) or the first
record entry (for unload)
For ADMN_XTR_SETR, the output consists of a single segment entry for the base
segment, followed by field entries for each of the supported input fields
documented in “SETROPTS administration” on page 452.
Note: Not all of the fields are returned, and fields that are not returned are noted
in the field table.
There is no defined order in which fields are returned. The segment and field entry
for ADMN_XTR_SETR uses the standard ADMN_USRADM_SEGENTRY and
ADMN_USRADM_FLDENTRY mappings used by other R_admin functions. See
“Segment and field entry mappings” on page 421 for details.
For ADMN_UNL_SETR, the output data is mapped using the following mapping
for each unloaded record type, the number of which is contained in
ADMN_EXTRACT_NUM. There is a single record type of "RACFINIT" to describe
the basic RACF options. Following this record is a series of records of type
"CLASNAME". There are as many "CLASNAME" records as there are classes
defined in the class descriptor table (CDT). These include classes supplied by IBM
(ICHRRCDX), installation-defined classes defined in ICHRRCDE, and classes in the
dynamic class descriptor table. Columns 44 through 51 of each record identify the
name of the class that the record describes. See z/OS Security Server RACF Macros
and Interfaces for detailed mappings of these record types.
The following table is the mapping of the output message block returned by
R_admin for the ADMN_XTR_PWENV and ADMN_XTR_PPENV function codes.
The output storage is obtained in the subpool specified by the caller in the
Out_message_subpool parameter.
Table 39. Output message block
Offset Length Description
0 4 Eye catcher to aid in virtual storage dumps: "RXPW"
for password envelope and "RXPP" for password
phrase envelope.
4 1 Subpool of this block
5 3 Total length of the output buffer
8 0 Start of the encrypted envelope
Note that the RACF certificate is required to verify the signature of the envelope.
See the description of the RACF password and password phrase enveloping
function in z/OS Security Server RACF Security Administrator's Guide on how the
recipient can obtain the RACF certificate.
PKCS #7 defines several data types using ASN.1 notation to describe them. Each
type is contained in a ContentInfo type. ContentInfo simply identifies the
contained data type with an object identifier (OID), followed by the actual data.
See section 7 of the PKCS #7 standard.
SignedData contains a field called contentInfo, which is the data being signed. This
data can be of any of the types defined by the standard. The type we use is Data,
so the contentInfo field within SignedData contains the ContentInfo for the Data
type. The Data type is defined as OCTET STRING. This OCTET STRING is the
payload that RACF is constructing as input to the whole envelope-creation process.
The payload contains password related information in BER-encoded ASCII format.
The following is the ASN.1 notation describing the password phrase payload as
constructed by RACF:
PasswordphrasePayload::=SEQUENCE{
Version INTEGER
Expired BOOLEAN
Passwordphrase UTF8String
Changetime IA5String
Language IA5String OPTIONAL DEFAULT "ENU"
}
Version is the version number of the payload. For the password payload, it is set
to 1 if the password has been changed to lowercase, or 2 if the password appears
as entered. For the password phrase payload, it is set to 1.
Expired will be true if the new password or password phrase is marked as expired
at the time of the change (for example, an ALTUSER command is used to change
the password or password phrase without specifying the NOEXPIRED operand). If
Expired is true, the password or password phrase must be changed the next time
the user logs on.
Password is the value of the new password. If the mixed case password support is
not active, the password is in lowercase. If it is active, the password case is as
entered.
Passwordphrase is the value of the new password phrase, with case preserved.
Language is the 3 character language code which RACF has used in order to
determine the UTF-8 code points for the variant characters. This is for diagnostic
purposes. Currently, RACF assumes the language is U.S. English ('ENU'). This may
result in RACF propagating a different password or password phrase than may be
expected by a given user using a given keyboard and code page. If so, users
should avoid using variant characters in passwords and password phrases when
RACF is participating in a password synchronization network. For example, a
person in the United Kingdom may enter the pound sterling symbol as a character
in a new password. This is represented as X'5B', which RACF will accept. When
RACF envelopes this password assuming U.S. English, the UTF-8 code point for '$'
will be used. If this password is propagated to another system, and the person
tries to log on to that system using the same keystrokes he used to change his
password in RACF, the password will be rejected.
The IRRXUTIL program provides a REXX interface to the RRSF settings extract
function. The IRRXUTIL program is designed to be invoked by REXX in problem
state, and converts the output of an R_admin extract request to a set of REXX stem
variables. For more information, refer to z/OS Security Server RACF Macros and
Interfaces.
The following structure is repeated 4 times in each of the 112 byte data areas
previously described.
Table 41. Mapping of Set settings (ADMN_XTRSF_SET_USER_INFO)
Offset Length Description
0 8 RRSF node to which to send output or notification. This
will be blank when the user ID is "&RACUID", or when
the entry is not in use.
8 8 RRSF user id to whom to send output or notification. This
will be blank when the entry is not in use.
16 6 OUTPUT level, one of ALWAYS, WARN, FAIL, N/A. This
will be "N/A" when the entry is not in use.
22 6 NOTIFY level, one of ALWAYS, WARN, FAIL, N/A. This
will be "N/A" when the entry is not in use.
The value of all offset fields is the offset from the beginning of
out_message_strings to the following structure (ADMN_XTRSF_DATA). Fields with
no value will have an offset to a structure with a length of 0.
Table 43. Offset field values (ADMN_XTRSF_DATA)
Offset Length Description
0 4 Length of data. If no data exists, the length will be 0.
4 * Data
Function
The R_audit service provides an audit interface for functions that need to write an
audit record for a condition where an audit by a security check service is not
sufficient.
This service fills in the base part of the record and some standard relocate sections
based on the function code in the CRED and the defined input parameters.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSAU00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, CRED,
ALET, File_Identifier_1,
ALET, FSP1,
ALET, File_deleted_flag,
ALET, File_Identifier_2,
ALET, FSP2
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
CRED
The name of the CRED structure for the current file system syscall.
File_Identifier_1
The name of a 16-byte area containing a unique identifier of the file identified
by the old (or only) pathname specified on the syscall.
FSP1
The name of the IFSP for the old (or only) file.
File_deleted_flag
For system calls that can cause a file to be deleted, the address of a byte
containing a flag:
v 0 - the last link was not removed.
v 1 - the last link was removed for a file. The file is deleted.
File_Identifier_2
For system calls that create a new file name. If the “new” file existed, this is
the name of a 16-byte area containing a unique identifier of the “new” file.
FSP2
The name of the IFSP for the new file.
Usage notes
1. This service can be called by the MVS BCP, by a z/OS UNIX file system, or by
z/OS UNIX servers. The service contains support for z/OS UNIX servers, but
cannot be directly invoked by an z/OS UNIX server.
2. IRRSAU00 tests whether auditing is required and, if so, builds and writes an
audit record. The record built contains data from the calling process's security
attributes (USP) and from the input CRED, the input IFSPs, and the input
parameters. The content depends on the function being audited, as determined
from the CRED_audit_function_code.
3. See z/OS Security Server RACF Macros and Interfaces for tables describing the
data included in audit records, the data included in each event record, and
syscalls that cause the event records to be written.
Related services
None
Function
The R_auditx callable service generates an SMF type 83 audit record to record a
security-related event and optionally issues a message indicating an authorization
failure to the console. This service is intended for use only by components of z/OS
that require the ability to log security-related events. The subtype must be defined
to RACF or an equivalent security product. Contact IBM to determine the
appropriate SMF type 83 record subtype to use.
Requirements
Authorization:
Any PSW key in supervisor state or problem state
Dispatchable unit mode:
Task
Cross memory mode:
PASN = HASN
AMODE:
31 or 64
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
FRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing ALETs must be in the primary address space.
The Num_parms parameter must be in the primary address space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the Num_parms parameter must
indicate the number of parameters in the parameter list.
RACF authorization
For callers not running in system key or supervisor state, the use of R_auditx is
authorized by the resource IRR.RAUDITX in the FACILITY class. The caller must
be running with a RACF user or group that has at least READ authority to this
resource. If the class is inactive, or the resource is not defined, only callers running
with a system key or in supervisor state may use the R_auditx service.
Format
For 31-bit callers, every parameter address is 4 bytes in length:
For 64-bit callers, every parameter address is 8 bytes in length. The module name
is different but has the same number and order of parameters:
For C callers (31 or 64 bit), include sample irrc.h, which defines the rauditx
prototype with the same number and order of parameters:
#include <irrc.h>
int rauditx (Work_area,...)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a 4–byte area in which the SAF router returns the SAF return
code.
RACF_return_code
The name of a 4–byte area in which the service routine stores the return code.
RACF_reason_code
The name of a 4–byte area in which the service routine stores the reason code.
Num_parms
The name of a 4-byte area containing the number of parameters in the
parameter list, including the Num_parms parameter. This parameter must be
in the primary address space. It must be initialized to 26.
ACEE_ALET
The name of a 4-byte area containing the ALET for the ACEE pointed to
named by the ACEE_ptr parameter. The 4-byte area must be in the primary
address space.
ACEE
The name of an area containing the ACEE belonging to the RACF user that
should appear in the log record. An ACEE may only be specified by a caller in
supervisor state or system key. The ACEE must begin with eyecatcher "ACEE".
Otherwise, the area must contain binary zeros in the first 4 bytes. When the
area contains binary zeros, RACF uses the task-level ACEE if found, or the
address space ACEE.
Parm_ALET
The name of a 4-byte area containing the ALET for the remaining parameters
in the parameter list and any data areas referenced by parameter list pointers.
The word containing the ALET must be in the primary address space.
Option_word
The name of a 4-byte area containing binary zeros. This area is reserved for
future use.
Link_value
The name of an 8-byte area containing a value used to mark related SMF
records. Since a single event may result in multiple calls to R_auditx for
logging, you can logically link the records by specifying a common value such
as a time stamp. Otherwise, fill the area with binary zeros.
Attributes
The name of a 4-byte area containing flags set by the caller. Possible attribute
values are the following:
x'80000000'
Event Result. Used to indicate if the event was a success or a failure.
Success if flag is set. Failure if flag is not set.
x'40000000'
Authentication Event. Use logging defaults for authentication events
described in the usage notes.
x'20000000'
Authorization Event. Use logging defaults for authorization events
described in the usage notes.
x'10000000'
Always log successes.
x'08000000'
Always log failures.
x'04000000'
Never log successes.
x'02000000'
Never log failures.
x'01000000'
Check warning mode.
Set any combination of attributes flags except the following pairs that directly
conflict with each other:
’Authentication Event’ & ’Authorization Event’
’Always log successes’ & ’Never log successes’
’Always log failures’ & ’Never log failures’
’Never log success’ & ’Never log failures’
Refer to the usage notes for additional information about the priority of these
flags for logging determination.
Component
The name of an area that consists of a 4-byte length field followed by character
data. The character data is the name of the product or component calling the
R_auditx service. The length represents the length of the character data. The
maximum length of the data is 255. The component is required, therefore, the
length must be greater than zero.
FMID
The name of a 7-byte area containing the FMID of the product or component
calling the R_auditx service.
Subtype
The name of a 4-byte integer with the SMF type 83 record subtype assigned to
the component. The value may range from 2 to 32767, but should match the
subtype assigned to the component. Assigned subtypes are:
Event
The name of a 4-byte integer which the caller initializes with the event code.
The value may range from 1 through 255.
Qualifier
The name of a 4-byte integer which the caller initializes with the event code
qualifier. The value may range from 0 through 255.
Class
The name of an 8-byte area containing a RACF class name. If not specified, the
area must contain all blanks. Otherwise, the class name is assumed to have the
following characteristics:
v Left justified
v Padded to the right with blanks
v Specified in uppercase
v A static IBM class name, a statically defined installation class name, or a
dynamically defined installation class name
v A general resource class
The class cannot be USER, GROUP, or DATASET. It must also be active and
RACLISTed.
Resource
The name of an area that consists of a 4-byte length field followed by a
resource name covered by a profile defined in the RACF class specified. The
length represents the length of the resource name. The maximum length is 246.
The resource name is ignored if the length is zero. Ensure the letter case of the
resource matches that defined for profiles in the class. For the RAUDITX class,
profiles must be uppercase so the resource name must be folded to uppercase
before being passed to this service. Some classes preserve case sensitivity for
profiles and corresponding resource names should not be folded. Refer to z/OS
Security Server RACF Macros and Interfaces for more information about class
definitions.
Log_string
The name of an area that consists of a 4-byte length field followed by character
126 z/OS Security Server RACF Callable Services
R_auditx
data to be written with the audit information. The length represents the length
of the character data. The maximum length of the log string is 255. If character
data is not specified, the length must equal zero.
Relocate_count
The name of a 4-byte area containing the number of relocate sections. The
maximum number of relocate sections is 512. The minimum is 0.
Relocate_ptr
The name of an area containing the address of an array of relocate sections. For
31-bit callers, this area is 4-bytes long. For 64-bit callers, this area is 8-bytes
long. The area is 4-bytes long. This parameter is ignored when the
Relocate_count parameter is zero. The number of entries in the array must
equal the value in the Relocate_count. The relocate is not added to the log
record when the length is zero. When the length is greater than zero, the
relocate data pointer must not be zero. An array entry for a 31 bit caller is:
Usage notes
1. This service is intended for use by components of z/OS that require the
ability to log security-related events.
2. The use of RACF audit controls is optional. A product or component that uses
its own mechanism for determining when to audit can pass in the appropriate
'always log' or 'never log' attributes for successes and failures to prevent the
service from continuing to the RACF checks.
3. The service determines when to log by comparing the event result attribute
flag (x'80000000') with auditing controls settings passed through logging
attribute flags or found in RACF definitions. The following table describes the
sequence of checks that the service makes. At any step for which 'log' or 'no
log' is determined, the service ends the checking process.
Settings Action
Input Attribute Checks:
a. The caller specified 'authentication event' log if failure, otherwise, skip to
RACF checks
b. The caller specified 'authorization event' skip to RACF checks
c. The caller specified 'always log successes' log if success
d. The caller specified 'always log failures' log if failure
e. The caller specified '' no log if success
f. The caller specified 'never log failures' no log if failure
RACF Checks:
g. UAUDIT was specified for the user. ALTUSER log
RACFU00 UAUDIT
RACF Checks if Class Specified:
h. SETROPTS LOGOPTIONS(NEVER(class)) no log
i. SETROPTS LOGOPTIONS(ALWAYS(class)) log
j. SETROPTS LOGOPTIONS(SUCCESSES(class)) log if success
k. SETROPTS LOGOPTIONS(FAILURES(class)) log if failure
l. If a covering resource profile is found in the class, the log if success or failure with
AUDIT and GLOBALAUDIT settings are checked. corresponding AUDIT or
RALTER class profile AUDIT(ALL | SUCCESSES | GLOBALAUDIT settings
FAILURES | NONE)
Default if prior steps do not determine logging
m. Always no log
4. The SMF Type 83 subtype must be one defined in z/OS Security Server RACF
Macros and Interfaces. Contact IBM if you need to define a subtype for your
component.
5. The SMF Type 83 record contains the following types of information:
a. The record subtype
b. The name of the component and release that detected the event
c. The event, the event code qualifier, RACF release, and an indicator if the
event was a success or a failure
d. The reasons this event was logged. Did the calling application require it?
Was SETROPTS LOGOPTIONS used? Was there a profile in the specified
class covering the resource name associated with the event that had
AUDIT or GLOBALAUDIT settings? Was UAUDIT specified for the end
user? Many of these conditions could be valid for auditing the event, but
only the first check that passes in the list of checks will be listed as the
reason for auditing.
e. Information about the user
f. Additional data about the event
6. The class must be a general resource class defined in the class descriptor table
(CDT). It must be active and RACLISTed. The length of the resource name
cannot exceed the length defined for profiles in the class. Generics may be
used if they are enabled for the class.
7. The service will issue two multiline messages if the event is logged and the
caller specified event result 'Failure' and the Message_count greater than zero.
The first message is generated directly from the message segment data
referenced by the Message_ptr parameter. The message text should be
uppercase and contain component-specific details about the event. The first
line should begin with a component message ID of 15 characters or less, as in
the following example:
COMP123I THE USER [email protected] ATTEMPTED TO UPDATE THE PRICE LIST WITHOUT PERMISSION.
THE TRANSACTION RECORD IS TJV04123.
The second message includes associated information collected by R_auditx as
in the following example:
IRRY000I A SECURITY-RELATED EVENT HAS BEEN LOGGED.
COMPONENT(EXPRESSO SERVICES)
EVENT(AUTHORIZATION) TYPE(FAILURE) MESSAGE(COMP123I)
USER(JOE) GROUP(JAVACLUB) NAME(JOE T. COFFEE)
CLASS(RAUDITX) PROFILE(COMP.RESOURCE.*)
The messages are routed to the security and programmer consoles (route
codes 9 & 11) with the job status descriptor (6).
8. This service does not make use of the access levels (ALTER, READ,
CONTROL, UPDATE) that may be specified with the RDEFINE AUDIT,
RALTER AUDIT GLOBALAUDIT, and SETROPTS LOGOPTIONS commands.
9. An invoker of this service may call it several times, each time requiring a
slightly different set of relocate sections. To allow these types of applications
to reuse a single definition of the arrays of relocate sections, the service will
skip over any relocate section that has a length of zero.
10. R_auditx supports warning mode. Warning mode is a feature of RACF that
allows installations to try out security policies. Installations can define a
profile with the WARNING attribute. When RACF performs an authorization
check using the profile, it will log the event (if there are audit settings), issue a
message to the operator's console if the check failed, and allow the
authorization check to proceed. The messages and log records can be
monitored to ensure the new policy is operating as expected before putting
the policy into production by turning off WARNING attribute.
A component which wants to provide a similar capability must first perform
its authentication or authorization check. When it calls R_auditx to perform
the logging, it must indicate to R_auditx using an attribute bit on the call that
it is able to bypass authentication or authorization failures (for example,
undoing the failure). R_auditx will proceed through its list of checks for
logging. If it reaches the point where it searches for a profile and detects that
the WARNING mode indicator is on for the profile, then R_auditx will log the
event as indicated by the AUDIT and GLOBALAUDIT options, issue any
messages to the operator's console for failures, and then return to the caller
with a 0/0/8 return code. The component can then allow the security event to
continue as if it succeeded.
Related services
None
Function
The R_cacheserv SAF callable service provides a mechanism for the storage and
retrieval of security relevant information from a cache.
Function codes X'0001' through X'0005' only: In addition, the entire cache can be
automatically hardened to the security product (RACF) database, and restored as
needed.
Requirements
Authorization:
Any PSW key in supervisor state or problem state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have a FRR active
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. Use the NumParms parameter to indicate the number
of parameters specified.
RACF authorization
Function codes X'0001' through X'0005' only: For callers not running in system key
or supervisor state, the use of R_cacheserv is authorized by the resource
IRR.RCACHESERV.cachename in the FACILITY class. The application server must
be running with a RACF user or group that has at least READ authority to this
resource. READ allows the application server to utilize the Fetch function, x'0004',
while UPDATE authority provides the capability to use all the functions.
Function code X'0006' only: For callers not running in system key or supervisor
state, the use of R_cacheserv is authorized by the resource
Function code X'0007' only: For callers not running in system key or supervisor
state, the use of R_cacheserv is authorized by the resource
IRR.RCACHESERV.ICRX in the FACILITY class. The application server must be
running with a RACF user or group ID at the address space level that has at least
READ authority to this resource, and the FACILITY class must be active and
RACLISTed. READ authority allows the application server to utilize the
RetrieveAppl and Remove options (X'0002' and X'0003'), while UPDATE authority
provides the capability to use all of the options.
All function codes: If the class is inactive, or the resource is not defined, only
servers running with a system key or in supervisor state may use the R_cacheserv
service. Changes to the RACF user or group ID’s authorization to the facility class
profile will not take effect until the job step task invoking the R_cacheserv service
ends and a new one is started.
Format
CALL IRRSCH00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ParmALET,
NumParms,
Function_code,
Option,
Version,
Version_length,
Cache_name,
Record_name_ptr,
Record_name_length,
Data_ptr,
Data_length,
Data_timeout,
Source_ptr,
Source_length,
Reference_timeout,
Reference_userID,
Reference,
Subpool,
ACEE_ALET,
ACEE,
ICRX_area,
ICRX_length
)
Parameters
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a fullword containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
ParmALET
The name of a fullword that must be in the primary address space and
contains the ALET for the remaining parameters, not including the
ACEE_ALET and ACEE parameters.
NumParms
The name of a fullword containing the number of remaining parameters in the
parameter list, including the NumParms parameter. This number must be 19
for function code X'0006' or 21 for function code X'0007'. However, for
compatibility with prior releases, invokers who only use function codes X'0001'
through X'0005' can continue to specify a NumParms value of 10.
Function_code
The name of a half-word (2-byte) area containing the function code.
Function codes X'0001' through X'0005', function code X'0006', and function
code X'0007' are not compatible. In other words, function code X'0006' option
X'0003' cannot be used to retrieve a record that was added to a cache using
function code X'0002' and function code X'0004' cannot be used to fetch a
record that was stored using function code X'0006' option X'0001'. The function
code has one of the following values:
X'0001'-Start a new cache.
The cache is created and the caller is now ready to start adding records.
No one but the caller has access to the cache. The cache is not made
available to other callers at this time.
X'0002'-Add a record to the new cache.
The caller must provide a name for this record and the data associated
with the record. The caller calls this function multiple times, once per
record to complete the cache. Only the caller of function code X'0001' may
call function code X'0002'. A caller of function code X'0002' who is not the
same task as the one who called function code X'0001', will not be allowed
to add a record to the cache.
X'0003'-End cache creation.
Only the caller of function code X'0001' is allowed to end the creation of
the cache. A caller of function code X'0003' who is not the same task as the
one who called function code X'0001', will not be allowed to end cache
creation. This function is further defined by the Option parameter.
If the Option parameter is X'0001':
v The cache is made available, with system-wide name/token service, to
callers of function x'0004' so they can retrieve records from the cache.
Any previous cache of the same Cache-name is deleted.
v The cache is hardened to the RACF database if the CACHECLS class is
active and if a profile exists in that class with a profile name identical to
the Cache_name provided as input to R_cacheserv.
If the Option parameter is X'0002', discard the new cache and leave the
existing cache intact. This is used if the calling application determines that
something is wrong with the new cache or encounters an error while
creating it.
X'0004'-Fetch information from cache.
Retrieve information from the cache. This function is further defined by the
Option parameter.
If the Option parameter is X'0001' and the cache already exists, the
requested (by name) record is retrieved for the caller (or is not found). If
the cache does not exist yet (for example, immediately after IPL), a new
cache can be automatically restored and populated with records that were
hardened to the RACF database the last time someone called function code
x'0003'. The cache is restored if the CACHECLS class is active and the
cachename_ddd_nnnnn profiles containing the cache contents exist. Data
and Data_Length are updated.
If the Option parameter is X'0002', then retrieve the version number of the
existing in-storage cache. If no in-storage cache exists, retrieve the version
from the database-hardened copy of the cache. Do not restore the cache
from the database in this case. Version and Version_Length are updated.
X'0005'-Delete the cache.
This function is further defined by the Option parameter.
If the Option parameter is X'0001', then delete the in-storage cache only.
If the Option parameter is X'0002', then delete the hardened database copy
of the cache only.
If the Option parameter is X'0003', then delete both the hardened database
copy and in-storage cache.
X'0006'-Manage a read/write cache.
The function code X'0001-X'0005' cache is essentially a read-only cache. All
of the data is added to the cache before the cache is made available for
retrieval and if data needs to be changed a new cache must be created.
This function, X'0006', provides support for a read/write cache. Multiple
callers can store and retrieve cache data at the same time.
The read/write cache is not hardened to the RACF database.
This function is further defined by the Option parameter.
If the Option parameter is X'0001', then Store data in the read/write cache
and return a reference to the data.
v The caller can store the following records:
– A source record (Source_ptr parameter). The caller is responsible for
building the source record. It will be stored as binary data.
– An application data record (Data_ptr parameter). Like the source
record, the caller is responsible for building the application data
record and it will be stored as binary data. The caller must also
specify the name of the record (Record_name_ptr parameter), so that
the application data record can be found on a Locate request. The
caller can also store a null application data record, by specifying a
record name and a Data_length of zero.
If the caller is in supervisor state or system key and specifies a valid
ACEE on a Store request (option X'0001'), RACF will use the specified
v Locate uses the timeout interval that was specified when the application
data record was stored (Data_timeout parameter). When this interval
has expired, the record will not be found.
v The caller must specify a source record (Source_ptr parameter) and,
optionally, a reference timeout interval (Reference_timeout parameter).
If not specified, a default timeout value will be assumed.
v When the Locate is successful, the source record is stored in the cache
and a cache reference is returned. A cache reference consists of both a
reference value (Reference parameter) and an associated reference user
ID (Reference_userID parameter). The cache reference can be used to
retrieve the source record and the application data record(Retrieve
option), retrieve just the application data record (RetrieveAppl option),
or to remove the source record (Remove option).
A cache reference can only be used to retrieve or remove data one time.
When it has been specified, the cache reference is no longer valid.
RACF recommends that customers put the Integrated Cryptographic
Service Facility (ICSF) CSNBRNG module in the link pack area (LPA) or
the modified link pack area (MLPA) so that it can be used for generating
reference values (Reference parameter). If RACF cannot find CSNBRNG
in LPA or MLPA, it will default to using a less efficient software pseudo
random number generator (PRNG) for generating reference values.
If the Option parameter is X'0003', then Retrieve data from the read/write
cache.
v The caller must specify a cache reference. A cache reference consists of
both a reference value (Reference parameter) and an associated reference
user ID (Reference_userID parameter).
A cache reference can only be used to retrieve data one time. When it
has been specified, the cache reference is no longer valid.
v Retrieve uses the reference timeout interval that was specified on a
Store or Locate request (Reference_timeout parameter). When this
interval has expired, Retrieve will fail.
v When a Retrieve is successful, the following data can be returned:
– A source record (Source_ptr parameter). The Source_length
parameter contains the length of the record and the Source_ptr
parameter contains the name of a fullword containing the address of
the source record. Storage for the record is obtained in the subpool
specified by the caller (Subpool parameter) and the caller is
responsible for freeing it. A length of zero indicates that no source
record was returned.
– An application data record name (Record_name_ptr parameter). The
Record_name_length parameter contains the name of a fullword
containing the address of the application data record name. Storage
for the application data record name is obtained in the subpool
specified by the caller (Subpool parameter) and the caller is
responsible for freeing it. A length of zero indicates that no
application data record name was returned.
– An application data record (Data_ptr parameter). The Data_length
parameter contains the length of the record and the Data_ptr
parameter contains the name of a fullword containing the address of
the application data record. If the caller specifies an area and length
that is large enough to contain the application data record, RACF will
return the record in that area. If the caller specifies an area and length
that is too small to contain the record, RACF will obtain storage in
If the Option parameter is X'0006', then remove all expired records from
the read/write cache (RemoveExpired).
v RemoveExpired uses the timeout values specified when the data was
stored to determine which records are expired, so they are no longer
valid. Source records are removed based on the reference timeout
interval (Reference_timeout parameter) and application data records are
removed based on the data timeout interval (Data_timeout parameter).
v RACF does cache cleanup on a regular basis by doing an internal
RemoveExpired, so caller invocation of RemoveExpired processing is
optional.
If the Option parameter is X'0007', then Destroy the read/write cache.
v The read/write cache is destroyed. All references to data in the cache are
no longer valid.
Under normal circumstances, the caller should have no reason to
destroy the read/write cache. This option is provided only as a means
for a customer, working with IBM support, to recover from a
catastrophic cache error.
v A subsequent request to Store data will cause a new cache to be created.
The value of the Option parameter also determines how other
parameters will be used for Function_code X'0006'. For example, on a
Store (Option X'0001') request, Data_ptr is an input parameter and on a
Retrieve (Option X'0003') request, it is an output parameter. See the
description of Function_code X'0006' for more information.
X'0007'-Manage an extended read/write cache.
The cache for function codes X'0001-X'0005' is essentially a read-only cache.
All of the data is added to the cache before the cache is made available for
retrieval, and if data needs to be changed a new cache must be created.
Function code X'0006' provides support for a read/write cache of
distributed user information. Function code X’0007’ provides support for
an extended read/write cache containing both RACF and distributed user
information. Multiple callers can store and retrieve cache data at the same
time. The read/write cache is not hardened to the RACF database.
This function is further defined by the Option parameter.
If the Option parameter is X'0001', then locate the record if present. If the
record is not present, Store data in the read/write cache, and return an
extended context reference to the data.
RACF recommends that customers put the Integrated Cryptographic
Service Facility (ICSF) CSNBRNG module in the link pack area (LPA) or
the modified link pack area (MLPA) so that it can be used for generating
reference values (the ICRXREFR portion of the ICRX). If RACF cannot find
CSNBRNG in LPA or MLPA, it will default to using a less efficient
software pseudo random number generator (PRNG) for generating
reference values.
v If the caller is in supervisor state or system key and specifies a valid
ACEE on a Store request (option X'0001'), RACF will use the specified
ACEE to locate, or to build and store, an application data record name
and an application data record. The Source_length,
Record_name_length, Data_length parameters, and their associated data
parameters will be ignored. See the description of the ACEE parameter
for more information. The ACEE parameter is ignored unless specified
by a caller in supervisor state or system key.
outstanding context references will no longer find the record, and it will
not be used for subsequent store requests.
If the Option parameter is X'0004' (store and return reusable ICRX), then
processing proceeds as with Option X'0001', but the returned ICRX will be
marked as being reusable. This ICRX will be valid for multiple Option
X'0002' RetrieveAppl calls until it times out after an hour of inactivity.
If the Option parameter is X'0005' (validate the input ICRX), we will
validate the input ICRX and the IDID included in it. This function is
intended to validate the user-built ICRX that is provided by the application
to a subsystem like CICS®, not the completed ICRX that is returned by
RACF to the caller of R_cacheserv as is done with Option X'0001', which
contains the RACF user-id in ICRXUSER and the ICR. The caller must be
in supervisor state or system key.
The following fields will be validated:
v ICRX fields:
– ICRXID – The value must be the literal 'ICRX'
– ICRXVERS – The value must be greater than or equal to ICRXVR01
and less than or equal to the current version – ICRXCURV (currently
set to 2)
– ICRXOFFN – The number of offsets must be 3 (for versions 1 and 2
of the ICRX)
– ICRXFLGS – The value of this flag-byte must be 0
– ICRXLEN – The value must be greater than or equal to the length of
the ICRX header – ICRXHLN, and less than or equal to the length of
the ICRX provided in the R_cacheserv parameter list
– ICRXICRO – Must be 0
– ICRXDIDO – Must be equal to the length of the ICRX header –
ICRXHLN
– ICRXUSRO – Must be 0
v IDID fields:
– IDIDID – The value must be the literal 'IDID'
– IDIDVERS – The value must be greater than or equal to IDIDVR01
and less than or equal to the current version – IDIDCURV (currently
set to 1)
– IDIDOFFN – The number of offsets must be 5 (for version 1 of the
IDID)
– IDIDHSHN – The three high order bits of this bit string must be off
(0), and for any IDID section not specified (offset is 0), the
corresponding bit must be off (0)
– IDIDSP – The value must be the same as the value in ICRXSP
– IDIDLEN – The value must be greater than the length of the IDID
header – IDIDHLN, and the sum ICRXDIDO + IDIDLEN must be
less than or equal to the length of the ICRX – ICRXLEN
– IDIDOFF1 – Must be equal to the length of the IDID header –
IDIDHLN
– IDIDOFF2 – Must be 0
– IDIDOFF3, IDIDOFF4, and IDIDOFF5 – Must be either 0, or (if
non-zero) must be contained within the IDID and be in sequential
order.
Note: This parameter applies only to read-only caches. The function code
X’0006’ and X'0007' read/write cache is not hardened to the RACF database.
Record_name_ptr
Function codes X'0002' (Add) and X'0004' (Fetch) with Option X'0001' only.
Name of the address of the record name to be added or retrieved. The length
is specified in Record_name_length.
Function code X'0006' (Manage a read/write cache) with Options X’0001’
(Store), X’0002’ (Locate), X'0003' (Retrieve), and X’0004’ (RetrieveAppl) only:
Name of the address of the application data record name to be stored (option
X'0001') or located (option X'0002'), or name of a fullword where the address of
the application data record name is to be placed during retrieval (options
X'0003' and X'0004').
When an application data record is specified on a Store (option X'0001')
request, the caller must also specify the application data record name. The
caller is responsible for obtaining and freeing storage for the application data
record name. The length is specified in Record_name_length. When an
application data record is not specified on a Store request (Data_length is
zero), specification of an application data record name is optional.
If the caller is in supervisor state or system key and specifies a valid ACEE on
a Store request (option X'0001'), RACF will use the specified ACEE to build
and store an application data record name and an application data record. The
Record_name_ptr, Record_name_length, Data_ptr, and Data_length
parameters will be ignored. See the description of the ACEE parameter for
more information.
If no ACEE (see the parameter description for more information), source
record, application data record name, and application data record are specified
(Source_length, Record_name_length, and Data_length are all zeros) on a
Store request, RACF will build and store the application data record name and
the application data record using the task-level ACEE if found, or the address
space ACEE.
An application data record name built by RACF has the same structure as the
Identity Context Extension (ICTX) block described in z/OS Security Server RACF
Data Areas in the z/OS Internet library (www.ibm.com/systems/z/os/zos/
library/bkserv). RACF fills in the ICTXID, ICTXVERS, and values for:
v Authenticated user name: If no authenticated user name is available, RACF
sets ICTXUSRL to zero. When an application data record name is built from
an ACEE, RACF sets ICTXUSRL and the value pointed to by ICTXUSR@
from the ACEE user ID values (ACEEUSRL and ACEEUSRI).
v Registry name: If no registry name is available, RACF sets ICTXREGL to
zero. When an application data record name is built from an ACEE, RACF
sets ICTXREGL and the value pointed to by ICTXREG@ to the name of the
local RACF registry. The registry name is taken from an in-storage copy of
the LOCALREGISTRY field in the IRR.ICTX.DEFAULTS.sysid profile or
IRR.ICTX.DEFAULTS profile in the LDAPBIND class.
v Host name: If no host name is available, RACF sets ICTXHSTL to zero.
When an application data record name is built from an ACEE, RACF sets
ICTXHSTL and the value pointed to by ICTXHST@ to the SMF SYSID. The
system identifier is the 4-character value specified for the SID parameter of
the SMFPRMxx member of SYS1.PARMLIB. See z/OS MVS Initialization and
Tuning Reference for additional information about SMFPRMxx.
v Authentication mechanism object identifier (OID): If no authentication
mechanism object identifier (OID) is available, RACF sets ICTXMCHL to
zero. When an application data record name is built from an ACEE, RACF
sets ICTXMCHL and the value pointed to by ICTXMCH@ to OID value
"1.3.18.0.2.33.1".
When an application data record name is built from an ACEE, ICTXLEN is set
to the value that will be used for Record_name_length.
When Locate (option X'0002') is specified, the caller must provide an
application data record name and is responsible for obtaining and freeing
storage for the application data record name. The length is specified in
Record_name_length.
When Retrieve (option X'0003') or RetrieveAppl (option X'0004') is specified,
RACF obtains storage for the application data record name in the subpool
provided by the Subpool parameter. Storage will be obtained in the primary
address space. The caller is responsible for freeing this storage.
Record_name_length will be set to the actual length of the record name
retrieved.
This parameter is ignored for function code X'0007'.
Record_name_length
Function codes X'0002' (Add) and X'0004' (Fetch) with Option X'0001' only.
Name of a fullword containing the length of the record name to be stored or
retrieved. Valid values are 1 to 8192.
Function code X’0006’ (Manage a read/write cache) with Options X’0001’
(Store), X’0002’ (Locate), X’0003’ (Retrieve), and X'0004' (RetrieveAppl) only:
Name of a fullword containing the length of the application data record name
to be stored (option X'0001') or located (option X'0002'), or the length of the
application data record name retrieved (options X'0003' and X'0004').
When Store (option X'0001') is specified, a zero length indicates that the
application data record name has not been specified. Otherwise, valid values
are 1 to 8192.
When Retrieve (option X'0003') or RetrieveAppl (option X'0004') is specified,
Record_name_length will be set to the actual length of the record name
retrieved.
This parameter is ignored for function code X'0007'.
Data-Ptr
Function codes X'0002' (Add) and X'0004' (Fetch) with Option X'0001' only.
Name of the address of the data to be stored in cache (X'0002'), or name of the
address where data are to be placed during retrieval (X'0004'). Length is
specified in Data_length.
Function code X'0006' (Manage a read/write cache) with Options X'0001'
(Store), X'0003' (Retrieve), and X'0004' (RetrieveAppl) only: Name of the
address of the application data record to be stored (option X'0001'), or name of
a fullword where the address of the application data record is to be placed
during retrieval (options X'0003' and X'0004').
v When an application data record is specified on a Store (option X'0001')
request, the length is specified in Data_length.
v If the caller is in supervisor state or system key and specifies a valid ACEE
on a Store request (option X'0001'), RACF will use the specified ACEE to
build and store an application data record name and an application data
record. The Record_name_ptr, Record_name_length, Data_ptr, and
Data_length parameters will be ignored. See the description of the ACEE
parameter for more information.
The length of the application data record is equal to the length of the
ApplData structure plus the sum of the lengths of the data related to the
length and offset pairs. When an application data record is built from an
ACEE, RACF will set ApplUserIDLen and the value pointed to by
ApplUserIDOff from the ACEE user ID values (ACEEUSRL and ACEEUSRI).
v When Retrieve (option X’0003’) or RetrieveAppl (option X’0004’) is
specified, the caller can either specify the address where the output
application data record is to be placed, or RACF will obtain an area and
return the address of that area. If the caller specifies an area and length that
is large enough to contain the application data record, RACF will return the
record in that area, ALET qualified using the ParmALET. If the caller
specifies an area and length that is too small to contain the record, RACF
will obtain storage in the specified subpool (Subpool parameter) and will
return the address of the application data record along with SAF return code
0, RACF return code 0 and RACF reason code 16. The caller can also just
specify a length of zero to ask that RACF obtain storage without returning
the 0/0/16 return code. If RACF obtains storage for the return of the data
record, the storage will be obtained in the primary address space.
Data_length will be set to the actual length of the application data record
retrieved. The caller is responsible for freeing all application data record
output areas, either provided by the caller or obtained by RACF. A length of
zero indicates that no application data record was returned.
Function code X'0007' (Manage an extended read/write cache). Name of a
fullword where the address of the application data record is to be placed
during retrieval (option X'0002').
v When RetrieveAppl (option X'0002') is specified, the caller can either specify
the address where the output application data record is to be placed, or
RACF will obtain an area and return the address of that area. If the caller
specifies an area and length that is large enough to contain the application
data record, RACF will return the record in that area (ALET-qualified
through ParmALET parameter). If the caller specifies an area and length that
is too small to contain the record, RACF will obtain storage in the specified
subpool (Subpool parameter) and will return the address of the application
data record along with SAF return code 0, RACF return code 0 and RACF
reason code 16. The caller can also just specify a length of zero to ask that
RACF obtain storage without returning the 0/0/16 return code. If RACF
obtains storage for the return of the data record, the storage will be obtained
in the primary address space. Data_length will be set to the actual length of
the application data record retrieved. The caller is responsible for freeing all
application data record output areas, either provided by the caller or
obtained by RACF. A length of zero indicates that no application data record
was returned.
Data_length
Function codes X'0002' (Add) and X'0004' (Fetch) with Option X'0001' only.
Name of a fullword containing the length of the data in the record to be stored
or the amount of storage the caller has provided for retrieval. Valid values are
1 to 2,000,000,000.
When Function_code X'0004' (Fetch) and Option X'0001' are specified,
Data_length will be set to the actual length of the data requested. If return and
reason codes indicate that an insufficient length value was specified, resulting
in a return of partial data, use the updated Data_length value to obtain a
larger results area and resubmit the request.
Function code X'0006'(Manage a read/write cache) with Options X'0001'
(Store), X’0003’ (Retrieve), and X’0004’ (RetrieveAppl) only: Name of a
fullword containing the length of the application data record to be stored
(option X'0001'), or the length of the application data record retrieved (options
X'0003' and X'0004').
v When Store (option X'0001') is specified, a zero length indicates that the
application data record has not been specified. Otherwise, valid values are 1
to 8192.
v When Retrieve (option X’0003’) or RetrieveAppl (option X'0004') is specified,
the caller can either specify zero, indicating that RACF should obtain storage
for the output application data record, or specify the output area and the
length of the area. If the length of the caller-specified output area is large
enough to contain the application data record, RACF will use the area.
Otherwise, RACF will obtain storage for the output area. In either case,
Data_length will be changed to the actual length of the returned application
data record. A length of zero indicates that no application data record was
returned.
Function code X'0007' (Manage an extended read/write cache) with Option
X'0002' (RetrieveAppl) only: Name of a fullword containing the length of the
application data record retrieved.
v When RetrieveAppl (option X'0002') is specified, the caller can either specify
zero, indicating that RACF should obtain storage for the output application
data record, or specify the output area and the length of the area. If the
length of the caller-specified output area is large enough to contain the
application data record, RACF will use the area (ALET-qualified through
ParmALET parameter). Otherwise, RACF will obtain storage in the primary
address space for the output area. In either case, Data_length will be
(option X'0001’). To indicate that a record is no longer valid and should not be
used (option X’0003’), the ICRX_area contains the IDID identifying the record,
but does not contain a context reference.
For more information on extended identity context references and distributed
identity data (IDID), refer to z/OS Security Server RACF Data Areas in the z/OS
Internet library (www.ibm.com/systems/z/os/zos/library/bkserv).
ICRX_length
Function code X'0007' (Manage an extended read/write cache) only. Name of a
fullword containing the length of the ICRX to be used as the source of the
context reference to be retrieved or removed (options X'0002' and X'0003'), or
the actual length of the ICRX returned by store (option X’0001’).
Parameter usage
Function Start new cache Add record to End cache Fetch cache Delete cache
cache creation record
Function Code X'0001' X'0002' X'0003' X'0004' X'0005'
ParmALET In In In In In
NumParms In In In In In
Option N/A N/A In In In
Function Start new cache Add record to End cache Fetch cache Delete cache
cache creation record
Version In N/A N/A Out N/A
Version_length In N/A N/A In/Out N/A
Cache_name In In In In In
Record_name_ptr N/A In N/A In N/A
Record_name_length N/A In N/A In N/A
Data_ptr N/A In N/A In/Out N/A
Data_Length N/A In N/A In/Out N/A
Data_timeout N/A N/A N/A N/A N/A
Source_ptr N/A N/A N/A N/A N/A
ACEE N/A N/A N/A N/A N/A
Source_length N/A N/A N/A N/A N/A
Reference_timeout N/A N/A N/A N/A N/A
Reference_userID N/A N/A N/A N/A N/A
Reference N/A N/A N/A N/A N/A
Subpool N/A N/A N/A N/A N/A
ACEE_ALET N/A N/A N/A N/A N/A
Usage notes
1. An ALET must be specified for the SAF_return_code, RACF_return_code, and
RACF_reason_code parameters, and a single ALET specified for all of the
remaining parameters, not including the ACEE_ALET and ACEE parameters.
The ALET for the ACEE parameter must be specified separately, using the
ACEE_ALET parameter.
2. The parameter list for this callable service is intended to be variable length to
allow for future expansion. Therefore, a parameter containing a count of
parameters is used: NumParms. This parameter tells how many parameters
appear in the list following and including the NumParms parameter.
NumParms must be set to 19 for function code X'0006' or 21 for function code
X'0007'. However, for compatibility with prior releases, invokers who only use
function codes X'0001' through X'0005' can continue to specify a NumParms
value of 10.
3. Use of the Add function code first requires an invocation of R_cacheserv with
the Start function code. After all records have been added, R_cacheserv must
be invoked one additional time with the End function code to indicate that
the cache has been filled and should be made available for use. Only the
issuer of Start (same task) can Add and End.
4. To allow the R_cacheserv callable service to harden/restore the cache to/from
the RACF database as profiles in the CACHECLS class, two steps must be
taken:
a. the class must be made active by the RACF SETROPTS CLASSACT
command, that is, SETROPTS CLASSACT(CACHECLS)
b. a base profile for this cache must be defined in the CACHECLS class using
the RACF RDEFINE command, that is, RDEFINE CACHECLS cachename,
where cachename is the Cache_name given as input to the R_cacheserv
callable service.
Unless both of these steps are taken, the harden and restore phases of the End
and Fetch functions, respectively, will not be performed for the cache
identified by Cache_name.
5. When the cache is hardened to the RACF database, the cache contents are
written to the database as profiles containing 50K pieces of the cache with the
last profile's size being less than or equal to 50K. The names of the profiles are
constructed from the input Cache_name parameter by adding the values
_ddd, where ddd is the sequential dataspace number (in decimal), starting
with 001 and _nnnnn, where nnnnn is the number of the profile containing
cache information for that dataspace, also in decimal. The first 50K of the
cache is written as cachename_001_00001, the second as
cachename_001_00002, and so on. The profiles will be created with the same
owner as that of the base profile.
6. If a request is made to Start a cache, followed by any number of Add
requests, then Start is requested again for the same cache name without an
intervening End request, this will result in the Start of a new empty cache,
causing all records that were previously added to be discarded.
7. If a Start, Add, or End (Option X'0001') results in a SAF return code of 8, the
state of the cache is undefined and it is highly recommended that R_cacheserv
be invoked again, specifying End with Option X'0002' to discard the new
cache, leaving the existing cache intact. Note that if the SAF return code 8 was
caused by an ABEND during Start or Add, End with Option X'0002' will
result in SAF return code 8 with RACF return code 8 and RACF reason code
36, indicating that the new cache was already discarded during ABEND
recovery processing.
8. If more than one record is added to the cache with the same name (specified
using the Record_name_ptr parameter), Fetch results are unpredictable.
9. The dataspaces that form the cache are associated with the master address
space and are persistent so that records in the cache can be fetched from any
address space. Function code X'0005' can be used to delete the cache when its
contents no longer need to be accessed.
10. Function codes X'0001' through X'0005', function code X'0006', and function
code X'0007' are not compatible. In other words, function code X'0006' option
X'0003' cannot be used to retrieve a record that was added to a cache using
function code X'0002' and function code X'0004' cannot be used to fetch a
record that was stored using function code X'0006' option X'0001'.
11. For function code X'0006', Manage a read/write cache, and function code
X'0007', Manage an extended read/write cache, when a parameter list error is
detected, R_cacheserv returns SAF return code 8, RACF return code 12, and
RACF reason code nn, where nn indicates the position in the parameter list of
the parameter in error. For example, the NumParms parameter is the 9th
parameter in the parameter list, so if an invalid value is supplied, R_cacheserv
will return SAF return code 8, RACF return code 12, and RACF reason code 9.
12. If a supervisor state or system key caller specifies a valid ACEE on a Store
request (option X’0001’), RACF will use the specified ACEE to build and store
an application data record name and an application data record. The
Record_name_ptr, Record_name_length, Data_ptr, and Data_length
parameters will be ignored. See the description of the ACEE parameter for
more information.
If no ACEE (see the parameter description for more information), source
record, application data record name, and application data record are specified
(Source_length, Record_name_length, and Data_length are all zeros) on a
Store request, RACF will build and store the application data record name
and the application data record using the task-level ACEE if found, or the
address space ACEE..
13. R_cacheserv does not use the parmALET value when it obtains storage for the
application data record name, the application data record, the ICRX, or the
source record. Storage will always be obtained in the primary address space.
14. When RACF is enabled for sysplex communication and it determines that an
R_cacheserv retrieve or remove request (function code X’0006’, options X'0003',
X'0004', or X'0005' and function code X'0007', options X'0002' and X'0003') is for
data that is cached on another member of the sysplex, RACF will attempt to
retrieve or remove the data from the other member. See z/OS Security Server
RACF System Programmer's Guide for more information about how to enable
RACF for sysplex communication.
15. RACF recommends that customers put the Integrated Cryptographic Service
Facility (ICSF) CSNBRNG module in the link pack area (LPA) or the modified
link pack area (MLPA) so that it can be used for generating reference values
(Reference parameter). If RACF cannot find CSNBRNG in LPA or MLPA, it
will default to using a less efficient software pseudo random number
generator (PRNG) for generating reference values.
16. The RACF read/write cache, function code X'0006', has a capacity limit of 2
GB. Assuming that application data records are less than 500 bytes, the cache
can contain a maximum of approximately 4 million records at any point in
time. When data records are in the 501-1000 byte range, the maximum number
of cached records will be approximately 2 million. However, RACF does cache
cleanup regularly by doing an internal RemoveExpired, so it is unlikely that
cache limits will be reached.
17. Function code X'0007', option X'0001' stores an ENVR object in the extended
read/write cache. This ENVR object does not include any installation data
pointed to by ACEEIEP.
Related services
None
Function
The R_chaudit service verifies that the user has authority to change the audit
options for the specified file and, if so, sets the audit bits from the input audit
options parameter.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
If the SECLABEL class is active and the file or directory has a security label, the
current security label of the process must be greater than or equal to the security
label of the resource or the security label of the resource must be greater than or
equal to the current security label of the process, that is, the security labels are not
disjoint. If MLFSOBJ is active, a failure will occur if the resource does not have a
security label. Security label checking is bypassed if the ACEE indicates trusted or
privileged authority or if the service has passed a system CRED. Security label
checking will also be bypassed for the users with the AUDITOR attribute that are
setting the audit options.
Format
CALL IRRSCA00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Audit_options,
ALET, FSP,
ALET, File_identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Audit_options
The name of a word containing the audit options to be set. For RACF, the
following options are defined:
v Audit options can be specified for each type of access:
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. Two sets of audit bits exist for a file, one for auditor-specified options and one
for user-specified options. The audit flag in the parameter list indicates which
type of options should be set.
If the audit flag indicates auditor options, the user must have auditor authority.
Auditors can set the auditor options for any file, even those they do not have
path access to or authority to use for any other reason.
If the audit flag indicates user options, the user must be a superuser or must be
the owner of the file (that is, the effective UID of the calling process is equal to
the owner UID of the file.)
3. If the change is being made for an open file, that pathname in the CRED is not
used.
4. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
None
Function
The R_chmod service checks whether the calling process is authorized to change
the mode of the specified file (identified by the input IFSP) and, if so, changes the
permission bits and the S_ISUID, S_ISGID, and S_ISVTX bits in the IFSP to the
values specified by the mode parameter.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. To change the mode, the user must be a superuser or must be the owner of the
file. If the user can change the mode and the user is not a superuser, the
S_ISGID bit is cleared, except when the owner z/OS UNIX group identifier
(GID) of the file is equal to the effective GID or to one of the supplementary
groups of the calling process.
2. Only a superuser or directory/file owner can change the S_ISVTX bit.
3. If the caller is not superuser, or the file owner, an authorization check is
performed for READ access to the resource named
SUPERUSER.FILESYS.CHANGEPERMS in the UNIXPRIV class. If the
authorization check is successful, the caller is treated as a superuser.
4. If the SECLABEL class is active and the file or directory has a security label,
then the current security label of the process must be greater than or equal to
the security label of the resource or the security label of the resource must be
greater than or equal to the current security label of the process, that is, the
security labels are not disjoint. If MLFSOBJ is active, a failure will occur if the
resource does not have a security label. Security label checking is bypassed if
the ACEE indicates trusted or privileged authority or if the service has passed a
system CRED.
Format
CALL IRRSCF00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Mode,
ALET, FSP,
ALET, File_Identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a full word in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Mode
The name of a word containing the mode value (the file type, the permission
bits, and the S_ISUID, S_ISGID, and S_ISVTX bits) to be set in the IFSP for the
file.
See “File type and file mode values” on page 4 for a definition of the security
bits in the mode parameter. Reserved bits in the mode parameter must be zero.
FSP
The name of the IFSP for the file whose mode bits are to be changed.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. The mode word is mapped by the z/OS UNIX macro BPXYMODE.
3. If the audit function code indicates an open file, the path name in the CRED is
not used.
4. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
makeFSP, R_umask, R_chown, R_setfacl, ck_access
Function
The R_chown service checks to see whether the user is authorized to change the
owner of the file, and, if so, changes the owner z/OS UNIX user identifier (UID)
and z/OS UNIX group identifier (GID) to the specified values.
If the user is authorized to change the file, the S_ISUID and S_ISGID bits are
cleared in the IFSP.
Requirements
Authorization:
Any PSW key in supervisor state
RACF authorization
1. This service implements the _POSIX_CHOWN_RESTRICTED feature in POSIX
1003.1.
If the discrete profile named CHOWN.UNRESTRICTED does not exist in the
UNIXPRIV class, or the caller has no access to it, then:
v A user can change the owner z/OS UNIX user identifier (UID) value only if
the user is a superuser.
v A user can change the owner z/OS UNIX group identifier (GID) of a file if:
– The user is a superuser,
– Or, all of the following are true:
- The effective UID of the calling process is equal to the owner UID of
the file (that is, the user is the owner of the file).
- The input UID is equal to the owner UID of the file or -1
- The input z/OS UNIX group identifier (GID) is equal to the effective
GID or to one of the supplemental groups of the calling process.
If the discrete profile named CHOWN.UNRESTRICTED exists in the
UNIXPRIV class, then:
v A user can change the owner z/OS UNIX user identifier (UID) if:
– The user is a superuser
– The effective UID of the calling process is equal to the owner UID of the
file ( that is, the user is the owner of the file)
– The caller has UPDATE access to CHOWN.UNRESTRICTED if the UID is
being changed to 0, or
– The caller has READ access to CHOWN.UNRESTRICTED if the UID is
being changed to a value other than 0
v A user can change the owner z/OS UNIX group identifier (GID) if:
– The user is a superuser
3. If the SECLABEL class is active and the file or directory has a security label,
then the current security label of the process must be greater than or equal to
the security label of the resource or the security label of the resource must be
greater than or equal to the process's current security label, that is, the security
labels are not disjoint. If MLFSOBJ is active, a failure will occur if the resource
does not have a security label. Security label checking is bypassed if the ACEE
indicates trusted or privileged authority or if the service has passed a system
CRED.
Format
CALL IRRSCO00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, UID,
ALET, GID,
ALET, FSP,
ALET, File_identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
UID
The name of a word containing the z/OS UNIX user identifier (UID) to be set
as the file owner UID or -1 to indicate that:
1. This field is not changed in the IFSP.
2. The z/OS UNIX group identifier (GID) can be changed.
GID
The name of a word containing the z/OS UNIX group identifier (GID) to be
set as the file owner GID or -1 to indicate that this field is not changed in the
IFSP.
FSP
The name of the IFSP for the file whose owner z/OS UNIX user identifier
(UID) and z/OS UNIX group identifier (GID) are to be changed.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by a z/OS UNIX file system and by z/OS
UNIX servers. The service contains support for z/OS UNIX servers, but cannot
be directly invoked by a z/OS UNIX server.
2. If the input UID or GID (or both) is equal to -1, that field is not changed in the
IFSP.
3. If the audit function code indicates an open file, the pathname in the CRED is
not used.
4. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
query_file_security_options, R_chmod, R_setfacl
Function
The R_datalib service provides the function required to implement the OCSF
(Open Cryptographic Services Facility) Data library functions using RACF key
rings and z/OS PKCS #11 tokens.
Requirements
Authorization:
PSW key 8, non-APF authorized, problem state
Dispatchable unit mode:
Task
Cross memory mode:
PASN = HASN
AMODE:
31 or 64
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. The mapping macro IRRPCOMP is for 31 bit callers
and IRRPCOMX is for 64 bit callers. To allow for this, the last word in the
parameter list , for 31 bit callers, must have a 1 in the high-order (sign) bit.
Num_Parms takes care of 64 bit callers.
RACF authorization
There are two authorization modes for the R_datalib callable service: global or
granular. Global checking uses the FACILITY class; granular checking uses the
RDATALIB class. Global checking applies to all the key rings and certificates.
With ring-specific checking using the RDATALIB class, a resource with the format
<ringOwner>.<ringName>.LST is used to provide access control to a specific key
ring on R_datalib READ functions, that are, DataGetFirst, DataGetNext,
GetUpdateCode and GetRingInfo. A resource with the format
<ringOwner>.<ringName>.UPD is used to provide access control to a specific key
ring on the UPDATE functions, that are, NewRing, DataPut, DataRemove, and
DelRing.
With certificate-specific checking using the RDATALIB class, a resource with the
format IRR.DIGTCERT.<certOwner>.<certLabel>.UPD.ADD/DELETE/ALTER is
used to provide access control to a specific certificate on the DataPut (when it is
used to add a certificate without connecting to a key ring), DataRemove (when it is
used to delete a certificate) or DataAlter functions.
Note: ringNames which differ only in case use the same profile.
If the data entered in the ringOwner and ringName fields has reached the field
size limits, and you want to create a discrete profile, you can truncate the ring
name from the end to make the whole profile name length 246 characters.
For example, if the owner ID is JOESMITH and the ring name is:
THISISARINGWITH237CHARACTERS...RINGEND (with a length of 237), the
discrete profile will be
JOESMITH.THISISARINGWITH237CHARACTERS...RIN.UPD.
Note: Supervisor or system key callers can bypass the authorization checks for the
DataGetFirst, DataGetNext, and GetUpdateCode functions by setting the
CDDL(X)_ATT_SKIPAUTH flag in the Attributes parameter.
Table 48. Global profile checking for the DataGetFirst, DataGetNext, and GetUpdateCode
functions
Function Authority required under FACILITY class
List certificates and get the sequence number READ authority to
for one's own key ring, a CERTAUTH, or a IRR.DIGTCERT.LISTRING
SITE's virtual key ring
List certificates and get the sequence number UPDATE authority to
for other's ring IRR.DIGTCERT.LISTRING
For information about the additional authority needed for the private key retrieval,
see “Usage notes” on page 198.
Note: Supervisor or system key callers can bypass the authorization checks for the
CheckStatus function by setting the CDDL(X)_ATT_SKIPAUTH flag in the
Attributes parameter.
If the caller is RACF special, no authority checking is done; otherwise the resource
<ringOwner>.<ringName>.UPD is checked first. If there is no match for
<ringOwner>.<ringName>.UPD, the IRR.DIGTCERT.ADDRING and
IRR.DIGTCERT.REMOVE resources are used.
Table 51. Ring-specific profile checking for the NewRing function
Function Authority required under RDATALIB class
Create a new ring for <ringOwner> named READ authority to
<ringName> <ringOwner>.<ringName>.UPD
Remove all certificates from an existing ring READ authority to
<ringOwner>.<ringName>.UPD
If the caller is RACF special, no authority checking is done; otherwise the resource
<ringOwner>.<ringName>.UPD is checked first. If there is no match for
<ringOwner>.<ringName>.UPD, the IRR.DIGTCERT.DELRING resource is used.
Table 56. Global profile checking for the DataRemove function if the removed certificate is
not to be deleted
Function Authority required under FACILITY class
Remove one's own certificate from one's READ authority to IRR.DIGTCERT.REMOVE
own ring
Remove someone else's certificate from one's UPDATE authority to
own ring IRR.DIGTCERT.REMOVE
Remove one's own certificate from other's CONTROL authority to
ring IRR.DIGTCERT.REMOVE
Remove someone else's certificate from CONTROL authority to
other's ring IRR.DIGTCERT.REMOVE
Remove a SITE or CERTAUTH certificate CONTROL authority to
from other's ring IRR.DIGTCERT.REMOVE
Remove a SITE or CERTAUTH certificate UPDATE authority to
from one's own ring IRR.DIGTCERT.REMOVE
Note: There are two types of mapping, 31-bit mapping and 64-bit
mapping. For every CDDL_xx entry, which comes from the 31-bit
mapping, there is a corresponding CDDLX_xx entry from the 64-bit
mapping. In this information, CDDL(X) is used to indicate both of the
mappings.
Table 57. Additional profile checking for the DataRemove function if the removed certificate
is to be deleted
Function Authority required under FACILITY class
Delete one's own certificate after it is READ authority to IRR.DIGTCERT.DELETE
removed from the ring
Delete someone else's certificate after it is UPDATE authority to
removed from the ring IRR.DIGTCERT.DELETE
Delete a SITE or CERTAUTH certificate after CONTROL authority to
it is removed from the ring IRR.DIGTCERT.DELETE
See Table 57 for Authority required if global profile checking under the
FACILITY class is used.
Table 59. Ring-specific profile checking for the DataPut function - Authority required to
connect with the Personal usage
Function Authority required under RDATALIB class
Connect one's own certificate to the ring READ authority to
<ringOwner>.<ringName>.UPD
Connect someone else's certificate to the ring v CONTROL authority to
<ringOwner>.<ringName>.UPD (If the
private key is not specified)
v UPDATE authority to
<ringOwner>.<ringName>.UPD (If the
private key is specified)
Connect a SITE or CERTAUTH certificate to v CONTROL authority to
the ring <ringOwner>.<ringName>.UPD (If the
private key is not specified)
v UPDATE authority to
<ringOwner>.<ringName>.UPD (If the
private key is specified)
Table 60. Ring-specific profile checking for the DataPut function - Authority required to
connect with the SITE or CERTAUTH usage
Function Authority required under RDATALIB class
Connect one's own certificate to the ring UPDATE authority to
<ringOwner>.<ringName>.UPD
Connect someone else's certificate to the ring UPDATE authority to
<ringOwner>.<ringName>.UPD
Connect a SITE or CERTAUTH certificate to UPDATE authority to
the ring <ringOwner>.<ringName>.UPD
Table 61. Global profile checking for the DataPut function - Authority required to connect
with the Personal usage
Function Authority required under FACILITY class
Connect one's own certificate to one's own READ authority to
ring IRR.DIGTCERT.CONNECT
Connect someone else's certificate to one's UPDATE authority to
own ring IRR.DIGTCERT.CONNECT
Connect one's own certificate to someone CONTROL authority to
else's ring IRR.DIGTCERT.CONNECT
Connect someone else's certificate to CONTROL authority to
someone else's ring IRR.DIGTCERT.CONNECT
Connect a SITE or CERTAUTH certificate to CONTROL authority to
one's own ring IRR.DIGTCERT.CONNECT
Connect a SITE or CERTAUTH certificate to CONTROL authority to
someone else's ring IRR.DIGTCERT.CONNECT
Table 62. Global profile checking for the DataPut function - Authority required to connect
with the SITE or CERTAUTH usage
Function Authority required under FACILITY class
Connect one's own certificate to one's own CONTROL authority to
ring IRR.DIGTCERT.ADD and READ authority to
IRR.DIGTCERT.CONNECT
Connect someone else's certificate to one's CONTROL authority to
own ring IRR.DIGTCERT.ADD and UPDATE authority
to IRR.DIGTCERT.CONNECT
Connect one's own certificate to someone CONTROL authority to
else's ring IRR.DIGTCERT.ADD and CONTROL
authority to IRR.DIGTCERT.CONNECT
Connect someone else's certificate to CONTROL authority to
someone else's ring IRR.DIGTCERT.ADD and CONTROL
authority to IRR.DIGTCERT.CONNECT
Connect a SITE or CERTAUTH certificate to UPDATE authority to
one's own ring IRR.DIGTCERT.CONNECT
Connect a SITE or CERTAUTH certificate to CONTROL authority to
someone else's ring IRR.DIGTCERT.CONNECT
Note: For information about the additional authority required to add or re-add,
see Table 63.
Table 63. Global profile checking for the DataPut function - Authority required under the
FACILITY class to add or re-add a certificate
Function Authority required under FACILITY class
Add one's own certificate READ authority to IRR.DIGTCERT.ADD
Add someone else's certificate UPDATE authority to IRR.DIGTCERT.ADD
Add a SITE or CERTAUTH certificate CONTROL authority to
IRR.DIGTCERT.ADD
Re-add one's own existing certificate with a READ authority to IRR.DIGTCERT.ALTER
different status
Re-add someone else's existing certificate UPDATE authority to
with a different status IRR.DIGTCERT.ALTER
Re-add a SITE or CERTAUTH's existing CONTROL authority to
certificate with a different status IRR.DIGTCERT.ALTER
Table 64. Certificate-specific profile checking for the DataPut function - Authority required
under the RDATALIB class to add or re-add a certificate
Function Authority required using the RDATALIB class
Add one's own or someone READ authority to IRR.DIGTCERT.<CERT_user_ID>.<cert
else's certificate with label label>.UPD.ADD
specified
Add a SITE certificate with READ authority to IRR.DIGTCERT.SITECERTIF.<cert
label specified label>.UPD.ADD
Add a CERTAUTH READ authority to IRR.DIGTCERT.CERTIFAUTH.<cert
certificate with label label>.UPD.ADD
specified
Add one's own or someone READ authority to
else's certificate with no IRR.DIGTCERT.<CERT_user_ID>.LABEL*.UPD.ADD
label specified
Add a SITE certificate with READ authority to
no label specified IRR.DIGTCERT.SITECERTIF.LABEL*.UPD.ADD
Add a CERTAUTH READ authority to
certificate with no label IRR.DIGTCERT.CERTIFAUTH.LABEL*.UPD.ADD
specified
Re-add one's own or READ authority to IRR.DIGTCERT.<CERT_user_ID>.<cert
someone else's existing label>.UPD.ALTER
certificate with a different
status
Re-add a SITE's existing READ authority to IRR.DIGTCERT.SITECERTIF.<cert
certificate with a different label>.UPD.ALTER
status
Re-add a CERTAUTH's READ authority to IRR.DIGTCERT.CERTIFAUTH.<cert
existing certificate with a label>.UPD.ALTER
different status
Profile in the RDATALIB class will be checked first. If it doesn't exist, check that in
the FACILITY class.
Table 65. Certificate-specific profile checking for the DataAlter function - Authority required
under the RDATALIB class to alter a certificate
Function Authority required using the RDATALIB class
Alter one's own or someone READ authority to IRR.DIGTCERT.<CERT_user_ID>.<cert
else's certificate's status label>.UPD.ALTER
Alter a SITE certificate's READ authority to IRR.DIGTCERT.SITECERTIF.<cert
status label>.UPD.ALTER
Alter a CERTAUTH READ authority to IRR.DIGTCERT.CERTIFAUTH.<cert
certificate's status label>.UPD.ALTER
Table 65. Certificate-specific profile checking for the DataAlter function - Authority required
under the RDATALIB class to alter a certificate (continued)
Function Authority required using the RDATALIB class
Alter one's own or someone READ authority to
else's certificate's label IRR.DIGTCERT.<CERT_user_ID>.<original cert
label>.UPD.ALTER
and
and
and
Table 66. Global profile checking for the DataAlter function - - Authority required under the
FACILITY class to alter a certificate
Function Authority required using the Facility class
Alter one's own certificate's
READ authority to IRR.DIGTCERT.ALTER
status
Alter one's own certificate's READ authority to IRR.DIGTCERT.ALTER
label
Alter someone else's
UPDATE authority to IRR.DIGTCERT.ALTER
certificate's status
Alter someone else's UPDATE authority to IRR.DIGTCERT.ALTER
certificate's label
Alter a SITE or CERTAUTH
CONTROL authority to IRR.DIGTCERT.ALTER
certificate's status
Alter a SITEor CERTAUTH CONTROL authority to IRR.DIGTCERT.ALTER
certificate's label
Profile in the RDATALIB class will be checked first. If it doesn't exist, check that in
the FACILITY class.
Table 67. Ring-specific profile checking for the GetRingInfo function - Authority required
under the RDATALIB class to list information for one or more key rings
Function Authority required using the RDATALIB class
List a specific ring owned READ authority to <Ring owner>.<Ring name>.LST
by a specific user
List all the rings owned by READ authority to <Ring owner>.*.LST
a specific user
List all rings in the RACF READ authority to *.<Ring name>.LST
database with a specific
name
List all rings in the RACF READ authority to *.*.LST
database
Note: For search type 0 which is used for getting ring information for a specific
ring, if insufficient authority is granted, 8 8 8 will be returned. For other search
types which are used for getting ring information for multiple rings, only the
authorized entries will be returned, with return/reason code 4 4 8.
Table 68. Global profile checking for the GetRingInfo function - Authority required under the
FACILITY class to list information for one or more key ring's
Function Authority required using the FACILITY class
List one's own rings READ authority to IRR.DIGTCERT.LISTRING
List someone else's rings UPDATE authority to IRR.DIGTCERT.LISTRING
ICSF considerations
R_datalib processing makes use of ICSF services. If your installation has
established access control over ICSF services, then the callers of R_datalib will need
to be granted READ authority to ICSF services according to the following table:
Table 69. ICSF services used by R_datalib
ICSF Service (CSFSERV
R_datalib function Specific parameters class resource)
DataGetFirst and When Ring_name is a z/OS CSF1TRL and CSF1GAV
DataGetNext PKCS #11 token
GetUpdateCode When Ring_name is a z/OS CSF1TRL
PKCS #11 token
DataPut When a label of an existing CSFPKRR
PKDS private key is
specified
If your installation has also established access control over keys stored in ICSF, the
issuer of the DataPut function must have READ access authority to ICSF key by
label set up by the profile in the CSFKEYS class too.
Format
31 bit invocation:
CALL IRRSDL00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_code,
Attributes,
RACF_user_ID,
Ring_name,
Parm_list_version,
Parmlist
)
or 64 bit invocation:
CALL IRRSDL64 (Num_parms,
Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_code,
Attributes,
RACF_user_ID,
Ring_name,
Parm_list_version,
Parmlist
)
Parameters
In this section, there is a function-specific parameter list for each function code, in
addition to the general parameter list for R_datalib.
X'01' DataGetFirst: Locate and return the first certificate in the ring specified
in Ring_name, based on the selection criteria specified by
Number_predicates and Cert_status. The user may specify some
selection criteria by setting Number_predicates to 1, and then
supplying some attribute information, such as attribute type, and the
length and address of the attribute data. The user may also specify the
status (TRUST, HIGHTRUST, NOTRUST, ANY) of the certificate to be
returned by setting Cert_status. The data in the returned certificate will
match the attribute data and certificate status supplied.
X'02' DataGetNext: Locate and return the next trusted certificate in the ring,
based on the criteria specified in DataGetFirst.
X'03' DataAbortQuery: Free resources from previous DataGetFirst and
DataGetNext requests.
X'04' CheckStatus: Return the TRUST/ NOTRUST status for a specified
certificate.
X'05' GetUpdateCode: Return the sequence number for the ring specified. A
change in the ring sequence number (from a previously obtained ring
sequence number) indicates that the ring has changed. A ring is
considered changed when the list of certificates in the ring has
changed, or the digital certificate information for a certificate in the
ring has changed.
X'06' IncSerialNum: Increment and return the last serial number field
(CERTLSER) associated with the input certificate.
X'07' NewRing: Create a new key ring or remove all the certificates from an
existing key ring.
The RACF_user_ID and Ring_name are used to identify the ring. If the
RACF_user_ID is not specified, it is equal to the user ID of the caller
by default.
The syntax of Ring_name follows that of the RACDCERT ADDRING
resource, that are, the restrictions imposed by the TSO parse, RACF's
conversion rules, and the ADDRING validation exit.
X'08' DataPut: Add a certificate to the RACF database (if it does not already
exist), and optionally connect it to a key ring identified by the
RACF_user_ID and Ring_name. If an ‘*’ is specified in the Ring_name
parameter, this function is to add a certificate only.
If the input certificate does not exist in the RACF database, it will be
added to RACF with a specified or system-generated label under the
specified user ID. The certificate will be added with either of the
following status:
v A specified status through the CDDL(X)_ATT_TRUST or
CDDL(X)_ATT_HIGHTRUST attribute, or
v A status determined by RACF.
For more information, see the Attributes section.
If the private key associated with the certificate is specified in a
DER-encoded format or as a key label, the certificate will be added
with the following key types accordingly in the RACF database:
v Software RSA key
v Software DSA key
Note: Retained hardware keys and Clear hardware keys are not
supported.
If the certificate specified to be added is not already in the RACF
database, after it is added, it will be connected to the key ring with the
specified USAGE and DEFAULT value.
If the certificate specified to be added is already connected to the key
ring, it will be reconnected with the specified USAGE and DEFAULT
value.
If the certificate specified to be added is already in the RACF database
with no associated private key, it might be re-added with a specified
private key under the original ID, label, and status if the TRUST or
HIGHTRUST attribute is not specified.
If the DIGTCERT class is RACLISTed, a successful DataPut operation
indicates that a DataRefresh call is needed.
X'09' DataRemove: Remove a certificate from the key ring. If
CDDL(X)_ATT_DEL_CERT_TOO flag is X'80000000', this function also
deletes the certificate from the RACF database if it is not connected to
any other rings. If '*' is specified in the Ring_name parameter, this
function deletes a certificate from the RACF database.
RACF_user_ID and Ring_name are used to identify the ring. If the
RACF_user_ID is not specified, it is equal to the user ID of the caller
by default.
X'0A' DelRing: Delete a key ring.
X'0B' DataRefresh: Refresh the in-storage certificates in the RACF database if
the DIGTCERT class is RACLISTed. If the DIGTCERT class is not
RACLISTed, no action is performed. DataRefresh might be required
after calling DataPut or DataRemove.
The DIGTCERT class can be RACLISTed for digital certificates
(processing the in-storage version instead of the database version) after
calling the DataPut or DataRemove function. Therefore you need to
refresh the in-storage version to reflect any changes to the certificate
profiles. This can be done either through a RACF SETROPTS command
SETROPTS RACLIST(DIGTCERT) REFRESH by a RACF administrator, or
through the DataRefresh function by the caller.
All other bit positions are reserved and must be set to zero to ensure
compatibility with future enhancements.
v The CheckStatus (X'04') function
X'20000000' - CDDL(X)_ATT_SKIPAUTH flag. This flag directs R_datalib to
bypass authorization checks to RACF key rings for a supervisor state or
system key caller. This does not bypass the authorization required in order
to retrieve private key information, nor does this bypass authorization
checks for PKCS #11 tokens. This flag is ignored for problem state callers.
All other bit positions are reserved and must be set to zero to ensure
compatibility with future enhancements.
v The IncSerialNum (X'06') function
X'80000000' - CDDL(X)_ATT_SET_MIN_SERIAL flag. This flag is used to
indicate that the last used serial number field (CERTLUER) is to be
incremented to at least the input serial number parameter. When this flag is
set the serial number will only be changed if the current actual value is less
than the input serial number value.
v The GetUpdateCode (X'05) function
X'20000000' - CDDL(X)_ATT_SKIPAUTH flag. This flag directs R_datalib to
bypass authorization checks to RACF key rings for a supervisor state or
system key caller. This does not bypass the authorization required in order
to retrieve private key information, nor does this bypass authorization
checks for PKCS #11 tokens. This flag is ignored for problem state callers.
All other bit positions are reserved and must be set to zero to ensure
compatibility with future enhancements.
v The NewRing (X'07') function
X'80000000' - CDDL(X)_ATT_REUSE_RING flag. This flag directs R_datalib
to reuse the existing key ring and remove all the certificates from it. When
this flag is off, it indicates the creation of a new key ring.
All other bit positions are reserved and must be set to zero to ensure
compatibility with future enhancements.
v The DataPut (X'08') function
X'80000000' - CDDL(X)_ATT_TRUST flag. This flag is used to add
certificates, with the TRUST status. When this flag is off, RACF will
determine the status based on the following factors in the same way that the
RACDCERT ADD command behaves:
– Whether the issuer of the certificate is trusted
– Whether the signature of the certificate can be verified
– Whether the certificate has expired
– Whether the validity date range of the certificate is within that of its
issuer
All other bit positions are reserved and must be set to zero to ensure
compatibility with future enhancements. If the certificate already exists,
turning on this attribute will change its status from NOTRUST to TRUST
when connecting it to the key ring. However, if the status is already
HIGHTRUST, it will remain unchanged.
X'40000000' - CDDL(X)_ATT_HIGHTRUST flag. This flag is used to add or
change certificates with the HIGHTRUST status if the certificate to be added
or changed is under CERTAUTH; otherwise this value will be treated as
CDDL(X)_ATT_TRUST, that is, add or change certificates with the TRUST
status.
For the DataGetFirst function code, the RACF-reserved user IDs (“irrcerta” or
“irrsitec” in lowercase) or their alternate forms (*AUTH* or *SITE* in
uppercase) can also be specified.
The value “*TOKEN*” can be specified to indicate that a z/OS PKCS #11
token, rather than a RACF key ring, is the target of the operation. If the length
is not specified, it must be equal to 0. If the current user ID is not specified, it
is equal to the user ID of the ring owner or the token owner.
Ring_name
The name of a variable length input area that consists of a 1-byte length field
followed by up to 237 characters that represent the ring name. The syntax rules
for this field, are the same as those for the RACDCERT command. The value
specified is case sensitive. The Ring_name is used for the following functions:
DataGetFirst, GetUpdateCode, NewRing, DataPut, DataRemove, DelRing and
GetRingInfo.
For DataGetFirst, the Ring_name can represent a real or virtual key ring or a
z/OS PKCS #11 token name if Parm_list version is 0. A real key ring must be
explicitly created before being used by this service. A virtual key ring is the
collection of certificates assigned to a given user ID, including the RACF
reserved user IDs for CERTAUTH (“irrcerta” or “*AUTH*”) and SITE
(“irrsitec” or “*SITE*”). A virtual key ring can be specified by coding an
asterisk (“*”) for the Ring_name with the corresponding RACF_user_ID, such
as user01/* or *SITE*/*.
A z/OS PKCS #11 token is a collection of certificates and keys similar to a key
ring, but it is managed by the Integrated Cryptographic Service Facility (ICSF).
Like a real key ring, it must be explicitly created before being used by this
service.
For DataGetNext, the Ring_name is specified on the initial DataGetFirst call
and cannot be re-specified.
For CheckStatus, DataAbortQuery, IncSerialNum, and DataGetNext, the
Ring_name field is ignored.
parm_list_version
A 4-byte input value which contains the version number for the following
field, parm_list. Set this field to 1 to specify Cert_status on the DataGetFirst
and DataGetNext function-specific parameter list, otherwise set this field to
zero.
Parm_list
Specifies the address of the function-specific parameter list for the function
specified in Function_code. This information is defined in the following
sections of function-specific parameter lists.
v X'07' – NewRing
v X'08' – DataPut
v X'09' – DataRemove
v X'0A' – DelRing
v X'0B' – DataRefresh
v X'0C' – DataAlter
v X'0D' – GetRingInfo
There are no function-specific parameters for Function codes X'07', X'0A', and X'0B',
so these function codes are not shown in this table.
Table 70. R_datalib function specific parameter usage
Parameter X'01' X'02' X'03' X'04' X'05' X'06' X'08' X'09' X'0C' X'0D'
Results_handle Input Input Input n/a n/a n/a n/a n/a n/a n/a
Certificate_Usage Output Output n/a n/a n/a n/a Input n/a n/a n/a
Default Output Output n/a n/a n/a n/a Input n/a n/a n/a
Certificate_length Input / Input / n/a Input n/a Input Input n/a n/a n/a
Output Output
Certificate_ptr Input Input n/a Input n/a Input Input n/a n/a n/a
Private_key_length Input / Input / n/a n/a n/a n/a Input n/a n/a n/a
Output Output
Private_key_ptr Input Input n/a n/a n/a n/a Input n/a n/a n/a
Private_key_type Output Output n/a n/a n/a n/a n/a n/a n/a n/a
Private_key_bitsize Output Output n/a n/a n/a n/a n/a n/a n/a n/a
Label_length Input / Input / n/a n/a n/a n/a Input / Input Input n/a
Output Output Output
Label_ptr Input Input n/a n/a n/a n/a Input / Input Input n/a
Output
New_Label_length n/a n/a n/a n/a n/a n/a n/a n/a Input n/a
New_Label_ptr n/a n/a n/a n/a n/a n/a n/a n/a Input n/a
CERT_user_ID Output Output n/a n/a n/a n/a Input / Input Input n/a
Output
Subjects_DN_length Input Input n/a n/a n/a n/a n/a n/a n/a n/a
Subjects_DN_ptr Input Input n/a n/a n/a n/a n/a n/a n/a n/a
Record_ID_length Input / Input / n/a n/a n/a n/a n/a n/a n/a n/a
Output Output
Record_ID_ptr Input Input n/a n/a n/a n/a n/a n/a n/a n/a
Ring_sequence_number n/a n/a n/a n/a Output n/a n/a n/a n/a n/a
Serial_number n/a n/a n/a n/a n/a Input / n/a n/a n/a n/a
Output
Cert_status Input / Input / n/a n/a n/a n/a n/a n/a n/a n/a
Output Output
Search_type n/a n/a n/a n/a n/a n/a n/a n/a n/a Input
Ring_result_length n/a n/a n/a n/a n/a n/a n/a n/a n/a Input
Ring_result_ptr n/a n/a n/a n/a n/a n/a n/a n/a n/a Input
X'00000000'
ANY
On output, it indicates the status of the returned certificate with one of the
aforementioned values, except X'00000000'.
Certificate_Usage
A 32 bit output flag value, indicating the usage of the certificate.
Certificate_Usage can have the following values:
X'00000002'
Certauth
X'00000008'
Personal
X'00000000'
Other (site)
X'fffffff5'
Reserved
Default
A 4-byte output value. A X'00000000' value indicates that this certificate is not
the default certificate for the ring. A non-zero value indicates that this is the
default certificate for the ring.
Certificate_length
A 4-byte value containing the length of the certificate. On input, it contains the
length of the field pointed to by certificate_ptr. On output, it contains the
actual size of the certificate that is returned. A zero indicates that no certificate
was returned.
Certificate_ptr
An input value containing the address of the DER encoded certificate output
area.
Private_key_length
A 4-byte value containing the length of the private key. On input, it contains
the length of the field pointed to by private_key_ptr. On output, it contains the
actual size of the private key that is returned. A zero indicates that no
private_key was returned.
If private_key_length is zero, then private_key_bitsize and private_key_type
are not returned.
Private_key_ptr
An input value containing the address of the private key output area.
Private_key_type
A 4-byte output value indicating the form of the private key. The valid values
are:
X'00000001'
PKCS #1 private key, DER encoded
X'00000002'
ICSF key token label. If the first character is an '=' sign, it is a key
token from the TKDS, otherwise it is from the PKDS.
X'00000003'
PCICC key token label
long. On output, it contains the actual size of the label that is returned. A zero
value indicates that no label was returned.
Label_ptr
An input value containing the address of the label output area.
CERT_user_ID
A 9-byte output area containing a 1-byte length, followed by the user ID which
owns the certificate.
The 1-byte length must specify a length of 8. The user ID must be left-justified
and padded with blanks.
Subjects_DN_length
A 4-byte input value containing the length of the DER encoded subject's
distinguished name. On input, it contains the length of the field pointed to by
Subjects_DN_ptr. On output, it contains the actual size of the subject's
distinguished name that is returned.
Subjects_DN_ptr
a 4-byte input value containing the address of the subject's distinguished name
output area.
Record_ID_length
On input, it contains the length of the field pointed to by Record_ID_ptr. This
field must have a length of at least 246 bytes. On output, it contains the actual
size of the record ID that is returned. A zero value indicates that no record ID
was returned.
Serial_number
The 8-byte output area to contain the returned serial number. This serial
number is also an input field when the CDDL(X)_ATT_SET_MIN_SERIAL flag
is set.
Cert_owner
A field consisting of a 1-byte length field followed by
the certificate owner name.
Cert_name
A field consisting of a 1-byte length field followed by
the certificate label.
Table 72. DataGetFirst and DataGetNext return and reason codes (continued)
SAF return RACF return RACF reason Explanation
code code code
8 8 36 dbToken error. The token may be zero, in
use by another task, or may have been
created by another task.
8 8 40 Internal error while validating dbToken.
8 8 44 No trusted certificate found.
8 8 48 An output area is not long enough. One or
more of the following input length fields
were too small: Certificate_length,
Private_key_length, or Subjects_DN_length.
The length field(s) returned contain the
amount of storage needed for the service to
successfully return data.
8 8 52 Internal error while obtaining record
private key data.
| 8 8 56 Parameter error - Number_predicates,
| Attribute_ID or Cert_status
8 8 80 Internal error while obtaining the key ring
or z/OS PKCS #11 token certificate
information or record trust information.
8 8 84 The key ring profile for
RACF_user_ID/Ring_name or z/OS PKCS
#11 token is not found, or the virtual key
ring user ID does not exist.
Note: For search type 0 which is used for getting ring information for a specific
ring, if insufficient authority is granted, 8 8 8 will be returned. For other search
types which are used for getting ring information for multiple rings, only the
authorized entries will be returned, with return/reason code 4 4 8.
Usage notes
1. For real key rings, a certificate's ring usage is set when the certificate is
connected to the key ring.
2. For virtual key rings, all certificates within the ring have the same usage as
follows:
v CERTAUTH for the CERTAUTH virtual key ring (RACF reserved user ID
irrcerta or *AUTH*).
v SITE for the SITE virtual key ring (RACF-reserved user ID irrsitec or *SITE*).
v PERSONAL for the virtual key rings of all other non-reserved user IDs.
3. For z/OS PKCS #11 tokens, a certificate's token usage is set when the certificate
is bound to the token.
4. Applications can call the R_datalib callable service (IRRSDL00) to extract the
private keys from certain certificates after they have access to the key ring. A
private key is returned only when the following conditions are met:
a. For RACF real key rings:
v User certificates
An application can extract the private key from a user certificate if the
following conditions are met:
– The certificate is connected to the key ring with the PERSONAL usage
option.
– One of the following two conditions is true:
Table 84. GetRingInfo results with input contains existing owner or ring (continued)
Specified Specified Specified Data returned if sufficient area provided and caller Data returned if Note
RACF_user_ID Ring_name Search_type has sufficient authority sufficient area
for 2 objects
User1 - ignored User1.RingX, User1.RingY, User1.RingZ User1.RingX, RC=4 4 0, call
User1.RingY again type
2(1Y)
- RingX ignored User1.RingX, User2.RingX, User3.RingX User1.RingX, RC=4 4 0, call
User2.RingX again type
3(2X)
- - ignored User1.RingY, User1.RingY, User1.RingZ, User1.RingX, RC=4 4 0, call
User2.RingX, User2.RingY, User2.RingZ, User1.RingY again 4times
User3.RingX, User3.RingY, User5.RingY with type 1
(1Y, 2X, 2Z,
3Z)
Table 85. GetRingInfo results with input contains non existing owner or ring
Specified Specified Specified Data returned if sufficient area provided and caller Data returned Note
RACF_user_ID Ring_name Search_type has sufficient authority if sufficient
area for 2
objects
User0 RingX 0 none none RC=8 8 32
User0 RingX 1 User1.RingX, User1.RingY, User1.RingZ, User1.RingX, RC=4 4 0, call
User2.RingX, User2.RingY, User2.RingZ, User1.RingY again 4times
User3.RingX, User3.RingY, User5.RingY with type 1
(1Y, 2X, 2Z,
3Z)
User0 RingT 2 none none RC=8 8 32
User4 RingY 3 User5.RingY User5.RingY RC=0
User4 - ignored none none RC=8 8 44
- RingT ignored none none RC=8 8 32
- - ignored User1.RingX, User1.RingY User1.RingX, RC=4 4 0, call
User1.RingY, User1.RingY, User1.RingZ, User1.RingY again 4times
User2.RingX, User2.RingY, User2.RingZ, with type 1
User3.RingX, User3.RingY, User5.RingY (1Y, 2X, 2Z,
3Z)
Related services
None
Function
The R_dceauth service enables an application server to check a RACF-defined
user's authority to access a RACF-defined resource. It is intended to be used only
by the z/OS UNIX kernel on behalf of an application server.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR ASC mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
RACF authorization
1. RACF checks the ACEE, RACF_userid, and the UUID parameters in the
following order:
v If the ACEE parameter has been specified, this parameter is used to identity
the user for this authorization request.
v If the ACEE parameter has not been specified, and the RACF_userid
parameter is present, this parameter is used to identify the user for this
authorization request.
v If neither the ACEE nor the RACF_userid parameter is present, the
Cell_string_uuid and the Principal_string_uuid parameters are used to identify
the user for this authorization request.
v If the ACEE, RACF_userid, and UUID parameters have not been supplied,
RACF uses the current task-level ACEE if it is found. If there is no task-level
ACEE, RACF uses the address-space ACEE, if it is present, to identify the
user for this authorization request.
Format
CALL IRRSDA00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ACEE_ptr,
ALET, Principal_string_uuid,
Cell_string_uuid,
RACF_userid,
RACF_class,
entity_name,
entity_length,
access_requested
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
ALET can be different. The words containing the ALETs must be in the
primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
ACEE_ptr
The name of a fullword containing the address of an area that contains a
previously created ACEE. If the caller does not specify an ACEE, this area
must contain binary zeros. The ACEE parameter is not specified by an ALET.
This parameter must be in the primary address space.
ALET
The name of a word which must be in the primary address space and which
contains the ALET for the following fields:
v Principal_string_uuid
v Cell_string_uuid
v RACF_userid
v RACF_class
v Entity_name
v Entity_length
v Access_requested
Principal_string_uuid
The name of an area containing the string form of the client's DCE UUID. If
the caller does not specify the client's DCE UUID, then the first character of the
area must be a NULL byte. (That is, the first byte of the 36-byte area must
contain X'00'.)
Cell_string_uuid
The name of an area containing the string form of the cell DCE UUID. The
string form of the cell UUID, if supplied by the caller, must be 36 bytes long.
The Cell_string_uuid must be the name of a 36-byte area that contains one of
the following:
v The string form of the cell UUID
v A null byte (X'00') as the first character of the 36-byte area. If the home cell
UUID is not applicable and the caller wants to obtain cross linking
information using only the DCE principal UUID, the caller must pass the
Cell_string_uuid parameter with the first byte of this field containing a null
byte of X'00'.
RACF_userid
The name of a 9-byte area, which consists of a 1-byte length field followed by
up to eight characters. It must be specified in uppercase. If not specified, the
length must equal zero.
RACF_class
The name of an 8-byte area containing the RACF class name of the resource
(such as TAPEVOL). The class name must be
v Left justified
v Padded to the right with blanks
v Specified in uppercase
v Defined to RACF in the RACF class descriptor table.
Entity_name
The name of an area that contains the RACF entity or resource name (such as
TAPE01). It must be specified in uppercase and should not contain generic
characters.
Entity_length
The name of an area that contains the halfword length of the entity_name. The
valid range of this parameter is 1 to 246 characters.
Access_requested
The requested access (READ, UPDATE, CONTROL, ALTER) to the resource,
which is the name of a 1-byte area containing:
Usage notes
1. This service may not be used to determine access to z/OS UNIX resources,
such as shared UNIX files or data sets.
2. The DATASET class is not valid for this service.
3. If the user ID parameter is specified, the user's default security label, if any,
will be used for authorization checking when the SECLABEL class is active.
4. When the class is SETR RACLISTed, RACROUTE REQUEST=FASTAUTH will
be issued instead of REQUEST=AUTH to increase performance. There are some
differences between FASTAUTH and AUTH:
v Regarding authorization checking
If the ACEE specified as input to FASTAUTH does not grant authority to the
specified resource, and that ACEE has a nested ACEE and the user has
authority to use it, then the nested ACEE is also checked to see if it grants
authority. If so, authority is granted. AUTH does not use nested ACEEs.
v Regarding parmlist checking
FASTAUTH does very little parmlist checking because it constitutes a
performance path. There may be some unusual situations that give different
results than AUTH. For instance, an input entity length that is greater than
the maximum profile length for the class will result in an abend for an
AUTH request and an “8/8/12 internal error” RC , while a FASTAUTH
request will use the maximum profile length as the entity length, likely
resulting in an “8/8/4 profile not found” RC.
v Regarding logging
AUTH uses SETR LOGOPTIONS settings in determining when to create an
audit record, while FASTAUTH does not.
Related services
R_dceruid
Function
The RACF R_dceinfo callable service retrieves or sets the following fields from a
user profile DCE segment:
v The DCE principal name associated with this RACF user
v DCE UUID of this user
v DCE cell name that this user is defined to (HOME CELL)
v DCE cell UUID that is associated with DCE cell that this user is defined to
(HOMEUUID)
Chapter 2. Callable services descriptions 205
R_dceinfo
v A flag byte that indicates whether z/OS DCE creates a DCE security context
(autologin) automatically
The action performed by this callable service is based on the function code passed
by the caller in the R_dceinfo parameter list.
v When the function code is set to EXTRACT, R_dceinfo retrieves the information
requested from the user's DCE segment.
v When the function code is set to REPLACE, R_dceinfo replaces the fields that
have been specified in the parameter list.
Requirements
Authorization:
Any PSW key in: Supervisor state for REPLACE DCE fields Supervisor or
problem state for EXTRACT DCE fields
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR ASC mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. The replace function fails if the user ID specified in the parameter has not been
previously defined as a DCE RACF user.
2. Field level access checking does not occur when retrieving or replacing fields
with this service.
Format
CALL IRRSDI00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Function_code,
ALET, RACF_userid,
ALET, Field_list,
ALET, Output_area,
ALET, Output_area_length
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a full word in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area containing the function code:
X'01' Retrieve DCE fields
X'02' Replace DCE fields
RACF_userid
The name of a 9-byte area, containing a 1-byte length field, followed by a user
ID up to eight characters long. It must be specified in uppercase.
Field_list
The name of an area containing the fields to be replaced or retrieved. The
format of the parameter list is:
The ordered triplet (name of the field, length of the field, and field data) is a
repeating data structure. This triplet can repeat for the total number of fields in the
input Field_list.
v If the function code is X'01' (retrieve DCE fields), the caller is expected to
provide the following fields in the Field_list:
– The total length in bytes of the input field list
– The total number of fields to be retrieved
– The name of the fields to be retrieved
– The length of the data
Note:
For the retrieve function, there is no input field data. The caller is expected to
provide a length of binary zero.
The name of the field and the place holder of zero may repeat for the total
number of fields to be retrieved.
v If the function code is X'02' (replace DCE fields), the caller is expected to be in
supervisor state and to provide the following fields in the Field_list:
– The total length in bytes of the input field list
– The total number of fields to be retrieved
– The name of the field to be retrieved
– The length of the data
– Field data
A problem-state caller is not authorized to replace DCE information.
Output_area
The name of an area that contains the fields obtained by the R_dceinfo service
when the function code is X'01' (Retrieve DCE fields). The format of the
output area is:
The ordered triplet (name of the field, length of the field, and field data) is a
repeating data structure. This triplet can repeat for the number of times shown in
the output_area 'number of fields retrieved' count.
Output_area_length
The name of a fullword that contains the length of the output_area that is
supplied by the caller of this service.
Usage notes
1. If the caller is in problem state, the RACF_userid specified must be the same
RACF user as found in either the task level ACEE or the address space level
ACEE.
2. If the caller is in supervisor state, the task and address space ACEEs are not
checked. Therefore, an authorized caller may extract or replace DCE segment
fields for any user who has a DCE segment.
3. The retrieve function returns fields that have been previously populated.
Associated with the returned fields is a length indicator. The length indicator is
set to zero if a field does not exist.
4. It is the responsibility of the caller to obtain and free the output area. If the
fields to be retrieved from RACF are larger than the output area, RACF fails
the request and returns the actual length required in the output_area_length
parameter.
5. The field names supplied by the caller may be:
v UUID
v DCENAME
v HOMECELL
v HOMEUUID
v DCEFLAGS
The field names must be supplied as 8-character fields, left justified, and
padded with blanks. They must be specified in uppercase.
6. The DCEFLAGS field is a 1-byte field with the following meaning:
v Value of X'00' means that z/OS DCE does not attempt to sign on this user to
z/OS DCE automatically
v Value of X'01' means that z/OS DCE attempts to automatically sign on this
user to z/OS DCE
Parameter Usage:
Related services
R_dcekey
Function
The RACF R_dcekey callable service enables z/OS DCE to retrieve or set a DCE
password (key) or retrieve an LDAP bind password. The three functions supported
are:
v This service retrieves the DCE password from a DCE segment. The password is
decrypted using the key that was stored in the user's DCE segment when the
password was encrypted.
v This service sets the DCE password in a user profile DCE segment. The
password is encrypted using the key stored in the DCE.PASSWORD.KEY profile
in the RACF KEYSMSTR general resource class.
v This service retrieves the LDAP bind password from the PROXY segment of a
general resource profile in the LDAPBIND Class or the IRR.PROXY.DEFAULTS
profile in the FACILITY Class. The password is decrypted using the key that
was stored in the profile's PROXY segment when the password was encrypted
(for example, when the RDEFINE or RALTER PROXY(...) command was issued.)
Requirements
Authorization:
Any PSW key in supervisor state or problem state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR ASC mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
v For function codes get_key and put_key, the user ID specified in the
RACF_entity parameter must have a DCE segment.
v For function code get_ldap_pw, the LDAPBIND Class profile specified in the
RACF_entity parameter must have a PROXY segment previously created
through a RDEFINE or RALTER command. If the RACF_entity is not specified,
the IRR.PROXY.DEFAULTS profile in the FACILITY Class must have a PROXY
segment previously created through a RDEFINE or RALTER command.
v For callers not running in system key or supervisor state, the use of the
R_dcekey service is authorized by FACILITY class resources:
– The ACEE associated with the address space is used to determine the caller. If
the caller is running in a clean environment with a RACF user or group that
has at least READ authority to the BPX.SERVER resource, use of R_dcekey is
permitted and no subsequent access checks are made.
– Otherwise, the current TCB is checked for an ACEE. If one is found, it will be
used to determine the caller. If there is no ACEE associated with the current
TCB, the ACEE associated with the address space is used to determine the
caller. If the caller is running in a clean environment with a RACF user or
group that has at least READ authority to the IRR.RDCEKEY resource, use of
R_dcekey is permitted.
If the FACILITY class is inactive, or the preceding resources are not defined,
only servers running in system key or supervisor state may use the R_dcekey
service. For more information about running in a clean environment, see the
discussion of Program Control in the z/OS Security Server RACF Security
Administrator's Guide.
Format
CALL IRRSDK00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Function_code,
ALET, RACF_entity,
ALET, key_area,
ALET, key_area_length
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF use. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area containing the function code:
X'01' get_key (retrieve current DCE key)
X'02' put_key (set DCE key)
X'03' get_ldap_pw (get the LDAP bind password from the PROXY segment)
RACF_entity
Formally called RACF_userid. The name of a 247-byte area, which consists of a
1-byte length field followed by up to 246 characters. This field is to contain the
RACF entity for the password being set or retrieved.
For functions get_key and put_key, this field is the RACF user ID.
For function get_ldap_pw, this field is a LDAPBIND Class general resource
profile name. Setting the length byte to x'00' indicates to retrieve the default
LDAP bind password from the IRR.PROXY.DEFAULTS profile in the FACILITY
Class.
Key_area
The name of an area containing the DCE key, preceded by a 2-byte length
field.
Key_area_length
The name of a fullword that contains the length of the key_area.
Usage notes
1. When the function is get_key, this service returns the current DCE key in clear
text form to the output area supplied by the caller. This is the value defined by
the key_area parameter. The length of the key_area is supplied by the
key_area_length parameter.
2. If the key_area supplied by the caller is too small to contain the user's current
DCE key or the profile's LDAP password, the service sets the required length in
the key_area_length parameter.
3. When the function is put_key, this service replaces the current DCE key in the
specified user profile DCE segment with the value specified in the key_area
parameter.
4. When the function is get_ldap_pw, this service returns the LDAP bind
password in clear text form to the output area supplied by the caller. This is the
value defined by the key_area parameter. The length of the key_area is
supplied by the key_area_length parameter.
Parameter usage
GET_KEY PUT_KEY GET_LDAP_PW
Parameter Direction Direction Direction
SAF_return_code Output Output Output
RACF_return_code Output Output Output
RACF_reason_code Output Output Output
Function_code Input Input Input
RACF_entity Input Input Input
Key_area Output Input Output
Related services
R_dceinfo
Function
The R_dceruid service enables z/OS DCE servers to determine the RACF user ID
of the client from the string forms of the client's DCE UUID pair, which consists of
the home cell UUID and the principal UUID. It also enables the servers to determine
the DCE UUIDs of a client from the RACF user ID.
Note that this service can only convert a DCE UUID to a RACF user ID and a
RACF user ID to a DCE UUID for users who have:
v A populated DCE segment associated with their user profile
v A DCEUUIDS-class profile that defines the association between the DCE UUIDs
and the RACF user ID
The R_dceruid service is sensitive to the profiles defined to the RACF DCEUUIDS
class.
Requirements
Authorization:
Any PSW key in supervisor state or problem state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. This service can only translate a RACF user ID to a DCE UUID and a DCE
UUID to a RACF user ID for users who have:
v A populated DCE segment associated with the user profile
v A DCEUUIDS-class profile defined to RACF that associates a DCE UUID pair
with a RACF user ID
2. Use of the R_dceruid service is authorized by the profile IRR.RDCERUID in the
RACF FACILITY class. The user ID of the application server (the RACF identity
associated with the application server), or a group to which the server is
connected, must be permitted with READ access to the profile IRR.RDCERUID
in the RACF FACILITY class. Assigning a UACC of READ to the profile
IRR.RDCERUID is not recommended.
Format
CALL IRRSUD00 (Work_area,
ALET,SAF_return_code,
ALET,RACF_return_code,
ALET,RACF_reason_code,
ALET,Function_code,
ALET,Principal_string_uuid,
ALET,Cell_string_uuid,
ALET,RACF_userid
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area containing the function code:
X'01' Return RACF user ID
Usage notes
1. This callable service allows z/OS DCE servers to associate a DCE UUID pair
with a RACF user ID.
v If the function code is return RACF user ID, the R_dceruid service returns
the RACF user ID associated with the string form of the DCE UUIDs
supplied by the caller, if it is available.
v If the function code is return DCE UUID, the R_dceruid service returns the
string form of the DCE UUIDs associated with the RACF user ID supplied
by the caller, if it is available. RACF stores the UUIDs as uppercase
characters and therefore returns the UUIDs in uppercase.
Parameter usage
Parameter UUID to RACF userID RACF userID to UUID
Direction Direction
SAF_return_code Output Output
RACF_return_code Output Output
RACF_reason_code Output Output
Function_code Input Input
Principal_string_uuid Input Output
Cell_string_uuid Input Output
RACF_userid Output Input
Related services
R_dceinfo, R_usermap
Function
The R_exec service sets the effective and saved z/OS UNIX user identifiers (UIDs)
and z/OS UNIX group identifiers (GIDs) for a process to the specified input
values. Input flags indicate whether the UIDs or GIDs or both should be changed.
R_exec returns the new values of the real, effective, and saved UIDs and GIDs in
the output areas provided.
Requirements
Authorization:
Any PSW key in supervisor state
RACF authorization
None
Format
CALL IRRSEX00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Flags,
ALET, UID,
ALET, GID,
ALET, UID_output_area,
ALET, GID_output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Flags
The name of a byte containing the settings of the SETUID and SETGID flags
for the file being executed. The flags are:
v X'01' - SETUID
v X'02' - SETGID
v X'03' - Both SETUID and SETGID
UID
The name of a fullword containing the z/OS UNIX user identifier (UID) to be
set. The UID must be defined to RACF.
GID
The name of a fullword containing the z/OS UNIX group identifier (GID) to
be set. The GID must be defined to RACF.
UID_output_area
The name of a 3-word area in which the new real, effective, and saved z/OS
UNIX user identifiers (UIDs), in that order, are returned.
GID_output_area
The name of a 3-word area in which the new real, effective, and saved z/OS
UNIX group identifiers (GIDs), in that order, are returned.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. An audit record is optionally written, depending on the options in effect for the
system.
3. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
None
Function
The R_Factor service provides functions required by multi-factor authentication
applications to store and retrieve associated data in the RACF database.
1. Get general factor data
2. Set general factor data
3. Get user factor data
4. Set user factor data
5. Get general policy data
Requirements
Authorization:
Any PSW key in supervisor or problem state
Dispatchable unit mode:
Task or user
Cross memory mode:
PASN = HASN
AMODE:
64
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing ALETs must be in the primary address space.
The Num_parms parameter must be in the primary address space.
Linkage conventions
Callers in 64-bit addressing mode should link-edit the IRRSAF64 stub module with
their code and use the IRRPCOMY mapping macro.
RACF authorization
Callers running in system key or supervisor state may specify any function code.
Non-system key problem-state callers require the following authorization for each
function code:
1. Get general factor data
Read access to the resource IRR.RFACTOR.MFADEF.factorName in the
FACILITY class, where factorName matches a profile defined in the MFADEF
class.
Format
CALL IRRSFA64 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Num_parms,
Parm_ALET, Function_code,
Function_parmlist
)
Parameters
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. The words containing the ALETs
must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Num_parms
Specifies the name of a fullword that contains the total number of parameters
in the parameter list. The contents of this field must be set to eleven
(x'0000000B').
Parm_ALET
The name of a word containing the ALET for all the parameters that follow,
including function code specific parameter lists and areas referenced from
them.
Function_code
The name of a 2-byte area containing the function code. The function code has
one of the folowing values:
x'0001' - Get general factor data
Table 87. Function parmlist for x'0002' - Set general factor data
Offset Length Name Description
0 0 FACT_SETF_PLIST Name of structure.
0 4 FACT_SETF_OPTIONS Reserved. Must be initialized to
zeros.
4 4 FACT_SETF_FACTOR_ LENGTH Length (in bytes) of the factor
name.
8 8 FACT_SETF_FACTOR@ Address of the factor name.
16 4 * Reserved. Must be initialized to
zeros.
20 4 FACT_SETF_AF_LENGTH Length (in bytes) of free-form
application data area. Must not
exceed 4096. Specify 0 to delete the
current value.
24 8 FACT_SETF_AF@ Address of free-form application
data area. The area must be
pre-allocated by the caller and its
size specified in
FACT_SETF_AF_LENGTH.
Table 88. Function parmlist for x'0003' - Get user factor data
Offset Length Name Description
0 0 FACT_GETU_PLIST Name of structure.
0 4 FACT_GETU_OPTIONS x'00000000' – Return application
data area only.
x'80000000' – Return
FACT_UFT_POL in
FACT_GETU_UF@.
4 4 FACT_GETU_UF_COUNT Number of user factors. Must be
initialized to zero.
8 4 * Reserved. Must be initialized to
zero.
12 4 FACT_GETU_UF_LENGTH Total length (in bytes) of the user
factor area, a contiguous block of
storage for the user factor list, user
factor field lists, user factor tag lists,
and other variable-length data
referenced by those lists.
16 8 FACT_GETU_UF@ Address of user factor area (see
FACT_UF_ENTRY). The area must
be pre-allocated by the caller and its
size specified in
FACT_GETU_UF_LENGTH.
24 1 FACT_GETU_USER_ LENGTH Length of User ID. Value must be
from 1 to 8.
25 8 FACT_GETU_USER User ID padded on the right with
blanks.
33 1 FACT_GETU_FALL_BACK Value must be initialized to zero.
Table 89. Function parmlist for x'0004' - Set user factor data
Offset Length Name Description
0 0 FACT_SETU_PLIST Name of structure.
0 4 FACT_SETU_OPTIONS Reserved. Must be initialized to
zeroes.
4 4 FACT_SETU_UF_COUNT Number of user factors. No more
than 10 factors may be defined in
the user profile.
8 4 * Reserved. Must be initialized to
zero.
Table 89. Function parmlist for x'0004' - Set user factor data (continued)
Offset Length Name Description
12 4 FACT_SETU_UF_LENGTH Total length (in bytes) of the user
factor area, a contiguous block of
storage for the user factor list, user
factor field lists, user factor tag lists,
and other variable-length data
referenced by those lists.
16 8 FACT_SETU_UF@ Address of user factor area (see
FACT_UF_ENTRY). The area must
be pre-allocated by the caller and its
size specified in
FACT_SETU_UF_LENGTH.
24 1 FACT_SETU_USER_LENGTH Length of User ID.
25 8 FACT_SETU_USER User ID padded on the right with
blanks.
33 1 FACT_SETU_FALL_BACK The value must be x'00' indicating
no change to the current setting.
Table 90. Function parmlist for x'0005' - Get general policy data
Offset Length Name Description
0 0 FACT_GETP_PLIST Name of structure.
0 4 FACT_GETP_OPTIONS Reserved. Must be initialized to
zeros.
4 4 FACT_GETP_POLICY_LENGTH Length (in bytes) of the policy
name.
8 8 FACT_GETP_POLICY@ Address of the policy name.
16 4 FACT_GETP_FL_COUNT Number of policies. The policy
entries start at FACT_GETP_PA@
and mapped by FACT_PF_ENTRY.
20 4 FACT_GETP_PA_LENGTH Length (in bytes) of the policy list.
24 8 FACT_GETP_PA@ Address of the policy list.
32 4 FACT_GETP_TIMEOUT Token time-out value in seconds.
36 1 FACT_GETP_REUSE Token reuse setting.
The user factor tag list begins with a 2-byte header (FACT_UFT_HEADER) which
must be initialized to zero. The subsequent fields (FACT_UFT_PAIR_LENGTH
through FACT_UFT_VALUE) are repeated as a group for each tag/value pair in
the list.
For function code 4, if the tag already exists for the factor, the tag and value are
replaced; unless the specified value length is zero, in which case they are deleted.
If the tag does not exist in the database and its value length is nonzero, it is added.
No more than 20 tags may be specified per user factor.
Table 95. User factor tag list
Offset Length Name Description
0 0 FACT_UFT_LIST Name of structure mapping.
0 2 FACT_UFT_HEADER Reserved. Must be zero.
2 2 FACT_UFT_PAIR_LENGTH Total length of this tag/value pair
entry, not including the length of
this field.
4 2 FACT_UFT_TAG_ ATTRIBUTE Tag attributes.
6 2 FACT_UFT_TAG_LENGTH Length of tag.
8 var FACT_UFT_TAG Tag name.
* 2 FACT_UFT_VALUE_ LENGTH Length of value. The length may
not exceed 1024.
* var FACT_UFT_VALUE Value associated with tag. Type is
EBCDIC character data.
The user factor active date is the time after which the factor is considered 'active'
for the user. Prior to this time, the user is not required to authenticate with the
factor in order to logon to the system.
On input for function 4, the active date may be specified in one of the following
ways:
v The 7-character keyword 'CURRENT', which stores the current UTC time.
v A length of zero (FACT_UFF_VALUE_LENGTH = 0), which clears any existing
value from the user profile, resulting in the 'noactive' default.
On output for function 3, the service returns a 19-character UTC time of the format
'yyyy-mm-dd hh:mm:ss' if set in the user profile. The service does not return an
active date field if the value was cleared or never set.
10 - FACT_GETF_AF_LENGTH
30 - FACT_GETU_UF_LENGTH
50 - FACT_GETP_PA_LENGTH
Function
When called from the parent process, the R_fork service returns the address,
subpool, and key of the storage containing the user security information for the
calling process.
When called from the child process, the R_fork service returns the address of an
area containing a copy of the security information pointed to on the initial call. The
storage pointed to by the address is obtained by the subpool and key returned on
the previous call.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
None. Caller handles recovery.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSFK00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Flag,
ALET, Data_key,
ALET, Data_address,
ALET, Data_length,
ALET, Data_subpool
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Flag
The name of a fullword flag that describes whether fork processing is being
done in the parent's or child's address space:
X'00000000'
Fork processing is being done in parent's address space.
X'00000001'
Fork processing is being done in child's address space.
X'00000002'
Fork processing is being done in parent's address space for additional
security information.
X'00000003'
Fork processing is being done in child's address space for additional
security information.
Data_key
The name of a word in which:
v The storage key of the parent's USP or additional security information is
returned by IRRSFK00 during parent fork processing.
v The storage key of the parent's USP or additional security information is
supplied to IRRSFK00 during child fork processing.
Data_address
The name of a word in which the address of:
v The parent's USP or additional security information is returned by IRRSFK00
during parent fork processing.
v A copy of the parent's USP or additional security information is supplied to
IRRSFK00 during child fork processing.
Data_length
The name of a word that contains the length of the data addressed by
Data_address.
Data_subpool
The name of a word in which:
v The storage subpool for the parent's USP or additional security information
is returned by IRRSFK00 during parent fork processing.
v The storage subpool for the parent's USP or additional security information
is supplied to IRRSFK00 during child fork processing.
SAF return code RACF return code RACF reason code Explanation
0 0 0 The service was
successful.
0 0 4 Additional security
information available.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. The key is meaningful only when the following subpools are used:
v 129–132
v 227–231
v 241
3. The following user security information is propagated from the parent address
space to the child address space:
v Controlled status
v Keep-controlled indicators
v Saved messages
Note: Only a subset of this information is copied during the first call to
R_fork. A second call may be necessary. RACF reason code 4 indicates that
there is additional security information related to the parent address space
that should be propagated to the child address space. If a reason code 4 is
received when a flag value of 0 was passed, R_fork should be called again
with a flag value of 2 specified. If a reason code 4 is received when a flag
value of 1 was passed, R_fork should be called again with a flag value of 3
specified.
4. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
None
Function
The R_GenSec service allows for the invocation of a subset of the GSS-API and
PassTicket functions through a native SAF service. The underlying processing of
these functions is provided by RACF through the IBM Network Authentication
Service on z/OS or by RACF alone.
Requirements
Authorization:
Any PSW key in supervisor or problem state
Dispatchable unit mode:
Task of user
Cross memory mode:
PASN = HASN
AMODE:
31 or 64
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the first parameter list must have the
number of parameters passed. For the Generic Security API Parameter List
(IRRPCOMX), the main parameter mappings will be used by both AMODE 31 and
AMODE 64 callers. The address double words from 31 bit callers should have the
first word filled with zeros and the second word filled with the 31 bit address.
Sub-parameter addresses will be in the format of the AMODE of the caller.
RACF authorization
For callers not running in system key or supervisor state, the use of R_GenSec is
authorized by the resource IRR.RTICKETSERV for function code 1 and
IRR.GSSERV for function code 2 in the FACILITY class. The application server
must be running with a RACF user or group that has at least READ authority to
this resource. If the class is inactive, or the resource is not defined, only servers
running with a system key or in supervisor state may use the R_GenSec service.
For all callers, the use of the R_Gensec service to use PassTicket services (function
code 3) is authorized by the resources in the PTKTDATA class that correspond to
the application ID and target userid used in the PassTicket operation. The
application server must be running with a RACF user or group that has the
authority specified in the following table. If the PTKTDATA class is inactive, or the
resource is not defined, the request will fail because of insufficient authority. All
callers, regardless of PSW key or state, must pass the authorization check. Generic
profiles can be used for authorization.
See z/OS Security Server RACF Security Administrator's Guide for more information
about configuring RACF to use PassTicket services.
To log in a user using a PassTicket, use a standard z/OS function such as __login()
or RACROUTE REQUEST=VERIFY.
Format
31 bit invocation:
CALL IRRSGS00 (Num_parms,
Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Option_word,
Function_code,
Function_parm_count,
Function_parms
)
or 64 bit invocation:
CALL IRRSGS64 (Num_parms,
Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Option_word,
Function_code,
Function_parm_count,
Function_parms
)
Parameters
Num_parms
The name of a fullword containing the number of parameters in the parameter
list, including the Num_parms parameter. The number must be 12 for this
release.
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a fullword containing the ALET for the following parameter. Each
parameter preceded by an ALET parameter must have an ALET specified. Each
ALET can be different. The words containing the ALETs must be in the
primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Option_word
The name of a fullword containing binary zeros. The area referenced by this
parameter is reserved for future use.
Function_code
The name of a 2-byte area containing the function code. The function code is
one of the following values:
Value Description
1 Extract from token
Value Description
2 Invoke GSS-API service
3 PassTicket function
Function_parm_count
The name of a fullword containing the number of function-specific parameters
passed.
Function_parms
The name of an area that contains the remaining parameters for the specific
function to be invoked. The list of addresses that make up this area are
dependent on the subfunction code and the AMODE of the caller. The
addresses are 4 bytes for AMODE 31 callers and 8 bytes for AMODE 64 callers.
Note: For problem state callers the subpool must be in the range 0-127.
String block
8 or 16-byte data area containing 4-byte length and data address. The
length of the address is dependent on the AMODE of the caller. For
AMODE 31, it is length followed by 4 byte address. For AMODE 64, it is
length followed by 4 bytes of reserved space followed by an 8-byte
address.
Expiration Time
4-byte area with value in seconds (hex)
Major/Minor Status
4-bytes of status bits
Note: All output data areas must be supplied to the service so the specified data
can be returned. The only area that the service will allocate storage for is the data
portion of the Buffer Control Block and is the responsibility of the caller to free at
the end of processing. The header of the Buffer Control Block must be supplied by
the caller.
Subfunction codes:
Value Description
1 Return principal name
Return principal name (1): This function will extract the Kerberos principal name
from the input context token.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word containing the context token length (input)
v Address of a GSS-API context token (input)
v Address of a 24-byte string block for use by the server
v Address of the string block for the principal name (output). The data area
supplied should be 240 bytes.
v Address of a word to contain the return code (output)
All references to addresses in the description of this callable service are considered
to be 4 bytes in length for AMODE 31 callers and 8 bytes for AMODE 64 callers.
Storage allocations performed by this service will be in the home address space
and will be owned by the task issuing the call to R_GenSec. It is up to the caller to
free any storage that is allocated and returned to the caller.
Any GSS-API error code which can be generated by the IBM Kerberos runtime
could be returned for the major and minor status code parameters. Refer to the
messages and codes section in the z/OS Integrated Security Services Network
Authentication Service Administration for a description of the various error codes.
Refer to the GSS-API function descriptions in the z/OS Integrated Security Services
Network Authentication Service Programming for a description of the GSS-API
functions, associated input and output parameters and status codes.
Flag Values:
Status codes:
Bit 0 7 8 15 16 31
Miscellaneous definitions:
Name Value
GSS_NO_CREDENTIAL 0
GSS_C_NO_BUFFER 0
GSS_C_NO_CONTEXT 0
GSS_C_INDEFINITE x'FFFFFFFF'
Subfunction codes:
Value Subfunction
1 Initiate a GSS-API security context
2 Continue initiation of a GSS-API security
context
3 Accept a GSS-API security context
4 Delete a GSS-API security context
5 Release a GSS-API credential
6 Get the MIC for a message
Value Subfunction
7 Verify the MIC for a message
8 Wrap a message
9 Unwrap a message
10 Export a GSS-API security context
11 Import a GSS-API security context
12 Export a GSS-API credential
13 Import a GSS-API credential
14 Acquire a GSS-API initiator credential
v Address of the buffer control block for the output token (output). The
security server will obtain storage in the requested subpool for the return
data. The caller must set the subpool number and the security server will set
the length and address values in the buffer control block. The caller is
responsible for releasing the return data when it is no longer needed.
Continue initiation of a GSS-API security context (2)
This function will continue context initiation using the context token returned
by the remote partner after accepting the context. This sub-function is called
only if sub-function 1 completed with GSS major status of
GSS_S_CONTINUE_NEEDED. Refer to the description of the
gss_init_sec_context() function for more information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a 24-byte buffer containing the context handle returned by
function 1 (input). The RACF userid associated with the thread that makes
the request must be the context owner and the context must have been
created on the local system.
v Address of a word containing the length of the context token (input)
v Address of the context token returned by the context acceptor (input)
v Address of a word which will contain the return flags (output). Specify a
zero address if the return flags are not needed. Refer to the description of
the gss_init_sec_context() function for the flag definitions.
v Address of a word which will contain the actual context expiration time in
seconds (output). Specify a zero address if the context expiration time is not
needed.
Accept a GSS-API security context (3)
This function will accept a GSS-API security context. The RACF userid
associated with the thread that makes the request will be the owner of the
security context and delegated credentials. The Kerberos principal associated
with the RACF userid must be the same as the target principal specified by the
context initiator. The output token must be returned to the context initiator if it
has a non-zero length (a length of zero indicates no output token is needed).
See the description of the gss_accept_sec_context() function for more
information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a word containing the length of the input context token (input)
v Address of the input context token received from the context initiator (input)
v Address of a 24-byte buffer which will contain the context handle for the
new security context (output). The caller is responsible for deleting the
security context when it is no longer needed.
v Address of the string block for the source principal name (output). The
string buffer should be 240 bytes. The principal name will be returned in
global format (/.../realm-name/principal-name). Specify a zero address of
the source principal name is not needed.
v Address of a word which will contain the return flags (output). Specify a
zero address if the return flags are not needed. Refer to the description of
the gss_accept_sec_context() function for the flag definitions.
v Address of the context expiration time in seconds (output). Specify a zero
address if the expiration time is not needed.
v Address of the buffer control block for the output token (output). The
security server will obtain storage in the requested subpool for the return
data. The caller must set the subpool number and the security server will set
the length and address values in the buffer control block. The caller is
responsible for releasing the return data when it is no longer needed.
v Address of a 24-byte buffer which will contain the credential handle for the
delegated credentials (output). The caller is responsible for deleting the
credential when it is no longer needed. Specify a zero address if the
delegated credentials are not needed. Delegated credentials are available
only if the GSS_C_DELEG_FLAG flag is set in the return flags.
Delete a GSS-API security context (4)
This function will delete a GSS-API security context. The RACF userid
associated with the thread that makes the request must be the security context
owner and the security context must have been created on the local system.
See the description of the gss_delete_sec_context() function for more
information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of the 24-byte context handle (input)
Release a GSS-API credential (5)
This function will release a GSS-API credential. The RACF userid associated
with the thread that makes the request must be the credential owner and the
credential must have been created on the local system. See the description of
the gss_release_cred() function for more information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of the 24-byte credential handle (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a 24-byte context handle (input)
v Address of a word containing the confidentiality request flag (input). Set the
flag to 1 to request encryption or to 0 to request no encryption. A request for
encryption will be ignored if the current system configuration does not
support message encryption.
v Address of a word containing the message length (input). The maximum
message length is 65536.
v Address of the message (input).
v Address of a word which will contain the confidentiality state (output). The
state will be set to 1 if the message was encrypted and to 0 otherwise.
Specify a zero address if the confidentiality state is not needed.
v Address of the buffer control block for the output token (output). The
security server will obtain storage in the requested subpool for the return
data. The caller must set the subpool number and the security server will set
the length and address values in the buffer control block. The caller is
responsible for releasing the return data when it is no longer needed.
Unwrap a message (9)
This function will verify the signature and optionally decrypt a message. The
RACF userid associated with the thread that makes the request must be the
owner of the GSS-API security context and the context must have been created
on the local system. See the description of the gss_unwrap() function for more
information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of the 24-byte context handle (input)
v Address of a word containing the input token length (input)
v Address of the input token (input)
v Address of the buffer control block for the unwrapped message (output).
The security server will obtain storage in the requested subpool for the
return data. The caller must set the subpool number and the security server
will set the length and address values in the buffer control block. The caller
is responsible for releasing the return data when it is no longer needed.
v Address of a word which will contain the confidentiality state (output). The
state will be set to 1 if the message was encrypted and to 0 otherwise.
Specify a zero address if the confidentiality state is not needed.
Export GSS-API security context (10)
This function will export a GSS-API security context. The security context will
no longer be available upon completion of the export request. The RACF
userid associated with the thread that makes the request must be the owner of
the GSS-API security context and the context must have been created on the
local system. See the description of the gss_export_sec_context() function for
more information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of the 24-byte context handle (input)
v Address of the buffer control block for the output token (output). The
security server will obtain storage in the requested subpool for the return
data. The caller must set the subpool number and the security server will set
the length and address values in the buffer control block. The caller is
responsible for releasing the return data when it is no longer needed.
Import GSS-API security context (11)
This function will import a GSS-API security context. The RACF userid
associated with the thread that makes the request will be the owner of the new
context. See the description of the gss_import_sec_context() function for more
information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a word containing the length of the input token (input)
v Address of the input token (input)
v Address of a 24-byte buffer which will contain the context handle for the
new security context (output). The caller should delete the security context
when it is no longer needed.
Export GSS_API credential (12)
This function will export a GSS-API credential. The credential will still be
available upon completion of the export request. The RACF userid associated
with the thread that makes the request must be the owner of the GSS-API
credential. The credential may have been created on any system in the sysplex.
A credential can be exported only if it is an initiate credential
(GSS_C_INITIATE was specified when the credential was created). See the
description of the gss_export_cred() function for more information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of the 24-byte credential handle (input)
v Address of the buffer control block for the output token (output). The
security server will obtain storage in the requested subpool for the return
data. The caller must set the subpool number and the security server will set
the length and address values in the buffer control block. The caller is
responsible for releasing the return data when it is no longer needed.
Import GSS-API credential (13)
This function will import a GSS-API credential. The RACF userid associated
with the thread that makes the request will be the owner of the new credential.
See the description of the gss_import_cred() function for more information.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a word containing the length of the input token (input).
v Address of the input token (input)
v Address of a 24-byte buffer which will contain the credential handle for the
new credential (output). The caller should release the credential when it is
no longer needed.
Acquire GSS-API initiator credential (14)
This function will acquire a GSS-API credential which can be used to initiate a
GSS-API security context. The RACF userid associated with the thread that
makes the request will be the owner of the new credential. The Kerberos
principal associated with the RACF userid will be used to obtain the initial
ticket-granting ticket for the credential. This initial ticket will be forwardable
and will not contain a client address list.
Function-specific parameters:
v Address of a word containing the subfunction code (input)
v Address of a word which will contain the GSS-API major status code
(output)
v Address of a word which will contain the GSS-API minor status code
(output)
v Address of ACEE to run under the authority of (input)
v Address of a word containing the requested credential expiration time in
seconds (input). An expiration time of 0 will request the default expiration
time of 2 hours while an expiration time of -1 will request the maximum
expiration time. The actual credential expiration time will be limited by the
lifetime of the Kerberos ticket-granting ticket.
v Address of a 24-byte buffer which will contain the credential handle for the
new credential (output). The caller should release the credential when it is
no longer needed.
v Address of a string block for the principal name (output). Specify a zero
address if the principal name is not needed. The string buffer should be
large enough for a 240-byte name. The principal name will be returned in
global format (/.../realm-name/princ-name).
v Address of a word which will contain the actual credential expiration time
in seconds (output). Specify a zero address if the credential expiration time
is not needed.
SAF RACF
return return RACF reason
code code code Explanation
0 0 0 The service was successful.
4 0 0 RACF is not installed.
8 8 0 Invalid function code.
8 8 4 Parameter list error.
8 8 8 An internal error was encountered.
8 8 12 A recovery environment could not be
established.
8 8 16 Not authorized to use this service.
8 12 8 Invocation of the Kerberos server program
call (PC) interface failed with a 'parameter
buffer overflow' return code. This indicates an
internal error in IRRSKG00.
SAF RACF
return return RACF reason
code code code Explanation
8 12 12 Invocation of the Kerberos server program
call (PC) interface failed with an 'unable to
allocate storage' return code. The region size
of the Kerberos server-started task
(SKRBKDC) should be increased.
8 12 16 Invocation of the Kerberos server program
call (PC) interface failed with a 'local services
are not available' return code. This indicates
that the Kerberos server-started task
(SKRBKDC) address space has not been
started or is terminating.
8 12 20 Invocation of the Kerberos server program
call (PC) interface failed with a 'abend in PC
service routine' return code. The symptom
record associated with this abend can be
found in the logrec data set.
8 12 24 Invocation of the Kerberos server program
call (PC) interface failed with an 'unable to
obtain control lock' return code. This can
occur if the task holding the lock is not being
dispatched (for example, a dump is in
progress).
| 8 16 28 PassTicket generation failure. Verify that the
| secured signon (PassTicket) function and
| application ID is configured properly by
| referring to Using the secured signon function
| in z/OS Security Server RACF Security
| Administrator's Guide.
8 16 32 PassTicket evaluation failure. Possible reasons
are:
v PassTicket to be evaluated is not a
successful PassTicket.
v The PassTicket to be evaluated was already
evaluated before and replay protection is in
effect.
v No PTKTDATA profile exists to match the
specified application.
v An internal error occurred.
8 16 X'nnnnnnnn' The Kerberos server was not able to
successfully process the function.
X'nnnnnnnn' is the Network Authentication
Service function status code. See Network
Authentication Service documentation for
more information.
8 16 X'nnnnnnnn' PassTicket evaluation extended failure.
X'nnnnnnnn' is the internal reason code for
the evaluation failure.
Usage notes
1. This service is intended for use by z/OS application servers, which are not
executing in a Language Environment®. It allows z/OS application servers to
perform GSS-API functions.
Related services
R_ticketserv
Function
The R_getgroups service checks the high-order bit of the input group count. See
Group_count under “Parameters” on page 248 for more information.
The GIDs are not explicitly added to or deleted from the supplemental group list.
A GID is in this list if the user was a member of the group when the user's ACEE
was created through a RACROUTE REQUEST=VERIFY request and if the GID was
assigned to the group before the initUSP service was performed for the process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSGG00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, User_key,
ALET, Group_count,
ALET, Grouplist,
ALET, Number_of_GIDs
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
User_key
The name of a byte containing the user's key. This key is used to store into the
output grouplist area. The key is in the four high-order bits of the byte.
Group_count
The name of a word containing the number of GID entries that can be stored
in the Grouplist area. IRRSGG00 uses the high-order bit to determine how to
process the value in the parameters.
If the high-order bit of the input Group_count is:
1. On, the caller must store into this area the list of GIDs of the supplemental
groups to be set as the supplemental groups of the current process.
2. Off, IRRSGG00 checks the input Group_count value. If it is:
a. 0, the Grouplist area is not used. IRRSGG00 returns the total
supplemental GID count of the current process in the Number_of_GIDs
parameter.
b. Less than the total supplemental GID count:
1) An error code is returned.
2) The GIDs of the supplemental groups for the current process are put
into the Grouplist area, which can only accommodate the number of
GIDs specified in the Group_count parameter.
3) The count of the supplemental GIDs actually placed in the Grouplist
area is returned in the Number_of_GIDs parameter.
4) The Group_count field is set to the total supplemental GID count of
the current process.
The supplemental groups in the Grouplist area are listed in the same
order as the group connections shown in the output of the
LISTUSER command.
c. Greater than or equal to the total supplemental GID count:
1) The GIDs of the supplemental groups for the current process are put
into the Grouplist area.
2) The supplemental GID count of the current process is put into the
Number_of_GIDs parameter.
Grouplist
The name of an area in which the GIDs of the supplemental groups for a
process are returned. The Group_count parameter indicates the number of
entries this area can contain. The GIDs are returned as consecutive 4-byte
entries.
Number_of_GIDs
The name of a word in which the number of GIDs put in the Grouplist area is
returned.
Usage note
v This service is intended only for use by the MVS BCP and by z/OS UNIX
servers. The service contains support for z/OS UNIX servers, but cannot be
directly invoked by a z/OS UNIX server.
Related services
None
Function
The R_getgroupsbyname service checks the input group count and, if it is zero,
returns the number of supplemental groups for the specified user ID. If the input
count is not zero and it is less than the number of groups, an error code is
returned. If the count is not less than the number of groups, the GIDs of the
supplemental groups for the specified user ID are put into the grouplist area, and
the number of GIDs is returned.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
A RACF user can be connected to more than NGROUPS_MAX groups, but only up
to the first NGROUPS_MAX z/OS UNIX groups will be associated with the user
for this service.
Format
CALL IRRSUG00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, User_key,
ALET, Userid_length,
ALET, Userid,
ALET, Group_count,
ALET, Grouplist,
ALET, Number_of_GIDs
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
User_key
The name of a byte containing the user's key. This key is used to store into the
output grouplist area and number_of GIDs word. The key is in the four
high-order bits of the byte.
Userid_length
The name of a byte containing the length of the user ID.
Userid
The name of an 8-byte area containing the user ID whose groups are to be
returned. The user ID must be left-justified in the area. The userid_length
parameter specifies the actual length of the name.
Group_count
The name of a fullword containing the number of GID entries in the input
grouplist area.
Grouplist
The name of an area in which the GIDs of the supplemental groups are
returned. The GIDs are returned as consecutive 4-byte entries. The
group_count parameter indicates the number of entries this area can contain.
Number_of_GIDs
The name of a word in which the number of GIDs actually put in the grouplist
area is returned.
Usage notes
1. This service is intended only for use by the MVS BCP.
Related services
None
Function
The R_GetInfo SAF callable service allows servers to retrieve a subset of security
server information. Invokers provide a function code value to identify which
subset of information is requested.
Requirements
Authorization:
Any PSW key in supervisor or problem state
Dispatchable unit mode:
Task
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the Num_parms parameter must
indicate the number of parameters in the parameter list.
RACF authorization
For callers not running in system key or supervisor state, the use of the R_GetInfo
service is authorized by FACILITY class resources:
1. BPX.SERVER
The ACEE associated with the address space is used to determine the caller. If
the caller is running with a RACF user or group that has at least READ
authority to the BPX.SERVER resource, use of R_GetInfo is permitted and no
subsequent access checks are made.
2. IRR.RGETINFO.EIM
Determining if function code X'0001' is found. The current TCB is checked for
an ACEE. If one is found, it will be used to determine the caller. If there is no
ACEE associated with the current TCB, the ACEE associated with the address
space is used to determine the caller. If the caller is running with a RACF user
or group that has at least READ authority to the IRR.RGETINFO.EIM resource,
use of R_GetInfo is permitted.
3. IRR.RGETINFO.REALM
Determining if function code X’0002’ is found. The current TCB is checked for
an ACEE. If one is found, it will be used to determine the caller. If there is no
ACEE associated with the current TCB, the ACEE associated with the address
space is used to determine the caller. If the caller is running with a RACF user
or group that has at least READ authority to the IRR.RGETINFO.REALM
resource, use of R_GetInfo is permitted.
If the FACILITY class is inactive, or the preceding resources are not defined, only
servers running in system key or supervisor state may use the R_GetInfo service.
Format
CALL IRRSGI00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Num_parms,
Parm_ALET
Function_code
Option,
RACF_entity,
RACF_class,
Result_entries
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF use. The work area
must be in the primary address space.
ALET
The name of a fullword containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_Return_Code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_Return_Code
The name of a fullword in which the service routine stores the return code.
RACF_Reason_Code
The name of a fullword in which the service routine stores the reason code.
Num_parms
The name of a fullword containing the number of parameters in the parameter
list, including the Num_parms parameter. This number must be 14 for z/OS
Version 1, Release 7 or later.
Parm_ALET
The name of a fullword which must be in the primary address space and
contains the ALET for the remaining parameters.
Function_code
The name of a half-word (2-byte) area containing the function code. Use the
following values for z/OS Version 2, Release 7, or later:
X'0001' - Get Enterprise Identity Mapping (EIM) information
Get Enterprise Identity Mapping (EIM) information. This function is
further defined by the Option parameter.
v If the Option parameter is X'0001', return the LDAPBIND profile
name from the Enterprise Identity Mapping (EIM) segment of the
specified RACF_entity value, where RACF_entity identifies a RACF
userid.
v If the Option parameter is X'0002', return the local registry name, the
Kerberos registry name, and the X.509 registry name from the
Enterprise Identity Mapping (EIM) segment of the
IRR.PROXY.DEFAULTS profile in the FACILITY class.
v If the Option parameter is X'0003', return EIM and PROXY segment
data:
– Distinguished name of the Enterprise Identity Mapping (EIM)
domain
– Enterprise Identity Mapping (EIM) options
– The LDAP host name
– The distinguished name to use for LDAP binding
– Whether or not a password for LDAP binding has been specified
(YES or NO)
for the specified RACF_class name and RACF_entity value, where
RACF_entity identifies a RACF profile name.
Requested information will be returned in the Result_entries output
area.
Parameter usage
Function Function_code Option RACF_entity RACF_class Result_entries
Get X'0001' X'0001' In N/A In/Out
Enterprise
X'0002' N/A N/A In/Out
Identity
Mapping X'0003' In In In/Out
(EIM)
information
Get Realm X'0002' X'0001' In N/A In/Out
Usage notes
1. Function code X'0001' is provided specifically for use by the Enterprise Identity
Mapping (EIM) component of the Integrated Security Services Element.
2. It is the responsibility of the caller to obtain and free the Result_entries data
area. ResultAreaLen must be set to the total length of the area provided,
including the length of the ResultArea structure and the length of the
appropriate function specific data area.
On output, ResultAreaUsed will be set to the total length of the data returned.
If ResultAreaLen is insufficient to return the requested information, an error
will be returned and ResultAreaUsed will set to the total length required, if the
size of the provided ResultArea structure is sufficient to contain this value.
3. When R_GetInfo detects a parameter list error, it will return SAF return code 8,
RACF return code 12, and RACF reason code nn, where nn indicates the
position in the parameter list of the parameter in error. For example, the
Num_parms parameter is the eighth parameter in the parameter list, and if an
invalid value is supplied for Num_parms, R_GetInfo will return SAF return
code 8, RACF return code 12, and RACF reason code 8.
4. A length of zero can be specified for RACF_entity for Function_code X'0001'
and Option X'0001'. In this case, RACF will attempt to determine the userid
from the ACEE associated with the current TCB. If there is no ACEE associated
with the current TCB, the address space level ACEE will be used. If no userid
can be determined, an error will be returned.
5. When Function_code is X'0001', all CHARACTER values returned in the
function specific result data areas for Option X'0001', X'0002', and X'0003' will
be terminated by X'00'. For example, if the local registry name is "ABC", the
first four bytes of the RegLocal field will contain X'C1C2C300'.
6. When Function_code is X'0002', all CHARACTER values returned in the
function specific result data areas will be terminated by X'00'. The
ResultAreaUsed will reflect this extra '00'x byte.
Function
The R_IPC_ctl service performs a function based on the function code value in the
parameter list.
v When the function is Check Owner for Remove ID, R_IPC_ctl checks whether
the current process has the appropriate authority to the IISP.
v When the function is Check Owner and Set, R_IPC_ctl sets the owner's UID and
GID and the mode permission bits if the current process has the appropriate
authority.
v When the function is Check Superuser and Set, R_IPC_ctl sets the owner's UID
and GID and the mode permission bits if the current process is a superuser.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user/any task if system user type is specified
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. The access checks performed are defined in XPG4 System Interfaces and
Headers under msgctl, semctl, and shmctl interfaces for commands IPC_SET
and the IPC_RMID. The access checks are as follows:
a. The effective z/OS UNIX user identifier (UID) for the calling process is
used for all access checks.
b. If the CREI user type is system, IRRSCI00 grants authorization when the
function is Check Owner for Remove ID, or updates the IPCP when the
function is either Check Owner and Set or Check Superuser and Set.
c. The user is considered a superuser if the effective UID is zero or if the
ACEE indicates trusted or privileged authority.
d. If the function is Check Owner for Remove ID, the user must be either a
superuser or the effective UID of the process must match either the owner's
UID or creator's UID in the IISP for a successful completion. Otherwise, the
user is not authorized.
2. If the function is Check Superuser and Set, the user must be a superuser in
order to set the owner's z/OS UNIX user identifier (UID), owner's z/OS UNIX
group identifier (GID), and mode fields from the input parameters into the IISP
for a successful completion. Otherwise, the user is not authorized.
3. If the function is Check Owner and Set, the user must be either a superuser or
the effective UID of the process must match either the owner's UID or creator's
UID in the IISP in order to set the owner's UID, owner's GID, and mode fields
from the input parameters into the IISP for a successful completion. Otherwise,
the user is not authorized.
4. If the SECLABEL class is active and the ISP contains a security label, the
accessing process must have an equivalent security label. With MLIPCOBJ
active, requests will be failed if either the accessing process or the ISP does not
contain a security label.
Format
CALL IRRSCI00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Function_code,
ALET, Owner_UID,
ALET, Owner_GID,
ALET, Mode_Permissions,
ALET, ISP,
ALET, CREDIPC
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area containing the function code:
X'01' Check Owner for Remove ID
X'02' Check Owner and Set
X'03' Check Superuser and Set
Owner_UID
The name of a 4-byte area containing the new owner's UID to be set.
Owner_GID
The name of a 4-byte area containing the new owner's GID to be set.
Mode_Permissions
The name of a 4-byte area containing the new mode permission bits to be set.
The following is a list of defined permission bits mapped by BPXYMODE:
S_IRUSR
Permits the process that owns the IPC member to read it.
S_IWUSR
Permits the process that owns the IPC member to alter it.
S_IRGRP
Permits the group associated with the IPC member to read it.
S_IWGRP
Permits the group associated with the IPC member to alter it.
S_IROTH
Permits others to read the IPC member.
S_IWOTH
Permits others to alter the IPC member.
Alter and write have the same meaning for access checks. Alter applies to
semaphores, and write applies to message queueing and shared memory
segments.
ISP
The name of the IISP for the file being accessed.
CREDIPC
The name of the CREI structure for the current IPC system callable service. The
CREI contains the IPC identifier and the IPC key. See z/OS Security Server
RACF Data Areas in the z/OS Internet library (www.ibm.com/systems/z/os/
zos/library/bkserv).
Usage notes
1. This service is intended for use only by the MVS BCP.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
3. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
makeISP, ck_IPC_access
Function
The R_kerbinfo callable service can be used to either retrieve RACF Network
Authentication Service information, or to update the count of unsuccessful
attempts to use a Network Authentication Service key.
The action performed by this callable service is based on the function code passed
by the caller in the R_kerbinfo parameter list:
v When the function code is set to X'01', R_kerbinfo retrieves local Network
Authentication Service principal information. The caller must identify the
principal by providing a RACF name or a Network Authentication Service
principal name.
v When the function code is set to X'02', R_kerbinfo increments the count of
invalid attempts by a Network Authentication Service principal to use a key. The
caller must identify the principal by providing a Network Authentication Service
principal name.
v When the function code is set to X'03', R_kerbinfo resets the count of invalid
attempts by a Network Authentication Service principal to use a key to zero.
The caller must identify the principal by providing a Network Authentication
Service principal name.
v When the function code is set to X'04', R_kerbinfo retrieves Network
Authentication Service realm information. The caller may identify the realm by
providing a Network Authentication Service realm profile name, or by providing
a NULL name, in which case RACF will return information about the local
realm, KERBDFLT.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Ant task
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary only
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the last word in the parameter list
must have a one in the high-order (sign) bit.
Format
CALL IRRSMK00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_code,
RACF_name,
KERB_name,
Data_area,
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a 1-byte area in the primary address space containing the function
code:
X'01'
Retrieve local Network Authentication Service principal information.
X'02'
Increment a Network Authentication Service principal's count of invalid
key attempts.
RACF will process this request much the same as it does when an invalid
password is supplied during TSO logon. When the number of attempts
exceeds the number of incorrect password attempts which RACF allows,
set using the SETROPTS command PASSWORD REVOKE suboperand, the
RACF user ID will be revoked, an ICH408I message will be issued and an
SMF Type 80 record will be written.
X'03'
Reset a Network Authentication Service principal's count of invalid key
attempts to zero.
RACF will process this request much the same as a successful TSO logon
request and will update the date and time of the last successful logon (the
LJDATE/LJTIME fields in the RACF user profile) to the current date and
time.
X'04'
Retrieve Network Authentication Service realm information.
RACF_name
The name of a 9-byte area in the primary address space consisting of a 1-byte
length field followed by up to 8 characters. If a value is specified for
RACF_name, it must be defined RACF user ID and specified in uppercase. If a
RACF user ID is not specified, the length must equal zero.
RACF_name may only be specified with function code X'01' and will be used
to identify a local Network Authentication Service principal by the principal's
RACF user identity.
KERB_name
The name of an area in the primary address space containing the 240-byte
Network Authentication Service name. The name must be left-justified and
padded with blanks. The only way to get the local realm information is to
specify a null in the KERB_name field. If a Network Authentication Service
realm profile name is specified, it must be realm qualified (for example, follow
the DCE-like convention of /.../REALM_A/KRBTGT/REALM_B) and must be
folded to all uppercase.
Note: Local Network Authentication Service principal names and realm names
returned in the Data_area NAME field will not be realm qualified and will be
case sensitive.
If the caller does not want to specify a KERB_name, then the first character of
the area must be a NULL byte (that is, the first byte of the 240 byte area must
contain X'00').
KERB_name may be specified with any function code. For function codes
X'01,',X'02', and X'03', it is used to identify a local Network Authentication
Service principal. For function X'04', it is used to identify a Network
Authentication Service realm profile name.
Data_area
The name of an area in the primary address space for fields to be retrieved.
The format of the Data_area structure is:
The ordered triplet (name of the field, length of the field, and field data) is a
repeating data structure. This triplet will repeat for the total number of fields
in the input Data_area.
The following table lists the fields that will be returned for function code X'01'
(retrieve local principal information) and X'04' (retrieve realm information). The
caller-supplied Data_area structure must be allocated large enough for all of
the fields associated with the function to be returned. The fields that will be
returned, along with each field's maximum length in bytes and the order that
they will be returned, can be found in the following table:
Maximum
Field name length Data type Description
USERID 8 Character RACF userid (N/A for function X'04')
REVOKED 1 Boolean Flag indicating that user has been revoked
(N/A for function X'04')
EXPIRED 1 Boolean Flag indicating that user's key has expired
(N/A for function X'04')
NAME 240 Character Kerberos name
MINTKTLF 4 Integer Minimum ticket life value (N/A for
function X'01')
MAXTKTLF 4 Integer Maximum ticket life value
DEFTKTLF 4 Integer Default ticket life value (N/A for function
X'01')
SALT 240 Character Current key salt
ENCTYPE 4 Binary Specifies the encryption types allowed for
this profile. See Table 99 on page 266 for
ENCTYPE values.
CURKEYV 1 Integer Current key version (1-255)
CURKEY 98 Character Current key. See format in the following
table.
PREVKEYV 1 Integer Previous key version (1-255)
PREVKEY 98 Character Previous key. See format in the following
table.
CHKADDRS 1 Boolean Flag indicating that the Kerberos server
should check addresses in tickets.
The minimum length of the Data_area structure was previously 838 bytes. If
fewer than 849 bytes are supplied the service will behave as before the new
support. If the length is greater than or equal to 849 bytes the new triplet will
be returned along with the previous data. This accounts for the two 2-byte
length fields at the beginning and 14 sets of field triplets.
The value fields CURKEY and PREVKEY returned for information retrieval,
function codes X'01' and X'04', have the following format:
After a password change, profiles contain the new AES key values only. Therefore,
you might see the following profiles:
v A profile where neither CURKEY or PREVKEY contains the new AES key
values. This occurs when the profile was defined before z/OS V1R9 and no
password change has occurred after migrating to z/OS V1R9.
v A profile that has CURKEY with AES key values and PREVKEY with no AES
key values. This occurs when the profile was defined before z/OS V1R9 and one
password change has occurred after migrating to z/OS V1R9.
Only the keys for the encryption types allowed for this profile are returned (for
example, those indicated in the ENCTYPE field).
Usage notes
1. The caller is in supervisor state, so the task and address space ACEEs are not
checked. Therefore, for example, an authorized caller may extract KERB
segment fields, or update the invalid key count, for any user who has a KERB
segment.
2. This service returns fields that have been previously populated. Associated
with the returned fields is a length indicator. The length indicator is set to
zero if a field does not exist.
3. If RACF_name and KERB_name are both provided for function X'01',
R_kerbinfo will use RACF_name.
4. If RACF_name is provided for any function other than X'01', a parameter list
error will be returned.
5. If KERB_name is not supplied on a function X'04' request (the first character is
NULL), information about the local z/OS Kerberos Security Server,
KERBDFLT, will be returned. Alternatively, KERB_name may be explicitly set
to KERBDFLT.
6. It is the responsibility of the caller to obtain and free the Data_area. If the
fields to be retrieved from RACF are larger than the Data_area, RACF fails the
request and returns an error. If the size of the Data_area structure is sufficient
to contain this value, the Data_area length (offset 0) is set to the total length
required.
7. Field level access checking does not occur when retrieving fields with this
service.
8. Field names are returned as 8-character fields, left-justified, and padded with
blanks. They are specified in uppercase.
9. Fields that are not applicable for a function code, such as USERID for function
code X'04', will be returned with the length set to zero.
10. If function code X'02' causes a user to be revoked, an ICH408I message will be
issued and an SMF Type 80 record will be cut.
11. If the length of data_area structure specified is less than the minimum length
defined in the parameter description a subset of the data will be returned
unless it is less than 838 bytes which will result in return and reason codes
8,8,24.
Parameter usage
Table 100. Parameter usage
Parameter Function X'01' Function X'02' Function X'03' Function X'04'
SAF_return_code Output Output Output Output
RACF_return_code Output Output Output Output
RACF_reason_code Output Output Output Output
Function_code Input Input Input Input
KERB_name Input Input Input Input
Related services
R_ticketserv, R_usermap
Function
The R_Password service provides functions to:
1. Evaluate a clear-text password or password phrase (regardless of the
encryption algorithm in effect).
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Any task
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
None
Format
CALL IRRSPW00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Num_parms,
Parm_ALET,
Function_code,
UserID_length,
UserID,
Password_length,
Password,
Function_parmlist)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a 4-byte area in which the SAF router returns the SAF return
code.
RACF_return_code
The name of a 4-byte area in which the service routine stores the return code.
RACF_reason_code
The name of a 4-byte area in which the service routine stores the reason code.
Num_parms
Specifies the name of a 4-byte area that contains the total number of
parameters in the parameter list. It must be initialized to 15.
Parm_ALET
The name of a 4-byte area containing the ALET for the remaining parameters
in the parameter list and any data areas referenced by parameter list pointers.
The word containing the ALET must be in the primary address space.
Function_code
The name of a 2-byte area containing the Function code. The function code
must be one of the following values:
v X’0001’ - Verify a user's current password or phrase.
v X’0002’ - Generate an encrypted password or password phrase hash.
UserID_length
The name of a 4-byte area containing the length of the user ID associated with
the password. This value must be greater than zero and less than or equal to 8.
UserID
The name of an area containing the user ID.
Password_length
The name of a 4-byte area containing the length of the password. This value
must be greater than zero and less than or equal to 100. If the length is less
than 9, RACF assumes it is a password. If the length is 9 or greater, RACF
assumes it is a password phrase.
Password
The name of an area containing the password or password phrase.
Function_parmlist
Specifies the name of the required function code specific parameter list area for
the Function code specified.
Table 101. Structure for X'0001': Verify a user's current password or phrase.
Offset Length Name Description
0 0 XPWD_VFY_PLIST Name of structure
0 4 XPW_VFY_OPTIONS Option flags. Undefined bits must be
set to binary zeroes.
x'80000000' Perform password expiration and
user revocation checking.
| x'40000000 If there is no ACEE cache entry that
| can be used to validate the password,
| then fail immediately with return
| code 8/8/8. The password may or
| may not be valid.
Table 102. Structure for X'0002': Generate an encrypted password or password phrase hash
Offset Length Name Description
0 0 XPWD_GEN_PLIST Name of structure
0 4 * Reserved. Must be initialized to
zeroes.
4 4 XPWD_GEN_CRYPT1_LEN On input: Length of the area to
hold the first encrypted output
value.
On output: Actual/required
length of the first encrypted
output value.
8 4 * Reserved. Must be initialized to
zeroes.
12 4 XPWD_GEN_CRYPT1@ Address of pre-allocated output
area in which RACF returns the
first part of the encrypted
value. The area must be at least
8 bytes. This value may be
stored in the PASSWORD or
PHRASE field of the RACF
database using ICHEINTY.
16 4 XPWD_GEN_CRYPT2_LEN On input: Length of the area to
hold the second encrypted
output value.
On output: Actual/required
length of the second encrypted
output value.
20 4 * Reserved. Must be initialized to
zeroes.
Table 102. Structure for X'0002': Generate an encrypted password or password phrase
hash (continued)
Offset Length Name Description
24 4 XPWD_GEN_CRYPT2@ Address of pre-allocated output
area in which RACF returns the
second part of the encrypted
value. The area must be at least
40 bytes. This value may be
stored in the PWDX or
PHRASEX field of the RACF
database using ICHEINTY.
Usage notes
| 1. The password evaluation service checks to see if the specified password or
| phrase matches the one stored in the RACF database for the specified user. It
also optionally provides password expiration and user revocation checking.
| When the caller requests the extra checking (and the x'40000000' bit is not set
| on in XPW_VFY_OPTIONS), and the request fails, or caching does not find a
match, a RACROUTE REQUEST=VERIFY is issued. When the extra checking is
not requested, no RACROUTE is issued.
2. The encrypted password that is returned by function code 2 cannot be used for
subsequent authentication (for example, RACROUTE REQUEST=VERIFY/X or
initACEE) of the specified user. It is a means of temporarily encrypting a
clear-text password to protect its confidentiality. It can be stored in the RACF
database using the ICHEINTY interface.
Related services
None
Function
The R_PgmSignVer service provides the functions required to apply a digital
signature to a z/OS program object, and the functions required to verify such a
signature. The signing services are intended for use by the z/OS program binder.
The verification services are intended for use by the z/OS loader.
Requirements
Authorization:
Any PSW key in supervisor or problem state.
Linkage conventions
Callers in 31-bit addressing mode should link-edit the IRRSPS00 stub module with
their code, and use the IRRPCOMP mapping macro. Callers in 64-bit addressing
mode should link-edit the IRRSPS64 stub module with their code, and use the
IRRPCOMY mapping macro.
RACF authorization
For unauthorized callers of the program signing services, the caller must have
sufficient authority to use the key ring specified in the parameter list (or if not
specified, then as defined in the appropriate profile in the FACILITY class) and the
private key contained within it as determined by the R_datalib callable service and
ICSF. See “R_datalib (IRRSDL00 or IRRSDL64): OCSF data library” on page 166 for
more information.
Format
CALL IRRSPS00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Num_parms,
Function_code,
Function_parmlist
)
Parameters
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET must be 0 for this service.
The words containing the ALETs must be in the primary address space.
SAF_Return_Code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_Return_Code
The name of a fullword in which the service routine stores the return code.
RACF_Reason_Code
The name of a fullword in which the service routine stores the reason code.
Num_parms
Specifies the name of a fullword that contains the total number of parameters
in the parameter list. The contents of this field must be set to binary ten.
Function_code
The name of a 2-byte area containing the Function code. The function code has
one of the following values:
X’0001’
Initialize signing. (Function name SIGINIT.) This function must be
called before calling any of the other signing functions.
X’0002’
Digest intermediate program data for signature generation. (Function
name SIGUPDAT.) This function is optional. It should be called only if
all the program’s data cannot be processed on one call to generate
signature. It may be called multiple times before calling generate
signature.
X’0003’
Generate signature. (Function name SIGFINAL.) This function finalizes
the signature generation and returns the result. It also frees any work
area storage that may have been allocated.
X’0004’
Terminates the signing operation and frees resources allocated by
SIGINIT. (Function name SIGCLEAN.) This function should be called
only if signature generation is not to be finalized with a call to
SIGFINAL. Note that all R_PgmSignVer functions will perform this
cleanup if they return an error to the caller. The caller needs to call the
cleanup function only if it is terminating for its own reason.
X’0005’
Initialize signature-verification and optionally digest initial program
data. (Function name VERINIT.) This function must be called before
calling any of the other verification functions except VERINTER
(interrogate directive).
X’0006’
Digest intermediate program data for signature-verification. (Function
name VERUPDAT.) This function is optional. It should be called only if
all the program’s data cannot be processed on the VERINIT and
VERFINAL calls. It may be called multiple times before performing
final verification.
X’0007’
Perform final verification. (Function name VERFINAL.) This function
finalizes the signature-verification and returns the result. It also audits
the event and frees any work area storage that may have been
allocated. If all the program data can be specified in a single call, then
VERFINAL can be called without first calling VERINIT. See Table 109
on page 279 for more information.
X’0008’
Terminates the signing operation and frees resources allocated by
VERINIT. (Function name VERCLEAN.) This function should be called
only if signature generation is not to be finalized with a call to
VERFINAL. Note that all R_PgmSignVer functions will perform this
cleanup if they return an error to the caller. The caller only needs to
call the cleanup function if it is terminating for its own reason.
X’0009’
Interrogate directive. (Function name VERINTER.) This function
examines the directive (supplied within the ICHSFENT in the
function-specific parameter list) to determine the appropriate action.
This would be used for the cases where VERFINAL will not be called.
For example, when digital signature processing is required but the
module does not have a digital signature. This function is not available
to unauthorized callers.
Function_parmlist
Specifies the name of the function code specific parameter list area for the
Function_code specified.
All address fields are 8-byte addresses. When referring to 31-bit storage
addresses, the caller must make sure that the high-order word of the address
field is set to binary zeros.
owning-userid/ring-name
Usage notes
Usage notes for program signing
1. This service tracks the resources used for signing using a task-related
name/token pair. The 16–byte token name has the following format:
IRRPSIGNprogram-name
8. The default message digest algorithm is SHA256. This is the only supported
message digest algorithm.
9. The ZOSSignatureInfo structure is DER encoded. It has the following ASN.1
definition:
ZOSSignatureInfo ::= SEQUENCE {
signDetails SignatureDetails
certs SET OF Certificate -- In reverse hierarchy order, EE to root
signature BIT STRING -- PKCS #1 format - Encrypted DigestInfo
}
Related services
None.
Function
The R_PKIServ SAF callable service allows applications to request the generation,
retrieval, and administration of X.509 V.3 certificates and certificate requests
through z/OS Cryptographic Services PKI Services. See z/OS Cryptographic Services
PKI Services Guide and Reference for more information on this service.
Requirements
Authorization:
Any PSW key in supervisor or problem state
Dispatchable unit mode:
Task of user
Cross memory mode:
PASN = HASN
AMODE:
31 or 64
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have a FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. Use the Number _parameters parameter to indicate the
number of parameters specified. The mapping macro IRRPCOMP is for 31 bit
callers and IRRPCOMY is for 64 bit callers.
RACF authorization
The RACF authorization mechanism for this callable service varies depending on
the type of function requested (end user versus administrative) and the requested
provider (SAF versus PKI Services).
For the end user functions, this interface is protected by FACILITY class profiles
(resources) of the form IRR.RPKISERV.(function)[.ca-domain], where (function) is one
Chapter 2. Callable services descriptions 289
R_PKIServ
of the end user function names described under the Function_code parameter. If
the CA_domain parameter supplied on the R_PKIServ call is not null (has a length
greater than 0), the profile is qualified with the CA domain name. If the
CA_domain parameter supplied on the R_PKIServ call is null, the qualifier is not
used. For example, if the function name is GENCERT and the CA_domain
parameter is “Customers”, the FACILITY class resource is
IRR.RPKISERV.GENCERT.CUSTOMER. However, if the CA_domain parameter is
null, the FACILITY class resource is IRR.RPKISERV.GENCERT.
The user ID (from the ACEE associated with the address space) for the application
is used to determine access:
NONE
Access is denied.
READ
Access is permitted based on subsequent access checks against the caller's user
ID. To determine the caller, the current TCB is checked for an ACEE. If one is
found, the authority of that user is checked. If there is no ACEE associated
with the current TCB, the ACEE associated with the address space is used to
locate the user ID.
UPDATE
Access is permitted based on subsequent access checks against the application's
user ID.
ALTER OR CONTROL (or user ID is RACF SPECIAL)
Access is permitted with no subsequent access checks made.
For SAF GENCERT and EXPORT requests where the application has READ and
UPDATE access, subsequent access checks are performed against the
IRR.DIGTCERT.(function) FACILITY profiles. These are identical to the checks
made by the RACDCERT TSO command. See z/OS Security Server RACF Command
Language Reference and z/OS Security Server RACF Security Administrator's Guide for
more information.
If the caller is not RACF SPECIAL, the caller will need READ access to perform
read operations (QUERYREQS, QUERYCERTS, REQDETAILS, and CERTDETAILS)
and UPDATE access for the action operations (PREREGISTER, MODIFYREQS, and
MODIFYCERTS). To determine the caller, the current TCB is checked for an ACEE.
If one is found, the authority of that user is checked. If there is no ACEE associated
with the current TCB, the ACEE associated with the address space is used to locate
the user ID.
Format
31 bit invocation:
64 bit invocation:
Parameters
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_Return_Code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_Return_Code
The name of a fullword in which the service routine stores the return code.
RACF_Reason_Code
The name of a fullword in which the service routine stores the reason code.
Number_parameters
Specifies the name of a fullword that contains the number of parameters that
follow in the non-request specific portion of the R_PKIServ callable service
invocation. If the CA_domain parameter is specified, Number_parameters must
be set to 6. Otherwise, Number_parameters must be set to 5.
Function_code
The name of a 2-byte area containing the function code. The function code has
one of the following values:
End user functions:
v X'0001'-Generate a basic X.509V3 certificate using the application-provided
data pointed to by the function-specific parameter list (Function name
GENCERT).
v X'0002'-Extract certificate by certificate request ID (Function name EXPORT).
Parmlist_version
The name of a 4-byte input value which contains the version number for the
following input field, Function_parmlist. To take full advantage of the support
provided by this release, this field should be set to 1 for the EXPORT function,
and should be set to 2 for the MODIFYCERTS and MODIFYREQS functions.
For all other functions this field must be set to 0.
Function_parmlist
Specifies the name of the function code specific parameter list for the
Function_code specified:
Table 123. Function_parmlist for GENCERT
Field Attributes Usage Description
Eyecatcher 8 characters In Eyecatcher, 8 characters left-aligned blank
filled. Actual value set by invoker, for
example 'GENCERT'.
CertPlistLen 4-byte length In Describes the length in bytes of the
certificate generation plist.
CertPlist Address of In The name of the area which is the
CertGen request parameter list. This area
maps the specific name, length,
address/data values which are used in
satisfying the certificate request for the
specified user. Also, see Table 124.
Certid Address of In/Out Points to a 57-byte area, in which the first
byte will contain the actual length on
return of the certificate request ID. The
storage address specified must be
obtained by the caller, and freed by the
caller. The returned certificate request ID
is used to extract the completed
certificate, if the request has been
accepted by RACF.
Note: All data values are EBCDIC character data unless otherwise indicated.
Also, NotBefore and NotAfter are replaced with StartDate and EndDate.
value. The field name is a fixed 12-character field, case sensitive, left-aligned,
and padded with blanks, the length field is a binary four byte value, which
qualifies the length of the data item. Note that all data values are EBCDIC
character data unless otherwise indicated.
Table 138. CertPlist for CERTDETAILS
Field Max length Description
AltIPAddr 45 bytes IP address in IPv4 or IPv6 format for subject
alternative name extension. Note that this field
may be repeated.
AltURI 255 bytes Uniform Resource Identifier for subject alternative
name extension. Note that this field may be
repeated.
AltEmail 100 bytes Email address for subject alternative name
extension. Note that this field may be repeated.
AltDomain 100 bytes Domain Name for subject alternative name
extension. Note that this field may be repeated.
AltOther 255 bytes Other Name for subject alternative name
extension. Note this field may be repeated.
HostIdMap 100 bytes HostIdMapping extension entry. Note this field
may be repeated.
CustomExt 1024 bytes Customized extension in the form of a
comma-separated four-part string. The first part is
the OID of the extension. The second part is the
critical flag – ‘C’(critical) or ‘N’(non-critical), the
third part is the encode type – ‘INT’(integer in
printable hexadecimal format), ‘IA5’(IA5 string),
‘PRT’(printable string), ‘BMP’(BMP string) ,
‘OCT’(Octet string) or ‘UTF’(UTF8 string), the last
part is the value. Note that this field may be
repeated.
Here is the layout and supported fields for the RENEW CertPlist. Because most
of the certificate information from the old certificate is reused for the new
certificates, very little new information can be specified in the RENEW
CertPlist. Like GENCERT, the CertPlist is a list of ordered triplets that consists
of name, length and data value. The field name is a fixed 12-character field,
case sensitive, left-aligned, and padded with blanks. The length field is a
binary four byte value, which qualifies the length of the data item. Note that
all data values are EBCDIC character data unless otherwise indicated. See
GENCERT for more information about the other individual fields
Table 145. CertPlist for GENRENEW and REQRENEW
Field name Max length Description
DiagInfo 80 bytes (exactly) Diagnostic information area. Must be first field in
the CertPlist. For certificate generation warnings
and errors, RACF will update this field with
diagnostic information. The length will be
updated as well. Required field.
PassPhrase 32 bytes Value to be used for challenge/response when
retrieving the certificate through function
EXPORT. When renewing a certificate whose key
pair was generated by PKI Services, the
PassPhrase from the original certificate will be
used if this field is not specified. Optional.
NotAfter 4 bytes Number of days from today's date that the
certificate expires. Range 1-9999. Validity checked
by RACF. Optional. Default is 365. The start date
of the validity period is set from the original
certificate's start of validity.
NotifyEmail 64 bytes Email address for notification purposes. When
renewing a certificate whose key pair was
generated by PKI Services, the specified value
must not exceed 32 characters. If this field is not
specified, the notification email address of the
original certificate will be used. Optional.
CertPolicies 32 bytes Blank separated array of non-repeating policy
numbers. Range 1 - 99, for the CertificatePolicies
extension. These correspond to the policy numbers
defined during PKI Services configuration. Each
value must be one or two digits with no leading
zeros. Optional, no default.
AuthInfoAcc 255 bytes A comma separated two part string specifying
information used to create the
AuthorityInfoAccess extension. The two part
string identifies the accessMethod and
accessLocation. The accessMethod is one of 'OCSP'
| 'IdentrusOCSP' (not case sensitive, no quotes).
The accessLocation is a URI in the form
URI=access-url or URL=access-url. Optional, no
default. Note this field may be repeated.
Critical 32 bytes Name of a certificate extension to be marked
critical. One of 'CertificatePolicies' | 'CertPolicies'
(not case sensitive, no quotes). Optional.
Note: All data values are EBCDIC character data unless otherwise indicated.
See GENCERT for more information about the other individual fields.
Table 149. CertPlist for PREREGISTER
Field name Max length Description
DiagInfo 80 bytes EyeCatcher to identify this request in virtual
(exactly) storage for diagnostic reasons. For certificate
generation warnings and errors RACF will
update this field with diagnostic information.
The length will be updated as well. Required
field. Must be first field in the CertPlist.
ClientName 64 bytes Name of the person or device that is being
preregistered. Must match either the
CommonName or the UnstructName when the
certificate request is received. Required field.
PassPhrase 32 bytes Challenge/response value to be used for
authenticating when the certificate request is
received. Optional. No default.
CA_domain
The name of an optional 9-byte input area that consists of a 1-byte length field
followed by up to 8 characters from the following character set: the
alphanumerics (a-z, A-Z, 0-9) and the hyphen ('-'). In addition, the leftmost
character must not be a digit or the hyphen. The value is the not case-sensitive
domain name of the PKI Services certificate authority instance to be invoked. If
Number_parameters is less than 6, CA_domain is null, or the length byte is 0,
then the default instance of PKI Services will be invoked. This field is ignored
for SAF requests.
Table 153. Reason and return code parameters specific to function GENCERT and
REQCERT
SAF return RACF return RACF reason
code code code Explanation
4 4 0 Successful completion. However,
notification of the TID through email is
unsuccessful.
8 8 40 CertPlist has an incorrect length
8 8 44 CertPlist DiagInfo field missing or has an
incorrect length
Table 153. Reason and return code parameters specific to function GENCERT and
REQCERT (continued)
SAF return RACF return RACF reason
code code code Explanation
8 8 48 Incorrect field name specified in CertPlist.
The field name is either unknown or not
supported by this certificate generation
provider
8 8 52 Incorrect field value specified in CertPlist
8 8 56 Required field is missing from the CertPlist
8 8 60 Certificate generation provider input or
environment error
8 8 64 PKCS#11 Token Service encountered an
error.
8 8 68 Notification form is not set up correctly in
the case of key generation.
8 8 76 Conflicting field names specified in
CertPlist.
Table 154. Reason and return code parameters specific to function EXPORT
SAF RACF RACF
return return reason
code rode code Explanation
0 0 0 Successful completion. If the “PKICACERT” CertId
was specified, then the returned certificate package
contains just the X.509 CA certificate
0 0 1 Successful completion. The “PKICACERT” CertId was
specified. The returned certificate package is the
RA/CA PKCS #7 certificate chain
0 0 2 Successful completion. If serial number was specified
in CertId, the returned certificate package contains the
PKCS12 package.
8 8 40 CertAnchor area missing
8 8 44 CertAnchor area too small
8 8 48 Incorrect CertID (transaction ID or serial number)
specified
8 8 52 Incorrect PassPhrase specified
8 8 56 Request is still pending approval or has yet to be
issued
8 8 60 Request has been rejected by the administrator
8 8 64 PKCS#11 Token Service has encountered an error.
8 8 68 Incorrect KeyId specified or private key object in
TKDS not found.
8 8 72 “PKICACERT” CertId specified, but SCEP is disabled
Table 155. Reason and return code parameters specific to function QUERYREQS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Results list area missing.
Table 156. Reason and return code parameters specific to function REQDETAILS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Summary list or CertPlist area missing.
8 8 44 Summary list or CertPlist area too small.
8 8 48 Incorrect CertId specified.
8 8 52 Success, however name fields not
returned in CertPlist.
8 8 64 Not authorized to display the details of
the request under a specific template.
Table 157. Reason and return code parameters specific to function MODIFYREQS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 CertPlist has an incorrect length.
8 8 44 CertPlist DiagInfo field missing or has
an incorrect length.
8 8 48 Incorrect field name specified in
CertPlist.
8 8 52 Incorrect field value specified in
CertPlist.
8 8 56 Required field missing from CertPlist.
8 8 60 Certificate generation input or
environment error.
8 8 64 CertIds has an incorrect length or value.
8 8 68 Incorrect Action specified.
8 8 72 One or more requests could not be
modified because of a state or content
change. CertIds contains the certificate
request Ids that could not be modified.
ErrList contains the corresponding error
description.
8 8 76 One or more requests could not be
approved again because the request(s)
has/have been approved by the same
administrator. CertIds contains the
certificate request Ids that could not be
modified. ErrList contains the
corresponding error description.
Table 158. Reason and return code parameters specific to function QUERYCERTS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Results list area missing.
8 8 44 Results list area too small.
8 8 48 Incorrect SerialNum specified.
8 8 56 Incorrect status criteria specified.
8 8 60 No certificates satisfy the input criteria.
Table 159. Reason and return code parameters specific to function CERTDETAILS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Summary list or CertPlist area missing.
8 8 44 Summary list or CertPlist area too small.
8 8 48 Incorrect SerialNum specified.
8 8 64 Not authorized to display the details of
the certificate under a specific template.
Table 160. Reason and return code parameters specific to function MODIFYCERTS
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Incorrect Reason specified.
8 8 52 Incorrect field value specified in
RequestorEmail.
8 8 64 SerialNums has an incorrect length or
value.
8 8 68 Incorrect Action specified.
8 8 72 One or more certificates cannot be set up
for automatic renewal. SerialNums
contains the certificate serial numbers
that could not be set up for automatic
renewal. ErrList contains the
corresponding error description.
Table 161. Reason and return code parameters specific to function VERIFY
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Summary list or CertPlist area missing.
8 8 44 Summary list or CertPlist area too small.
8 8 64 Incorrect certificate specified.
Table 162. Reason and return code parameters specific to function REVOKE
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Incorrect Reason specified.
8 8 64 SerialNum has an incorrect length or
value.
8 8 72 The certificate could not be revoked
because of a state change.
Table 163. Reason and return code parameters specific to functions GENRENEW and
REQRENEW
SAF return RACF return RACF reason Explanation
code code code
4 4 0 Successful completion. But notification of
the TID through email was unsuccessful.
8 8 40 CertPlist has an incorrect length.
8 8 44 CertPlist DiagInfo field missing or has an
incorrect length.
8 8 48 Incorrect field name specified in CertPlist.
The field name is either unknown or not
supported by this certificate generation
provider.
8 8 52 Incorrect field value specified in CertPlist.
8 8 56 Required field missing from CertPlist.
8 8 60 Certificate generation input or
environment error.
8 8 64 SerialNum has an incorrect length or
value.
8 8 68 Notification form is not set up correctly
for key generation.
8 8 72 The certificate could not be renewed
because of a state change.
8 8 76 Conflicting field names specified in
CertPlist.
8 8 80 The certificate could not be renewed
because the requester's email has changed.
Table 164. Reason and return code parameters specific to function RESPOND
SAF return RACF return RACF reason
code code code Explanation
8 8 40 Response area missing.
8 8 44 Response area too small.
8 8 64 Incorrect request specified.
8 8 72 Responder disabled.
Table 165. Reason and return code parameters specific to function SCEPREQ
SAF return RACF return RACF reason
code code code Explanation
8 8 40 Response area missing.
8 8 44 Response area too small.
8 8 64 Incorrect request specified.
8 8 72 SCEP disabled.
Table 166. Reason and return code parameters specific to function PREREGISTER
SAF return RACF return RACF reason
code code code Explanation
8 8 40 CertPlist has an incorrect length
8 8 44 CertPlist DiagInfo field missing or has an
incorrect length
8 8 48 Incorrect field name specified in CertPlist.
The field name is either unknown or not
supported by this certificate generation
provider
8 8 52 Incorrect field value specified in CertPlist
8 8 56 Required field missing from CertPlist
8 8 60 Certificate generation provider input or
environment error
8 8 72 Client already preregistered
8 8 76 Not authorized to preregister a client
under a specific template.
Table 167. Reason and return code parameters specific to function QRECOVER
SAF return RACF return RACF reason Explanation
code code code
8 8 40 Results list area missing.
8 8 44 Results list area too small.
8 8 48 Incorrect requester’s email address
specified.
8 8 52 Incorrect pass phrase specified.
8 8 56 Notify form is not set up correctly.
8 8 60 No certificates satisfy the input criteria.
8 8 64 Notify email cannot be sent.
Usage notes
1. This service is intended for use by z/OS application servers, to
programmatically request the fulfillment of an X.509 V.3 certificate request.
2. An audit record will be created as a result of invoking this service which will
indicate the success or failure of the attempt.
3. For GENCERT, the certificate generation provider is designated by the first
four characters of the CertPlist SignWith value, SAF: for SAF requests, PKI: for
PKI Services requests. For EXPORT, the caller designates the certificate
generation provider indirectly by providing the Certificate ID returned by the
provider. For all other functions, PKI Services is used exclusively. There is no
SAF equivalent for these functions.
4. TheCertPlist for the PREREGISTER, GENCERT REQCERT, REQDETAILS,
MODIFYREQS, VERIFY, REQRENEW, GENRENEW, and CERTDETAILS
functions consists of triplets which consist of field name, field length, and
data. The field name is a fixed field, 12 characters in length, and the field
name must be left-aligned, and padded with blanks. The data length is also a
fixed width field of 4 bytes which contain an integer which represents the
length of the following field data.
5. The R_PKIServ service requires the caller to preallocate the 57-byte storage
area that will hold the certificate ID returned on a successful GENCERT,
REQRENEW, GENRENEW, or REQCERT. When successful, RACF will update
the first byte with the actual length of the CertID. The entire 57 areas must be
provided for EXPORT even if the actual CertId is smaller than that.
6. The R_PKIServ service requires the caller to preallocate the storage that will
hold the certificate being extracted through the EXPORT function code. On
successful certificate retrieval, RACF will update the CertAnchorLen field with
the actual length of the certificate. If the storage area is too small to hold the
certificate, then RACF will fail the request and update the CertAnchorLen
field in the EXPORT request-specific parameter list as supplied by the caller of
this service. The caller is responsible for releasing and obtaining a new area of
virtual storage that is the size as specified by RACF, and retrying the EXPORT
operation.
IDs or Serial Numbers that could not be updated. The length field will also be
updated to reflect the size of the data being returned.
13. For GENCERT and REQCERT PKI Services requests, the special user IDs that
start with lowercase 'irr' may not be specified for the CertPlist field UserId.
14. For PREREGISTER, GENCERT, REQCERT, GENRENEW, REQRENEW, and
MODIFYREQS certificate generation errors (reason code 60) RACF will update
the DiagInfo field with a product-specific diagnostic message. For SAF
requests, the message will have the following format: error-description
(message-ID), where message-ID is the RACDCERT error message ID that is
closely related to this error:
Additionally, for successful certificate generation (reason code 0), RACF may
also update the DiagInfo field with one of the following informational
diagnostic messages:
RACF may also issue its own diagnostic messages when acting as an RA for PKI Services.
For further information see z/OS Security Server RACF Command Language Reference and z/OS Security Server RACF
Messages and Codes. It is expected that other security products that may be installed in place of RACF have their own
product-specific diagnostic data.
v Jurisdiction Country
v Street
v Locality
v StateProv
v PostalCode
v Country
Except as noted in the following, only those portions of the name specified in
the CertPlist will appear in the certificate. For GENCERT and REQCERT, if no
name fields are specified in the CertPlist, the name is taken directly from the
PublicKey field. For SCEPREQ, the name is always taken from the initial
PKCS #10 request.
16. Different certificate generation providers may produce certificates with
different extension values. To determine what certificate extensions will be
created by a given provider, see the provider's supporting documentation,
z/OS Security Server RACF Security Administrator's Guide, and z/OS Security
Server RACF Command Language Reference, or z/OS Cryptographic Services PKI
Services Guide and Reference.
17. For GENCERT and REQCERT, if CommonName is specified with a null value
(length 0), RACF will use the PGMRNAME field from the RACF user profile
as determined by the UserID field for this request. If PGMRNAME is null, the
common name will be of the form of RACF User ID:<user's-racf-identity>, for
example RACF UserID:JOHNDOE. The above formula is also used for SAF
requests if none of the subject's distinguished name fields are specified
(CommonName, Title, OrgUnit, Org, Locality, StateProv, or Country) and the
PublicKey field contains no information.
18. For PREREGISTER, GENCERT, REQCERT, GENRENEW, REQRENEW, and
MODIFYREQS, all CertPlist fields specified must have a non-zero length
except for CommonName, which may be null for GENCERT and REQCERT
only.
19. For PREREGISTER, GENCERT, REQCERT, GENRENEW, REQRENEW, and
MODIFYREQS, OrgUnit, HostIdMap, AuthInfoAcc, Critical, KeyUsage, and
ExtKeyUsage may be repeated, where applicable. For all other CertPlist fields
if multiple occurrences are found, the last one will be used.
20. For GENCERTand REQCERT, the PublicKey must be either a Netscape
Navigator key, a Microsoft Internet Explorer key, or a true PKCS #10 certificate
request.
21. For successful EXPORTs where the CertId is not "PKICACERT", the certificate
returned in the CertAnchor area is either a base64 encoded DER X509
certificate, a base64 encoded DER PKCS #7 certificate chain, or a DER PKCS
#12 certificate package. The base64 data is wrapped with the standard
"-----BEGIN CERTIFICATE-----" header and "-----END CERTIFICATE-----"
footer. For RACF requests, the returned certificate is always X.509. For PKI
Services requests, if the key was not generated by PKI Services, the returned
certificate will be packaged as a PKCS #7 certificate chain if at least one
hierarchy certificate can be located under the CERTAUTH category and either
subsequent access checking is not being performed or the access check user ID
has CONTROL authority to IRR.DIGTCERT.EXPORT in the FACILITY Class or
is RACF SPECIAL. Otherwise, an X.509 certificate is returned. If the key was
generated by PKI Services, the returned certificate will be packaged as a PKCS
#12 package with its issuer's certificate. The return code will indicate which
format is being returned.
a. Printable string:
v Country
v SerialNumber
v DNQualifier
v JurisdictionCountry
b. IA5 string (Basic Latin):
v DomainName
v Mail / Email
v NotifyEmail
v EmailAddr
v AltEmail
v AltDomain
v AltURI
v AuthInfoAcc
v HostIdMap
c. Basic Latin and Latin-1 supplement:
v CommonName
v Title
v OrgUnit
v Org
v Street
v Locality
v StateProv
v PostalCode
v UID
v UnstructName
v UnstructAddr
v EmailAddr
v BusinessCategory
v JurisdictionLocality
v JurisdictionStateProv
31. For MODIFYREQS that approves a request with modifications, any prior
approvals for the request specified in the CertIds parameter are nullified if
multiple approvers are required to approve the request. The number of
performed approvals for the request is reset to 1 and the request remains in
Pending Approval state.
Function
The R_proxyserv SAF callable service invokes the IBM Tivoli Directory Server for
z/OS to store or obtain data which resides in an LDAP directory. Invokers are not
required to be Language Environment-enabled.
Requirements
Authorization:
For function codes 1 and 2, any PSW key in supervisor or problem state.
For function code 3, supervisor state
Dispatchable unit mode:
Task of user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have a FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. Therefore, the last word in the parameter list must
have a 1 in the high-order (sign) bit.
RACF authorization
For callers not running in system key or supervisor state, for function codes 1 and
2, the use of R_proxyserv is authorized by the resource IRR.RPROXYSERV in the
FACILITY class. The application server must be running with a RACF user or
group that has at least READ authority to this resource. If the class is inactive, or
the resource is not defined, only servers running with a system key or in
supervisor state may use the R_proxyserv service. Function code 3 of R_proxyserv
requires the caller to be in supervisor state.
Format
CALL IRRSPY00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ParmALET,
Function_code,
LDAP_host,
Bind_DN,
Bind_PW,
Host_userID,
Base_DN,
Result_entries,
Function_parmlist_version,
Function_parmlist,
LDAP_error_string
)
Parameters
Work_area
The name of a 1024-byte work area for SAF. The work area must be in the
primary address space.
ALET
The name of a fullword containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
ParmALET
The name of a fullword which must be in the primary address space and
contains the ALET for the remaining parameters.
Function_code
The name of a halfword (2-byte) area containing the function code. The
function code has one of the following values:
Value Description
X'0001' Return the distinguished name (DN) of the user identified by
the input host user ID.
X'0002' Return the Policy Director Authorization Services attributes for
the specified base DN.
X'0003' Create an LDAP change log entry for a RACF profile update.
DATASET profiles are not supported.
LDAP_host
This is optional, see Usage Notes. The name of an area that consists of a 4-byte
length field followed by the string of EBCDIC characters that identify the URL
of the LDAP server that the IBM Tivoli Directory Server is to contact when
acting as a proxy for this request. The maximum length of this string is 1023
When the function code is X'0001', Return Distinguished Name (DN), the
function code specific result data (ResultAreaData) will be mapped as follows:
Function_parmlist_version
The name of a 4-byte input value which contains the version number for the
Function_parmlist input field. The contents of this field must be set to binary
zero.
Function_parmlist
The name of an area containing data specific to a given value of
Function_code. Not every function code will require a function-specific
parameter list. If there is no parameter list required for a given function code,
then this parameter is ignored. The specific mappings are provided in the
IRRPCOMP macro.
The function-specific parameter lists are formatted as listed. All parameters are
required unless otherwise noted.
Table 169. Parameter list for function code 3
Offset Length Type Name Description
0 0 Structure PRXY_F3_PLIST Function-specific plist for function 3
0 1 Unsigned PRXY_F3_OPTYPE Operation type:
X’00’ - Add
X’01’ - Delete
X’02’ - Modify
1 1 Bitstring PRXY_F3_FLAGS Request flags
1... .... PRXY_F3_PWUPD Reserved for use by the security product. Not for
application use. This bit should be set to zero by
applications using this interface.
.1.. .... PRXY_F3_PWUPD2 Reserved for use by the security product. Not for
application use. This bit should be set to zero by
applications using this interface.
..1. .... PRXY_F3_PWUPD3 Reserved for use by the security product. Not for
application use. This bit should be set to zero by
applications using this interface.
...1 1111 Reserved for future use. These bits must be set to 0.
2 8 Character PRXY_F3_CLASS RACF class name, padded to the right with blanks. The
DATASET class is not supported.
10 2 Unsigned PRXY_F3_PROFLEN Length of profile being changed. Must adhere to length
requirements for the class name in PRXY_F3_CLASS.
12 4 Address PRXY_F3_PROFNAME@ Address of profile name being added, altered, or deleted.
When PRXY_F3_CLASS is CONNECT, the profile name
takes the format of USER.GROUP.
16 8 Character PRXY_F3_INITIATOR The user ID who initiated the RACF profile change. If
this field contains binary zeros, then R_proxyserv will use
the identity of the caller.
LDAP_error_string
The name of an area that consists of a 4-byte length field followed by 256
characters. This field is completed when LDAP returns an error message. The
length will be updated with the actual length of the LDAP error string or zero.
This field is used for function code 3.
Parameter usage
Function Func LDAP_ Bind_ Bind_ Host_ Base_ Result Func Func LDAP_
tion host DN PW user DN _entri tion_ tion_ error_
Code ID es parm parm string
list list
_version
Return the base DN X'0001' In1 In1 In1 In N/A Out N/A N/A N/A
for the specified host
UID
Return the Policy X'0002' In1 In1 In1 N/A In Out N/A N/A N/A
Director attributes for
the specified base DN
Create an LDAP X'0003' N/A N/A N/A N/A N/A N/A In In Out
change log entry
Usage notes
1. This service is intended for use by z/OS application servers that are not
running in a Language Environment. It allows z/OS application servers to
perform limited LDAP queries that retrieve information from a directory
information tree (DIT). Note that Language Environment-enabled applications
can also use this service, if they choose to do so.
2. The R_proxyserv service requires an instance of the LDAP Server on each
physical z/OS instance (whether in a sysplex data sharing configuration or not)
and each of these LDAP Server instances must be configured to support PC call
and the extended operations backend. See z/OS IBM Tivoli Directory Server
Administration and Use for z/OS for information about configuring this support.
3. The parameter list for this callable service is intended to be variable length to
allow for future expansion. Therefore, the last word in the parameter list must
have a 1 in the high-order (sign) bit. If the last word in the parameter list does
not have a 1 in the high-order (sign) bit, the caller receives a parameter list
error. For function codes 1 and 2, the first parameter that can have the
high-order bit on, ending the parameter list, is the Result_entries parameter. For
function code 3, the first parameter that can have the high-order bit on, ending
the parameter list, is the LDAP_error_string parameter.
4. The LDAP_host, Bind_DN, and Bind_PW parameters are all optional. If any of
the three parameters are specified, all must be specified, or R_proxyserv will
return an error. If all three parameters are omitted, RACF attempts to
determine this information from the PROXY segment associated with the RACF
user identity of the invoker (that is, the server's address space level ACEE). If
the user profile PROXY segment is found, but any of the corresponding
segment values (LDAPHOST, BINDDN, or BINDPW) are not defined,
R_proxyserv will return an error. If the LDAP_host, Bind_DN, and Bind_PW
parameters are omitted and the PROXY segment is not defined for the
invoker's user identity, RACF will then look for the IRR.PROXY.DEFAULTS
profile in the FACILITY class. If this profile is not found or does not have a
PROXY segment or does not have values defined for LDAPHOST, BINDDN,
and BINDPW, R_proxyserv will return an error.
5. The format of the Result_entries output area differs, based on the function code
specified. Mappings are provided for each format (see Mappings for
Result_entries output area). Storage will be obtained in primary in the subpool
indicated in the Result_entries output area and it is the responsibility of the
invoker to release this storage.
Related services
None
Function
The R_ptrace service checks whether the calling process can ptrace the target
process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. R_ptrace checks whether the caller is a superuser, or whether the caller is the
owner of the target process. If the caller is the owner of the target process,
R_ptrace verifies that the target process is not running a SETUID or SETGID
program. If the caller is a superuser, R_ptrace does not verify that the target
precess is not running a SETUID or SETGID program.
2. If the caller is not superuser nor the process owner, an authorization check is
performed on the resource name in the UNIXPRIV class shown in Table 170. If
the authorization check is successful, the caller is treated as a superuser.
Table 170. UNIXPRIV class resource names used in R_ptrace
Audit function code Resource name Access required
N/A SUPERUSER.PROCESS.PTRACE READ
3. When the SECLABEL class is active, and the high order bit of the Target_PID is
on, R_ptrace checks if the caller's security label is equivalent to the target
process's security label, unless the ACEE indicates trusted or privileged
authority.
Format
CALL IRRSPT00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Target_process_UIDs,
ALET, Target_process_GIDs,
ALET, Target_PID
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Target_process_UIDs
The address of a 3-word area containing the real, effective, and saved z/OS
UNIX user identifiers (UIDs) (in that order) for the target process. IRRSPT00
uses the high-order bit of the Target_PID to indicate that this area is 5 words,
containing the real, effective, and saved z/OS UNIX user identifiers, and the
8-byte security label for the target process.
Target_process_GIDs
The address of a 3-word area containing the real, effective, and saved z/OS
UNIX group identifiers (GIDs) (in that order) for the target process.
Target_PID
The name of a fullword containing the PID of the target process. The high
order bit of the PID is used to indicate that the Target_process_UIDs field is a
five word rather than a three-word area.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. An audit record is optionally written, depending on the audit options in effect
for the system.
3. This service uses task-level support when z/OS UNIX has indicated in the
task's ACEE that this is a task-level process.
Related services
None
| Function
| The R_SecMgtOper service provides an interface to set security policy in the
| security database of the system, performing a function similar to that of the RACF
| TSO commands. Unlike the RACF commands, the inputs to R_SecMgtOper are
| designed to be consistent across all External Security Managers (ESM) running on
| z/OS. This provides an ESM-neutral security policy definition interface with
| common inputs for all ESMs which support R_SecMgtOper.
| The contents of the XML document are translated into RACF command text which
| is returned to the caller and optionally executed on the system. The resulting
| command text and optional command execution results are returned to the caller
| in another XML document. The existing R_ADMIN (IRRSEQ00) callable service is
| used to both generate the command text, and optionally execute the RACF
| command.
| Requirements
| Authorization:
| Any PSW key in supervisor or problem state.
| Linkage conventions
| Callers in 31-bit addressing mode should link-edit the IRRSMO00 stub module
| with their code, and use the IRRPCOMP mapping macro. Callers in 64-bit
| addressing mode should link-edit the IRRSMO64 stub module with their code, and
| use the IRRPCOMY mapping macro.
| RACF Authorization
| There are no authorization requirements, regardless of the caller's state, to use this
| service, with the following exceptions:
| 1. If the RunAs_userID parameter is specified, the caller must have UPDATE
| access to resource RunAs_userID.IRRSMO00 in the SURROGAT class.
| RunAs_userID is the value specified for the RunAs_userID parameter. All users
| who specify the RunAs_userID parameter are subject to this authorization
| check. If the authorization check fails, IRRSMO00 fails.
| 2. A non-zero ACEE parameter may only be specified by authorized callers.
| IRRSMO00 fails if an unauthorized caller specifies anything other than a zero
| value.
| 3. All updates performed on the security database (when the x'00000001'
| EXECUTE option is specified) run under the authority of the caller or the
| specified ACEE or RunAs_userID. This user must have authority to perform
| those security database updates. The required authority required varies
| depending on the type of updates being executed. An attempt is made to
| execute all of the security definitions, and each one will succeed or fail
| depending on the authorizations imbuing the user.
| 4. Unauthorized callers who specify the PRECHECK option code require READ
| access to resource IRR.IRRSMO00.PRECHECK in the XFACILIT class. The
| request will fail if the caller lacks this access.
| Format
| CALL IRRSMO00 (Work_area,
| ignored, SAF_return_code,
| ignored, RACF_return_code,
| ignored, RACF_reason_code,
| num_parms,
| Function_code,
| Options,
| Request_len,
| Request,
| Request_Handle,
| RunAs_userID,
| ACEE_ptr,
| result_len,
| result_area
| )
| Parameters
| Work_area
| The name of a 1024-byte work area for SAF and RACF use. The work area
| must be in the primary address space.
| Ignored
| The name of a fullword containing the value 0. The value of 0 is enforced.
| SAF_Return_Code
| The name of a fullword in which the SAF router returns the SAF return code.
| RACF_Return_Code
| The name of a fullword in which the service routine stores the return code.
| RACF_Reason_Code
| The name of a fullword in which the service routine stores the reason code.
| Num_Parms
| Specifies the name of a 4 byte area which contains the total number of
| parameters in the parameter list. The contents of this field must be set to
| binary seventeen.
| Function_code
| The name of a 4-byte area containing the Function code. The function code has
| one of the following values:
| X'00000001'
| This function will parse the input and generate commands based on
| the security definitions specified in the XML. On systems running
| RACF, RACF commands will be generated and optionally executed.
| The generated commands, and the results of their optional execution,
| will be returned in the result_area in XML form.
| Options
| The name of a 4-byte area containing the Option values. The individual bits in
| the Option activate the options.
| X'00000001' – EXECUTE.
| If this bit is ON, the security definitions specified in the Request XML
| are executed, resulting in updates being made to the RACF database.
| The executed commands, along with their results are returned in the
| result_area. If this bit is OFF, the commands are generated and
| returned without being executed. This allows the caller to examine the
| Usage notes
| If return codes indicate that the result buffer is too small (RACFRC=4000), it means
| that one or more calls to R_SecMgtOper are required. The result buffer contains
| partial results. These partial results should be copied to local storage before calling
| R_SecMgtOper again. The results of subsequent calls to R_SecMgtOper must be
| appended to the results from the previous call(s) until return codes indicate
| something other than a buffer-too-small condition
| 1. Only the result and result_len parameters may be changed when making
| subsequent calls to R_SecMgtOper in a buffer-too-small situation. Be sure that
| the result buffer is at least the size indicated by the reason code in the prior call
| to R_SecMgtOper which resulted in the buffer-too-small situation. If parameters
| other than result and result_len are changed between calls to R_SecMgtOper in
| a buffer-too-small situation, the results are unpredicatable.
| 2. The request_handle may contain a token stored by R_SecMgtOper, and must
| not be changed. The other parameters must have the same values as they did
| on the first call to R_SecMgtOper; these values were not changed by
| R_SecMgtOper, so the caller does not need to reset them.
| 3. It is recommended that a large enough result buffer be allocated to contain all
| of the results in a single call to R_SecMgtOper. It is very inefficient to process
| the input request over multiple calls. Making the result buffer at least the same
| size as the request will ensure a low probability of the results being too small.
| 4. In certain cases, it might be possible that no data was returned if the result
| buffer was too small to contain even a minimal response. This situation is no
| different than a partial results case, except there is no data to copy. Be sure the
| result buffer is at least the size reflected in the reason code and call
| R_SecMgtOper again
| Note: It is possible for IRRSMO00 to process a part of the input document, and
| then find there is not enough space in the result buffer to return the results. In this
| situation, the results for that portion of the input are lost, and that part of the
| request is repeated on the next call to IRRSMO00. This may result in unexpected
| output, such as a 'not found' error if the work in question was a delete operation.
| This can only happen If the result is too small.
| If the Request contains any EBCDIC linefeed characters ('15'x), they are suppressed.
| They are not replaced by spaces, they are simply omitted from the Request while
| being processed.
| All leading and trailing spaces in field data in the Request are removed.
| All EBCDIC tab characters ('05'x) in the Request are converted to spaces.
| IRRSMO00 can only process XML documents which are in the IBM-1047 code
| page, regardless of the encoding= attribute in the <?xml...?> declaration. There is
| no support for other code pages.
| Javaâ„¢ code can use a Java interface that uses a Java Native Interface (JNI) and
| calls the r_SecMgtOper callable service. For information about this interface, see
| the JavaDoc shipped in the IRRSAFDoc.jar file, which is installed into the directory
| /usr/include/java_classes. Download the jar file to a workstation, un-jar it, and
| read it with a Web browser.
| Related services
| None
| Reference documentation
| The following information describes how to use the various functions of
| R_SecMgtOper:
| Request format
| The request parameter points to a well-formed XML document. The document can
| specify as many different security definitions as are desired in a single request.
| There can be multiple users, groups, permissions, resources, etc. defined in the
| same request document which are all processed in a single call to the service.
| Example:
| <?xml version="1.0" encoding="IBM-1047" ?>
| <securityrequest xmlns="http://www.ibm.com/systems/zos/saf">
| <user name="user1" operation="set" requestid="user1">
| <omvs>
| <home>/u/user1</home>
| </omvs>
| </user>
| </securityrequest>
| Response format
| The response to the example in “Request format” on page 362 is:
| <?xml version="1.0" encoding="IBM-1047"?>
| <securityresult xmlns="http://www.ibm.com/systems/zos/saf/IRRSMO00Result1">
| <user name="USER1" operation="set" requestid="user1">
| <command>
| <safreturncode>0</safreturncode>
| <returncode>0</returncode>
| <reasoncode>0</reasoncode>
| <image>ADDUSER USER1</image>
| <message>ICH01024I User USER1 is defined as PROTECTED.</message>
| </command>
| <command>
| <safreturncode>0</safreturncode>
| <returncode>0</returncode>
| <reasoncode>0</reasoncode>
| <image>ALTUSER USER1 OMVS (HOME ('/u/user1'))</image>
| </command>
| </user>
| <returncode>0</returncode>
| <reasoncode>0</reasoncode>
| </securityresult
| Certain invalid data may cause errors in the r_admin service which is used to
| generate the command images and execute them. If an R_admin parameter list
| error is encountered, the r_admin parameter list is returned in the XML so the
| problem can be diagnosed. Presence of an r_admin parameter list may indicate an
| internal error, or bad input data in the XML request. Other ESMs may include
| other forms of diagnostic output.
| <?xml version=’1.0’ encoding="IBM-1047"?>
| <securityresult xmlns="http://www.ibm.com/systems/zos/saf/IRRSMO00Result1">
| <securitydefinition name="name" ... copy of all attributes from input>
| <command>
| <safreturncode>8</safreturncode>
| <returncode>8</returncode>
| <reasoncode>16</reasoncode>
| <radminParmList>00000000 04E3C5E2 E3404040 |.TESTbb |</radminParmList>
| <radminParmList>00000008 40400024 0002C2C1 |bb....BA|</radminParmList>
| <radminParmList>00000010 E2C54040 4040E800 |SEbbbbY.|</radminParmList>
| <radminParmList>00000018 00C2C1E2 C5404040 |.BASEbb |</radminParmList>
| <radminParmList>Offset to parm list error 0x00000019</radminParmList>
| </command>
| </securitydefinition>
| <returncode>rc</returncode>
| <reasoncode>rsn</reasoncode>
| </securityresult>
| If the XML is well formed, but contains invalid segment, field, or other
| information, the <command> is replaced by <error>. <errorfunction> refers to the
| current operation in progress and is meant for use by IBM support, if necessary.
| <errorreason> is the IRRSMO00 reason code corresponding to return code 2000.
| <textinerror> refers to the text in the request which was found to be in error. In
| certain cases, the <textinerror> may refer to the nearest XML element encountered,
| rather than the actual text in error.
| <?xml version=’1.0’ encoding="IBM-1047"?>
| <securityresult xmlns="http://www.ibm.com/systems/zos/saf/IRRSMO00Result1">
| <securitydefinitionname="name" ... copy ofall attributes from input>
| <error>
| <errorfunction>fn</errorfunction>
| <errorcode>rc</errorcode>
| <errorreason>rsn</errorreason>
| <erroroffset>offset into source XML of approximate
| location of error</erroroffset>
| <errormessage>Explanation of error</errormessage>
| <textinerror>bad text</textinerror>
| </error>
| </securitydefinition>
| <returncode>rc</returncode>
| <reasoncode>rsn</reasoncode>
| </securityresult>
| If the XML is not well formed, the <error> tag is returned, but it is not within a
| <securitydefinition> tag. <errorcode> and <errorreason> are return and reason
| codes from z/OS XML services. The numeric value of <errorcode> is 1000 greater
| than the actual z/OS XML return code. <errorcode>1012</errocode> indicates an
| XML return code of 12. The<erroroffset> is an approximate offset into the request
| document where the error occurred. In some cases, this offset may be at the
| beginning or end of an XML tag which contains a problem within the tag, as
| opposed to the exact location of the error. There may also be an <errormessage>
| with text explaining the problem. <textinerror>contains the text in the request
| document near the<errorOffset>. <textinerror> may be the exact failing text, or an
| element or attribute name associated with the failing text.
| <?xml version=’1.0’ encoding="IBM-1047"?>
| <securityresult xmlns="http://www.ibm.com/systems/zos/saf/IRRSMO00Result1">
| <error>
| <errorfunction>fn</errorfunction>
| <errorcode>rc</errorcode>
| <errorreason>rsn</errorreason>
| <erroroffset>offset into source XML of approximate
| location of error</erroroffset>
| <errormessage>Explanation of error</errormessage>
| <textinerror>bad text</textinerror>
| </error>
| <returncode>rc</returncode>
| <reasoncode>rsn</reasoncode>
| </securityresult>
| Namespaces
| Although R_SecMgtOper provides an ESM neutral interface used to define security
| policy, RACF has its own RACF-specific data which is not common across all
| ESMs. Presumeably, other ESMs have their own ESM-specific data.
| For the purpose of this discussion, there are three types of data to consider:
| 1. SAF data. This is data which is common across all ESMs, including RACF. This
| is common data, such as userid, general resource class names and other data.
| RACF processes all SAF data. All SAF compliant ESMs should processes all of
| this data.
| 2. RACF specific data is data which does not necessarily apply to other ESMs. An
| example of this data is the RACF 'installation data' field, or everything in the
| SETROPTS command. ESMs which are not RACF should ignore all of this data.
| 3. non-RACF, ESM specific data. Any ESM may have data which is specific only
| to itself and no other ESMs. RACF will ignore this data. Other ESMs may do as
| they see fit with it.
| XML namespaces are used to denote which parts of the request are for SAF, RACF
| and other ESMs. XML namespaces have 2 parts, a prefix and a URI. The URIs are
| In this example, the <securityrequest> defines 3 namespaces, saf, racf and esm1. In
| the short example above, everything is in the saf namesapce. The next example
| contains racf specific information, and information specific to ESM1.
| <?xml version="1.0" encoding="IBM-1047" ?>
| <securityrequest xmlns:saf= "http://www.ibm.com/systems/zos/saf"
| xmlns:racf="http://www.ibm.com/systems/zos/racf"
| xmlns:esm1="http://www.esm.com/esm1”>
| <saf:user name="user1" operation="set" requestid="user1">
| <saf:base>
| <racf:data>Data for RACF</racf:data>
| <esm1:type>typeA</esm1:type>
| </saf:base>
| <saf:omvs>
| <saf:home>/u/user1</saf:home>
| </saf:omvs>
| </saf:user>
| </securityrequest>
| When processing this example, RACF disregards the <esm1:type> field. ESM1
| should disregard the <racf:data> field.
| The prefixes saf:, racf: and esm1: are arbitrary and can be anything, as long as they
| are defined in the XML as shown above.
| All security definitions, segments, fields and even XML attributes can be qualified
| by namespace. Non-RACF ESMs can define any security definitions, segments or
| fields as desired. These will all be ignored by RACF as long as they are denoted by
| namespaces other than saf or racf.
| Note: Everything with namespaces other than the SAF or RACF namespaces is
| skipped by RACF, even definitions which RACF is capable of processing.
| For example:
| <saf:user name=”user1”.../>
| <racf:user name=”racfu1” ../>
| <esm1:user name=”esm1” ../>
| <racf:systemsettings ../>
| Despite the fact that both RACF and ESM1 are able to process users, RACF would
| process only the first 2 users, while ESM1 should process only the first and third
| users. RACF will also perform a systemsettings operation after processing the
| users. When writing XML intended to be processed on multiple systems with
| different ESMs, use the SAF namespace for as much as possible, except for
| definitions which are specifically directed at a certain ESM.
| Request version
| The <securityrequest> root element of the XML document accepts an optional
| version=”xx” attribute. version=”1” is the only allowable specification of the
| version attribute. If the version attribute is omitted, its value is assumed to be 1.
| Security definition
| Security definitions are set by specifiying them in the XML, one at a time inside of
| the root <securityrequest> element.
| Note: All xml <element> names and attribute= names must be composed of
| lowercase letters or numbers. Data values can be any case desired. Exceptions
| documented below.
| Some of the parameters for a security definition are contained as attributes in the
| security definition XML element. Other parameters are contained inside the
| security definition in their own XML elements. If a parameter is required in order
| to uniquely identify a security definition, it is usually specified as an attribute,
| otherwise it is specified in the segment and field data.
| set
| Define the user id and set all specific data contained within the
| <user..>..</user> tags.
| del
| Delete the user id from the system
| requestid
| An optional label which identifies the security definition. This is used so a
| caller can more easily locate the results of this particular security definition in
| the result.
| run
| Default=yes. If set to 'no', the security definition is skipped.
| override
| Default=”yes”. Works in conjunction with the '00000002'x – PRECHECK option.
| Ignored if operation is not “set”.
| v If the PRECHECK option is set, an attempt is made to locate the user in the
| RACF database.
| – If the user is found, processing depends on the value of the override
| attribute:
| yes
| An alter command is generated to update the user id with the data
| contained in the XML.
| no The user id is not updated at all
| force
| An add command is generated, followed by an alter command to
| update the user id with the data contained in the XML.
| – If the user id is not found, an add command is generated, followed by an
| alter command to update the user id with the data contained in the XML.
| v If the PRECHECK option is not set, an add command is generated, followed
| by an alter command to update the user id with the data contained in the
| XML.
| Specification of segment and field information: Data for the user being defined
| is organized as segments and fields within each definition.
| The data for each field is specified as chardata in the field element.
| <namespace:fieldname ..>data value</namespace:fieldname>
| Allowable data for each field is documented in the RACF Command Language
| Reference, for the command field as indicated in the 'keyword reference' column in
| the 'reference documentation tables'. The maximum amount of data which can be
| specified is 4096.
| Fields indicated as (boolean) in the table are set using the operation="set|del"
| attribute.
| List fields may have their data specified as a space deliminated list, or as a series
| of values using the <saf:value> XML tag.
| <namespace:listfield>value1 value2 value3<namespace:listfield>
| OR
| <namespace:listfield>
| <saf:value>value1</saf:value>
| <saf:value>value2</saf:value>
| <saf:value>value3</saf:value>
| </namespace:listfield>
| Do not specify the individual elements of a list field on multiple lines without
| using the <saf:value> tag to seperate them. The following are incorrect
| specifications for a list field.
| <namespace:listfield>
| value1
| value2 *** WRONG! DO NOT DO THIS!
| value3
| </namespace:listfield>
| v operation – Action to apply to definition. Value must be all lowercase. One of:
| – set → Define the group id and set all specific data contained within the
| <group..>..</group> tags. .
| – del → Delete the group from the system
| v requestid – An optional label which identifies the security definition. This is
| used so a caller can more easily locate the results of this particular security
| definition in the result.
| v run – Default=yes. If set to 'no', the security definition is skipped.
| v override – Default=”yes”. Works in conjunction with the '00000002'x –
| PRECHECK option. Ignored if operation is not “set”.
| – If the PRECHECK option is set, an attempt is made to locate the group in the
| RACF database.
| - If the group is found, processing depends on the value of the override
| attribute:
| v yes – An alter command is generated to update the group with the data
| contained in the XML.
| v no – The group is not updated at all
| v force - An add command is generated, followed by an alter command to
| update the group with the data contained in the XML.
| - If the group is not found, an add command is generated, followed by an
| alter command to update the group with the data contained in the XML.
| – If the PRECHECK option is not set, an add command is generated, followed
| by an alter command to update the group with the data contained in the
| XML.
| Segments and fields are specified as documented for a <user>. The segment and
| field names can be found in the “Group administration” on page 436 in
| Appendix B, “Reference documentation tables,” on page 425.
| Definition for a dataset: Use this element to define or delete a dataset profile.
| Segments and fields are specified as documented for a <user>. The segment and
| field names can be found in the “Data set administration” on page 448 in
| Appendix B, “Reference documentation tables,” on page 425.
| Definition for a general resource: Use this element to define or delete a general
| resource.
| Segments and fields are specified as documented for a <user>. The segment and
| field names can be found in the “General resource administration” on page 439 in
| Appendix B, “Reference documentation tables,” on page 425.
| Definition for system settings: Use this element to perform RACF setropts
| operations.
| Note that there are no <systemsettings> fields defined to the saf namespace. All
| <systemsettings> are esm-specific, other than the <systemsettings> definition itself.
| Definition for a permission: Use this element to perform a RACF permit operation.
| The generic and volume values are specified as attributes in the <permission>
| element, and not as fields in the XML. To delete a permission, specify
| operation=”del”. Do not specify the delete field in the XML.
| Note: The user or group id being granted permission is specified as a field within
| the permission element, and is not specified as an attribute.
| Definition for a group connection: Use this element to perform a connect or remove
| operation.
| The following special security definition types are translated to RACF general
| resources when processed on a RACF system. Other ESMs may support the same
| functionality, but may process them differently than RACF. Therefore, these
| definitions are defined in a platform neutral fashion. All of the following
| definitions and their fields exist only in the saf namespace. Note that equivalent
| resource definitions can be created in RACF using <resource ...> definitions if
| desired, however such definitions may not be compatible with other ESMs.
| Started task: Associates a userid, group and some options to a started task. RACF
| defines a resource in the STARTED class with data in the STDATA segment.
| <namespace:startedtask name=”name” operation=”set|del” requestid=”reqid"
| run=”yes|no” override="yes|no|force">
| <namespace:userid>Started task user id</namespace:userid>
| <namespace:group>Started task group id</namespace:group>
| <namespace:privileged operation=”set|del”/>
| <namespace:trace operation=”set|del”/>
| <namespace:trusted operation=”set|del”/>
| </namespace:startedtask>
| User, group, privileged, trace and trusted all conform to data as specified in the
| STDATA segment of a RACF general resource profile as described in the “General
| resource administration” on page 439 in Appendix B, “Reference documentation
| tables,” on page 425.
| Custom security database field: RACF defines a new profile in the CFIELD
| general resource class with data in the CFDEF segment.
| <namespace:customfield name=”name” type=”user|group” operation=”set|del”
| requestid=”reqid" run=”yes|no” override="yes|no|force">
| <namespace:type>char | flag | hex | num</namespace:type>
| <namespace:first>alpha | alphanum | any | nonatabc | nonatnum | numeric</namespace:first>
| <namespace:other>alpha | alphanum | any | nonatabc | nonatnum | numeric</namespace:other>
| <namespace:help>help-text</namespace:help>
| <namespace:list>list heading text</namespace:list>
| <namespace:mixed >yes|no</namespace:mixed>
| <namespace:minval>minimum numeric value</namespace:minval>
| <namespace:maxval>maximum numeric value</namespace:maxval>
| <namespace:maxlen>Maximum field value length</namespace:maxlen>
| </namespace:customfield>
| v name – Name of new field.
| v type – Type of security field to define. RACF supports definition of custom
| fields in user and group profiles. Other ESMs may support additional data
| types. Use a namespace other than the SAF or RACF namespaces when defining
| custom fields for data types not supported by RACF.
| v operation – Action to apply to definition. One of:
| – set → Define the custom field and set all specific data contained within the
| request.
| – del → Delete the custom field from the system
| Type, first, other, help, list, mixed, minval, maxval, maxlen correspond to the
| cfdtype, cffirst, cfother, cfhelp, cflist, cfmixed, cfmnval, cfmxval, cfmaxlen fields in
| the CFDEF segment respectively as described in the “General resource
| administration” on page 439 in Appendix B, “Reference documentation tables,” on
| page 425. Once all custom fields are defined to RACF, they must be activated using
| the IRRDPI00 command. There is no way to perform this activation using
| IRRSMO00.
| Custom general resource class: RACF defines a new resource in the CDT class
| with data in the CDTINFO segment.
| <namespace:customclass name=”name” operation=”set|del” requestid=”reqid" run=”yes|no”
| override="yes|no|force">
| <namespace:case>upper | asis</namespace:case>
| <namespace:defaultrc>0 |4 | 8</namespace:defaultrc>
| <namespace:first>alpha | numeric | national | special</namespace:first>
| <namespace:keyqualifiers> Number of key qualifiers </namespace:keyqualifiers>
| <namespace:macprocessing>normal | reverse | equal </namespace:macprocessing>
| <namespace:maxlength>maximum length </namespace:maxlength>
| <namespace:maxlenx>maximum length </namespace:maxlenx>
| <namespace:other> alpha | numeric | national | special </namespace:other>
| <namespace:posit> posit number </namespace:posit>
| <namespace:profilesallowed operation=”set|del”>yes|no </namespace:profilesallowed>
| <namespace:seclabelrequired operation=”set|del”>yes|no </namespace:seclabelrequired>
| <namespace:signal operation=”set|del”>yes|no </namespace:signal>
| <!-- The following are racf-specific extensions to customclass -->
| <namespace:generic> allowed | disallowed</namespace:generic>
| <namespace:genlist> allowed | disallowed</namespace:genlist>
| <namespace:grouping>grouping class name </namespace:grouping>
| <namespace:defaultuacc>none | read | update | control | alter</namespace:defaultuacc>
| <namespace:member>member class name</namespace:member>
| <namespace:oper>yes|no</namespace:oper>
| <namespace:raclist> allowed | disallowed | required </namespace:raclist>
| </namespace:customclass>
| v name – Name of new class.
| v operation – Action to apply to definition. One of:
| – set → Define the custom class and set all specific data contained within the
| request.
376 z/OS Security Server RACF Callable Services
R_secmgtoper
| Signed program
| RACF defines a general resource profile in the PROGRAM class with data in the
| SIGVER and BASE segments.
| <namespace:signedprogram name=”name” operation=”set|del” requestid=”reqid" run=”yes|no”
| override="yes|no|force">
| <namespace:sigrequired operation=”set|del”/>
| <namespace:failload>ANYBAD|BADSIGONLY|NEVER</namespace:failload>
| <namespace:sigaudit> ALL|SUCCESS|ANYBAD|BADSIGONLY|NONE</namespace:sigaudit>
| <namespace:library>PDSE containing signed program</namespace:library>
| </namespace:signedprogram>
| v name – Name of program to be signed.
| v operation – Action to apply to definition. One of:
| – set → Define the signed program and set all specific data contained within the
| request.
| – del → Delete the signed program from the system
| – library → Name of PDSE containing signed program.
| v requestid – An optional label which identifies the security definition. This is
| used so a caller can more easily locate the results of this particular security
| definition in the result.
| v run – Default=yes. If set to 'no', the security definition is skipped.
| The sigrequired, failload, and sigaudit fields correspond to the sigreqd, failload,
| sigaudit fields in the SIGVER segment of general resource profiles as described in
| the “General resource administration” on page 439 in Appendix B, “Reference
| documentation tables,” on page 425. The library field corresponds to the member
| field in the BASE segment.
| Kerberos Realm
| RACF defines a general resource profile in the REALM class with data in the KERB
| segment.
| <namespace:kerberosrealm name=”name” operation=”set|del” requestid=”reqid" run=”yes|no”
| override="yes|no|force">
| <namespace:checkaddrs operation=”set|del” override="yes|no|force"/>
| <namespace:deftktlife>default ticket life</namespace:deftktlife>
| <namespace:encrypt>DES|NODES|DES3|NODES3|DESD|NODESD|
| AES128|NOAES128|AES256|NOAES256
| </namespace:encrypt>
| <namespace:kerbname> name <namespace:kerbname>
| <namespace:maxtktlife>maximum ticket life</namespace:maxtktlife>
| <namespace:mintktlife>minimum ticket life</namespace:mintktlife>
| <namespace:password>kerberos password</namespace:password>
| </namespace:kerberosrealm>
| v name – Name of the kerberos realm.
| v operation – Action to apply to definition. One of:
| – set → Define the realm and set all specific data contained within the request.
| – del → Delete the realm from the system
| v requestid – An optional label which identifies the security definition. This is
| used so a caller can more easily locate the results of this particular security
| definition in the result.
| v run – Default=yes. If set to 'no', the security definition is skipped.
| v override – Default=”yes”. Works in conjunction with the '00000002'x –
| PRECHECK option. Ignored if operation is not “set”.
| – If the PRECHECK option is set, an attempt is made to locate the resource in
| the RACF database.
| APPC session
| RACF defines a general resource profile in the APPCLU class with data in the
| SESSION segment.
| <namespace:appcsession netid=”netid” locallu=”lu” partnerlu=”lu” operation=”set|del”
| requestid=”reqid" run=”yes|no” override="yes|no|force">
| <namespace:convsec> NONE | CONV | ALREADYV | PERSISTV | AVPV</namespace:convsec>
| <namespace:interval>#</namespace:interval>
| <namespace:lock operation=”set|del”/>
| <namespace:sesskey>session key</namespace:sesskey>
| </namespace:appcsession>
| v netid – Network id
| v locallu – local lu name
| v partnerlu – partner lu name
| v operation – Action to apply to definition. One of:
| – set → Define the custom field and set all specific data contained within the
| request.
| – del → Delete the custom field from the system
| v requestid – An optional label which identifies the security definition. This is
| used so a caller can more easily locate the results of this particular security
| definition in the result.
| v run – Default=yes. If set to 'no', the security definition is skipped.
| v override – Default=”yes”. Works in conjunction with the '00000002'x –
| PRECHECK option. Ignored if operation is not “set”.
| – If the PRECHECK option is set, an attempt is made to locate the resource in
| the RACF database.
| - If the resource is found, processing depends on the value of the override
| attribute:
| v yes – An alter command is generated to update the resource with the
| data contained in the XML.
| v no – The resource is not updated at all
| v force - An add command is generated, followed by an alter command to
| update the resource with the data contained in the XML.
| The fields documented as being part of the special definitions are specified in the
| XML without segments. They are specified in the element for the special definition
| itself. In addition to the above elements, any racf segments and fields may be
| added to any of the special definitions. These will be ignored by non-RACF ESMs.
| Example:
| <saf:startedtask name=”task1” operation=”set” requestid=”st1def" run=”yes”>
| <user>STCUSER</user>
| <group>STCGROUP</group>
| <racf:base>
| <racf:uacc>none</racf:uacc>
| </racf:base>
| <esm1:base>
| <esm1:stsetting1>active</esm1:stsetting1>
| </esm1:base>
| </saf:startedtask>
| In the case of RACF, the UACC of the new profile in the started class will be given
| a UACC on NONE. Non-RACF ESMs will skip that part of the definition. ESM1
| will process the stsetting1 keyword, which is skipped by RACF.
| If it is necessary to grant access to the RACF resources defined using the special
| definitions, for example ALTER for administrative purposes, use the
| <racf:permission .../> construct to grant access to the specified profile name in the
| class indicated for the special definition.
| <racf:permission name=”task1”class=”started” operation=”set” requestid=”p1”>
| <racf:id>RACFADMN</racf:id>
| <racf:access>ALTER</racf:access>
| </racf:permission>
| The use of the racf namespace causes other ESMs to skip the permission operation,
| which is the desired result in the case of ESMs which store started task information
| someplace other than general resource profiles.
| REXX callers
| The service is designed to be callable by REXX callers via the LINKPGM REXX
| service. The difficulty is that REXX stores numbers as character data, which must
| be converted to binary values when dealing with numeric inputs and outputs from
| IRRSMO00. REXX programs can only call the IRRSMO00 31 bit version of the
| service.
Function
The R_setegid service checks whether the user is authorized to change the GID
and, if so, changes the effective GID for the current process.
If the high-order bit of the input GID is on, the real, effective, and saved GIDs are
changed for the current process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
RACF authorization
1. If the high-order bit of the input GID is off and if the user is the superuser or if
the input GID is equal to the real or saved GID of the calling process, the
effective GID of the process is changed to the input GID. The real and saved
GIDs are not changed. The new values of the GIDs are returned to the calling
process.
Format
CALL IRRSEG00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, GID,
ALET, Output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
GID
The name of a fullword containing the GID to be set. The GID must be defined
to RACF. If the high-order bit is on, the GIDs stored in the output area are
stored as the real, effective, and saved GIDs (in that order) for the current
process.
Output_area
The name of a 3-word area in which the new real, effective, and saved GIDs
(in that order) are returned. If the high-order bit of the GID is on, the real,
effective, and saved GIDs in this area are stored as the real, effective, and
saved GIDs for the current process.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. IRRSEG00 only changes the GIDs. The user's current group in the ACEE is not
changed. Therefore, IRRSEG00 only affects access to z/OS UNIX files. Access to
other MVS files is not changed.
3. An audit record is written.
Related services
None
Function
The R_seteuid service checks whether the user is authorized to change the z/OS
UNIX user identifiers (UIDs) and, if so, changes the effective UID for the current
process.
If the high-order bit of the input UID is on, the real, effective, and saved UIDs are
changed for the current process.
Requirements
Authorization:
Any PSW key in supervisor state
RACF authorization
1. If the high-order bit of the input z/OS UNIX user identifier (UID) is off and if
the user is the superuser or if the input UID is equal to the real or saved UID
of the calling process, the effective UID of the process is changed to the input
UID. The real and saved UIDs are not changed. The new values of the UIDs are
returned to the calling process.
Format
CALL IRRSEU00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, UID,
ALET, Output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
UID
The name of a fullword containing the z/OS UNIX user identifier (UID) to be
set. The UID must be defined to RACF. If the high-order bit is on, the UIDs
stored in the output area are stored as the real, effective, and saved UIDs (in
that order) for the current process.
Output_area
The name of a 3-word area in which the new real, effective, and saved z/OS
UNIX user identifiers (UIDs) (in that order) are returned. If the high-order bit
of the UID is on, the real, effective, and saved UIDs in this area are stored as
the real, effective, and saved UIDs for the current process.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. For additional security-related information, see the description of the seteuid
callable service in z/OS UNIX System Services Programming: Assembler Callable
Services Reference
3. An audit record is written.
Related services
None
Function
The R_setfacl callable service is used to maintain the access lists for a UNIX file or
directory
Requirements
Authorization:
Any PSW key in supervisor state
RACF authorization
1. To change the ACL, the user must be a superuser or must be the owner of the
file. To be considered a superuser, the user must either have a UID value of 0,
or must be permitted with at least READ access to the resource named
SUPERUSER.FILESYS.CHANGEPERMS in the UNIXPRIV class.
2. If the SECLABEL class is active and the file or directory has a security label,
then the current security label of the process must be greater than or equal to
the security label of the resource or the security label of the resource must be
greater than or equal to the current security label of the process, that is, the
security labels are not disjoint. If MLFSOBJ is active, a failure will occur if the
resource does not have a security label. Security label checking is bypassed if
the ACEE indicates trusted or privileged authority or if the service has passed a
system CRED.
Format
CALL IRRSCL00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, ACL_Update,
ALET, ACL_Update_length,
ALET, FSP,
ALET, File_identifier,
ALET, CRED,
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
ACL_Update
The name of an area containing the type of ACL being updated, the operation
being requested, and an ACL structure which contains entries to be added,
updated, or removed. See the RACL_Edit structure in the IRRPCOMP macro
for the mapping of this area.
The ACL structure is mapped by IRRPFACL. If the operation is add and
entries are specified in this ACL mapping, then the current ACL will be
replaced with the entries specified in this structure.
ACL_Update_Length
The name of a fullword containing the length of the ACL_Update buffer.
FSP
The name of the IFSP for the file whose mode bits are to be changed.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv) for more information. The
CRED contains a pointer to the ACL being modified/deleted, or contains the
address of a buffer in which to create a new ACL.
Usage notes
1. This service is intended only for use by a z/OS UNIX System Services file
system and by z/OS UNIX System Services servers. The service contains
support for z/OS UNIX System Services servers, but cannot be directly
invoked by an z/OS UNIX System Services server.
2. An access list may contain a maximum of 1024 entries.
3. R_setfacl will manage the bit in the File Security Packet (FSP) which indicates
the presence of an ACL of a given type. That is, when an ACL is successfully
added (by using either the add or modify operation), R_setfacl will turn on
the appropriate bit in IFSP_FLAG2 (either IFSP_Access_Acl,
IFSP_File_Model_Acl, or IFSP_Dir_Model_Acl). For a delete operation, or an
add or modify operation which results in an empty ACL, RACF will turn off
the appropriate bit in IFSP_FLAG2 .
4. When a modify operation is specified, requests to delete ACL entries are
processed before requests to add or modify entries.
5. If a modify operation is specified and an ACL does not exist, it will be
created. Likewise, if a modify request for a specific ACL entry is specified, and
that entry does not exist, it will be created.
6. If a delete request is specified, but an ACL does not exist, the request will be
ignored. Likewise, if a delete request for a specific ACL entry is specified, and
that entry does not exist, it will be ignored.
7. If an add request is specified, and an ACL already exists, it will be replaced in
accordance with the contents of the RACL_Edit structure pointed to by the
ACL_Update parameter. If there is no RACL_Edit in this context, the existing
ACL will be deleted.
8. If a delete request is specified, and a RACL_Edit structure is also contained
within the structure pointed to by the ACL_Update parameter, then the
RACL_Edit is ignored and the ACL is deleted.
9. An audit record (or records) is optionally written, depending on the audit
options in effect for the system.
10. The parameter list passed to this service is a variable-length (VL) parameter
list. The high-order bit of the last field must be set to mark the end of the
parameter list.
11. The caller must pass in the length and address of a buffer which contains the
ACL being modified, or in which a new ACL is to be created. The buffer must
be large enough to contain the maximum size ACL. The length and address
fields are contained within the CRED, and different field names are used
depending on which ACL is being created, modified, or deleted. For an access
ACL, use CredAccAcl and CredAccAclLen. For a directory model ACL, use
CredDirModelAcl and CredDirModelAclLen. For a file model ACL, use
CredFileModelAcl and CredFileModelAclLen.
12. R_setfacl will perform validation on the ACL passed into the service as part of
the RACL_Edit parameter of IRRPCOMP. An error in this ACL will result in a
SAF return code 8, RACF return code 8, and RACF reason code 16 (decimal).
If an error is detected, the FACL_ErrOff field within this ACL mapping will be
updated with the offset (from the start of the header) to the header field or
ACL entry in error. Some of the items validated are: eye catcher = "FACL",
version = 1, length is large enough to contain the number of entries specified
in FACL_Num_Entry, the ACL contains at least one entry, ACL entry type is 1
or 2, and UID/GID value is greater than or equal to 0.
13. An error with the input parameter list will result in a SAF return code 8,
RACF return code 8, and RACF reason code 24 (decimal). Some of the items
validated are: all addresses in the parameter list are non-zero, the
variable-length parameter list bit is set, the ACL_Update_Length parameter
specifies a length which is large enough to contain the ACL_Update area, the
operation type and ACL type specified in the ACL_Update area are valid, and
the pointers in the CRED which point to ACL buffers are non-zero and point
to an area which is large enough to contain the ACL.
Related services
R_chmod, R_chown, ck_access
Function
The R_setfsecl service changes the security label in the FSP to the value specified
in the CRED, or if no value is specified, the security label of the address space
level ACEE.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
This function is available only to supervisor state callers passing a system CRED,
or, if no security label is currently assigned, a user running with SPECIAL
authority.
Format
CALL IRRSSB00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, FSP,
ALET, File_Identifier,
ALET, CRED
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
FSP
The name of the IFSP for the file whose security label is to be changed.
File_Identifier
The name of a 16-byte area containing a unique identifier of the file.
CRED
The name of the CRED structure for the current file system syscall. See z/OS
Security Server RACF Data Areas in the z/OS Internet library
(www.ibm.com/systems/z/os/zos/library/bkserv).
Usage notes
1. This service is intended only for use by the z/OS UNIX System Services file
system and by z/OS UNIX System Services file servers.
2. This service requires a system CRED if the FSP already contains a security
label.
3. If the FSP does not already contain a security label, this service requires a
system CRED, or a user CRED and an ACEE that indicates the user has the
SPECIAL attribute.
4. If the security label is not specified, the security label in the FSP will be set to
the value from the address space level ACEE.
5. An audit record is optionally written, depending on the audit options in effect
for the system.
6. Callers receiving a SAF RC0, RACF RC0, RACF RS4 indicating that the
SECLABEL class is not active, may choose to listen for the ENF event that
indicates the SECLABEL class has been RACLISTed before calling this service
again. See z/OS MVS Programming: Authorized Assembler Services Guide for more
information.
Related services
makeFSP, make_root_FSP
Function
The R_setgid service checks whether the user is authorized to change the GIDs
and, if so, changes the real, saved, or effective GID (or some combination of these)
for the current process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. If the calling process is a superuser, the real, saved, and effective GIDs are
changed. If the calling process is not a superuser but the input GID is equal to
the real or saved GID, the effective GID of the process is changed. If neither
condition is met, the GIDs of the process are not changed, and an error return
code and an error reason code are returned.
Format
CALL IRRSSG00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, GID,
ALET, Output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
GID
The name of a fullword containing the GID to be set. The GID must be defined
to RACF.
Output_area
The name of a 3-word area in which the new real, effective, and saved GIDs
(in that order) are returned.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. IRRSSG00 changes only the GIDs. No change is made to the user's current
group in the ACEE. Therefore, IRRSSG00 only affects access to z/OS UNIX
files. Access to other MVS files is unchanged.
3. An audit record is written.
Related services
None
Function
The R_setuid service checks whether the user is authorized to change the z/OS
UNIX user identifiers (UIDs) and, if so, changes the real, saved, or effective UID
(or some combination of these) for the current process.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area. The
words containing the ALETs must be in the primary address space.
RACF authorization
1. If the calling process is a superuser, the real, saved, and effective z/OS UNIX
user identifiers (UIDs) are changed. If the calling process is not a superuser, but
the input UID is equal to the real or saved UID, the effective UID of the
process is changed. If neither condition is met, the UIDs of the process are not
changed, and an error return code and and an error reason code are returned.
Format
CALL IRRSSU00 (Work_area,
ALET,SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, UID,
ALET, Output_area
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
UID
The name of a fullword containing the z/OS UNIX user identifier (UID) to be
set. The UID must be defined to RACF.
Output_area
The name of a 3-word area in which the new real, effective, and saved z/OS
UNIX user identifiers (UIDs) (in that order) are returned.
Usage notes
1. This service is intended only for use by the MVS BCP.
2. For additional security-related information, see the description of the setuid
callable service in z/OS UNIX System Services Programming: Assembler Callable
Services Reference.
3. An audit record is optionally written, depending on the audit options in effect
for the system.
Related services
None
Function
The R_ticketserv callable service allows callers to read GSS-API context tokens and
also provides RACF PassTicket services. R_ticketserv is similar to the Extract client
principal (function code 1) of the R_GenSec callable service (See “Extract client
principal functions (Function code 1):” on page 235 for more information). The
main difference is that R_ticketserv cannot be invoked from AMODE 64.
The R_ticketserv service, like other SAF calls that use Kerberos for authentication,
requires the SKRBKDC started task to be running in the same address space.
R_ticketserv checks that the server principal in the ticket maps to the current user
ID, before the ticket is accepted. If tickets for different service principals are to be
accepted, a KERBLINK mapping must exist for the service principal, and the
current user ID must be granted at least READ authority to the KERBLINK profile.
For example, if the server principal in the ticket is princ2/fully_qualified_hostname
and is associated with user2, and the current user is user1 who is defined to RACF,
you can use the PERMIT command to grant user1 READ authority to the
KERBLINK profile of the server principal. With READ authority, user1 can decrypt
the tickets of user2. However, before using the PERMIT command to grant this
READ authority, you must activate RACF protection for the KERBLINK profile (if
not already active). If the server principal does not have a KERBLINK profile, you
must create one. The following procedure shows how to activate RACF protection,
create a KERBLINK profile, and grant READ authority:
1. Activating RACF protection for the KERBLINK class using the SETROPTS
command:
SETROPTS CLASSACT(KERBLINK)
See z/OS Security Server RACF Command Language Reference for more
information about the SETROPTS command.
2. Creating a KERBLINK profile for the server principal (princ2/
fully_qualified_hostname) in the ticket using the RDEFINE command:
RDEFINE KERBLINK princ2/fully_qualified_hostname
See z/OS Security Server RACF Security Administrator's Guide for more
information about KERBLINK profiles and automatic local principal name
mapping.
3. Using the PERMIT command to grant user1 READ authority to the KERBLINK
profile of the server principal (princ2/fully_qualified_hostname):
PERMIT princ2/fully_qualified_hostname CLASS(KERBLINK) ID(user1) ACCESS(READ)
See z/OS Security Server RACF Security Administrator's Guide for more
information about the PERMIT command.
Requirements
Authorization:
Any PSW key in supervisor state or problem state
Dispatchable unit mode:
Task of user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have an FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. Therefore, the last word in the parameter list must
have a 1 in the high-order (sign) bit.
RACF authorization
For servers not running in system key or supervisor state, the use of R_ticketserv
service to manipulate GSS-API context tokens is authorized by the resource
IRR.RTICKETSERV in the FACILITY class. The application server must be running
with a RACF user or group that has at least READ authority to this resource. If the
class is inactive, or the resource is not defined, only servers running system key or
supervisor state may use the R_ticketserv service.
For all callers, the use of R_ticketserv service to use PassTicket services is
authorized by resources in the PTKTDATA class which correspond to the
application ID and target userid used in the PassTicket operation. The application
server must be running with a RACF user or group that has the authority specified
in the following table. If the PTKTDATA class is inactive, or the resource is not
defined, the request will fail due to insufficient authority. All callers, regardless of
PSW key or state, must pass the authorization check. Generic profiles may be used
for authorization.
See z/OS Security Server RACF Security Administrator's Guide for more information
about configuring RACF to use PassTicket services.
To log in a user using a PassTicket, use a standard z/OS function such as __login()
or RACROUTE REQUEST=VERIFY.
Format
CALL IRRSPK00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Function_code,
Option_word,
Ticket_area,
Ticket_options,
Ticket_principal_userid
Application_Id
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a full word in which the SAF router returns the SAF return code.
RACF_return_code
The name of a full word in which the service routine stores the return code.
RACF_reason_code
The name of a full word in which the service routine stores the reason code.
ALET
The name of a word that must be in the primary address space and contains
the ALET for the following fields:
v Function_code
v Option_word
v Ticket_area
v Ticket_options
v Ticket_principal_userid
v Application_Id
Function_code
The name of a half-word (2-byte) area containing the Function code. The
function code has one of the following values:
X'0001'
Parse-specified ticket and return Network Authentication Service
principal name.
X'0003'
PassTicket operation
Option_word
The name of a fullword containing binary zeros. The area pointed to by this
parameter is reserved for future use.
Ticket_area
For function code X'0001', this is the name of an area that consists of a 2-byte
field set to the length of the contents of the GSS-API context token, followed
by the contents of the GSS-API context token. The GSS-API context token is
assumed by SAF to have been created exclusively by the Network
Authentication Service Kerberos mechanism.
If the SKRBKDC started task is running with the -NOKDC option (a KDC is
not available in the same address space), the keytab file is used to locate the
service key that is needed to decrypt the server ticket. The following keytab
file is used by the R_ticketserv service and must only be readable by the
SKRBKDC started task:
/etc/skrb/home/kdc/tickserv.ktf
To decrypt the ticket, the server key in the keytab entry must match that used
by the Key Distribution Center (KDC) for the given server, version, and
encryption type used when the KDC issued the service ticket contained in the
| token. If the KDC is running under a FIPS level that restricts the use of
| non-FIPS compliant keys, the decryption of the ticket will fail if it was
| encrypted using a non-FIPS compliant encryption type.
Note: To decrypt the ticket, you need to know the password used to create the
server entry in the KDC.
If the SKRBKDC started task is running with the -KDC option (a KDC is
available on the same image), the service key in the KDC is used to decrypt
the ticket in the token, and the keytab file is not used.
For function code X'0003', this is the name of a 10-byte area that consists of a
2-byte length field, followed by an 8-byte PassTicket field. If ticket_options
indicates that a PassTicket is to be generated, the newly generated PassTicket
will be returned in this area. The caller must specify a length of at least 8 to
indicate that an acceptable buffer has been supplied for the generated
PassTicket.
If ticket_options indicates that a PassTicket is to be evaluated, this contains the
PassTicket to be evaluated.
Ticket_options
The name of a fullword containing the address of a binary bit string that
identifies the ticket-specific processing to be performed. This parameter is
unused when a function code of X'0001' is specified.
When function code X'0003' is specified, the bit string is used as an integer to
specify which PassTicket operation to perform.
X’00000001’ - Generate a PassTicket
X’00000002’ - Evaluate a PassTicket
X’00000003’ - Evaluate a PassTicket Extended
Ticket_principal_userid
For function code X'0001' this is the name of a 242-byte area that consists of a
2-byte length field followed by the name of the Ticket principal user ID.
Usage notes
Function code=X'0001':
1. This service is intended for use by z/OS application servers. The service allows
application servers with a GSS-API context token (created with the Kerberos V5
mechanism) to determine the Kerberos client principal associated with the
token.
2. This service requires that the Security Server Network Authentication Service
be installed and running. Otherwise, SAF return code 8, RACF return code 12,
and RACF reason code 16 will be returned to the invoker.
3. In a datasharing sysplex, there must be an Security Server Network
Authentication Service instance running on each system in the sysplex. The
Security Server Network Authentication Service instances must all be in the
same realm and share the same RACF database (if they do not share the same
database, then they cannot be in the same realm).
4. An ALET must be specified for the SAF_return_code, RACF_return_code, and
RACF_reason_code parameters, and a single ALET specified for all of the
remaining paramenters.
5. The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the last word in the parameter list
must have a 1 in the high-order (sign) bit. If the last word in the parameter list
does not have a 1 in the high-order (sign) bit, the caller receives a parameter
list error. The first parameter that can have the high-order bit on, ending the
parameter list, is the Ticket_principal_userid parameter.
6. A SAF return code 8 and a RACF return code 16 indicates that the Security
Server Network Authentication Service was unable to process the input
GSS-API token. The return code is passed back to the invoker as the RACF
reason code. The following list shows some common return codes:
v X'861B6D04' (G_BUFFER_ALLOC)=storage not available for GSS-API control
block.
v X'861B6D06' (G_WRONG_SIZE)=client principal name is too long for result
buffer.
v X'861B6D0B' (G_BAD_TOK_HEADER)=the GSS-API token header is
incorrect.
v X'861B6D58' (G_UNEXPECTED_TOKEN)=the GSS-API token was not created
by the gss_init_sec_context() function.
v X'861B6D60' (G_UNSUPPORTED_MECHANISM)=unsupported GSS-API
security mechanism.
v X'96C73A07'(KRB5KDC_ERR_S_PRINCIPAL_UNKNOWN)=the current
RACF userid is not associated with a Kerberos principal.
v X'96C73A20'(KRB5KDC_AP_ERR_TKT_EXPIRED)=Kerberos ticket is expired.
v X'96C73A25'(KRB5KDC_AP_ERR_SKEW)=Client and server clocks are not
synchronized or authenticator is expired.
v X'96C73A90'(KRB5KDC_AP_WRONG_PRINC)=the server principal in the
GSS-API security token does not match the principal associated with the
current RACF userid.
v X'96C73C02'(KRB5_NOMEM)=storage not available for Kerberos control
block.
| v X'96C73C30' (KRB5_INCOMPATIBLE_ENCTYPE)=Incompatible encryption
| type specified for the requested FIPS level.
Function code=X'0003': The parameter list for this callable service is intended to be
variable length to allow for future expansion. To allow for this, the last word in the
parameter list must have a 1 in the high-order (sign) bit. If the last word in the
parameter list does not have a 1 in the high-order (sign) bit, the caller receives a
parameter list error. Only the Application_Id parameter must have it's high order
bit set when the function_code =X'0003'.
Parameter usage
Parameter Function code X'0001' and X'0003'
SAF_return_code Output
RACF_return_code Output
RACF_reason_code Output
Function _code Input
Option_word Reserved
Ticket_area Input for function code X'0001'
Input or output for function code X'0003'
Ticket_options Input
Ticket_principal_userid Output for function code X'0001'
Input for function code X'0003'
Application_Id Input
Related services
R_kerbinfo, R_usermap
Function
The R_umask service sets the file mode creation mask for the current process to
the permission bits specified in the input mode parameter. It returns the
permission bits that were in the file mode creation map in the mode parameter.
Requirements
Authorization:
Any PSW key in supervisor state
Dispatchable unit mode:
Task of z/OS UNIX user
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
None
Serialization:
Enabled for interrupts
RACF authorization
None
Format
CALL IRRSMM00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Mode
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
parameter must have an ALET specified. Each ALET can be different. The
words containing the ALETs must be in the primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Mode
The name of a word containing the mode bits to be set in file mode creation
mask of the current process. Only the file permission bits in the mode
parameter are used. Other defined bits are ignored.
On output, the mode word is zeroed and the permission bits that were in the
file mode creation mask are set in the mode word.
See “File type and file mode values” on page 4 for a definition of the security
bits in the mode parameter.
Usage note
v This service is intended only for use by the MVS BCP and by z/OS UNIX
servers. The service contains support for z/OS UNIX servers, but cannot be
directly invoked by a z/OS UNIX server.
Related services
chmod, makeFSP
Function
The R_usermap service enables z/OS application servers to determine the
application user identity associated with a RACF user ID, or to determine the
RACF user ID associated with an application user identity or digital certificate,
except for Identity Propagation in which case a user's Distinguished Name and a
Registry/Realm Name will be used to determine the associated RACF user ID, but
not the reverse. Examples of applications supported are RACF user ID, application
user identity, application, Lotus Notes® for z/OS and Novell Directory Services
(NDS).
This service can only map application user identities which have already been
defined to RACF:
v For Lotus Notes for z/OS, the RACF USER profile must have an LNOTES
segment containing a short name. This can be added with the ADDUSER or
ALTUSER command, or the R_admin callable service.
v For NDS for z/OS, the RACF USER profile must have an NDS segment
containing a user name. This can be added with the ADDUSER or ALTUSER
command, or the R_admin callable service.
v For digital certificates, the certificate must be associated with a RACF user ID
through automatic registration or with the RACDCERT command.
v For Security Server Network Authentication Service, local Kerberos principals
require a RACF USER profile with a KERB segment containing a principal name.
Foreign Kerberos principals must be defined to RACF using KERBLINK profiles.
v For Identity Propagation, the distributed identity (user's Distinguished Name)
must be associated with a RACF user ID. Use the RACMAP command to create
the association between the distributed identity and a RACF defined user ID
(this association is also known as a ‘filter’).
v For e-mail, the RACF USER profile must have a WORKATTR segment
containing an e-mail address. This can be added with the ADDUSER or
ALTUSER command, or the R_admin callable service.
Requirements
Authorization:
Any PSW key in supervisor or problem state
Dispatchable unit mode:
Task of user
Cross memory mode:
PASN = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
ESTAE. Caller cannot have a FRR active.
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. The words containing the ALETs must be in the primary address
space.
Linkage conventions
The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the last word in the parameter list
must have a 1 in the high-order (sign) bit.
RACF authorization
Function codes X'0001' through X'0006', and X'0009' through X'000A' only: The use
of the R_usermap service is authorized by the resource IRR.RUSERMAP in the
FACILITY class for servers not running in system key or supervisor state. The
application server must be running with a RACF user or group that has at least
READ authority to this resource. Only servers running in system key or supervisor
state may use the R_usermap service if the class is inactive or the resource is not
defined.
Function codes X'0008' only: The use of the R_usermap service is authorized by the
resource IRR.IDIDMAP.QUERY in the FACILITY class for servers not running in
system key or supervisor state. The application server must be running with a
RACF user or group that has at least READ authority to this resource. Only
servers running in system key or supervisor state may use the R_usermap service
if the class is inactive or the resource is not defined.
Format
CALL IRRSIM00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
ALET, Function_code,
Option_word,
RACF_userid,
Certificate,
Application_userid
Distinguished_Name,
Registry_Name )
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space and must be on a doubleword boundary.
ALET
The name of a word containing the ALET for the following parameter. Each
ALET can be different. The last ALET in the parameter list will be used for the
remainder of the parameters. The words containing the ALETs must be in the
primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_code
The name of a halfword containing the function code. The function code has
one of the following values:
X'0001'
Return the Lotus Notes for z/OS application user identity associated
with the supplied RACF user ID.
X'0002'
Return the RACF user ID associated with the supplied Lotus Notes for
z/OS application user identity or digital certificate.
X'0003'
Return the NDS for z/OS application user identity associated with the
supplied RACF user ID.
X'0004'
Return the RACF user ID associated with the supplied NDS for z/OS
application user identity or digital certificate.
X'0005'
Return the Network Authentication Service application user identity
associated with the supplied RACF user ID.
RACF_userid
The name of a 9-byte area that consists of a 1-byte length field followed by up
to 8 characters. It must be specified in uppercase. If not specified, the length
must equal 0.
Certificate
The name of an area that consists of a 4-byte length field followed by a digital
certificate. The certificate must be a single BER encoded X.509 certificate. If not
specified, the length must equal 0.
Application_userid
The name of a 248-byte area that consists of a 2-byte length field followed by
the name of the application user identity. If not specified, the length must
equal 0.
Distinguished_Name
The name of an area that consists of a 2-byte length field followed by the
distinguished name (distributed user ID), in UTF-8 format, of up to the
maximum length allowed by the RCVT field RCVTDNL (currently 246). If not
specified, the length must equal 0. For a non-zero length, the field cannot be all
blanks (x'20'), all nulls (x'00'), or a combination of blanks and nulls.
Note:
1. The following operations are performed on a copy of the data. The original
data is not modified.
v All leading and trailing blanks (x'20'), nulls (x'00'), or combination of
blanks and null characters will be removed from the string and the
length will be appropriately adjusted.
v If the distributed-identity-user-name (user name) is in X.500 format the
name will be normalized before it is used to find the matching RACF
user ID that is associated with the distributed identity filter.
2. The normalization rules are described in detail under RACMAP MAP.
Registry_Name
The name of an area that consists of a 2-byte length field followed by the
registry/realm name, in UTF-8 format, of up to the maximum length allowed
by the RCVT field RCVTRL (currently 255). If not specified, the length must
equal 0. For a non-zero length, the field cannot be all blanks (x'20'), all nulls
(x'00'), or a combination of blanks and nulls.
Note: All leading and trailing blanks (x'20'), nulls (x'00'), or combination of
blanks and null characters will be removed from the string and the length will
be appropriately adjusted. This operation is performed on a copy of the data.
The original data is not modified.
Parameter usage
Table 172. Parameter usage
Parameter Function Function Function Function Function Function Function Function Function
code 1 code 2 code 3 code 4 code 5 code 6 code 8 code 9 code 10
(RACF to (Notes to (RACF to (NDS to (RACF to (KERB to (DID to (RACF user (e-mail
notes) RACF) NDS) RACF) KERB) RACF) RACF) ID to address to
e-mail RACF user
address) ID)
SAF_return_code Output Output Output Output Output Output Output Output Output
RACF_return_code Output Output Output Output Output Output Output Output Output
RACF_reason_code Output Output Output Output Output Output Output Output Output
Function_code Input Input Input Input Input Input Input Input Input
Option_word Reserved Reserved Reserved Reserved Reserved Reserved Reserved Reserved Reserved
Usage notes
1. This service is intended for use by z/OS application servers. It allows them to
map between supported application user identities and the corresponding
RACF user ID, or to determine the RACF user ID by supplying the
corresponding application user identity or digital certificate.
2. An ALET must be specified for the SAF_return_code, RACF_return_code,
RACF_reason_code parameters, and a single ALET specified for all of the
remaining parameters.
3. The parameter list for this callable service is intended to be variable length to
allow for future expansion. To allow for this, the last word in the parameter
list must have a 1 in the high-order bit. If the last word in the parameter list
does not have a 1 in the high-order (sign) bit, the caller receives a parameter
list error.
v For function codes 1-6 and 9-10, the first parameter that can have the
high-order bit on, ending the parameter list, is the Application_userid
parameter.
v For function code 8, the first parameter that can have the high-order bit on,
ending the parameter list, is the Registry_Name parameter.
4. If the Function_code indicates that an application identity is to be returned,
and no RACF_userid is supplied, the caller receives a parameter list error.
5. For function codes 1-6 and 9-10:
v The caller receives a parameter list error if the Function_code indicates that
a RACF user ID is to be returned, and no Application_userid or Certificate
is supplied.
v Specification of a RACF_userid with a length greater than 8 or an
Application_userid with a length greater than 246 will result in a parameter
list error.
v If the Function_code specifies that a RACF user ID is to be returned and the
length supplied for the Application_userid is greater than the maximum
allowed, such as greater than 64 for a Lotus Notes for z/OS user identity, or
greater than 240 for Security Server Network Authentication Service user
identity, the caller receives the "no mapping between RACF and an
application" error.
v If the Function_code indicates that a RACF user ID is to be returned, and
both an Application_userid and a Certificate are supplied, the
Application_userid will be used.
6. For function code 8:
v The length of the Distinguished_Name must be greater than 0 and less than
or equal to the maximum length allowed by the RCVT field RCVTDNL
(currently 246). A length of 0 or greater than the maximum allowed will
result in the, Distinguished Name length not valid, error (SAF Return Code
= 8, RACF Return Code = 8, RACF Reason Code = 40).
v The length of the Registry_Name must be greater than 0 and less than or
equal to the maximum length allowed by the RCVT field RCVTRL
(currently 255). A length of 0 or greater than the maximum allowed will
result in the, Registry Name length not valid, error (SAF Return Code = 8,
RACF Return Code = 8, RACF Reason Code = 44).
v The Distinguished_Name and Registry_Name must be in UTF-8 format. If
they are not in UTF-8 format the associated RACF user ID will not be found
(SAF Return Code = 8, RACF Return Code = 8, RACF Reason Code = 48).
7. Specification of an unknown function code will result in a parameter list error.
8. If the Function_code indicates that an application user identity is to be
returned, the caller is expected to supply a 248-byte area for the
Application_userid parameter. If an application user identity is defined for the
RACF_userid specified, R_usermap will update this area with the length and
value of the application user identity. This storage must be accessible in the
caller's key.
9. If the Function_code indicates that a RACF user ID is to be returned, the caller
is expected to supply a 9-byte area for the RACF_userid parameter. If a RACF
user ID is associated with the Application_identity specified, R_usermap will
update this area with the length and value of the RACF user ID. This storage
must be accessible in the caller's key.
10. The conversion between the supported application user identities (or
certificates) and RACF user IDs is dependent on the definition of the
application-specific segments associated with the RACF USER profile.
v To convert between Lotus Notes for z/OS user identity and a RACF user
ID, the RACF USER profile must have an LNOTES segment containing the
SNAME field.
v To convert between an NDS for z/OS user identity and a RACF user ID,
the RACF USER profile must have an NDS segment containing the
UNAME field.
v To convert between a certificate and a RACF user ID, the RACF USER
profile must be associated with the certificate.
v To convert between an e-mail address and a RACF user ID, the RACF
USER profile must have a WORKATTR segment containing the WAEMAIL
field.
11. The certificate supplied by the certificate parameter is used only to identify a
RACF user ID. It is expected that the certificate was previously verified. Note
the following additional details regarding certificate processing:
a. All fields as defined for X.509 version 1 certificates must be present and
non-null.
b. X.509 certificates with version numbers greater than 3 are not supported.
c. Version 3 certificates with critical extensions are not supported. Noncritical
extensions are ignored.
d. Subject and issuer names can contain only the following string types:
v T61STRING - TAG 20
v PRINTABLESTRING - TAG 19
v IA5STRING - TAG 22
v VISIBLESTRING - TAG 26
v GENERALSTRING - TAG 27
e. The length of the serial number plus the length of the issuer's name cannot
exceed 245.
f. No date validity check is performed on the certificate.
g. No signature check is performed on the certificate.
12. If the certificate supplied by the caller is defined to RACF with a status of
NOTRUST, R_usermap will return a RACF return code 8, RACF reason code
32, indicating that no user ID is defined to use this certificate.
| 13. For function_codes 5 and 6, the application user identity is the Security Server
| Network Authentication Service principal name. Local and foreign principal
| names are case-sensitive, however, the realm name portion of a foreign
| principal must be folded to uppercase when defined in the KERBLINK class
| profile. R_usermap will accept mixed case input of foreign profile names, but
| will fold the realm name portion of the foreign principal to uppercase before
| attempting to locate the appropriate KERBLINK identity mapping profile.
| R_usermap output of foreign principal names will match the case of the
| KERBLINK profile name (realm name will be uppercase). Additionally, while
| local principal names may be supplied fully qualified with the name of the
| local realm, R_usermap output of local principal names will always be
| unqualified. Realm qualified names follow a DCE-like convention of
| /.../realm_name/principal_name.
14. The Distinguished Name value can be in any of the following formats:
a. As a simple character string, such as a user ID defined in a non-LDAP
registry.
Typically, special characters do not appear in user names stored within a
registry. However, if you need to specify a user name value that includes
certain characters, they must be preceded by the backslash (\) escape
character.
These characters include the plus sign (+), semicolon (;), comma (,),
quotation mark ("), backslash (\), less than symbol (<), greater than
symbol (>) and the equal sign (=).
b. As a character string that represents an X.500 distinguished name (DN).
A Distinguished Name (DN) consists of one or more relative distinguished
names (RDNs). Each RDN consists of an attribute type and attribute value,
separated by an equal sign (=). RDNs are separated by a comma (,).
Like the RACMAP command, R_usermap does not perform validity
checking of the X.500 name.
15. The following rules are used to define a user name as Distinguished Name
when the RACMAP command is used to define the mappings:
v Specify the user name value in its canonical form, as it is defined within the
registry, with any special characters preceded by the backslash (\) escape
character. You must specify the RDNs in their correct sequence.
For example, for users of WebSphere® Application Server applications, the
canonical form of the user name must match the value returned by the
WSCredential interface method called getUniqueSecurityName().
v Typically, special characters do not appear in user names stored within a
registry. However, if you need to specify a user name value that includes
certain characters, including LDAP special characters, they must be
preceded by the backslash (\) escape character.
These characters include the plus sign (+), semicolon (;), comma (,),
quotation mark ("), backslash (\), less than symbol (<), greater than symbol
(>), and the equal sign (=).
Exception: Do not escape the equal sign (=), semicolon (;), or comma (,)
when you specify them as delimiters of an RDN.
v Do not specify blank characters immediately preceding or following the
equal sign (=) when using the equal sign as a delimiter of an attribute type
or RDN.
16. Check if any logrec entry has been created to ensure R_usermap service was
being run successfully and also refer to z/OS Security Server RACF Diagnosis
Guide for detailed logrec information.
Related services
R_dceinfo, R_dceruid
Function
The R_writepriv service sets, resets, or queries the setting of the write-down
privilege in the ACEE. Only callers in system key or supervisor state can change
the value in an ACEE other than the current address space level ACEE.
Requirements
Authorization:
Any PSW key in any state
Dispatchable unit mode:
Task
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
31
RMODE:
Any
ASC mode:
Primary or AR mode
Recovery mode:
SETFRR
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area must be in the primary address
space. ALETs must be passed for all parameters except the work area and
function code. The words containing the ALETs must be in the primary
address space.
RACF authorization
To specify an ACEE value, the calling program must be running in a system key or
in supervisor state. If the ACEE is not specified, the address space level ACEE is
used. In either case, the ability to enable the write-down privilege is determined
using the IRR.WRITEDOWN.BYUSER profile in the FACILITY class based on the
user ID in the ACEE. The FACILITY class must be active and RACLISTed, the
IRR.WRITEDOWN.BYUSER profile must exist in the RACLISTed profiles, and the
SETR MLS option must be active.
Format
CALL IRRSWP00 (Work_area,
ALET, SAF_return_code,
ALET, RACF_return_code,
ALET, RACF_reason_code,
Function_Code,
ALET, ACEE
)
Parameters
Work_area
The name of a 1024-byte work area for SAF and RACF usage. The work area
must be in the primary address space.
ALET
The name of a word containing the ALET for the following parameter. Each
ALET can be different. The words containing the ALETs must be in the
primary address space.
SAF_return_code
The name of a fullword in which the SAF router returns the SAF return code.
RACF_return_code
The name of a fullword in which the service routine stores the return code.
RACF_reason_code
The name of a fullword in which the service routine stores the reason code.
Function_Code
The name of a 1-byte area containing the function code.
X'00' query the current setting of the write-down privilege
X'01' activate the write-down privilege
X'02' inactivate the write-down privilege
X'03' reset the write-down privilege to its default value
ACEE
The name of an area containing an ACEE or a fullword of zeros if ACEE is not
specified. If not specified, the home address space level ACEE is to be used.
Usage notes
1. If the SAF and RACF return codes are zero, the RACF reason code will indicate
the current setting of the write-down privilege when the callable service
completes.
2. An audit record is written if the write-down privilege is set successfully, or if a
request has been made to change the write-down privilege and the user is not
authorized to IRR.WRITEDOWN.BYUSER.
Related services
None
Function
As described in Chapter 1, “Using the RACF callable services,” on page 1, Linkage
Conventions for the Callable Services, IRRSXT00 is invoked by the SAF callable
services router before and after RACF is called. It receives as input, a function code
indicating which callable service is being called, and the parameter list that will be
passed to RACF. The first parameter in the parameter list points to a work area.
The exit can use the first 152 bytes of this work area. The first word of the work
area is set to zero before the pre-RACF call to the exit. the exit should set another
value in this word to indicate to the post-RACF exit call that it is the second call.
The first four words of the work area are passed unchanged from the pre-RACF to
the post-RACF exit.
The pre-RACF exit can change the content of the parameter list that will be passed
to the external security product. It can also indicate with return codes that the
external security product should be bypassed and control returned to the caller.
The SAF return code is set based on the exit return code. If the external security
product is bypassed, the exit routine must provide all of the output including
RACF-compatible return and reason codes that the invokers of the services expect.
The post-RACF exit can look at or change the output from RACF including the
RACF return and reason codes. No exit return codes are defined from this exit call.
SAF return codes are set based on the RACF return codes, not on an exit return
code.
Requirements
Authorization:
*State and key of the user calling the security function
Dispatchable unit mode:
Task of user calling security function
Cross memory mode:
PASN = HASN or PASN not = HASN
AMODE:
Any or 31 or 64 for IRRSXT0X
RMODE:
Any or 24
ASC mode:
AR mode
Serialization:
Enabled for interrupts
Locks: No locks held
Control parameters:
The parameter list and the work area are in the primary address space.
ALETs are passed for all parameters except the work area. The words
containing the ALETs are in the primary address space.
Note: *Most callable services will be supervisor state and key 0. For services that
can be invoked unauthorized, it can be problem state and any key.
Interface registers
Table 173. Input registers
Register AR content GR content
0 Any Function code of service.
Refer to the description of
IRRPFC in z/OS Security
Server RACF Data Areas in
the z/OS Internet library
(www.ibm.com/systems/z/
os/zos/library/bkserv).
1 0 Address of parameter list
2 - 13 Any Undefined
14 0 Return address
15 0 Entry point address
Input
The parameter list is the same as the list that will be passed to the external security
product (for example, RACF). The content of the list varies depending on the
service requested. See z/OS Security Server RACF Data Areas in the z/OS Internet
library (www.ibm.com/systems/z/os/zos/library/bkserv) for descriptions of the
parameter list, IRRPCOMP, as well as detailed descriptions of structures such as
the FSP and CRED, which are passed as parameters on a number of the callable
services. See Chapter 2, “Callable services descriptions,” on page 9 for descriptions
of the possible parameter lists. IRRSXT0X uses IRRPCOMX for parameter
mapping.
The first 152 bytes of the work area pointed to by the parameter list can be used
by the exit. The rest of the work area is reserved for SAF and RACF. The first four
words of the 152-byte area can be used to pass data from the pre-RACF call of the
exit to the post-RACF call to the exit. These words are not used by SAF or RACF.
The other 136 bytes may be used by RACF services or the SAF router between the
calls to the pre-RACF exit and the post-RACF exit.
Output
Returned data: If the exit indicates that RACF is not to be called, the exit is
responsible for setting the RACF return and reason codes and providing any other
output data expected by the caller of the requested service.
Note: The return and reason codes are not stored in the parameter list as they are
for SAF exit ICHRTX00. For IRRSXT00, the parameter list contains the addresses of
two words in which the return and reason codes must be stored.
The pre-RACF exit routine must restore all registers on return except register 15,
which must contain a return code.
The post-RACF exit must also restore all registers except 15. No return codes are
defined for the post-RACF exit.
Return codes: The pre-RACF exit can return one of the following return codes:
Usage notes
1. The exit must be reentrant.
2. The exit can receive control in cross memory mode.
3. The exit must use BAKR to save registers. No save area is provided on entry. It
is called in AR mode and must save both general and access registers.
4. To install the SAF callable services router installation exit, create the load
module, name it IRRSXT00, and load it into the link pack area (LPA).
5. The exit must provide its own recovery routine. If the exit routine terminates
abnormally, its recovery routine gets control. If a recovery routine is not
provided or if the recovery routine percolates, the recovery routine of the caller
of the service stub will get control.
6. To determine the caller of the SAF callable service, use the function code in
register 0 to determine which callable service is being called. Refer to Table 1 on
page 9, in Chapter 2, for the list of components and products that are possible
callers of each service.
The usage notes that follow the callable service descriptions are also helpful in
determining the caller.
Many services receive the CRED as a parameter. The CRED contains an audit
function code, defined in macro IRRPAFC, which identifies the z/OS UNIX
function calling the service. You can find additional information on which
callable services are called by z/OS UNIX functions in the z/OS Security Server
(RACF) Auditor's Guide, under Classes that Control Auditing for z/OS UNIX
System Services.
For the R_admin update functions, the caller provides segment and field entries to
identify the segment(s) and field(s) which should be added, altered, deleted, or
listed. For SETROPTS extract, RACF returns a BASE segment entry and field
entries in the same way.
For user and group delete functions, no segment data is expected. The number of
segments should be zero. If non-zero, any segment data present is ignored.
For list functions, the caller must provide a segment entry for each segment which
is to be listed (including the BASE segment). The command output for the
segments is returned in the order in which the segment entries were supplied,
except that the BASE segment is always returned first.
Note:
Note:
v For boolean fields, no field data is allowed. Coding field data results in an
"Invalid Request" error being returned to the caller.
v For flag byte 'N', any field data specified is ignored.
User administration
The following tables define field names and their usage. All field names relate
directly to the ADDUSER and ALTUSER keywords. Although the fields are
alphabetized in the following tables, there is no defined order in which the fields
are returned when using the extract functions. See z/OS Security Server RACF
Command Language Reference for questions pertaining to field usage and data. Note
that within the command image generated internally, RACF truncates long
keywords to 12 characters.
Boolean and list fields are identified in the field name column. Unless otherwise
noted, a field is a character field by default. For list fields, the list header field
returned by the extract function is also specified. Unless otherwise noted, all list
fields are 1-dimensional arrays.
Table 179. BASE segment fields
| Field name SAF field Flag ADDUSER/ALTUSER Allowed on Allowed on Returned
| name byte keyword Reference, or add alter on extract
values LISTUSER heading (for requests requests requests
output-only fields)
ADSP (boolean) 'Y' ADSP Yes Yes Yes
'N' NOADSP Yes Yes Yes
AUDITOR 'Y' AUDITOR Yes Yes Yes
(boolean)
'N' NOAUDITOR Yes Yes Yes
AUTH 'Y' AUTHORITY (xx) Yes Yes No
CATEGORY 'Y' ADDCATEGORY(xx ...) Yes No Yes
(list NUMCTGY)
Note: A custom field (keyword and value type) is installation specific. On extract
requests the field descriptor mapping will contain the custom-keyword and the
associated data value.
Table 182. DCE segment fields
| Field name SAF field Flag ADDUSER/ALTUSER Allowed on Allowed on Returned
| name byte keyword reference add alter on extract
values requests requests requests
| AUTOLOG autolog 'Y' DCE(AUTOLOGIN (YES)) Yes Yes Yes
(boolean)
'N' DCE(AUTOLOGIN(NO)) Yes Yes Yes
| DCENAME dcename 'Y' DCE(DCENAME(xx)) Yes Yes Yes
'N' DCE(DCENAME ) No Yes Yes
| HOMECELL homecell 'Y' DCE(HOMECELL (xx)) Yes Yes Yes
'N' DCE(NOHOMECELL) No Yes Yes
| HOMEUUID homeuuid 'Y' DCE(HOMEUUID (xx)) Yes Yes Yes
'N' DCE(NOHOMEUUID) No Yes Yes
| UUID uuid 'Y' DCE(UUID(xx)) Yes Yes Yes
'N' DCE(NOUUID) No Yes Yes
Notes:
v For the ADMN_ALT_USER function, MFA fields are treated as a non-BASE
segment even though the fields reside in the BASE segment of the user profile.
v For the ADMN_XTR_USER function, MFA fields are returned in the BASE
segment. See Table 179 on page 425.
Table 189. NDS segment fields
| Field name SAF field Flag ADDUSER/ALTUSER Allowed on Allowed on Returned
| name byte keyword reference add alter on extract
values requests requests requests
UNAME 'Y' NDS(UNAME (xx)) Yes Yes Yes
'N' NDS(NOUNAME) No Yes Yes
Group administration
The following tables define field names and their usage. All field names relate
directly to the ADDGROUP and ALTGROUP keywords. Although the fields are
alphabetized in the following tables, there is no defined order in which fields are
returned when using the extract functions. See z/OS Security Server RACF Command
Language Reference for questions pertaining to field usage and data. Note that
within the command image generated internally, RACF truncates long keywords to
12 characters.
Boolean and list fields are identified in the field name column. Unless otherwise
noted, a field is a character field by default. For list fields, the list header field
returned by the extract function is also specified. Unless otherwise noted, all list
fields are 1-dimensional.
Table 197. BASE segment fields
| Field name SAF field Flag ADDGROUP/ALTGROUP Allowed Allowed Returned
| name byte keyword reference, or on add on alter on extract
values LISTGROUP heading (for requests requests requests
output-only fields)
CONNECTS N/A Note: This is the list header field No No Yes
for the 2-dimensional array
consisting of the following two
fields.
GAUTH N/A ACCESS= No No Yes
Boolean fields are identified in the field name column. Unless otherwise noted, a
field is a character field by default.
Table 203. Base segment fields
| Field name SAF field Flag CONNECT and REMOVE Allowed on Allowed on Returned
| name byte keyword reference , or CONNECT REMOVE on extract
values LISTUSER heading (for requests requests requests
output-only fields)
ADSP (boolean) 'Y' ADSP Yes No Yes
'N' NOADSP Yes No
AUDITOR 'Y' AUDITOR Yes No Yes
(boolean)
'N' NOAUDITOR Yes No
AUTH 'Y' AUTHORITY(xx) Yes No Yes
Boolean fields are identified in the field name column. Unless otherwise noted, a
field is a character field by default.
For add and alter, if working with a password-protected data set, append "/password? to the data set
profile name, and include this additional data in the length field for the data set profile name.
RETPD 'Y' RETPD (xx) Yes Yes No No
SECLABEL 'Y' SECLABEL (xx) Yes Yes No No
'N' NOSECLABEL No Yes No No
SECLEVEL 'Y' SECLEVEL (xx) Yes Yes No No
'N' NOSECLEVEL No Yes No No
SET (boolean) 'Y' SET Yes Yes No Yes
SETONLY 'Y' SETONLY Yes No No No
(boolean)
STATS (boolean) 'Y' STATISTICS No No Yes No
TAPE (boolean) 'Y' TAPE Yes No No No
UACC 'Y' UACC Yes Yes No No
UNIT 'Y' UNIT (xx) Yes Yes No No
VOLUME 'Y' VOLUME (xx ...) Yes Yes Yes Yes
'A' ADDVOL (xx ...) No Yes No No
'D' DELVOL (xx ...) No Yes No No
WARNING 'Y' WARNING Yes Yes No No
(boolean)
'N' NOWARNING No Yes No No
Boolean fields are identified in the field name column. Unless otherwise noted, a
field is a character field by default.
Table 223. Base segment fields
| Field name SAF field name Flag byte PERMIT keyword reference
values
| ACCESS access 'Y' ACCESS (xx)
DELETE (boolean) 'Y' DELETE
FCLASS 'Y' FCLASS (xx)
FPROFILE 'Y' FROM (xx)
FGENERIC (boolean) 'Y' FGENERIC
FVOLUME 'Y' FVOLUME (xx)
GENERIC (boolean) 'Y' GENERIC
| ID authid 'Y' ID (xx)
PROFILE 'Y' N/A (See note.)
NOTE: This field is required; there is no associated command keyword because it is a
positional parameter.
RESET 'Y' RESET (xx)
VOLUME 'Y' VOLUME (xx)
WHENAPPC 'Y' WHEN (APPCPORT (...))
WHENCONS 'Y' WHEN (CONSOLE ( ...))
WHENJES 'Y' WHEN (JESINPUT (...))
WHENPROG 'Y' WHEN (PROGRAM (...))
WHENSERV 'Y' WHEN(SERVAUTH(...))
| WHENSMS 'Y' WHEN(CRIT(SMS(...)))
WHENSQLR 'Y' WHEN(CRIT(SQLROLE(...)))
WHENSYS 'Y' WHEN (SYSID (...))
WHENTERM 'Y' WHEN (TERMINAL (...))
Boolean fields are identified in the field name column. Unless otherwise noted, a
field is a character field by default.
When SETROPTS extract returns the fields which contain a list of classes
(CLASSACT, CLASSTAT, GENCMD, GENERIC, GENLIST, GLOBAL, RACLIST,
AUDIT, LOGALWYS, LOGNEVER, LOGSUCC, LOGFAIL, AND LOGDEFLT), each
class name (including the final one) will be padded with blanks to eight characters,
and followed by a single blank. Therefore, you can determine the number of
classes by dividing the total field length by nine.
Table 224. BASE segment field names
Field name Flag byte SETROPTS keyword reference
value
ADDCREAT 'Y' ADDCREATOR
(boolean)
'N' NOADDCREATOR
ADSP (boolean) 'Y' ADSP
'N' NOADSP
APPLAUDT 'Y' APPLAUDIT
(boolean)
'N' NOAPPLAUDIT
AUDIT 'A' AUDIT (xx ...)
'D' NOAUDIT (xx ...)
CATDSNS 'Y' CATDSNS ( xx )
'N' NOCATDSNS
CLASSACT 'A' CLASSACT (xx ...)
'D' NOCLASSACT (xx ...)
CLASSTAT 'A' STATISTICS (xx ...)
'D' NOSTATISTICS (xx ...)
CMDVIOL 'Y' CMDVIOL
(boolean)
'N' NOCMDVIOL
COMPMODE 'Y' COMPATMODE
(boolean)
'N' NOCOMPATMODE
EGN (boolean) 'Y' EGN
'N' NOEGN
ERASE (boolean) 'Y' ERASE
'N' NOERASE
ERASEALL 'Y' ERASE (ALL)
(boolean)
For example, if the RULE1 field is specified with field data of "3:6 A*NV*A", the resulting
SETROPTS PASSWORD keyword would be RULE1(LENGTH(3:6) ALPHA(1 6)
NUMERIC(3) VOWEL(4)).
See the z/OS Security Server RACF Command Language Reference for details on SETROPTS.
RVARSWPW 'Y' RVARY ( SWITCH ( xx ))
NOTE: For ADMN_XTR_SETR, the value returned for this field is not the actual password,
but one of two predefined values. A value of "DEFAULT" indicates that the default
password in in effect, while a value of "INSTLN" indicates that an installation-defined
password is in effect.
RVARSTPW 'Y' RVARY ( STATUS ( xx ) )
NOTE: For ADMN_XTR_SETR, the value returned for this field is not the actual password,
but one of two predefined values. A value of "DEFAULT" indicates that the default
password in in effect, while a value of "INSTLN" indicates that an installation-defined
password is in effect.
SAUDIT 'Y' SAUDIT
(boolean)
'N' NOSAUDIT
SECLABCT 'Y' SECLABELCONTROL
(boolean)
'N' NOSECLABELCONTROL
SECLANG 'Y' LANGUAGE (SECONDARY ( xx ) )
SESSINT 'Y' SESSIONINTERVAL ( xx )
'N' NOSESSIONINTERVAL
SLABAUDT 'Y' SECLABELAUDIT
(boolean)
'N' NOSECLABELAUDIT
SLBYSYS 'Y' SECLBYSYSTEM
(boolean)
'N' NOSECLBYSYSTEM
If you experience difficulty with the accessibility of any z/OS information, send a
detailed message to the Contact z/OS web page (www.ibm.com/systems/z/os/
zos/webqs.html) or use the following mailing address.
IBM Corporation
Attention: MHVRCFS Reader Comments
Department H6MA, Building 707
2455 South Road
Poughkeepsie, NY 12601-5400
United States
Accessibility features
Accessibility features help users who have physical disabilities such as restricted
mobility or limited vision use software products successfully. The accessibility
features in z/OS can help users do the following tasks:
v Run assistive technology such as screen readers and screen magnifier software.
v Operate specific or equivalent features by using the keyboard.
v Customize display attributes such as color, contrast, and font size.
Each line starts with a dotted decimal number; for example, 3 or 3.1 or 3.1.1. To
hear these numbers correctly, make sure that the screen reader is set to read out
The dotted decimal numbering level denotes the level of nesting. For example, if a
syntax element with dotted decimal number 3 is followed by a series of syntax
elements with dotted decimal number 3.1, all the syntax elements numbered 3.1
are subordinate to the syntax element numbered 3.
Certain words and symbols are used next to the dotted decimal numbers to add
information about the syntax elements. Occasionally, these words and symbols
might occur at the beginning of the element itself. For ease of identification, if the
word or symbol is a part of the syntax element, it is preceded by the backslash (\)
character. The * symbol is placed next to a dotted decimal number to indicate that
the syntax element repeats. For example, syntax element *FILE with dotted decimal
number 3 is given the format 3 \* FILE. Format 3* FILE indicates that syntax
element FILE repeats. Format 3* \* FILE indicates that syntax element * FILE
repeats.
The following symbols are used next to the dotted decimal numbers.
? indicates an optional syntax element
The question mark (?) symbol indicates an optional syntax element. A dotted
decimal number followed by the question mark symbol (?) indicates that all
the syntax elements with a corresponding dotted decimal number, and any
subordinate syntax elements, are optional. If there is only one syntax element
with a dotted decimal number, the ? symbol is displayed on the same line as
the syntax element, (for example 5? NOTIFY). If there is more than one syntax
element with a dotted decimal number, the ? symbol is displayed on a line by
itself, followed by the syntax elements that are optional. For example, if you
hear the lines 5 ?, 5 NOTIFY, and 5 UPDATE, you know that the syntax elements
NOTIFY and UPDATE are optional. That is, you can choose one or none of them.
The ? symbol is equivalent to a bypass line in a railroad diagram.
! indicates a default syntax element
The exclamation mark (!) symbol indicates a default syntax element. A dotted
decimal number followed by the ! symbol and a syntax element indicate that
the syntax element is the default option for all syntax elements that share the
same dotted decimal number. Only one of the syntax elements that share the
dotted decimal number can specify the ! symbol. For example, if you hear the
lines 2? FILE, 2.1! (KEEP), and 2.1 (DELETE), you know that (KEEP) is the
Notes:
1. If a dotted decimal number has an asterisk (*) next to it and there is only
one item with that dotted decimal number, you can repeat that same item
more than once.
2. If a dotted decimal number has an asterisk next to it and several items
have that dotted decimal number, you can use more than one item from the
list, but you cannot use the items more than once each. In the previous
example, you can write HOST STATE, but you cannot write HOST HOST.
3. The * symbol is equivalent to a loopback line in a railroad syntax diagram.
+ indicates a syntax element that must be included
The plus (+) symbol indicates a syntax element that must be included at least
once. A dotted decimal number followed by the + symbol indicates that the
syntax element must be included one or more times. That is, it must be
included at least once and can be repeated. For example, if you hear the line
6.1+ data area, you must include at least one data area. If you hear the lines
2+, 2 HOST, and 2 STATE, you know that you must include HOST, STATE, or
both. Similar to the * symbol, the + symbol can repeat a particular item if it is
the only item with that dotted decimal number. The + symbol, like the *
symbol, is equivalent to a loopback line in a railroad syntax diagram.
IBM may not offer the products, services, or features discussed in this document in
other countries. Consult your local IBM representative for information on the
products and services currently available in your area. Any reference to an IBM
product, program, or service is not intended to state or imply that only that IBM
product, program, or service may be used. Any functionally equivalent product,
program, or service that does not infringe any IBM intellectual property right may
be used instead. However, it is the user's responsibility to evaluate and verify the
operation of any non-IBM product, program, or service.
IBM may have patents or pending patent applications covering subject matter
described in this document. The furnishing of this document does not grant you
any license to these patents. You can send license inquiries, in writing, to:
The following paragraph does not apply to the United Kingdom or any other
country where such provisions are inconsistent with local law:
INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS
PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS
FOR A PARTICULAR PURPOSE. Some states do not allow disclaimer of express or
implied warranties in certain transactions, therefore, this statement may not apply
to you.
IBM may use or distribute any of the information you supply in any way it
believes appropriate without incurring any obligation to you.
Licensees of this program who wish to have information about it for the purpose
of enabling: (i) the exchange of information between independently created
programs and other programs (including this one) and (ii) the mutual use of the
information which has been exchanged, should contact:
IBM Corporation
Site Counsel
2455 South Road
Poughkeepsie, NY 12601-5400
USA
The licensed program described in this document and all licensed material
available for it are provided by IBM under terms of the IBM Customer Agreement,
IBM International Program License Agreement or any equivalent agreement
between us.
All statements regarding IBM's future direction or intent are subject to change or
withdrawal without notice, and represent goals and objectives only.
This information contains examples of data and reports used in daily business
operations. To illustrate them as completely as possible, the examples include the
names of individuals, companies, brands, and products. All of these names are
fictitious and any similarity to the names and addresses used by an actual business
enterprise is entirely coincidental.
Applicability
These terms and conditions are in addition to any terms of use for the IBM
website.
Personal use
You may reproduce these publications for your personal, noncommercial use
provided that all proprietary notices are preserved. You may not distribute, display
or make derivative work of these publications, or any portion thereof, without the
express consent of IBM.
Commercial use
You may reproduce, distribute and display these publications solely within your
enterprise provided that all proprietary notices are preserved. You may not make
derivative works of these publications, or reproduce, distribute or display these
publications or any portion thereof outside your enterprise, without the express
consent of IBM.
Rights
IBM reserves the right to withdraw the permissions granted herein whenever, in its
discretion, the use of the publications is detrimental to its interest or, as
determined by IBM, the above instructions are not being properly followed.
You may not download, export or re-export this information except in full
compliance with all applicable laws and regulations, including all United States
export laws and regulations.
Notices 465
NON-INFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE.
Depending upon the configurations deployed, this Software Offering may use
session cookies that collect each user’s name, email address, phone number, or
other personally identifiable information for purposes of enhanced user usability
and single sign-on configuration. These cookies can be disabled, but disabling
them will also eliminate the functionality they enable.
If the configurations deployed for this Software Offering provide you as customer
the ability to collect personally identifiable information from end users via cookies
and other technologies, you should seek your own legal advice about any laws
applicable to such data collection, including any requirements for notice and
consent.
For more information about the use of various technologies, including cookies, for
these purposes, see IBM’s Privacy Policy at ibm.com/privacy and IBM’s Online
Privacy Statement at ibm.com/privacy/details in the section entitled “Cookies,
Web Beacons and Other Technologies,” and the “IBM Software Products and
Software-as-a-Service Privacy Statement” at ibm.com/software/info/product-
privacy.
Trademarks
IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of
International Business Machines Corp., registered in many jurisdictions worldwide.
Other product and service names might be trademarks of IBM or other companies.
A current list of IBM trademarks is available at Copyright and Trademark
information (www.ibm.com/legal/copytrade.shtml).
Notices 467
468 z/OS Security Server RACF Callable Services
Index
Special characters D GIDs
effective
_POSIX_CHOWN_RESTRICTED 162 data field name parameter list 72 set 217
_POSIX_SAVED_IDS 70 Data set administration 448 get 33
delete USP 29 saved
set 217
A group
access E change 162
check 11 effective UID Group administration 436
control 385 set 383 Group connection administration 438
IPC effective UIDs/GIDs group name
check 18 set 217 GID to
access control lists 385 exit get mapping 31
Access list administration 451 installation groups
accessibility 459 IRRSXT00 417 get
contact IBM 459 by name 250
features 459 supplemental
ACEE
initialize 39
F get 33, 247
set 247
factor
administration, RACF
authentication 220
classroom courses xv
file identifiers
all UIDs
description 4 I
set 383 IFSP
detecting in audit stream 4
assistive technologies 459 make 59
file mode
audit 120, 122 IFSP (file security packet)
change 160
audit options description 2
creation mask
change 157 IFSP data area
set 403
file mode values, bit mapping for 4 description 2
file owner IFSP, root
B check 15 make 65
bit mappings file security options, query 68 IISP
file mode values 4 file security packet (IFSP) make 62
BPXYIPCP mapping macro 6 description 2 IISP (IPC security packet)
files description 5
check owner of two 20 IISP data area
C fork
a process 229
description 5
initialize ACEE 39
cache 133 initialize USP 55
function 220
change audit options 157 installation exit
change file mode 160 IRRSXT00 417
change owner and group 162
check access 11 G IPC access
check 18
check file owner 15 Gen IPC control 258
check IPC access 18 Sec 232 IPC security credentials (CREI)
check owner of two files 20 General resource administration 439 description 7
check privilege 23 get IPC security packet (IISP)
check process owner 25 GID-to-group-name mapping 31 description 5
classroom courses, RACF xv GIDs 33 IRRPCRED macro 2
clear set ID 27 groups IRRPCREI data area
contact by name 250 description 7
z/OS 459 supplemental groups 33 IRRPIFSP macro 2
Contents of an encrypted password or UIDs 33 IRRPIISP macro 5
password phrase envelope 114 get supplemental groups 247 IRRPWORK macro 1
courses about RACF xv get UID-to-user-ID mapping 36 IRRSAU00 9, 120
CRED (security credentials) get user factor data 228 IRRSAX00 9
description 2 getGMAP 31 IRRSAX64 122
CRED data area getUMAP 36 IRRSC200 9, 20
description 2 GID-to-group-name mapping IRRSCA00 9, 157
CREI (IPC security credentials) get 31 IRRSCF00 9, 160
description 7 IRRSCH00 9, 133
IRRSCI00 9, 258
T
tables 421
TME
administration 72
trademarks 467
U
UID
effective
set 383
UID-to-user-ID mapping, get 36
UIDs
all
set 383
effective
set 217
Index 471
472 z/OS Security Server RACF Callable Services
IBM®
Printed in USA
SA23-2293-30