Reusing a remote trusted connection through Db2 for z/OS servers

The Db2 for z/OS® server performs a sequence of tasks when it receives a request to switch users on a trusted connection.

About this task

The Db2 z/OS server performs these tasks in the following sequence:

  1. Db2, on successful authorization, invokes the connection exit routine. The invocation associates the primary authorization ID, possibly one or more secondary authorization IDs, and an SQL ID with the remote request. This new set of IDs replaces the previous set of IDs that was associated with the request.
  2. Db2 determines if the primary authorization ID is allowed to use the trusted connection. If the WITH AUTHENTICATION clause is specified for the user, Db2 requires an authentication token for the user. The authentication token can be a password, a RACF® passticket, or a Kerberos ticket.
  3. Assuming that the primary authorization ID is allowed, Db2 determines the trusted context for any SECURITY LABEL definition. If a specific SECURITY LABEL is defined for this user, it becomes the SECURITY LABEL for this user. If no specific SECURITY LABEL is defined for this user but a DEFAULT SECURITY LABEL is defined for the trusted context, Db2 verifies the validity of this SECURITY LABEL for this user through RACF by issuing the RACROUTE VERIFY request.

    If the primary authorization ID is allowed, Db2 performs a connection initialization. This results in an application environment that truly mimics the environment that is initialized if the new user establishes the connection in the normal Db2 manner. For example, any open cursor is closed, and temporary table information is dropped.

  4. If the primary authorization ID is not allowed to use the trusted connection or if SECURITY LABEL verification fails, the connection is returned to an unconnected state. The only operation that is allowed is to establish a valid authorization ID to be associated with the trusted connection. Until a valid authorization is established, if any SQL statement is issued, an error (SQLCODE -900) is returned.