You can use the GNTRAN system initialization parameter to specify a "good night" transaction that you want CICS® to invoke when a user’s terminal-timeout period expires. The default value for GNTRAN is 'NO', which means that CICS does not schedule a "good night" transaction, but instead tries to sign off the terminal user. (Whether or not the sign off is successful depends on the value of the SIGNOFF attribute on the terminal’s TYPETERM definition.)
For further information about GNTRAN, see the CICS System Definition Guide.
Writing your own "good night" program allows you to include functions in addition to, or instead of, sign-off. For example, your program could prompt the terminal user to enter their password, and allow the session to continue if the correct response is received. CICS supplies a sample "good night" program, DFH0GNIT, that demonstrates this, and a sample transaction definition, GNIT, that points to DFH0GNIT.
CICS passes the "good night" program a parameter list in the communications area shown in Figure 110. If a terminal times out during a pseudoconversational transaction, your program could, using information in the parameter list: