OpenSSL Encryption

Text to encrypt : There ain't no such thing as a free lunch.

iv in plaintext to use : Desperately
password in plaintext to use : Seeking Susan

iv in hex to use : 4465737065726174656c792020202020
password in hex to use : 5365656b696e6720537573616e

$ciphertext = openssl_encrypt( $source, $cipher, $key, $options=0, $ivhex, $tag )
Encrypted text : NpcTIzBwkeDY1XB6jiOFtkr6cITsAJRQS2Ri+EUWg2Adh7L+8iS+Y8HJ

$original_source = openssl_decrypt( $ciphertext, $cipher, $key, $options=0, $ivhex, $tag )
Decrypted text : There ain't no such thing as a free lunch.


PHP code as textfile

Source ➠ http://php.net/manual/en/function.openssl-encrypt.php

Jul 04 2022 17:03:48