Crypt::Eksblowfish::Subkeyed

Crypt::Eksblowfish::Subkeyed - Blowfish/Eksblowfish with access to subkeys.
Download

Crypt::Eksblowfish::Subkeyed Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Andrew Main
  • Publisher web site:
  • http://search.cpan.org/~zefram/

Crypt::Eksblowfish::Subkeyed Tags


Crypt::Eksblowfish::Subkeyed Description

Crypt::Eksblowfish::Subkeyed - Blowfish/Eksblowfish with access to subkeys. Crypt::Eksblowfish::Subkeyed - Blowfish/Eksblowfish with access to subkeys.SYNOPSIS use Crypt::Eksblowfish::Subkeyed; $block_size = Crypt::Eksblowfish::Subkeyed->blocksize; $cipher = Crypt::Eksblowfish::Subkeyed ->new_from_subkeys(@p_array, @s_boxes); $cipher = Crypt::Eksblowfish::Subkeyed->new_initial; $block_size = $cipher->blocksize; $ciphertext = $cipher->encrypt($plaintext); $plaintext = $cipher->decrypt($ciphertext); $p_array = $cipher->p_array; $s_boxes = $cipher->s_boxes; if($cipher->is_weak) { ...An object of this class encapsulates a keyed instance of the Blowfish or Eksblowfish block cipher, ready to encrypt and decrypt. Normally this class will not be used directly, but through subclasses such as Crypt::Eksblowfish.Eksblowfish is a variant of the Blowfish cipher with a modified key setup algorithm. This class doesn't implement either form of key setup, but only provides the actual encryption and decryption parts of the ciphers. This part is shared between Blowfish and Eksblowfish, and also any other cipher that uses the core of Blowfish but supplies its own key setup. This class has "Eksblowfish" in its name rather than "Blowfish" merely due to the historical accident that it is derived from the encryption engine that was used to implement Eksblowfish.The key setup phase of a block cipher, also known as the "key schedule", produces a set of "subkeys", which are somewhat like ordinary cryptographic keys (which are the input to the key setup algorithm) but are much larger. In some block ciphers the subkeys also have special interrelationships. In Blowfish the subkeys consist of a "P-array" of 18 32-bit entries (one per encryption round plus two more) and four "S-boxes" ("S" is for "substitution") each of which consists of 256 32-bit entries. There is no special relationship between the values of the subkeys.Methods in this class allow a cipher object to be constructed from a full set of subkeys, and for the subkeys to be extracted from a cipher object. Normal users don't need to do either of these things. It's mainly useful when devising a new key schedule to stick onto the Blowfish core, or when performing cryptanalysis of the cipher algorithm.Generating subkeys directly by a strong random process, rather than by expansion of a smaller random key, is an expensive and slightly bizarre way to get greater cryptographic strength from a cipher algorithm. It eliminates attacks on the key schedule, and yields the full strength of the core algorithm. However, this is always a lot less strength than the amount of subkey material, whereas a normal key schedule is designed to yield strength equal to the length of the (much shorter) key. Also, any non-randomness in the source of the subkey material is likely to lead to a cryptographic weakness, whereas a key schedule conceals any non-randomness in the choice of the key. Requirements: · Perl


Crypt::Eksblowfish::Subkeyed Related Software