Kerberos preauth request fails with KrbException after upgrading OpenJDK

Solution Verified - Updated -

Issue

  • After upgrading the OpenJDK version, the Kerberos preauth request throws the following exception:

    Exception in thread "main" javax.security.auth.login.LoginException: Message stream modified (41)
      at com.sun.security.auth.module.Krb5LoginModule.attemptAuthentication(Krb5LoginModule.java:808)
      at com.sun.security.auth.module.Krb5LoginModule.login(Krb5LoginModule.java:618)
      <...>
    Caused by: KrbException: Message stream modified (41)
      at sun.security.krb5.KrbKdcRep.check(KrbKdcRep.java:53)
      at sun.security.krb5.KrbAsRep.decrypt(KrbAsRep.java:159)
      at sun.security.krb5.KrbAsRep.decryptUsingPassword(KrbAsRep.java:139)
      at sun.security.krb5.KrbAsReqBuilder.resolve(KrbAsReqBuilder.java:310)
      at sun.security.krb5.KrbAsReqBuilder.action(KrbAsReqBuilder.java:447)
      at com.sun.security.auth.module.Krb5LoginModule.attemptAuthentication(Krb5LoginModule.java:770)
      ... 4 more
    

Environment

  • Java OpenJDK
    • 14
    • 11.0.6
    • 8u252
    • 8u242

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In