public class EncryptionInfo extends Object
| Modifier and Type | Field and Description |
|---|---|
static BitField |
flagAES
A value that MUST be 1 if the protected content is an ECMA-376 document
ECMA-376.
|
static BitField |
flagCryptoAPI
A flag that specifies whether CryptoAPI RC4 or ECMA-376 encryption
ECMA-376 is used.
|
static BitField |
flagDocProps
A value that MUST be 0 if document properties are encrypted.
|
static BitField |
flagExternal
A value that MUST be 1 if extensible encryption is used.
|
| Constructor and Description |
|---|
EncryptionInfo(DirectoryNode dir)
Opens for decryption
|
EncryptionInfo(DirectoryNode dir,
EncryptionMode encryptionMode)
Deprecated.
Use
EncryptionInfo(EncryptionMode) (dir parameter no longer required) |
EncryptionInfo(DirectoryNode dir,
EncryptionMode encryptionMode,
CipherAlgorithm cipherAlgorithm,
HashAlgorithm hashAlgorithm,
int keyBits,
int blockSize,
ChainingMode chainingMode)
|
EncryptionInfo(EncryptionMode encryptionMode)
Prepares for encryption, using the given Encryption Mode, and
all other parameters as default.
|
EncryptionInfo(EncryptionMode encryptionMode,
CipherAlgorithm cipherAlgorithm,
HashAlgorithm hashAlgorithm,
int keyBits,
int blockSize,
ChainingMode chainingMode)
Constructs an EncryptionInfo from scratch
|
EncryptionInfo(LittleEndianInput dis,
boolean isCryptoAPI) |
EncryptionInfo(NPOIFSFileSystem fs)
Opens for decryption
|
EncryptionInfo(NPOIFSFileSystem fs,
EncryptionMode encryptionMode)
Deprecated.
Use
EncryptionInfo(EncryptionMode) (fs parameter no longer required) |
EncryptionInfo(NPOIFSFileSystem fs,
EncryptionMode encryptionMode,
CipherAlgorithm cipherAlgorithm,
HashAlgorithm hashAlgorithm,
int keyBits,
int blockSize,
ChainingMode chainingMode)
|
EncryptionInfo(OPOIFSFileSystem fs)
Opens for decryption
|
EncryptionInfo(POIFSFileSystem fs)
Opens for decryption
|
EncryptionInfo(POIFSFileSystem fs,
EncryptionMode encryptionMode)
Deprecated.
Use
EncryptionInfo(EncryptionMode) (fs parameter no longer required) |
EncryptionInfo(POIFSFileSystem fs,
EncryptionMode encryptionMode,
CipherAlgorithm cipherAlgorithm,
HashAlgorithm hashAlgorithm,
int keyBits,
int blockSize,
ChainingMode chainingMode)
|
| Modifier and Type | Method and Description |
|---|---|
protected static EncryptionInfoBuilder |
getBuilder(EncryptionMode encryptionMode) |
Decryptor |
getDecryptor() |
int |
getEncryptionFlags() |
Encryptor |
getEncryptor() |
EncryptionHeader |
getHeader() |
EncryptionVerifier |
getVerifier() |
int |
getVersionMajor() |
int |
getVersionMinor() |
public static BitField flagCryptoAPI
public static BitField flagDocProps
public static BitField flagExternal
public static BitField flagAES
public EncryptionInfo(POIFSFileSystem fs) throws IOException
IOExceptionpublic EncryptionInfo(OPOIFSFileSystem fs) throws IOException
IOExceptionpublic EncryptionInfo(NPOIFSFileSystem fs) throws IOException
IOExceptionpublic EncryptionInfo(DirectoryNode dir) throws IOException
IOExceptionpublic EncryptionInfo(LittleEndianInput dis, boolean isCryptoAPI) throws IOException
IOException@Deprecated public EncryptionInfo(POIFSFileSystem fs, EncryptionMode encryptionMode)
EncryptionInfo(EncryptionMode) (fs parameter no longer required)@Deprecated public EncryptionInfo(NPOIFSFileSystem fs, EncryptionMode encryptionMode)
EncryptionInfo(EncryptionMode) (fs parameter no longer required)@Deprecated public EncryptionInfo(DirectoryNode dir, EncryptionMode encryptionMode)
EncryptionInfo(EncryptionMode) (dir parameter no longer required)@Deprecated public EncryptionInfo(POIFSFileSystem fs, EncryptionMode encryptionMode, CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
@Deprecated public EncryptionInfo(NPOIFSFileSystem fs, EncryptionMode encryptionMode, CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
@Deprecated public EncryptionInfo(DirectoryNode dir, EncryptionMode encryptionMode, CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
public EncryptionInfo(EncryptionMode encryptionMode)
public EncryptionInfo(EncryptionMode encryptionMode, CipherAlgorithm cipherAlgorithm, HashAlgorithm hashAlgorithm, int keyBits, int blockSize, ChainingMode chainingMode)
encryptionMode - see EncryptionMode for values, EncryptionMode.cryptoAPI is for
internal use only, as it's record basedcipherAlgorithm - hashAlgorithm - keyBits - blockSize - chainingMode - EncryptedDocumentException - if the given parameters mismatch, e.g. only certain combinations
of keyBits, blockSize are allowed for a given CipherAlgorithmprotected static EncryptionInfoBuilder getBuilder(EncryptionMode encryptionMode) throws ClassNotFoundException, IllegalAccessException, InstantiationException
public int getVersionMajor()
public int getVersionMinor()
public int getEncryptionFlags()
public EncryptionHeader getHeader()
public EncryptionVerifier getVerifier()
public Decryptor getDecryptor()
public Encryptor getEncryptor()
Copyright © 2007-2020. All Rights Reserved.