Class: SmartCipherCrypto
Provides a built-in based feature to handle the Blowfish (CBC) encryption / decryption.
This provides an advanced crypto handler for Blowfish CBC algorithm.
Hints: Blowfish is a 64-bit (8 bytes) block cipher. Max Key is up to 56 chars length (56 bytes = 448 bits). The CBC mode requires a initialization vector (iv).
Usage: static object: Class::method() - This class provides only STATIC methods
class Methods
public staticfunctionencrypt (
string$cipher,
string$key,
string$data
) {} :: STRING
@return: {STRING} The encrypted data as B64S or empty string on error
@param: {ENUM} $cipher: Selected cipher: hash/{mode}, blowfish.cbc, openssl/cipher/mode
@param: {STRING} $key: The encryption key (must be between 7 and 4096 bytes)
@param: {STRING} $data: The plain data to be encrypted
Encrypts a string using the selected Cipher Algo.
public staticfunctiondecrypt (
string$cipher,
string$key,
string$data
) {} :: STRING
@return: {STRING} The plain (decrypted) data or empty string on error
@param: {ENUM} $cipher: Selected cipher: hash/{mode}, blowfish.cbc, openssl/cipher/mode
@param: {STRING} $key: The encryption key (must be between 7 and 4096 bytes)
@param: {STRING} $data: The encrypted data
Provides a built-in based feature to handle the Blowfish (CBC) encryption / decryption.
This provides an advanced crypto handler for Blowfish CBC algorithm.