Home >> All >> gnu >> javax >> crypto >> [ mode Javadoc ] |

**•**

**gnu.javax.crypto.mode**: Javadoc index of package gnu.javax.crypto.mode.

**Package Samples:**

**•**gnu.javax.crypto.mode

**Classes:**

**•**OFB: The Output Feedback (OFB) mode is a confidentiality mode that requires a unique IV for every message that is ever encrypted under the given key. The OFB mode is defined as follows: OFB Encryption: I 1 = IV; I j = O j -1 for j = 2...n; O j = CIPH K (I j ) for j = 1, 2...n; C j = P j XOR O j for j = 1, 2...n. OFB Decryption: I 1 = IV; I j = O j -1 for j = 2...n; O j = CIPH K (I j ) for j = 1, 2...n; P j = C j XOR O j for j = 1, 2...n. In OFB encryption, the IV is transformed by the forward cipher function to produce the first output block. The first output block is exclusive-ORed with the first plaintext ...

**•**ICM: An implementation of David McGrew Integer Counter Mode (ICM) as an IMode . ICM is a way to define a pseudorandom keystream generator using a block cipher. The keystream can be used for additive encryption, key derivation, or any other application requiring pseudorandom data. In the case of this class, it is used as additive encryption, XOR-ing the keystream with the input text --for both encryption and decryption. In ICM, the keystream is logically broken into segments. Each segment is identified with a segment index, and the segments have equal lengths. This segmentation makes ICM especially appropriate ...

**•**IMode: The basic visible methods of any block cipher mode. Block ciphers encrypt plaintext in fixed size n-bit blocks. For messages larger than n bits, the simplest approach is to segment the message into n-bit blocks and process (encrypt and/or decrypt) each one separately (Electronic Codebook or ECB mode). But this approach has disadvantages in most applications. The block cipher modes of operations are one way of working around those disadvantages. A Mode always employs an underlying block cipher for processing its input. For all intents and purposes, a Mode appears to behave as any other block cipher ...

**•**EAX: A conventional two-pass authenticated-encrypted mode, EAX. EAX is a Authenticated Encryption with Additional Data ( AEAD ) scheme, which provides protection and authentication for the message, and provides authentication of an (optional) header. EAX is composed of the counter mode (CTR) and the one-key CBC MAC (OMAC). This class makes full use of the IAuthenticatedMode interface, that is, all methods of both IMode and gnu.javax.crypto.mac.IMac can be used as specified in the IAuthenticatedMode interface. References: M. Bellare, P. Rogaway, and D. Wagner; A Conventional Authenticated-Encryption ...

**•**CFB: The cipher feedback mode. CFB mode is a stream mode that operates on s bit blocks, where 1 <= s <= b , if b is the underlying cipher's block size. Encryption is: I[1] = IV I[j] = LSB(b-s, I[j-1]) | C[j-1] for j = 2...n O[j] = CIPH(K, I[j]) for j = 1,2...n C[j] = P[j] ^ MSB(s, O[j]) for j = 1,2...n And decryption is: I[1] = IV I[j] = LSB(b-s, I[j-1]) | C[j-1] for j = 2...n O[j] = CIPH(K, I[j]) for j = 1,2...n P[j] = C[j] ^ MSB(s, O[j]) for j = 1,2...n CFB mode requires an initialization vector, which need not be kept secret. References: Bruce Schneier, Applied Cryptography: Protocols, Algorithms, ...

**•**CTR: The implementation of the Counter Mode. The algorithm steps are formally described as follows: CTR Encryption: O[j] = E(K)(T[j]); for j = 1, 2...n; C[j] = P[j] ^ O[j]; for j = 1, 2...n. CTR Decryption: O[j] = E(K)(T[j]); for j = 1, 2...n; P[j] = C[j] ^ O[j]; for j = 1, 2...n. where P is the plaintext, C is the ciphertext, E(K) is the underlying block cipher encryption function parametrised with the session key K , and T is the Counter . This implementation, uses a standard incrementing function with a step of 1, and an initial value similar to that described in the NIST document. References: Recommendation ...

**•**ECB: The implementation of the Electronic Codebook mode. The Electronic Codebook (ECB) mode is a confidentiality mode that is defined as follows: ECB Encryption: C j = CIPH K (P j ) for j = 1...n ECB Decryption: P j = CIPH -1 K (C j ) for j = 1...n In ECB encryption, the forward cipher function is applied directly, and independently, to each block of the plaintext. The resulting sequence of output blocks is the ciphertext. In ECB decryption, the inverse cipher function is applied directly, and independently, to each block of the ciphertext. The resulting sequence of output blocks is the plaintext. References: ...

**•**IAuthenticatedMode: The interface for encryption modes that also produce a message authentication tag. This interface is merely the conjuction of the IMode and gnu.javax.crypto.mac.IMac interfaces. Encryption and decryption is done via the IMode.update(byte[],int,byte[],int) 55 method, tag generation is done via the IMac.digest() > IMac.digest() 55 method, and header updating (if supported by the mode) is done via the IMac.update(byte[],int,int) > IMac.update(byte[],int,int) 55 method.

**•**CBC: The Cipher Block Chaining mode. This mode introduces feedback into the cipher by XORing the previous ciphertext block with the plaintext block before encipherment. That is, encrypting looks like this: C i = E K (P i ^ C i-1 Similarly, decrypting is: P i = C i-1 ^ D K (C i )

**•**BaseMode: A basic abstract class to facilitate implementing block cipher modes of operations.

**•**ModeFactory: A Factory to instantiate block cipher modes of operations.

Home | Contact Us | Privacy Policy | Terms of Service |