-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
P4
-
Affects Version/s: 11
-
Component/s: core-libs
-
None
In context of the issue reported in JDK-8362268, calling SaslOutputStream.write(...) on a closed SaslOutputStream instance leads to a NullPointerException like below:
Exception in thread "main" java.lang.NullPointerException: Cannot invoke "org.ietf.jgss.GSSContext.wrap(byte[], int, int, org.ietf.jgss.MessageProp)" because "this.secCtx" is null
at jdk.security.jgss/com.sun.security.sasl.gsskerb.GssKrb5Base.wrap(GssKrb5Base.java:140)
at java.naming/com.sun.jndi.ldap.sasl.SaslOutputStream.write(SaslOutputStream.java:89)
The implementation in SaslOutputStream should be updated to match the specification of OutputStream.write() which specifies an IOException to be thrown in such cases.
Exception in thread "main" java.lang.NullPointerException: Cannot invoke "org.ietf.jgss.GSSContext.wrap(byte[], int, int, org.ietf.jgss.MessageProp)" because "this.secCtx" is null
at jdk.security.jgss/com.sun.security.sasl.gsskerb.GssKrb5Base.wrap(GssKrb5Base.java:140)
at java.naming/com.sun.jndi.ldap.sasl.SaslOutputStream.write(SaslOutputStream.java:89)
The implementation in SaslOutputStream should be updated to match the specification of OutputStream.write() which specifies an IOException to be thrown in such cases.
- relates to
-
JDK-8362268 NPE thrown from SASL GSSAPI impl when TLS is used with QOP auth-int against Active Directory
-
- Open
-
- links to
-
Review(master)
openjdk/jdk/29647