com.healthmarketscience.jackcess.impl
Class OfficeCryptCodecHandler
java.lang.Object
com.healthmarketscience.jackcess.impl.BaseCryptCodecHandler
com.healthmarketscience.jackcess.impl.OfficeCryptCodecHandler
- All Implemented Interfaces:
- com.healthmarketscience.jackcess.impl.CodecHandler
- Direct Known Subclasses:
- BlockCipherProvider, StreamCipherProvider
public abstract class OfficeCryptCodecHandler
- extends BaseCryptCodecHandler
CryptCodecHandler for the Office Document Cryptography standard.
- Author:
- James Ahlborn
|
Constructor Summary |
protected |
OfficeCryptCodecHandler(com.healthmarketscience.jackcess.impl.PageChannel channel,
byte[] encodingKey)
|
|
Method Summary |
protected static int |
bits2bytes(int bits)
|
static com.healthmarketscience.jackcess.impl.CodecHandler |
create(PasswordCallback callback,
com.healthmarketscience.jackcess.impl.PageChannel channel,
Charset charset)
|
void |
decodePage(ByteBuffer inPage,
ByteBuffer outPage,
int pageNumber)
|
protected abstract void |
decodePageImpl(ByteBuffer inPage,
ByteBuffer outPage,
int pageNumber)
|
ByteBuffer |
encodePage(ByteBuffer buffer,
int pageNumber,
int pageOffset)
|
protected abstract ByteBuffer |
encodePageImpl(ByteBuffer buffer,
int pageNumber,
int pageOffset)
|
protected org.bouncycastle.crypto.Digest |
getDigest()
|
protected OfficeCryptCodecHandler.Phase |
getPhase()
|
protected org.bouncycastle.crypto.Digest |
initCryptDigest()
|
protected org.bouncycastle.crypto.Digest |
initDigest()
|
protected org.bouncycastle.crypto.Digest |
initPwdDigest()
|
protected byte[] |
int2bytes(int val)
|
protected byte[] |
iterateHash(byte[] baseHash,
int iterations)
|
protected void |
reset()
|
protected abstract boolean |
verifyPassword(byte[] pwdBytes)
|
| Methods inherited from class com.healthmarketscience.jackcess.impl.BaseCryptCodecHandler |
applyPageNumber, blockDecrypt, blockDecryptBytes, blockEncrypt, computeCipherParams, decryptBytes, decryptBytes, decryptInit, decryptInit, encryptInit, encryptInit, fill, fixToLength, fixToLength, getBlockCipher, getCipherParams, getEncodingKey, getEncodingKey, getStreamCipher, getTempBuffer, hash, hash, hash, hash, isBlankKey, processBytesFully, readHeaderPage, streamDecrypt, streamEncrypt, toString, wrap |
| Methods inherited from interface com.healthmarketscience.jackcess.impl.CodecHandler |
canDecodeInline, canEncodePartialPage |
OfficeCryptCodecHandler
protected OfficeCryptCodecHandler(com.healthmarketscience.jackcess.impl.PageChannel channel,
byte[] encodingKey)
create
public static com.healthmarketscience.jackcess.impl.CodecHandler create(PasswordCallback callback,
com.healthmarketscience.jackcess.impl.PageChannel channel,
Charset charset)
throws IOException
- Throws:
IOException
getPhase
protected OfficeCryptCodecHandler.Phase getPhase()
getDigest
protected org.bouncycastle.crypto.Digest getDigest()
initDigest
protected org.bouncycastle.crypto.Digest initDigest()
initPwdDigest
protected org.bouncycastle.crypto.Digest initPwdDigest()
initCryptDigest
protected org.bouncycastle.crypto.Digest initCryptDigest()
int2bytes
protected final byte[] int2bytes(int val)
reset
protected void reset()
decodePage
public void decodePage(ByteBuffer inPage,
ByteBuffer outPage,
int pageNumber)
throws IOException
- Throws:
IOException
encodePage
public ByteBuffer encodePage(ByteBuffer buffer,
int pageNumber,
int pageOffset)
throws IOException
- Throws:
IOException
iterateHash
protected byte[] iterateHash(byte[] baseHash,
int iterations)
bits2bytes
protected static int bits2bytes(int bits)
decodePageImpl
protected abstract void decodePageImpl(ByteBuffer inPage,
ByteBuffer outPage,
int pageNumber)
throws IOException
- Throws:
IOException
encodePageImpl
protected abstract ByteBuffer encodePageImpl(ByteBuffer buffer,
int pageNumber,
int pageOffset)
throws IOException
- Throws:
IOException
verifyPassword
protected abstract boolean verifyPassword(byte[] pwdBytes)
Copyright © 2010-2017 Health Market Science. All Rights Reserved.