NET/MASTER RMS Management and Operations Guide

Implementing the Security Exit NCL Procedure to Control Access
Planning for, Installing, and Managing RMS
3–12 115415 NonStop NET/MASTER RMS Management and Operations Guide
Customizing ZRMSSECN Customize the NCL procedure ZRMSSECN as follows:
1. Edit ZRMSSECN and search for the text string gosub .SECCHK.
2. Add */ and /* around gosub .SECCHK as shown below to make the NCL core
statement executable (modification is in boldface):
/*
*/ gosub .SECCHK /* INSTALLATION ATTRIBUTE SECURITY CHECK
- or -
gosub .NCLCHK USERWRITTEN SECURITY CHECK.
*/
3. Search for .SECCHK: and add your security checking code after the .SECCHK:
label. In the following example, the NCL procedure ensures that the value of the
&OPTION variable is RMS (the user is attempting to access RMS), checks a
character in the user installation attributes, and sets the &SYS.RETCODE to 16 if
the character is not Y. The character controls access to RMS from the NonStop
NET/MASTER MS primary menu panel.
.SECCHK:
SECCALL QUERY MDO=&RMS. /* Retrieve user ID definition of user to
MDO variable &RMS. */
IF &OPTION=RMS THEN /* Access to RMS requested? */
&ACCESS=LEFT(&RMS.INSTALL_ATTR2,1) /* Get the first character in INSTALL_
ATTR2 element to variable &ACCESS */
IF &ACCESS\=Y THEN /* Deny access? */
&SYS.RETCODE=16 /* Set code to 16 to deny access */
RETSUB
Refer to the NonStop NET/MASTER NCL Programmer’s Guide for information on how
to develop NCL procedures.
Security Exit Variable
&OPTION
Use the &OPTION variable to identify which RMS option a user has selected. Table
3-1 lists the &OPTION values and the corresponding RMS options.
Table 3-1. &OPTION Values (Page 1 of 3)
Value RMS Option
MHS Use the message handler ZRMSMGHN: for example, when you start a message handler
using NonStop NET/MASTER MS commands
RMS RMS Services on NonStop NET/MASTER MS primary menu panel
1.0 Start RMS Message Handler on NonStop NET/MASTER RMS primary menu panel
1.E Start a Message Handler as EMSPROC on RMS : Start Message Handler panel
1.L Start a Message Handler as LOGPROC on RMS : Start Message Handler panel