Uses of Class
com.nimbusds.jose.JOSEException
-
Packages that use JOSEException Package Description com.nimbusds.jose Base Javascript Object Signing and Encryption (JOSE) interfaces and classes.com.nimbusds.jose.crypto Implementations of standard Javascript Object Signing and Encryption (JOSE) algorithms.com.nimbusds.jose.crypto.factories JWS signer, JWS verifier, JWE encrypter and JWE decrypter factory implementations.com.nimbusds.jose.crypto.impl Cryptographic primitives for JWS signers, JWS verifiers, JWE encrypters and JWE decrypters in thecom.nimbusds.jose.crypto
package.com.nimbusds.jose.jwk JSON Web Key (JWK) classes.com.nimbusds.jose.jwk.gen JSON Web Key (JWK) generation utilities.com.nimbusds.jose.jwk.source JSON Web Key (JWK) sourcing interface and utilities.com.nimbusds.jose.mint JSON Web Signature (JWS) minting framework.com.nimbusds.jose.proc Framework for application-specific verification and decryption of JOSE objects (with arbitrary payloads).com.nimbusds.jose.produce Framework for producing JOSE objects (with arbitrary payloads).com.nimbusds.jose.util Utility interfaces and classes.com.nimbusds.jwt.proc Framework for application-specific verification and decryption of JSON Web Tokens (JWTs). -
-
Uses of JOSEException in com.nimbusds.jose
Subclasses of JOSEException in com.nimbusds.jose Modifier and Type Class Description class
ActionRequiredForJWSCompletionException
Action required for JWS completion.class
KeyException
Key exception.class
KeyLengthException
Key length exception.class
KeySourceException
Key source exception.class
KeyTypeException
Key type exception.class
RemoteKeySourceException
Remote key source exception.Methods in com.nimbusds.jose that throw JOSEException Modifier and Type Method Description Base64URL
CompletableJWSObjectSigning. complete()
Completes the JWS object signing.byte[]
JWEDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
Decrypts the specified cipher text of aJWE Object
.void
JWEObject. decrypt(JWEDecrypter decrypter)
Decrypts this JWE object with the specified decrypter.void
JWEObjectJSON. decrypt(JWEDecrypter decrypter)
Decrypts this JWE object with the specified decrypter.JWECryptoParts
JWEEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
Encrypts the specified clear text of aJWE object
.void
JWEObject. encrypt(JWEEncrypter encrypter)
Encrypts this JWE object with the specified encrypter.void
JWEObjectJSON. encrypt(JWEEncrypter encrypter)
Encrypts this JWE object with the specified encrypter.void
JWSObject. sign(JWSSigner signer)
Signs this JWS object with the specified signer.void
JWSObjectJSON. sign(JWSHeader jwsHeader, JWSSigner signer)
Signs this JWS secured object with the specified JWS signer and adds the resulting signature to it.void
JWSObjectJSON. sign(JWSHeader jwsHeader, UnprotectedHeader unprotectedHeader, JWSSigner signer)
Signs this JWS secured object with the specified JWS signer and adds the resulting signature to it.Base64URL
JWSSigner. sign(JWSHeader header, byte[] signingInput)
Signs the specifiedinput
of aJWS object
.boolean
JWSObject. verify(JWSVerifier verifier)
Checks the signature of this JWS object with the specified verifier.boolean
JWSObjectJSON.Signature. verify(JWSVerifier verifier)
Checks the signature with the specified verifier.boolean
JWSVerifier. verify(JWSHeader header, byte[] signingInput, Base64URL signature)
Verifies the specifiedsignature
of aJWS object
. -
Uses of JOSEException in com.nimbusds.jose.crypto
Methods in com.nimbusds.jose.crypto that throw JOSEException Modifier and Type Method Description byte[]
AESDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
AESDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
DirectDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
DirectDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
ECDH1PUDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
ECDH1PUDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
ECDH1PUX25519Decrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
ECDH1PUX25519Decrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
ECDHDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
ECDHDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
MultiDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
MultiDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
PasswordBasedDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
PasswordBasedDecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
RSADecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
RSADecrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
byte[]
X25519Decrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Deprecated.byte[]
X25519Decrypter. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, byte[] aad)
JWECryptoParts
AESEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
AESEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
DirectEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
DirectEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
ECDH1PUEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
ECDH1PUEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
ECDH1PUX25519Encrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
ECDH1PUX25519Encrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
ECDHEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
ECDHEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
MultiEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
MultiEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
PasswordBasedEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
PasswordBasedEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
RSAEncrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
RSAEncrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
JWECryptoParts
X25519Encrypter. encrypt(JWEHeader header, byte[] clearText)
Deprecated.JWECryptoParts
X25519Encrypter. encrypt(JWEHeader header, byte[] clearText, byte[] aad)
static int
MACSigner. getMinRequiredSecretLength(JWSAlgorithm alg)
Returns the minimal required secret length for the specified HMAC JWS algorithm.Base64URL
ECDSASigner. sign(JWSHeader header, byte[] signingInput)
Base64URL
Ed25519Signer. sign(JWSHeader header, byte[] signingInput)
Base64URL
MACSigner. sign(JWSHeader header, byte[] signingInput)
Base64URL
RSASSASigner. sign(JWSHeader header, byte[] signingInput)
boolean
ECDSAVerifier. verify(JWSHeader header, byte[] signedContent, Base64URL signature)
boolean
Ed25519Verifier. verify(JWSHeader header, byte[] signedContent, Base64URL signature)
boolean
MACVerifier. verify(JWSHeader header, byte[] signedContent, Base64URL signature)
boolean
RSASSAVerifier. verify(JWSHeader header, byte[] signedContent, Base64URL signature)
Constructors in com.nimbusds.jose.crypto that throw JOSEException Constructor Description ECDH1PUDecrypter(ECPrivateKey privateKey, ECPublicKey publicKey)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDH1PUDecrypter(ECPrivateKey privateKey, ECPublicKey publicKey, Set<String> defCritHeaders)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDH1PUDecrypter(ECPrivateKey privateKey, ECPublicKey publicKey, Set<String> defCritHeaders, Curve curve)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDH1PUEncrypter(ECPrivateKey privateKey, ECPublicKey publicKey)
Creates a new Elliptic Curve Diffie-Hellman encrypter.ECDH1PUEncrypter(ECPrivateKey privateKey, ECPublicKey publicKey, SecretKey contentEncryptionKey)
Creates a new Elliptic Curve Diffie-Hellman encrypter with an optionally specified content encryption key (CEK).ECDH1PUX25519Decrypter(OctetKeyPair privateKey, OctetKeyPair publicKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman decrypter.ECDH1PUX25519Decrypter(OctetKeyPair privateKey, OctetKeyPair publicKey, Set<String> defCritHeaders)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman decrypter.ECDH1PUX25519Encrypter(OctetKeyPair privateKey, OctetKeyPair publicKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman encrypter.ECDH1PUX25519Encrypter(OctetKeyPair privateKey, OctetKeyPair publicKey, SecretKey contentEncryptionKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman encrypter.ECDHDecrypter(ECKey ecJWK)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDHDecrypter(ECPrivateKey privateKey)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDHDecrypter(ECPrivateKey privateKey, Set<String> defCritHeaders)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDHDecrypter(PrivateKey privateKey, Set<String> defCritHeaders, Curve curve)
Creates a new Elliptic Curve Diffie-Hellman decrypter.ECDHEncrypter(ECKey ecJWK)
Creates a new Elliptic Curve Diffie-Hellman encrypter.ECDHEncrypter(ECPublicKey publicKey)
Creates a new Elliptic Curve Diffie-Hellman encrypter.ECDHEncrypter(ECPublicKey publicKey, SecretKey contentEncryptionKey)
Creates a new Elliptic Curve Diffie-Hellman encrypter with an optionally specified content encryption key (CEK).ECDSASigner(ECKey ecJWK)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSASigner(ECKey ecJWK, Set<JWSSignerOption> opts)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSASigner(ECPrivateKey privateKey)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSASigner(ECPrivateKey privateKey, Set<JWSSignerOption> opts)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSASigner(PrivateKey privateKey, Curve curve)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSASigner(PrivateKey privateKey, Curve curve, Set<JWSSignerOption> opts)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) signer.ECDSAVerifier(ECKey ecJWK)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) verifier.ECDSAVerifier(ECPublicKey publicKey)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) verifier.ECDSAVerifier(ECPublicKey publicKey, Set<String> defCritHeaders)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) verifier.Ed25519Signer(OctetKeyPair privateKey)
Creates a new Ed25519 signer.Ed25519Verifier(OctetKeyPair publicKey)
Creates a new Ed25519 verifier.Ed25519Verifier(OctetKeyPair publicKey, Set<String> defCritHeaders)
Creates a Ed25519 verifier.MACVerifier(byte[] secret)
Creates a new Message Authentication (MAC) verifier.MACVerifier(byte[] secret, Set<String> defCritHeaders)
Creates a new Message Authentication (MAC) verifier.MACVerifier(OctetSequenceKey jwk)
Creates a new Message Authentication (MAC) verifier.MACVerifier(OctetSequenceKey jwk, Set<String> defCritHeaders)
Creates a new Message Authentication (MAC) verifier.MACVerifier(String secretString)
Creates a new Message Authentication (MAC) verifier.MACVerifier(SecretKey secretKey)
Creates a new Message Authentication (MAC) verifier.MACVerifier(SecretKey secretKey, Set<String> defCritHeaders)
Creates a new Message Authentication (MAC) verifier.MultiDecrypter(JWK jwk)
Creates a new multi-recipient decrypter.MultiDecrypter(JWK jwk, Set<String> defCritHeaders)
Creates a new multi-recipient decrypter.RSADecrypter(RSAKey rsaJWK)
Creates a new RSA decrypter.RSAEncrypter(RSAKey rsaJWK)
Creates a new RSA encrypter.RSASSASigner(RSAKey rsaJWK)
Creates a new RSA Signature-Scheme-with-Appendix (RSASSA) signer.RSASSASigner(RSAKey rsaJWK, boolean allowWeakKey)
Deprecated.RSASSASigner(RSAKey rsaJWK, Set<JWSSignerOption> opts)
Creates a new RSA Signature-Scheme-with-Appendix (RSASSA) signer.RSASSAVerifier(RSAKey rsaJWK)
Creates a new RSA Signature-Scheme-with-Appendix (RSASSA) verifier.X25519Decrypter(OctetKeyPair privateKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman decrypter.X25519Decrypter(OctetKeyPair privateKey, Set<String> defCritHeaders)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman decrypter.X25519Encrypter(OctetKeyPair publicKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman encrypter.X25519Encrypter(OctetKeyPair publicKey, SecretKey contentEncryptionKey)
Creates a new Curve25519 Elliptic Curve Diffie-Hellman encrypter. -
Uses of JOSEException in com.nimbusds.jose.crypto.factories
Methods in com.nimbusds.jose.crypto.factories that throw JOSEException Modifier and Type Method Description JWEDecrypter
DefaultJWEDecrypterFactory. createJWEDecrypter(JWEHeader header, Key key)
JWSSigner
DefaultJWSSignerFactory. createJWSSigner(JWK key)
JWSSigner
DefaultJWSSignerFactory. createJWSSigner(JWK key, JWSAlgorithm alg)
JWSVerifier
DefaultJWSVerifierFactory. createJWSVerifier(JWSHeader header, Key key)
-
Uses of JOSEException in com.nimbusds.jose.crypto.impl
Methods in com.nimbusds.jose.crypto.impl that throw JOSEException Modifier and Type Method Description static byte[]
DeflateHelper. applyCompression(JWEHeader jweHeader, byte[] bytes)
Applies compression to the specified plain text if requested.static byte[]
DeflateHelper. applyDecompression(JWEHeader jweHeader, byte[] bytes)
Applies decompression to the specified plain text if requested.static byte[]
HMAC. compute(String alg, byte[] secret, byte[] message, Provider provider)
Deprecated.static byte[]
HMAC. compute(String alg, SecretKey secretKey, byte[] message, Provider provider)
Computes a Hash-based Message Authentication Code (HMAC) for the specified secret key and message.static byte[]
HMAC. compute(SecretKey secretKey, byte[] message, Provider provider)
Computes a Hash-based Message Authentication Code (HMAC) for the specified secret key and message.static byte[]
AESCBC. decrypt(SecretKey secretKey, byte[] iv, byte[] cipherText, Provider provider)
Decrypts the specified cipher text using AES/CBC/PKCS5Padding.static byte[]
AESGCM. decrypt(SecretKey secretKey, byte[] iv, byte[] cipherText, byte[] authData, byte[] authTag, Provider provider)
Decrypts the specified cipher text using AES/GCM/NoPadding.static byte[]
ContentCryptoProvider. decrypt(JWEHeader header, byte[] aad, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, SecretKey cek, JWEJCAContext jcaProvider)
Decrypts the specified cipher text.static byte[]
ContentCryptoProvider. decrypt(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, SecretKey cek, JWEJCAContext jcaProvider)
Decrypts the specified cipher text.static byte[]
LegacyAESGCM. decrypt(SecretKey secretKey, byte[] iv, byte[] cipherText, byte[] authData, byte[] authTag)
Decrypts the specified cipher text using AES/GCM/NoPadding.static byte[]
AESCBC. decryptAuthenticated(SecretKey secretKey, byte[] iv, byte[] cipherText, byte[] aad, byte[] authTag, Provider ceProvider, Provider macProvider)
Decrypts the specified cipher text using AES/CBC/PKCS5Padding/ HMAC-SHA2.static byte[]
XC20P. decryptAuthenticated(SecretKey secretKey, byte[] iv, byte[] cipherText, byte[] authData, byte[] authTag)
Decrypts the specified cipher text using XChaCha20_Poly1305.static SecretKey
AESGCMKW. decryptCEK(SecretKey kek, byte[] iv, AuthenticatedCipherText authEncrCEK, int keyLength, Provider provider)
Decrypts the specified encrypted Content Encryption Key (CEK).static SecretKey
RSA_OAEP_SHA2. decryptCEK(PrivateKey priv, byte[] encryptedCEK, int shaBitSize, Provider provider)
Decrypts the specified encrypted Content Encryption Key (CEK).static SecretKey
RSA_OAEP. decryptCEK(PrivateKey priv, byte[] encryptedCEK, Provider provider)
Decrypts the specified encrypted Content Encryption Key (CEK).static SecretKey
RSA1_5. decryptCEK(PrivateKey priv, byte[] encryptedCEK, int keyLength, Provider provider)
Decrypts the specified encrypted Content Encryption Key (CEK).static byte[]
AESCBC. decryptWithConcatKDF(JWEHeader header, SecretKey secretKey, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag, Provider ceProvider, Provider macProvider)
Decrypts the specified cipher text using the deprecated concat KDF from JOSE draft suite 09.protected byte[]
ECDH1PUCryptoProvider. decryptWithZ(JWEHeader header, byte[] aad, SecretKey Z, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Decrypts the encrypted JWE parts using the specified shared secret ("Z").protected byte[]
ECDHCryptoProvider. decryptWithZ(JWEHeader header, byte[] aad, SecretKey Z, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authTag)
Decrypts the encrypted JWE parts using the specified shared secret ("Z").SecretKey
ConcatKDF. deriveKey(SecretKey sharedSecret, int keyLengthBits, byte[] otherInfo)
Derives a key from the specified inputs.SecretKey
ConcatKDF. deriveKey(SecretKey sharedSecret, int keyLength, byte[] algID, byte[] partyUInfo, byte[] partyVInfo, byte[] suppPubInfo, byte[] suppPrivInfo)
Derives a key from the specified inputs.SecretKey
ConcatKDF. deriveKey(SecretKey sharedSecret, int keyLength, byte[] algID, byte[] partyUInfo, byte[] partyVInfo, byte[] suppPubInfo, byte[] suppPrivInfo, byte[] tag)
Derives a key from the specified inputs.static SecretKey
PBKDF2. deriveKey(byte[] password, byte[] formattedSalt, int iterationCount, PRFParams prfParams)
Derives a PBKDF2 key from the specified password and parameters.static SecretKey
ECDH1PU. deriveRecipientZ(OctetKeyPair privateKey, OctetKeyPair publicKey, OctetKeyPair epk)
Derives a shared secret (also called 'Z') for recipient where Z is the concatenation of Ze and Zs.static SecretKey
ECDH1PU. deriveRecipientZ(ECPrivateKey privateKey, ECPublicKey publicKey, ECPublicKey epk, Provider provider)
Derives a shared secret (also called 'Z') for sender where Z is the concatenation of Ze and Zs.static SecretKey
ECDH1PU. deriveSenderZ(OctetKeyPair privateKey, OctetKeyPair publicKey, OctetKeyPair epk)
Derives a shared secret (also called 'Z') for sender where Z is the concatenation of Ze and Zs.static SecretKey
ECDH1PU. deriveSenderZ(ECPrivateKey privateKey, ECPublicKey publicKey, ECPrivateKey epk, Provider provider)
Derives a shared secret (also called 'Z') for sender where Z is the concatenation of Ze and Zs.static SecretKey
ECDH. deriveSharedKey(JWEHeader header, SecretKey Z, ConcatKDF concatKDF)
Derives a shared key (via concat KDF).static SecretKey
ECDH1PU. deriveSharedKey(JWEHeader header, SecretKey Z, ConcatKDF concatKDF)
Derives a shared key (via concat KDF).static SecretKey
ECDH1PU. deriveSharedKey(JWEHeader header, SecretKey Z, Base64URL tag, ConcatKDF concatKDF)
Derives a shared key (via concat KDF).static SecretKey
ECDH. deriveSharedSecret(OctetKeyPair publicKey, OctetKeyPair privateKey)
Derives a shared secret (also called 'Z') from the specified ECDH key agreement.static SecretKey
ECDH. deriveSharedSecret(ECPublicKey publicKey, PrivateKey privateKey, Provider provider)
Derives a shared secret (also called 'Z') from the specified ECDH key agreement.static byte[]
AESCBC. encrypt(SecretKey secretKey, byte[] iv, byte[] plainText, Provider provider)
Encrypts the specified plain text using AES/CBC/PKCS5Padding.static AuthenticatedCipherText
AESGCM. encrypt(SecretKey secretKey, Container<byte[]> ivContainer, byte[] plainText, byte[] authData, Provider provider)
Encrypts the specified plain text using AES/GCM/NoPadding.static JWECryptoParts
ContentCryptoProvider. encrypt(JWEHeader header, byte[] clearText, byte[] aad, SecretKey cek, Base64URL encryptedKey, JWEJCAContext jcaProvider)
Encrypts the specified clear text (content).static JWECryptoParts
ContentCryptoProvider. encrypt(JWEHeader header, byte[] clearText, SecretKey cek, Base64URL encryptedKey, JWEJCAContext jcaProvider)
Encrypts the specified clear text (content).static AuthenticatedCipherText
LegacyAESGCM. encrypt(SecretKey secretKey, byte[] iv, byte[] plainText, byte[] authData)
Encrypts the specified plain text using AES/GCM/NoPadding.static AuthenticatedCipherText
AESCBC. encryptAuthenticated(SecretKey secretKey, byte[] iv, byte[] plainText, byte[] aad, Provider ceProvider, Provider macProvider)
Encrypts the specified plain text using AES/CBC/PKCS5Padding/ HMAC-SHA2.static AuthenticatedCipherText
XC20P. encryptAuthenticated(SecretKey secretKey, Container<byte[]> ivContainer, byte[] plainText, byte[] authData)
Encrypts the specified plain text using XChaCha20_Poly1305.static AuthenticatedCipherText
AESGCMKW. encryptCEK(SecretKey cek, Container<byte[]> iv, SecretKey kek, Provider provider)
Encrypts the specified Content Encryption Key (CEK).static byte[]
RSA_OAEP_SHA2. encryptCEK(RSAPublicKey pub, SecretKey cek, int shaBitSize, Provider provider)
Encrypts the specified Content Encryption Key (CEK).static byte[]
RSA_OAEP. encryptCEK(RSAPublicKey pub, SecretKey cek, Provider provider)
Encrypts the specified Content Encryption Key (CEK).static byte[]
RSA1_5. encryptCEK(RSAPublicKey pub, SecretKey cek, Provider provider)
Encrypts the specified Content Encryption Key (CEK).static AuthenticatedCipherText
AESCBC. encryptWithConcatKDF(JWEHeader header, SecretKey secretKey, Base64URL encryptedKey, byte[] iv, byte[] plainText, Provider ceProvider, Provider macProvider)
Encrypts the specified plain text using the deprecated concat KDF from JOSE draft suite 09.protected JWECryptoParts
ECDH1PUCryptoProvider. encryptWithZ(JWEHeader header, SecretKey Z, byte[] clearText, byte[] aad)
Encrypts the specified plaintext using the specified shared secret ("Z").protected JWECryptoParts
ECDHCryptoProvider. encryptWithZ(JWEHeader header, SecretKey Z, byte[] clearText, byte[] aad)
Encrypts the specified plaintext using the specified shared secret ("Z").void
CriticalHeaderParamsDeferral. ensureHeaderPasses(JWEHeader header)
Throws a JOSE exception if the specified JWE header doesn't pass the critical header parameters check.static void
ECDSA. ensureLegalSignature(byte[] jwsSignature, JWSAlgorithm jwsAlg)
Ensures the specified ECDSA signature is legal.static byte[]
PBKDF2. formatSalt(JWEAlgorithm alg, byte[] salt)
Formats the specified cryptographic salt for use in PBKDF2.static SecretKey
ContentCryptoProvider. generateCEK(EncryptionMethod enc, SecureRandom randomGen)
Generates a Content Encryption Key (CEK) for the specified JOSE encryption method.static SecretKey
LegacyConcatKDF. generateCEK(SecretKey key, EncryptionMethod enc, byte[] epu, byte[] epv)
Generates a Content Encryption Key (CEK) from the specified Content Master Key (CMK) and JOSE encryption method.static SecretKey
LegacyConcatKDF. generateCIK(SecretKey key, EncryptionMethod enc, byte[] epu, byte[] epv)
Generates a Content Integrity Key (CIK) from the specified Content Master Key (CMK) and JOSE encryption method.static JWEAlgorithm
JWEHeaderValidation. getAlgorithmAndEnsureNotNull(JWEHeader jweHeader)
Gets the JWE algorithm of the specified header and ensure it is notnull
.static Mac
HMAC. getInitMac(String alg, SecretKey secretKey, Provider provider)
Gets an initialised Message Authentication Code (MAC) service instance.static Mac
HMAC. getInitMac(SecretKey secretKey, Provider provider)
Gets an initialised Message Authentication Code (MAC) service instance.protected static String
MACProvider. getJCAAlgorithmName(JWSAlgorithm alg)
Gets the matching Java Cryptography Architecture (JCA) algorithm name for the specified HMAC-based JSON Web Algorithm (JWA).static int
ECDSA. getSignatureByteArrayLength(JWSAlgorithm alg)
Returns the expected signature byte array length (R + S parts) for the specified ECDSA algorithm.static Signature
ECDSA. getSignerAndVerifier(JWSAlgorithm alg, Provider jcaProvider)
Creates a new JCA signer / verifier for ECDSA.static Signature
RSASSA. getSignerAndVerifier(JWSAlgorithm alg, Provider provider)
Returns a signer and verifier for the specified RSASSA-based JSON Web Algorithm (JWA).static PRFParams
PRFParams. resolve(JWEAlgorithm alg, Provider macProvider)
Resolves the Pseudo-Random Function (PRF) parameters for the specified PBES2 JWE algorithm.static JWSAlgorithm
ECDSA. resolveAlgorithm(Curve curve)
Resolves the matching EC DSA algorithm for the specified elliptic curve.static JWSAlgorithm
ECDSA. resolveAlgorithm(ECKey ecKey)
Resolves the matching EC DSA algorithm for the specified EC key (public or private).static ECDH.AlgorithmMode
ECDH. resolveAlgorithmMode(JWEAlgorithm alg)
Resolves the ECDH algorithm mode.static ECDH.AlgorithmMode
ECDH1PU. resolveAlgorithmMode(JWEAlgorithm alg)
Resolves the ECDH algorithm mode.static int
ECDH. sharedKeyLength(JWEAlgorithm alg, EncryptionMethod enc)
Returns the bit length of the shared key (derived via concat KDF) for the specified JWE ECDH algorithm.static int
ECDH1PU. sharedKeyLength(JWEAlgorithm alg, EncryptionMethod enc)
Returns the bit length of the shared key (derived via concat KDF) for the specified JWE ECDH algorithm.static PrivateKey
RSAKeyUtils. toRSAPrivateKey(RSAKey rsaJWK)
Returns the private RSA key of the specified RSA JWK.static byte[]
ECDSA. transcodeSignatureToConcat(byte[] derSignature, int outputLength)
Transcodes the JCA ASN.1/DER-encoded signature into the concatenated R + S format expected by ECDSA JWS.static byte[]
ECDSA. transcodeSignatureToDER(byte[] jwsSignature)
Transcodes the ECDSA JWS signature into ASN.1/DER format for use by the JCA verifier.static SecretKey
AESKW. unwrapCEK(SecretKey kek, byte[] encryptedCEK, Provider provider)
Unwraps the specified encrypted Content Encryption Key (CEK).static void
ECDH1PU. validateSameCurve(OctetKeyPair privateKey, OctetKeyPair publicKey)
Ensures the private key and public key are from the same curve.static void
ECDH1PU. validateSameCurve(ECPrivateKey privateKey, ECPublicKey publicKey)
Ensures the private key and public key are from the same curve.static byte[]
AESKW. wrapCEK(SecretKey cek, SecretKey kek, Provider provider)
Wraps the specified Content Encryption Key (CEK).Constructors in com.nimbusds.jose.crypto.impl that throw JOSEException Constructor Description ECDH1PUCryptoProvider(Curve curve, SecretKey cek)
Creates a new Elliptic Curve Diffie-Hellman One-Pass Unified Model encryption / decryption provider.ECDHCryptoProvider(Curve curve, SecretKey cek)
Creates a new Elliptic Curve Diffie-Hellman encryption /decryption provider.ECDSAProvider(JWSAlgorithm alg)
Creates a new Elliptic Curve Digital Signature Algorithm (ECDSA) provider. -
Uses of JOSEException in com.nimbusds.jose.jwk
Subclasses of JOSEException in com.nimbusds.jose.jwk Modifier and Type Class Description class
JWKException
JSON Web Key (JWK) related exception.Methods in com.nimbusds.jose.jwk that throw JOSEException Modifier and Type Method Description static ThumbprintURI
ThumbprintURI. compute(JWK jwk)
Computes the SHA-256 JWK thumbprint URI for the specified JWK.static Base64URL
ThumbprintUtils. compute(JWK jwk)
Computes the SHA-256 thumbprint for the specified JWK.static Base64URL
ThumbprintUtils. compute(String hashAlg, JWK jwk)
Computes the thumbprint for the specified JWK.static Base64URL
ThumbprintUtils. compute(String hashAlg, LinkedHashMap<String,?> params)
Computes the thumbprint for the specified required JWK parameters.Base64URL
JWK. computeThumbprint()
Computes the SHA-256 thumbprint of this JWK.Base64URL
JWK. computeThumbprint(String hashAlg)
Computes the thumbprint of this JWK using the specified hash algorithm.ThumbprintURI
JWK. computeThumbprintURI()
Computes the SHA-256 thumbprint URI of this JWK.boolean
JWKSet. containsJWK(JWK jwk)
Returnstrue
if this JWK set contains the specified JWK as public or private key, by comparing its thumbprint with those of the keys in the set.ECKey.Builder
ECKey.Builder. keyIDFromThumbprint()
Sets the ID (kid
) of the JWK to its SHA-256 JWK thumbprint (RFC 7638).ECKey.Builder
ECKey.Builder. keyIDFromThumbprint(String hashAlg)
Sets the ID (kid
) of the JWK to its JWK thumbprint (RFC 7638).OctetKeyPair.Builder
OctetKeyPair.Builder. keyIDFromThumbprint()
Sets the ID (kid
) of the JWK to its SHA-256 JWK thumbprint (RFC 7638).OctetKeyPair.Builder
OctetKeyPair.Builder. keyIDFromThumbprint(String hashAlg)
Sets the ID (kid
) of the JWK to its JWK thumbprint (RFC 7638).OctetSequenceKey.Builder
OctetSequenceKey.Builder. keyIDFromThumbprint()
Sets the ID (kid
) of the JWK to its SHA-256 JWK thumbprint (RFC 7638).OctetSequenceKey.Builder
OctetSequenceKey.Builder. keyIDFromThumbprint(String hashAlg)
Sets the ID (kid
) of the JWK to its JWK thumbprint (RFC 7638).RSAKey.Builder
RSAKey.Builder. keyIDFromThumbprint()
Sets the ID (kid
) of the JWK to its SHA-256 JWK thumbprint (RFC 7638).RSAKey.Builder
RSAKey.Builder. keyIDFromThumbprint(String hashAlg)
Sets the ID (kid
) of the JWK to its JWK thumbprint (RFC 7638).static ECKey
ECKey. load(KeyStore keyStore, String alias, char[] pin)
Loads a public / private Elliptic Curve JWK from the specified JCA key store.static JWK
JWK. load(KeyStore keyStore, String alias, char[] pin)
Loads a JWK from the specified JCE key store.static OctetSequenceKey
OctetSequenceKey. load(KeyStore keyStore, String alias, char[] pin)
Loads an octet sequence JWK from the specified JCA key store.static RSAKey
RSAKey. load(KeyStore keyStore, String alias, char[] pin)
Loads a public / private RSA JWK from the specified JCA key store.static ECKey
ECKey. parse(X509Certificate cert)
Parses a public Elliptic Curve JWK from the specified X.509 certificate.static JWK
JWK. parse(X509Certificate cert)
static RSAKey
RSAKey. parse(X509Certificate cert)
Parses a public RSA JWK from the specified X.509 certificate.static JWK
JWK. parseFromPEMEncodedObjects(String pemEncodedObjects)
Parses an RSA or EC JWK from the specified string of one or more PEM-encoded object(s): X.509 certificate (PEM header: BEGIN CERTIFICATE) PKCS#1 RSAPublicKey (PEM header: BEGIN RSA PUBLIC KEY) X.509 SubjectPublicKeyInfo (PEM header: BEGIN PUBLIC KEY) PKCS#1 RSAPrivateKey (PEM header: BEGIN RSA PRIVATE KEY) PKCS#8 PrivateKeyInfo (PEM header: BEGIN PRIVATE KEY) matching pair of the abovestatic JWK
JWK. parseFromPEMEncodedX509Cert(String pemEncodedCert)
ECPrivateKey
ECKey. toECPrivateKey()
Returns a standardjava.security.interfaces.ECPrivateKey
representation of this Elliptic Curve JWK.ECPrivateKey
ECKey. toECPrivateKey(Provider provider)
Returns a standardjava.security.interfaces.ECPrivateKey
representation of this Elliptic Curve JWK.ECPublicKey
ECKey. toECPublicKey()
Returns a standardjava.security.interfaces.ECPublicKey
representation of this Elliptic Curve JWK.ECPublicKey
ECKey. toECPublicKey(Provider provider)
Returns a standardjava.security.interfaces.ECPublicKey
representation of this Elliptic Curve JWK.KeyPair
AsymmetricJWK. toKeyPair()
Returns a Java key pair representation of this JWK.KeyPair
ECKey. toKeyPair()
Returns a standardjava.security.KeyPair
representation of this Elliptic Curve JWK.KeyPair
ECKey. toKeyPair(Provider provider)
Returns a standardjava.security.KeyPair
representation of this Elliptic Curve JWK.KeyPair
OctetKeyPair. toKeyPair()
KeyPair
RSAKey. toKeyPair()
Returns a standardjava.security.KeyPair
representation of this RSA JWK.PrivateKey
AsymmetricJWK. toPrivateKey()
Returns a Java private key representation of this JWK.PrivateKey
ECKey. toPrivateKey()
PrivateKey
OctetKeyPair. toPrivateKey()
PrivateKey
RSAKey. toPrivateKey()
PublicKey
AsymmetricJWK. toPublicKey()
Returns a Java public key representation of the JWK.PublicKey
ECKey. toPublicKey()
PublicKey
OctetKeyPair. toPublicKey()
PublicKey
RSAKey. toPublicKey()
RSAPrivateKey
RSAKey. toRSAPrivateKey()
Returns a standardjava.security.interfaces.RSAPrivateKey
representation of this RSA JWK.RSAPublicKey
RSAKey. toRSAPublicKey()
Returns a standardjava.security.interfaces.RSAPublicKey
representation of this RSA JWK. -
Uses of JOSEException in com.nimbusds.jose.jwk.gen
Methods in com.nimbusds.jose.jwk.gen that throw JOSEException Modifier and Type Method Description ECKey
ECKeyGenerator. generate()
abstract T
JWKGenerator. generate()
Generates the JWK according to the set parameters.OctetKeyPair
OctetKeyPairGenerator. generate()
OctetSequenceKey
OctetSequenceKeyGenerator. generate()
RSAKey
RSAKeyGenerator. generate()
-
Uses of JOSEException in com.nimbusds.jose.jwk.source
Subclasses of JOSEException in com.nimbusds.jose.jwk.source Modifier and Type Class Description class
JWKSetParseException
JWK set parse exception, in the context of JWK set retrieval.class
JWKSetRetrievalException
JWK set retrieval exception, due to a network issue or the remote server being unavailable.class
JWKSetUnavailableException
JWK set unavailable exception.class
RateLimitReachedException
Rate limit reached exception. -
Uses of JOSEException in com.nimbusds.jose.mint
Methods in com.nimbusds.jose.mint that throw JOSEException Modifier and Type Method Description JWSObject
DefaultJWSMinter. mint(JWSHeader header, Payload payload, C context)
JWSObject
JWSMinter. mint(JWSHeader header, Payload payload, C context)
-
Uses of JOSEException in com.nimbusds.jose.proc
Methods in com.nimbusds.jose.proc that throw JOSEException Modifier and Type Method Description JWEDecrypter
JWEDecrypterFactory. createJWEDecrypter(JWEHeader header, Key key)
Creates a new JWE decrypter for the specified header and key.JWSVerifier
JWSVerifierFactory. createJWSVerifier(JWSHeader header, Key key)
Creates a new JWS verifier for the specified header and key.Payload
DefaultJOSEProcessor. process(JOSEObject joseObject, C context)
Payload
DefaultJOSEProcessor. process(JWEObject jweObject, C context)
Payload
DefaultJOSEProcessor. process(JWSObject jwsObject, C context)
Payload
DefaultJOSEProcessor. process(String compactJOSE, C context)
Payload
JOSEProcessor. process(JOSEObject joseObject, C context)
Processes the specified JOSE object (unsecured, JWS or JWE).Payload
JOSEProcessor. process(JWEObject jweObject, C context)
Processes the specified JWE object by decrypting it.Payload
JOSEProcessor. process(JWSObject jwsObject, C context)
Processes the specified JWS object by verifying its signature.Payload
JOSEProcessor. process(PlainObject plainObject, C context)
Processes the specified unsecured (plain) JOSE object, typically by checking its context.Payload
JOSEProcessor. process(String compactEncodedJOSE, C context)
Parses and processes the specified JOSE object (unsecured, JWS or JWE). -
Uses of JOSEException in com.nimbusds.jose.produce
Methods in com.nimbusds.jose.produce that throw JOSEException Modifier and Type Method Description JWSSigner
JWSSignerFactory. createJWSSigner(JWK key)
Create a JWS signer based on the key.JWSSigner
JWSSignerFactory. createJWSSigner(JWK key, JWSAlgorithm alg)
Create a JWS signer based on the key and algorithm. -
Uses of JOSEException in com.nimbusds.jose.util
Subclasses of JOSEException in com.nimbusds.jose.util Modifier and Type Class Description class
IntegerOverflowException
Integer overflow exception. -
Uses of JOSEException in com.nimbusds.jwt.proc
Methods in com.nimbusds.jwt.proc that throw JOSEException Modifier and Type Method Description JWTClaimsSet
DefaultJWTProcessor. process(EncryptedJWT encryptedJWT, C context)
JWTClaimsSet
DefaultJWTProcessor. process(JWT jwt, C context)
JWTClaimsSet
DefaultJWTProcessor. process(PlainJWT plainJWT, C context)
JWTClaimsSet
DefaultJWTProcessor. process(SignedJWT signedJWT, C context)
JWTClaimsSet
DefaultJWTProcessor. process(String jwtString, C context)
JWTClaimsSet
JWTProcessor. process(EncryptedJWT encryptedJWT, C context)
Processes the specified encrypted JWT by decrypting it.JWTClaimsSet
JWTProcessor. process(JWT jwt, C context)
Processes the specified JWT (unsecured, signed or encrypted).JWTClaimsSet
JWTProcessor. process(PlainJWT plainJWT, C context)
Processes the specified unsecured (plain) JWT, typically by checking its context.JWTClaimsSet
JWTProcessor. process(SignedJWT signedJWT, C context)
Processes the specified signed JWT by verifying its signature.JWTClaimsSet
JWTProcessor. process(String jwtString, C context)
Parses and processes the specified JWT (unsecured, signed or encrypted).
-