public class CipherTextHandler extends Object
Constructor and Description |
---|
CipherTextHandler() |
Modifier and Type | Method and Description |
---|---|
byte[] |
decrypt(EncryptionKey key,
EncryptedData data,
KeyUsage usage)
Decrypt a block of data.
|
EncryptedData |
encrypt(EncryptionKey key,
byte[] plainText,
KeyUsage usage) |
EncryptedData |
seal(EncryptionKey key,
org.apache.directory.api.asn1.Asn1Object message,
KeyUsage usage)
Performs an encode and an encrypt.
|
public CipherTextHandler()
public EncryptedData seal(EncryptionKey key, org.apache.directory.api.asn1.Asn1Object message, KeyUsage usage) throws KerberosException
key
- The key to use for encrypting.message
- The Kerberos object to encode.usage
- The key usage.KerberosException
- if the seal failedpublic EncryptedData encrypt(EncryptionKey key, byte[] plainText, KeyUsage usage) throws KerberosException
KerberosException
public byte[] decrypt(EncryptionKey key, EncryptedData data, KeyUsage usage) throws KerberosException
key
- The key used to decrypt the datadata
- The data to decryptusage
- The key usage numberKerberosException
- If the decoding failedCopyright © 2003–2020 The Apache Software Foundation. All rights reserved.