Incorrect hashCode / equals implementation in JWK, RSAKey
Issue #346
new
- In
com.nimbusds.jose.jwk.JWK
class the use of the fieldkeyStore
of typejava.security.KeyStore
which does not implementshashCode/equals
induce incorrecthashCode/equals
implementation in JWK, use insteadKeyStore.getType()
in place of keyStore directly. - In
com.nimbusds.jose.jwk.RSAKey
implementation of methodsequals/hashCode
is incorrect also asOtherPrimesInfo
inner class does not implementsequals/hashCode
Comments (3)
-
-
a5892e1 -> Removes parsedX5c from JWK.equals and JWK.hashCode calculation
-
Will keep the keyStore by ref comparison for now.
KeyStore.getType()
doesn’t really return something that can work for identifying the key store. - Log in to comment
Using of
parsedX5c
field inJWK#equals
andJWK#hashCode
is not necessary as it’s calculated from fieldx5c