Class XMLCipher.Factory.EncryptionMethodImpl
- java.lang.Object
-
- org.apache.xml.security.encryption.XMLCipher.Factory.EncryptionMethodImpl
-
- All Implemented Interfaces:
EncryptionMethod
- Enclosing class:
- XMLCipher.Factory
private class XMLCipher.Factory.EncryptionMethodImpl extends java.lang.Object implements EncryptionMethod
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Stringalgorithmprivate java.lang.StringdigestAlgorithmprivate java.util.List<org.w3c.dom.Element>encryptionMethodInformationprivate intkeySizeprivate java.lang.StringmgfAlgorithmprivate byte[]oaepParams
-
Constructor Summary
Constructors Constructor Description EncryptionMethodImpl(java.lang.String algorithm)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddEncryptionMethodInformation(org.w3c.dom.Element info)Adds encryption method information.java.lang.StringgetAlgorithm()Returns the algorithm applied to the cipher data.java.lang.StringgetDigestAlgorithm()Get the Digest Algorithm to usejava.util.Iterator<org.w3c.dom.Element>getEncryptionMethodInformation()Returns an iterator over all the additional elements contained in theEncryptionMethod.intgetKeySize()Returns the key size of the key of the algorithm applied to the cipher data.java.lang.StringgetMGFAlgorithm()Get the MGF Algorithm to usebyte[]getOAEPparams()Returns the OAEP parameters of the algorithm applied applied to the cipher data.voidremoveEncryptionMethodInformation(org.w3c.dom.Element info)Removes encryption method information.voidsetDigestAlgorithm(java.lang.String digestAlgorithm)Set the Digest Algorithm to usevoidsetKeySize(int size)Sets the size of the key of the algorithm applied to the cipher data.voidsetMGFAlgorithm(java.lang.String mgfAlgorithm)Set the MGF Algorithm to usevoidsetOAEPparams(byte[] params)Sets the OAEP parameters.(package private) org.w3c.dom.ElementtoElement()
-
-
-
Field Detail
-
algorithm
private java.lang.String algorithm
-
keySize
private int keySize
-
oaepParams
private byte[] oaepParams
-
encryptionMethodInformation
private java.util.List<org.w3c.dom.Element> encryptionMethodInformation
-
digestAlgorithm
private java.lang.String digestAlgorithm
-
mgfAlgorithm
private java.lang.String mgfAlgorithm
-
-
Method Detail
-
getAlgorithm
public java.lang.String getAlgorithm()
Returns the algorithm applied to the cipher data.- Specified by:
getAlgorithmin 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:
getKeySizein 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:
setKeySizein 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:
getOAEPparamsin interfaceEncryptionMethod- Returns:
- the OAEP parameters.
-
setOAEPparams
public void setOAEPparams(byte[] params)
Sets the OAEP parameters.- Specified by:
setOAEPparamsin interfaceEncryptionMethod- Parameters:
params- the OAEP parameters.
-
setDigestAlgorithm
public void setDigestAlgorithm(java.lang.String digestAlgorithm)
Set the Digest Algorithm to use- Specified by:
setDigestAlgorithmin interfaceEncryptionMethod- Parameters:
digestAlgorithm- the Digest Algorithm to use
-
getDigestAlgorithm
public java.lang.String getDigestAlgorithm()
Get the Digest Algorithm to use- Specified by:
getDigestAlgorithmin interfaceEncryptionMethod- Returns:
- the Digest Algorithm to use
-
setMGFAlgorithm
public void setMGFAlgorithm(java.lang.String mgfAlgorithm)
Set the MGF Algorithm to use- Specified by:
setMGFAlgorithmin interfaceEncryptionMethod- Parameters:
mgfAlgorithm- the MGF Algorithm to use
-
getMGFAlgorithm
public java.lang.String getMGFAlgorithm()
Get the MGF Algorithm to use- Specified by:
getMGFAlgorithmin interfaceEncryptionMethod- Returns:
- the MGF Algorithm to use
-
getEncryptionMethodInformation
public java.util.Iterator<org.w3c.dom.Element> getEncryptionMethodInformation()
Returns an iterator over all the additional elements contained in theEncryptionMethod.- Specified by:
getEncryptionMethodInformationin interfaceEncryptionMethod- Returns:
- an
Iteratorover all the additional information about theEncryptionMethod.
-
addEncryptionMethodInformation
public void addEncryptionMethodInformation(org.w3c.dom.Element info)
Adds encryption method information.- Specified by:
addEncryptionMethodInformationin interfaceEncryptionMethod- Parameters:
info- additional encryption method information.
-
removeEncryptionMethodInformation
public void removeEncryptionMethodInformation(org.w3c.dom.Element info)
Removes encryption method information.- Specified by:
removeEncryptionMethodInformationin interfaceEncryptionMethod- Parameters:
info- the information to remove from theEncryptionMethod.
-
toElement
org.w3c.dom.Element toElement()
-
-