User Exits › Exit Routine Programming Considerations › MIMATHXT Exit
MIMATHXT Exit
You can use the optional MIMATHXT exit routine to augment the command authorization processing provided by CA MIM and the operating system security subsystem. The MIMATHXT is called only when the MIMINIT SAFCMDAUTH statement has activated CA MIM command authorization.
CA MIM calls the MIMATHXT exit routine after all parameters have been set for command validation by the security system, but before the actual system authorization facility (SAF) call is made.
You can use this exit routine to determine whether CA MIM should:
- Unconditionally permit command execution
- Unconditionally reject commands
- Conditionally permit command execution based on the security system decision
You can alter the command entity name or the UTOKEN that CA MIM passes to the security system for command authorization. You cannot alter the command text from this exit routine.
Follow these rules when coding the MIMATHXT routine:
- Preserve all registers except registers 0, 1, and 15.
- Review all code you define in this routine to prevent abends from occurring. CA MIM may try to recover from abends but can terminate if it experiences repeated abends.
- Do not use the z/OS OPEN, CLOSE, LOAD, LINK, BLDL, or TSO facilities, or any other z/OS facility that implicitly or explicitly calls the WAIT supervisor.
- Do not use the STIMER or TTIMER macros.
- Make sure that you interpret the command name properly when intercepting a command with this routine.
- Cross-system commands are stripped of their command characters by the time the routine intercepts them. Also, command aliases are converted to the new command name (and parameters). Therefore, base your comparisons on the true command rather than on any aliases you have defined for that command.
- Use the EXIT parameter on the SETOPTION command to identify the appropriate load module for the MIMATHXT routine. For example, specify SETOPTION EXIT=MIMATHXT when the module name is MIMATHXT. If you use a different module name, then specify EXIT=MIMATHXT and specify the module name on the LOAD parameter. For example, to use the load module UEXIT1 for the MIMATHXT routine, specify the command SETOPTION EXIT=(MIMATHXT LOAD=UEXIT1).
Assemble and link-edit the completed routine as an authorized program with the module name you specify on the SETOPTION command. Link-edit the routine into the authorized load library for CA MIM. The sample member named ASMEXIT in the CAI.CBTDJCL data set contains JCL that you can use to assemble and link-edit this routine.
Note: For more information, see the Statement and Command Reference Guide.