WebSphere Application Server & Liberty

 View Only
Expand all | Collapse all

Open Liberty Datasource and access to DB2 LUW using securityMechanism=19 (JWT token auth)

  • 1.  Open Liberty Datasource and access to DB2 LUW using securityMechanism=19 (JWT token auth)

    Posted Fri November 10, 2023 10:05 AM

    Hi everyone,

     

    in our system we are using DB2 LUW and Open Liberty.

     For authentication to DB2 we want to use JWT tokens.

    We have enabled JWT token auth in DB2 and we can connect, e.g. using DB clients like DBVisualizer.

    In order to connect we need to specify the jdbc driver property: securityMechanism=19

     

    However, according to the documentation of the Open Liberty Datasource
    https://openliberty.io/docs/latest/reference/config/dataSource.html
    ("dataSource > properties.db2.jcc")

    there is no support for this value "19" only for max. "18".

     

    The question is now how we can then connect to DB2 with JWT token auth using the datasource.

    Is there a workaround / newer version / other set-up etc.?

     

    We would be grateful for any hint on this!

     

    Thanks and best regards,

    Andreas Geßner



    ------------------------------
    Andreas Geßner
    ------------------------------


  • 2.  RE: Open Liberty Datasource and access to DB2 LUW using securityMechanism=19 (JWT token auth)

    Posted Mon January 08, 2024 08:56 AM

    Good news, we found a solution: Instead of using the properties.db2.jcc configuration elements, we use the properties element and set securityMechanism="19" and accessTokenType="JWT" etc.

     



    ------------------------------
    Andreas Geßner
    ------------------------------