Public Member Functions |
| encrypt ($sValue, $sSecretKey) |
| decrypt ($sValue, $sSecretKey) |
Detailed Description
Definition at line 3 of file m_crypto.php.
Member Function Documentation
decrypt |
( |
|
$sValue, |
|
|
|
$sSecretKey |
|
) |
| |
Definition at line 25 of file m_crypto.php.
{
return rtrim(
mcrypt_decrypt(
MCRYPT_RIJNDAEL_256,
$sSecretKey,
base64_decode($sValue),
MCRYPT_MODE_ECB,
mcrypt_create_iv(
mcrypt_get_iv_size(
MCRYPT_RIJNDAEL_256,
MCRYPT_MODE_ECB
),
MCRYPT_RAND
)
), "\0"
);
}
encrypt |
( |
|
$sValue, |
|
|
|
$sSecretKey |
|
) |
| |
Definition at line 5 of file m_crypto.php.
{
return rtrim(
base64_encode(
mcrypt_encrypt(
MCRYPT_RIJNDAEL_256,
$sSecretKey, $sValue,
MCRYPT_MODE_ECB,
mcrypt_create_iv(
mcrypt_get_iv_size(
MCRYPT_RIJNDAEL_256,
MCRYPT_MODE_ECB
),
MCRYPT_RAND
)
)
), "\0"
);
}
The documentation for this class was generated from the following file: