Setting Security Parameters from COBOL Applications

In the case of Basic Authentication and OAuth 2.0 password grant flow, it is recommended to send the values (user ID, user password, access token) from the COBOL application instead of entering the values in the configuration file. This is important because the User ID and User Password are user-specific parameters and should be managed from the COBOL application.

You can use the user ID and user password parameters specified in the COBOL copy book to send these credentials to the ePortal proxy service.

    03  REFERENCESCOUNTRIESBYCOUNTRYCO REDEFINES REQ-BUFFER.
     05  USER-DATA.
        07  ACCESSTOKEN-LENGTH, PIC 9(5).
        07  ACCESSTOKEN PIC X(100).
        07  USERID-LENGTH, PIC 9(5).
        07  USERID PIC X(100).
        07  PASSWORD-LENGTH, PIC 9(5).
07  PASSWORD PIC X(100).

For OAuth 2.0, the access token parameter is included in the USER-DATA area of the copy book and it can be used for OAuth 2.0 supported specifications. Following are the recommended methods to handle access token for OAuth 2.0: