All Packages Class Hierarchy This Package Previous Next Index
Class is.hi.logir.cryptonite.DecryptCFB
java.lang.Object
|
+----is.hi.logir.cryptonite.Cryptonite
|
+----is.hi.logir.cryptonite.DecryptMode
|
+----is.hi.logir.cryptonite.DecryptCFB
- public class DecryptCFB
- extends DecryptMode
Use this class to decrypt ciphertext generated by EncryptCFB.
Note that unlike ECB or CBC mode, CFB mode uses teh same
key to encrypt and decrypt, even with asymmetric ciphers.
- Author:
- Logi Ragnarsson
(logir@hi.is)
- See Also:
- EncryptCFB
-
DecryptCFB()
- Create a new CFB-mode decrypt session with no key.
-
DecryptCFB(CipherKey)
-
Create a new CFB-mode decrypt session with the specified key.
-
decrypt(byte[], int, int)
- Decrypt
length
bytes from source
,
starting at i
and return the plaintext.
-
getKey()
-
Return the key used for decryption.
-
setKey(CipherKey)
- Set the key to use for decryption.
DecryptCFB
public DecryptCFB(CipherKey key)
- Create a new CFB-mode decrypt session with the specified key.
DecryptCFB
public DecryptCFB()
- Create a new CFB-mode decrypt session with no key. No decryption
can be performed until a call to
setKey()
has been
made.
getKey
public CipherKey getKey()
- Return the key used for decryption.
- Overrides:
- getKey in class DecryptMode
setKey
public void setKey(CipherKey key)
- Set the key to use for decryption.
- Overrides:
- setKey in class DecryptMode
decrypt
public synchronized byte[] decrypt(byte source[],
int i,
int length)
- Decrypt
length
bytes from source
,
starting at i
and return the plaintext. All data
is decrypted immediately.
- Overrides:
- decrypt in class DecryptMode
All Packages Class Hierarchy This Package Previous Next Index