//FSOJCL    JCLLIB ORDER=(&SRRHLQ..CNTL)
//TSSINSTX SET TSSINSTX=SYS2A.TSS.CAILOAD
//*  Ensure that the above SET specifies the data set that contains
//*  the TSSINSTX module.
//*--------------------------------------------------------------------
//*-------------------------->> TSSCMDS  <<----------------------------
//*--------------------------------------------------------------------
//*                         TSS COMMANDS
//*
//*  IMPORTANT:  Copy member JOBCARD to the beginning of this job.
//*
//*  This job executes multiple TSS commands and saves the output in
//*  individual pds members.
//*
//*  STEP1:           Removes previous runs datasets
//*  STEP3:           Runs a BATCH TMP, executes a CLIST to collect
//*                   the WHOOWNS and WHOHAS information from TSS.
//*  STEP4 - STEP22:  Each step runs a BATCH TMP, executes TSS
//*                   command(s), and stores the output in an
//*                   individual pds member.
//*  STEP23:          Execute IDCAMS DUMP of member TSSINSTX, ensure
//*                   that the SET TSSINSTX= specifies the dataset
//*                   that contains the TSSINSTX member, refer to
//*                   EXAM.RPT member MVSXRPT for the location of this
//*                   member.
//*  STEP24:          Executes SAFCRRPT to collect Certificates.
//*
//*    ===> NOTE:     TSS command error messages will be located in
//*                   the pds members used to hold the command output.
//*
//*                   Review all pds members to ensure proper
//*                   execution.
//*
//*  ===> IMPORTANT:  Perform the following steps before submitting
//*                   this job for execution:
//*
//*       1)  Change the SET TSSINSTX= to specify the data that
//*           contains the TSSINSTX module.  To obtain the proper data
//*           set name, refer to &SRRHLQ..EXAM.RPT(MVSXRPT).
//*--------------------------------------------------------------------
//STEP1     EXEC PGM=IEFBR14
//*
//TSSCMDS   DD DSN=&SRRHLQ..TSSCMDS.RPT,
//             DISP=(MOD,DELETE,DELETE),
//             SPACE=(TRK,0),UNIT=SYSDA
//TSSDUMP   DD DSN=&SRRHLQ..TSSDUMP.RPT,
//             DISP=(MOD,DELETE,DELETE),
//             SPACE=(TRK,0),UNIT=SYSDA
//TSSACIDS  DD DSN=&SRRHLQ..TSSACIDS,
//             DISP=(MOD,DELETE,DELETE),
//             SPACE=(TRK,0),UNIT=SYSDA
//STEP3     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//CNTL      DD DSN=&SRRHLQ..CNTL,
//             DISP=SHR
//OUTPUT    DD DSN=&SRRHLQ..TSSCMDS.RPT,
//             DISP=(,CATLG,DELETE),
//             DCB=(RECFM=VBA,LRECL=137,BLKSIZE=27920,DSORG=PO),
//             SPACE=(CYL,(50,10,10)),
//             UNIT=(SYSDA,1)
//SYSTSIN   DD *
  ISPSTART CMD(%CATC1001)
/*
//STEP4     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@ACIDS),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(USER)
/*
//STEP5     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@SCA),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(SCA)
/*
//STEP6     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@LSCA),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(LSCA)
/*
//STEP7     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@ZCA),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(ZCA)
/*
//STEP8     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@VCA),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(VCA)
/*
//STEP9     EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@DCA),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL,PA) TYPE(DCA)
/*
//STEP9A    EXEC PGM=IEBGENER
//SYSIN     DD DUMMY
//SYSPRINT  DD SYSOUT=*
//SYSUT1    DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@SCA)
//          DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@LSCA)
//          DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@ZCA)
//          DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@VCA)
//          DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@DCA)
//SYSUT2    DD DISP=SHR,DSN=&SRRHLQ..TSSCMDS.RPT(@ALL)
//STEP10    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@ZONES),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL) TYPE(ZONE)
/*
//STEP11    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@DIVS),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL) TYPE(DIV)
/*
//STEP12    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@DEPTS),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL) TYPE(DEPT)
/*
//STEP13    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@PROFS),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL) TYPE(PROF)
/*
//STEP14    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@ADMIN),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIS(ACIDS) DATA(ADMIN)
/*
//STEP15    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(@GROUP),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(ALL) TYPE(GROUP)
/*
//STEP16    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(#AUDIT),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIS(AUDIT)
/*
//STEP17    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(#RDT),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIS(RDT)
/*
//STEP18    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(#STC),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIS(STC)
/*
//STEP19    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(#ALL),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIS(ALL)
/*
//STEP20    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT($DSN),
//             DISP=SHR
//SYSTSIN   DD *
 TSS WHOH DSN(****)
/*
//STEP21    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(OMVSUSER),
//             DISP=SHR
//SYSTSIN   DD *
 TSS LIST(ACIDS) DATA(NAME) SEGMENT(OMVS)
/*
//STEP22    EXEC EXAMRPTS,
//             CNTL=&SRRHLQ..CNTL
//SYSTSPRT  DD DSN=&SRRHLQ..TSSCMDS.RPT(STATUS),
//             DISP=SHR
//SYSTSIN   DD *
 TSS MODIFY(ST)
/*
//STEP23    EXEC PGM=IDCAMS
//SYSPRINT  DD SYSOUT=*
//CAILIB    DD DSN=&TSSINSTX(TSSINSTX),
//             DISP=SHR
//TSSRPT2   DD DSN=&SRRHLQ..TSSDUMP.RPT(TSSINSTX),
//             DISP=(,CATLG,DELETE),
//             DCB=(RECFM=VBA,LRECL=125,BLKSIZE=27875),
//             SPACE=(TRK,(5,1,1)),
//             UNIT=SYSALLDA
//SYSIN     DD *
 PRINT -
  INFILE(CAILIB) -
  OUTFILE(TSSRPT2) -
  DUMP SKIP(5)
/*
//*
//STEP24   EXEC PGM=SAFCRRPT,PARM='TITLE(CERTIFICATE DETAILED REPORT)',
//         REGION=0M
//SYSUDUMP  DD SYSOUT=*
//SYSPRINT  DD DSN=&SRRHLQ..TSSCMDS.RPT(CERTRPT),
//             DISP=SHR
//SYSIN     DD *
RECORDID(-) DETAIL FIELDS(ISSUER SUBJECT ACTIVE EXPIRE TRUST)
/*
//*
