figdice / symcrypt
Simple symmetric cryptography
dev-master
2015-10-20 08:01 UTC
Requires
None
Requires (Dev)
- phpunit/phpunit: ^5.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is not auto-updated.
Last update: 2026-08-30 03:45:30 UTC
README
Provides an easy and secure way to encrypt/decrypt data with PHP using the Symmetric Cryptography method, a low cost algorithm that works based on the shared keys conecpt.
<?php
require_once 'Crypt/Crypt.php';
$crypt = new Crypt();
$crypt->Mode = Crypt::MODE_HEX;
$crypt->Key = '!@#$%&*()_+?:';
$encrypted = $crypt->encrypt('my test');
echo $crypt->decrypt($encrypted);
?>