Méthode | Description | |
---|---|---|
BlowfishCrypt ( ) : System | ||
BlowfishCrypt ( byte cipherKey ) : System |
Constructor for byte key
|
|
BlowfishCrypt ( string hexKey ) : System |
Constructor for hex key
|
|
Crypt_CTR ( byte text, int numThreads ) : byte[] | ||
Decrypt ( string ct ) : string | ||
Decrypt_CBC ( byte ct ) : byte[] |
Decrypts a byte array in CBC mode. IV must be created and saved manually.
|
|
Decrypt_CBC ( string ct ) : string |
Decrypts a string in CBC mode
|
|
Decrypt_CTR ( string ct ) : string |
Decrypt a string (CTR)
|
|
Decrypt_ECB ( byte ct ) : byte[] |
Decrypts a byte array (ECB)
|
|
Decrypt_ECB ( string ct ) : string |
Decrypts a string (ECB)
|
|
Encrypt ( string pt ) : string | ||
Encrypt_CBC ( byte pt ) : byte[] |
Encrypts a byte array in CBC mode. IV must be created and saved manually.
|
|
Encrypt_CBC ( string pt ) : string |
Encrypts a string in CBC mode
|
|
Encrypt_CTR ( string pt ) : string |
Encrypts a string (CTR)
|
|
Encrypt_ECB ( byte pt ) : byte[] |
Encrypts a byte array in ECB mode
|
|
Encrypt_ECB ( string pt ) : string |
Encrypt a string in ECB mode
|
|
SetKey ( byte key ) : void | ||
SetKey ( string key ) : void | ||
SetRandomIV ( ) : byte[] |
Creates and sets a random initialization vector.
|
Méthode | Description | |
---|---|---|
BlockDecrypt ( byte &block ) : void |
Decrypts a 64 bit block
|
|
BlockEncrypt ( byte &block ) : void |
Encrypts a 64 bit block
|
|
ByteToHex ( byte bytes ) : string | ||
Crypt_CBC ( byte text, bool decrypt ) : byte[] |
Encrypts or decrypts data in CBC mode
|
|
Crypt_ECB ( byte text, bool decrypt ) : byte[] |
Encrypts or decrypts data in ECB mode
|
|
GetBlock ( byte &block ) : void |
Converts the two uint values into a 64 bit block
|
|
GetHex ( char x ) : byte | ||
HexToByte ( string hex ) : byte[] | ||
SetBlock ( byte block ) : void |
Splits the block into the two uint values
|
|
SetupKey ( byte cipherKey ) : void |
Sets up the S-blocks and the key
|
|
SetupP ( ) : uint[] | ||
SetupS0 ( ) : uint[] | ||
SetupS1 ( ) : uint[] | ||
SetupS2 ( ) : uint[] | ||
SetupS3 ( ) : uint[] | ||
XorBlock ( byte &block, byte iv ) : void |
XoR encrypts two 8 bit blocks
|
|
decipher ( ) : void |
Runs the blowfish algorithm in reverse (standard 16 rounds)
|
|
encipher ( ) : void |
Runs the blowfish algorithm (standard 16 rounds)
|
|
round ( uint a, uint b, uint n ) : uint |
one round of the blowfish algorithm
|
|
wordByte0 ( uint w ) : byte | ||
wordByte1 ( uint w ) : byte | ||
wordByte2 ( uint w ) : byte | ||
wordByte3 ( uint w ) : byte |
public BlowfishCrypt ( byte cipherKey ) : System | ||
cipherKey | byte | Cipher key as a byte array |
Résultat | System |
public BlowfishCrypt ( string hexKey ) : System | ||
hexKey | string | Cipher key as a hex string |
Résultat | System |
public Crypt_CTR ( byte text, int numThreads ) : byte[] | ||
text | byte | |
numThreads | int | |
Résultat | byte[] |
public Decrypt_CBC ( byte ct ) : byte[] | ||
ct | byte | Ciphertext data to decrypt |
Résultat | byte[] |
public Decrypt_CBC ( string ct ) : string | ||
ct | string | Ciphertext with IV appended to front |
Résultat | string |
public Decrypt_CTR ( string ct ) : string | ||
ct | string | The ciphertext to decrypt |
Résultat | string |
public Decrypt_ECB ( byte ct ) : byte[] | ||
ct | byte | Ciphertext byte array |
Résultat | byte[] |
public Decrypt_ECB ( string ct ) : string | ||
ct | string | hHex string of the ciphertext |
Résultat | string |
public Encrypt_CBC ( byte pt ) : byte[] | ||
pt | byte | Plaintext data to encrypt |
Résultat | byte[] |
public Encrypt_CBC ( string pt ) : string | ||
pt | string | Plaintext data to encrypt |
Résultat | string |
public Encrypt_CTR ( string pt ) : string | ||
pt | string | The plaintext to encrypt |
Résultat | string |
public Encrypt_ECB ( byte pt ) : byte[] | ||
pt | byte | Plaintext data |
Résultat | byte[] |
public Encrypt_ECB ( string pt ) : string | ||
pt | string | Plaintext to encrypt as ascii string |
Résultat | string |