public class SimpleEncryptor extends Object implements JsonEncryptor
x-simple-encryption type $crypto JSON object.| Modifier and Type | Field and Description |
|---|---|
static String |
TYPE
The type of cryptographic representation that this encryptor supports.
|
| Constructor and Description |
|---|
SimpleEncryptor(String cipher,
Key key,
String alias)
Constructs a new simple encryptor for the specified cipher, key and alias.
|
| Modifier and Type | Method and Description |
|---|---|
JsonValue |
encrypt(JsonValue value)
Encrypts the specified value.
|
String |
getType()
Returns the type of cryptographic representation that this JSON encryptor supports.
|
public static final String TYPE
public String getType()
JsonEncryptortype property of a JsonCrypto object.getType in interface JsonEncryptorpublic JsonValue encrypt(JsonValue value) throws JsonCryptoException
JsonEncryptorencrypt in interface JsonEncryptorvalue - the JSON value to be encrypted.JsonCryptoException - if the encryptor fails to encrypt the value.Copyright © 2025 Open Identity Platform Community. All rights reserved.