IC SunsetThe developerWorks Connections Platform is now in read-only mode and content is only available for viewing. No new wiki pages, posts, or messages may be added. Please see our FAQ for more information. The developerWorks Connections platform will officially shut down on March 31, 2020 and content will no longer be available. More details available on our FAQ. (Read in Japanese.)
Topic
  • 1 reply
  • Latest Post - ‏2019-11-22T08:56:40Z by bayliss
Leo Mathew
Leo Mathew
8 Posts

Pinned topic Basic Authentication to a RESTful API endpoint

‏2019-11-21T09:01:10Z | zosconnect

Is there a way to send the Username and password for basic authentication from a CICS program to an API Provider and not from zOS connect?

 

We would like to avoid that the Username and password is hardcoded in the server.xml file when CICS is an API Consumer. 

 

 

  • bayliss
    bayliss
    37 Posts
    ACCEPTED ANSWER

    Re: Basic Authentication to a RESTful API endpoint

    ‏2019-11-22T08:56:40Z  

    @Leo Mathew

    Hello Leo,

    There is no current support in z/OS Connect EE for propagating a user ID used to authenticate between a CICS application and the z/OS Connect EE server on to a RESTful API endpoint.

    If your API provider (RESTful API endpoint) requires basic authentication, then you will need to define the user ID and password to be used in the server.xml file as you have seen.

    If your API provider supported an alternative authentication/authorization method, for example JSON Web Tokens (JWT) or OAuth 2.0, then the z/OS Connect EE server can be configured to use user ID and password credentials sent from the CICS application to obtain a JWT or OAuth 2.0 access token (which contains details about the user used to obtain the token), and then send that token to the API provider. JWT is often used as an authentication mechanism for RESTful APIs.

     

    Regards Sue

    IBM z/OS Connect EE

     

  • bayliss
    bayliss
    37 Posts

    Re: Basic Authentication to a RESTful API endpoint

    ‏2019-11-22T08:56:40Z  

    @Leo Mathew

    Hello Leo,

    There is no current support in z/OS Connect EE for propagating a user ID used to authenticate between a CICS application and the z/OS Connect EE server on to a RESTful API endpoint.

    If your API provider (RESTful API endpoint) requires basic authentication, then you will need to define the user ID and password to be used in the server.xml file as you have seen.

    If your API provider supported an alternative authentication/authorization method, for example JSON Web Tokens (JWT) or OAuth 2.0, then the z/OS Connect EE server can be configured to use user ID and password credentials sent from the CICS application to obtain a JWT or OAuth 2.0 access token (which contains details about the user used to obtain the token), and then send that token to the API provider. JWT is often used as an authentication mechanism for RESTful APIs.

     

    Regards Sue

    IBM z/OS Connect EE