optiwariindia / cryptography
Easy encryption with AES algo
1.0
2021-07-07 02:07 UTC
Requires
- lib-openssl: *
This package is auto-updated.
Last update: 2025-07-07 10:51:44 UTC
README
Features
- Multiple Algorithum Support
- Installable thorugh composer
- Multilanguage Exceptions
- Easy Setup and use
Why should you use
We have been working on many encryption methods and implementing them into the project. The basic idea of this library is to make your project secure enough for your customers. You can store important information like credentials etc.
How to use
Installation
Install using composer
composer require optiwariindia/cryptography
Initialize
$crypt=new optiwariindia\cryptography();
List Supported Algorithms
print_r($crypt->listAlgo());
Encrypt
$crypt->algo("AES-128-CBC");
$iv=$crypt->iv();
$crypt->key("SuperSecretKey");
list($cypher,$tag)=$crypt->encrypt("message");
Decrypt
$crypt->algo("AES-128-CBC");
$iv=$crypt->iv();
$crypt->key("SuperSecretKey");
$text=$crypt->decrypt($cypher,$tag);