Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-13411

Exception while connecting from kafka client consumer producers deployed in a wildfly context to a kafka broker implementing OAUTHBEARER sasl mechanism

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • 3.0.0
    • None
    • security
    • None
    • Windows, Linux , Wildfly Application server

    Description

      I have set up a Kafka cluster on my linux machine secured using keycloak
      (OAUTHBEARER) Mechanism. I can use the Kafka Console Consumers and
      Producers to send and receive messages.

       

      I have tried to connect to Kafka from my consumers and producers deployed
      as module on the wildfly App serve (version 19, java 11) . I have set up
      all the required configuration (Config Section at the bottom) .

      The SASL_JAAS_CONFIG provided as consumerconfig option has the details
      like (apache.kafka.common.security.oauthbearer.OAuthBearerLoginModule
      required LoginStringClaim_sub='kafka-client');

       

      I am able to get authenticated with the broker , but in the client callback
      I am getting an Unsupported Callback error . I have 3 modules in wildfly

      1) kafka producer consumer code dependent on the 2) oauth jar (for
      logincallbackhandler and login module) dependent on the 3) kafka-client
      jar (2.8.0)]

       

      I can see that the CLIENT CALL BACK IS CLIENTCREDENTIAL INSTEAD OF
      OAuthBearerTokenCallback. The saslclient is getting set as
      AbstractSaslClient instead of OAuthBearerSaslClient.

      https://www.mail-archive.com/dev@kafka.apache.org/msg120743.html

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              shankar.bhaskaran Shankar Bhaskaran
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - 12h
                  12h
                  Remaining:
                  Remaining Estimate - 12h
                  12h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified