Previous Topic: SETADDR()Next Topic: SETRC()


SECURITY()

This function validates a user ID and password or changes the authority for an IMOD task to that of a different user ID.

Syntax

SECURITY({VERIFY|LOGON},userid,password,[newpass])

Parameters

VERIFY

Checks the user ID/password combination for validity.

LOGON

Checks the user ID/password combination for validity and, if valid, the IMOD task continues execution under the authority of the new user ID.

userid

User ID known to the system security software.

password

Password that authorizes the user ID.

newpass

The new password. If userid and password are correct, newpass replaces password.

Note: The system security software permanently records this change.

Usage Notes

Return Codes

101 - 104

ARG n MISSING OR INVALID

121

RACROUTE FAILED: saf_rc racf_rc racf_re

saf_rc

The return code as set by SAF

racf_rc

The return code as set by RACF

racf_re

The reason code as set by RACF

Example

parse arg userid password
result = security('logon',userid,password)
 if rc ^= 0 then return 'LOGON REJECTED'
return 'LOGON SUCCESSFUL'