Class CryptoAPIEncryptionHeader
- java.lang.Object
-
- org.apache.poi.poifs.crypt.EncryptionHeader
-
- org.apache.poi.poifs.crypt.standard.StandardEncryptionHeader
-
- org.apache.poi.poifs.crypt.cryptoapi.CryptoAPIEncryptionHeader
-
- All Implemented Interfaces:
Duplicatable
,GenericRecord
,EncryptionRecord
public class CryptoAPIEncryptionHeader extends StandardEncryptionHeader
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
CryptoAPIEncryptionHeader(CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
protected
CryptoAPIEncryptionHeader(CryptoAPIEncryptionHeader other)
CryptoAPIEncryptionHeader(LittleEndianInput is)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CryptoAPIEncryptionHeader
copy()
void
setKeySize(int keyBits)
Sets the keySize (in bits).-
Methods inherited from class org.apache.poi.poifs.crypt.standard.StandardEncryptionHeader
write
-
Methods inherited from class org.apache.poi.poifs.crypt.EncryptionHeader
getBlockSize, getChainingMode, getCipherAlgorithm, getCipherProvider, getCspName, getFlags, getGenericProperties, getHashAlgorithm, getKeySalt, getKeySize, getSizeExtra, setBlockSize, setChainingMode, setCipherAlgorithm, setCipherProvider, setCspName, setFlags, setHashAlgorithm, setKeySalt, setSizeExtra
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.poi.common.usermodel.GenericRecord
getGenericChildren, getGenericRecordType
-
-
-
-
Constructor Detail
-
CryptoAPIEncryptionHeader
public CryptoAPIEncryptionHeader(LittleEndianInput is) throws IOException
- Throws:
IOException
-
CryptoAPIEncryptionHeader
protected CryptoAPIEncryptionHeader(CryptoAPIEncryptionHeader other)
-
CryptoAPIEncryptionHeader
protected CryptoAPIEncryptionHeader(CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
-
-
Method Detail
-
setKeySize
public void setKeySize(int keyBits)
Description copied from class:EncryptionHeader
Sets the keySize (in bits). Before calling this method, make sure to set the cipherAlgorithm, as the amount of keyBits gets validated against the list of allowed keyBits of the corresponding cipherAlgorithm- Overrides:
setKeySize
in classEncryptionHeader
-
copy
public CryptoAPIEncryptionHeader copy()
- Specified by:
copy
in interfaceDuplicatable
- Overrides:
copy
in classStandardEncryptionHeader
- Returns:
- a deep copy of the implementing class / instance
-
-