)ATTR
 _ TYPE(INPUT)  INTENS(HIGH) CAPS(ON) PADC(_)
 ~ TYPE(INPUT)  INTENS(LOW) CAPS(OFF) PADC(_)
 ^ AREA(SCRL) EXTEND(ON)
 # TYPE(OUTPUT) INTENS(HIGH) SKIP(ON) CAPS(OFF)
 $ TYPE(OUTPUT) INTENS(HIGH) COLOR(RED) SKIP(ON) CAPS(OFF)
 @ TYPE(OUTPUT) INTENS(LOW)  SKIP(ON) CAPS(OFF)
)BODY WIDTH(80) EXPAND("")
%"-" Security Readiness Review Self-Audit "-"+
%" "Asset Definition Process" "+
@PGM8     %       " "Version:@SRRVERS +
%Option ===>_OPT
$SRRMSG
$SRRMSG1
%                     Key Fields for Asset Definition Process.
+  Host Name:$HOSTNAME                       +  SYSNAME:$ZSYSID
+  Operating System:$OPSNAME                 +  ACP:$ACPNAME
%  Optional key field,+the first 4 IP addresses, if available, are shown.
+      #IPADD1         #IPADD2         #IPADD3         #IPADD4
^VMSAREA                                                                    ^
%EXIT+(PF3) to end with no action.     %CREATE+to create asset file.
%SAVE+to save above information.
%
)AREA VMSAREA DEPTH(5)
%                  Additional Fields for Asset Definition Process.
%  Description:    ~DESC
%  Classification: ~Z+  %  MAC:            ~Z+  %  Confidentiality:~Z+
%  Status:         ~Z+  %  Use:            ~Z+
%  Building:       ~BLDG
%  Room:           ~ROOM
%  Serial Number:  ~SERNR
%  Barcode:        ~BARCD
%  Make:           ~MAKE
%  Model:          ~MODEL
%  Manufacturer:   ~MANUF
)INIT
 .HELP = SRRHADMV
 .ZVARS = '(CLASS MAC CONF STATUS USE)'
 .CURSOR = OPT
 &ZERRALRM = YES
 &ZERRHM = SRRHADMV
 VGET(HOSTNAME IPADD1 IPADD2 IPADD3 IPADD4) ASIS
)REINIT
 REFRESH(*)
 .CURSOR = OPT
 .ZVARS = '(CLASS MAC CONF STATUS USE)'
 &ZERRHM = SRRHADMV
)PROC
&ZERRSM = 'Invalid value specified'
IF (VER(&HOSTNAME,NB) OR VER(&IPADD1,NB))
  GOTO CLASS
&ZERRSM = 'Error occurred'
&ZERRLM = 'Error occurred in UNIX System Services collecting HOSTNAME +
  and/or IP Address(es).'
.MSG=ISRZ002
&OPT = 'END'
EXIT
CLASS:
IF (VER(&CLASS,NB,LIST,0,1,2))
  GOTO MAC
&ZERRLM = 'Specify 0 - Secret, 1 - Confidential, or 2 - Unclassified'
.MSG=ISRZ002
EXIT
MAC:
IF (VER(&MAC,NB,LIST,0,1,2))
  GOTO CONF
&ZERRLM = 'Specify 0 - MAC I, 1 - MAC II, 2 - MAC III'
.MSG=ISRZ002
EXIT
CONF:
IF (VER(&CONF,NB,LIST,1,2,3))
  GOTO STATUS
&ZERRLM = 'Specify 1 - Public, 2 - Sensitive, 3 - Confidential'
.MSG=ISRZ002
EXIT
STATUS:
IF (VER(&STATUS,NB,LIST,1,2))
  GOTO VER
&ZERRLM = 'Specify 1 - Online, 2 - Offline'
.MSG=ISRZ002
EXIT
VER:
IF (VER(&USE,NB,LIST,1,2,3))
  GOTO BYPASS
&ZERRLM = 'Specify 1 - Production, 2 - Support, 3 - Test/Development'
.MSG=ISRZ002
EXIT
BYPASS:
IF (.RESP = END)   &OPT = END
IF (.RESP = EXIT)  &OPT = END
IF (&OPT = ' ' & .RESP = ENTER)
  &ZERRSM = 'Invalid option specified'
  &ZERRHM = SRRHADMV
  &ZERRLM = 'Specify END - Exit, CREATE - Create Asset file, or SAVE - Save +
    information'
  .MSG=ISRZ002
  EXIT
&ZSEL = TRANS (TRUNC (&OPT,'.')
  END,EXIT
  CREATE,EXIT
  SAVE,EXIT)
)END
