Package de.adorsys.sts.common.converter
Class KeyConverter
java.lang.Object
de.adorsys.sts.common.converter.KeyConverter
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic com.nimbusds.jose.jwk.JWKSetexportPrivateKeys(KeyStore keyStore, char[] keypass) static com.nimbusds.jose.JWSSignerfindSigner(KeyAndJwk randomKey) static com.nimbusds.jose.JWSAlgorithmgetJWSAlgo(KeyAndJwk randomKey) static KeytoPrivateOrSecret(com.nimbusds.jose.jwk.JWK jwk) Converts the specified of JSON Web Keys (JWK) it's standard Java class representation.static KeytoPrivateOrSecret(com.nimbusds.jose.jwk.JWK jwk, String alg) Converts the specified of JSON Web Keys (JWK) it's standard Java class representation.static KeytoPublic(com.nimbusds.jose.jwk.JWK jwk)
-
Constructor Details
-
KeyConverter
public KeyConverter()
-
-
Method Details
-
toPrivateOrSecret
Converts the specified of JSON Web Keys (JWK) it's standard Java class representation. AsymmetricRSAandEC keypairs are converted toPublicKeyandPrivateKey(if specified) objects.secret JWKsare converted toSecretKeyobjects.- Parameters:
jwk- jwk- Returns:
- private key, secret key or nul;
-
toPrivateOrSecret
Converts the specified of JSON Web Keys (JWK) it's standard Java class representation. AsymmetricRSAandEC keypairs are converted toPublicKeyandPrivateKey(if specified) objects.secret JWKsare converted toSecretKeyobjects.- Parameters:
jwk- jwk- Returns:
- private key, secret key or nul;
-
toPublic
-
exportPrivateKeys
-
getJWSAlgo
-
findSigner
public static com.nimbusds.jose.JWSSigner findSigner(KeyAndJwk randomKey) throws com.nimbusds.jose.JOSEException - Throws:
com.nimbusds.jose.JOSEException
-