| Package | Description |
|---|---|
| org.wso2.carbon.crypto.api |
| Modifier and Type | Method and Description |
|---|---|
static CryptoContext |
CryptoContext.buildEmptyContext(int tenantId,
String tenantDomain)
Creates and returns a
CryptoContext which has no attribute values other than the tenant information. |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
CryptoService.decrypt(byte[] ciphertext,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext)
Computes and returns the cleartext of the given ciphertext comes from an external entity.
|
byte[] |
ExternalCryptoProvider.decrypt(byte[] ciphertext,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext,
PrivateKeyInfo privateKeyInfo)
Computes and returns the cleartext of the given ciphertext.
|
byte[] |
CryptoService.encrypt(byte[] cleartext,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext)
Computes and returns the ciphertext of the given cleartext, using asymmetric cryptography.
|
byte[] |
ExternalCryptoProvider.encrypt(byte[] data,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext,
CertificateInfo certificateInfo)
Computes and returns the ciphertext of the given cleartext.
|
Certificate |
CryptoService.getCertificate(CryptoContext cryptoContext)
Returns the
Certificate based on the given CryptoContext. |
Certificate |
ExternalCryptoProvider.getCertificate(CryptoContext cryptoContext,
CertificateInfo certificateInfo)
Returns the
Certificate based on the given CryptoContext. |
abstract CertificateInfo |
KeyResolver.getCertificateInfo(CryptoContext cryptoContext)
Returns the discovery information about a certificate, based on the given context.
|
PrivateKey |
PrivateKeyRetriever.getPrivateKey(CryptoContext cryptoContext) |
PrivateKey |
ExternalCryptoProvider.getPrivateKey(CryptoContext cryptoContext,
PrivateKeyInfo privateKeyInfo)
Returns the
PrivateKey based on the given CryptoContext. |
abstract PrivateKeyInfo |
KeyResolver.getPrivateKeyInfo(CryptoContext cryptoContext)
Returns the discovery information about a private key, based on the given context.
|
default byte[] |
CryptoService.hybridDecrypt(HybridEncryptionOutput hybridEncryptionOutput,
String symmetricAlgorithm,
String asymmetricAlgorithm,
String javaSecurityProvider,
CryptoContext cryptoContext)
In hybrid decryption symmetric key used for encryption is decrypted with asymmetric decryption
and cipher data is decrypted using symmetric decryption mechanism.
|
default byte[] |
ExternalCryptoProvider.hybridDecrypt(HybridEncryptionOutput hybridEncryptionOutput,
String symmetricAlgorithm,
String asymmetricAlgorithm,
String javaSecurityProvider,
CryptoContext cryptoContext,
PrivateKeyInfo privateKeyInfo)
Computes and return clear data based on provided
HybridEncryptionOutput. |
default HybridEncryptionOutput |
CryptoService.hybridEncrypt(HybridEncryptionInput hybridEncryptionInput,
String symmetricAlgorithm,
String asymmetricAlgorithm,
String javaSecurityProvider,
CryptoContext cryptoContext)
In hybrid encryption clear data is encrypted using symmetric encryption mechanism
and symmetric key used for encryption is encrypted with asymmetric encryption.
|
default HybridEncryptionOutput |
ExternalCryptoProvider.hybridEncrypt(HybridEncryptionInput hybridEncryptionInput,
String symmetricAlgorithm,
String asymmetricAlgorithm,
String javaSecurityProvider,
CryptoContext cryptoContext,
CertificateInfo certificateInfo)
Computes and return a
HybridEncryptionOutput based on provided HybridEncryptionInput. |
abstract boolean |
KeyResolver.isApplicable(CryptoContext cryptoContext)
Checks whether this resolver is applicable for the given context.
|
byte[] |
CryptoService.sign(byte[] data,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext)
Computes and returns the signature of given data.
|
byte[] |
ExternalCryptoProvider.sign(byte[] data,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext,
PrivateKeyInfo privateKeyInfo)
Computes and returns the signature of given data.
|
boolean |
CryptoService.verifySignature(byte[] data,
byte[] signature,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext)
Verifies whether given signature of the given data was generated by a trusted external party.
|
boolean |
ExternalCryptoProvider.verifySignature(byte[] data,
byte[] signature,
String algorithm,
String javaSecurityAPIProvider,
CryptoContext cryptoContext,
CertificateInfo certificateInfo)
Verifies whether given signature of the given data was generated by a trusted external party.
|
Copyright © 2019 WSO2. All rights reserved.