arispati / php-encrypt-file
PHP library for encrypt and decrypt file
Installs: 27
Dependents: 1
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/arispati/php-encrypt-file
Requires
- php: ^7|^8
README
PHP library for encrypt and decrypt file
How to Install
- Install with composer
composer require arispati/php-encrypt-file
How to Use
use Arispati\PhpEncryptFile\Crypt; // by default use 'AES-256-CBC' cipher // you can change it on the second argument $crypt = new Crypt('your-secret-key'); // to encrypt $crypt->encrypt('./path/to/plainFile.ext', './path/to/encryptedFile.ext'); // to decrypt $crypt->decrypt('./path/to/encryptedFile.ext', './path/to/decryptedFile.ext');
Credits
- Thanks to Antoine Lamé - Medium.