Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Username: example
- Password: password
- <?php
- $source = 'very long text';
- $iv = "1234567812345678";
- $pass = 'difficultpassphrase';
- $method = 'aes-256-ofb';
- $encrypted = openssl_encrypt ($source, $method, $pass, true, $iv);
- echo $encrypted;
- $decrypted = openssl_decrypt ($encrypted, $method, $pass, true, $iv);
- echo $decrypted;
- ?>
Add Comment
Please, Sign In to add comment