Class XMLCipher.Factory.EncryptionMethodImpl
java.lang.Object
org.apache.xml.security.encryption.XMLCipher.Factory.EncryptionMethodImpl
- All Implemented Interfaces:
EncryptionMethod
- Enclosing class:
XMLCipher.Factory
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds encryption method information.Returns the algorithm applied to the cipher data.Get the Digest Algorithm to useReturns an iterator over all the additional elements contained in theEncryptionMethod
.int
Returns the key size of the key of the algorithm applied to the cipher data.Get the MGF Algorithm to usebyte[]
Returns the OAEP parameters of the algorithm applied applied to the cipher data.void
Removes encryption method information.void
setDigestAlgorithm
(String digestAlgorithm) Set the Digest Algorithm to usevoid
setKeySize
(int size) Sets the size of the key of the algorithm applied to the cipher data.void
setMGFAlgorithm
(String mgfAlgorithm) Set the MGF Algorithm to usevoid
setOAEPparams
(byte[] params) Sets the OAEP parameters.(package private) Element
-
Field Details
-
algorithm
-
keySize
private int keySize -
oaepParams
private byte[] oaepParams -
encryptionMethodInformation
-
digestAlgorithm
-
mgfAlgorithm
-
-
Constructor Details
-
EncryptionMethodImpl
Constructor.- Parameters:
algorithm
-
-
-
Method Details
-
getAlgorithm
Returns the algorithm applied to the cipher data.- Specified by:
getAlgorithm
in interfaceEncryptionMethod
- Returns:
- the encryption algorithm.
-
getKeySize
public int getKeySize()Returns the key size of the key of the algorithm applied to the cipher data.- Specified by:
getKeySize
in interfaceEncryptionMethod
- Returns:
- the key size.
-
setKeySize
public void setKeySize(int size) Sets the size of the key of the algorithm applied to the cipher data.- Specified by:
setKeySize
in interfaceEncryptionMethod
- Parameters:
size
- the key size.
-
getOAEPparams
public byte[] getOAEPparams()Returns the OAEP parameters of the algorithm applied applied to the cipher data.- Specified by:
getOAEPparams
in interfaceEncryptionMethod
- Returns:
- the OAEP parameters.
-
setOAEPparams
public void setOAEPparams(byte[] params) Sets the OAEP parameters.- Specified by:
setOAEPparams
in interfaceEncryptionMethod
- Parameters:
params
- the OAEP parameters.
-
setDigestAlgorithm
Set the Digest Algorithm to use- Specified by:
setDigestAlgorithm
in interfaceEncryptionMethod
- Parameters:
digestAlgorithm
- the Digest Algorithm to use
-
getDigestAlgorithm
Get the Digest Algorithm to use- Specified by:
getDigestAlgorithm
in interfaceEncryptionMethod
- Returns:
- the Digest Algorithm to use
-
setMGFAlgorithm
Set the MGF Algorithm to use- Specified by:
setMGFAlgorithm
in interfaceEncryptionMethod
- Parameters:
mgfAlgorithm
- the MGF Algorithm to use
-
getMGFAlgorithm
Get the MGF Algorithm to use- Specified by:
getMGFAlgorithm
in interfaceEncryptionMethod
- Returns:
- the MGF Algorithm to use
-
getEncryptionMethodInformation
Returns an iterator over all the additional elements contained in theEncryptionMethod
.- Specified by:
getEncryptionMethodInformation
in interfaceEncryptionMethod
- Returns:
- an
Iterator
over all the additional information about theEncryptionMethod
.
-
addEncryptionMethodInformation
Adds encryption method information.- Specified by:
addEncryptionMethodInformation
in interfaceEncryptionMethod
- Parameters:
info
- additional encryption method information.
-
removeEncryptionMethodInformation
Removes encryption method information.- Specified by:
removeEncryptionMethodInformation
in interfaceEncryptionMethod
- Parameters:
info
- the information to remove from theEncryptionMethod
.
-
toElement
Element toElement()
-