Cannot decrypt the same hash on another host with different OpenSSL version.
by czezz from LinuxQuestions.org on (#5E19V)
On HOST-1 following OpenSSL version is installed.
1. I encrypt string, using SSL and the hash is given as: VBIyVmy7wKFlFg==
2. Decrypt gives expected string
Code:OpenSSL> version
OpenSSL 1.1.1 11 Sep 2018
$ echo 'password1' | openssl enc -base64 -e -aes-256-cfb -nosalt -pass pass:secret
VBIyVmy7wKFlFg==
$ echo 'VBIyVmy7wKFlFg==' | openssl enc -base64 -d -aes-256-cfb -nosalt -pass pass:secret
password1BUT on another system - HOST2 - with another OpenSSL version installed, the same hash cannot be decrypted. It gives a rubbish. Why?
Code:OpenSSL> version
OpenSSL 1.0.2k-fips 26 Jan 2017
echo 'VBIyVmy7wKFlFg==' | openssl enc -base64 -d -aes-256-cfb -nosalt -pass pass:secret
F}h&
Note! By encrypting the same string on HOST-2, i get different hash. Why?
Code:echo 'password1' | openssl enc -base64 -e -aes-256-cfb -nosalt -pass pass:secret
KpEHgJcsvbg8Og==


1. I encrypt string, using SSL and the hash is given as: VBIyVmy7wKFlFg==
2. Decrypt gives expected string
Code:OpenSSL> version
OpenSSL 1.1.1 11 Sep 2018
$ echo 'password1' | openssl enc -base64 -e -aes-256-cfb -nosalt -pass pass:secret
VBIyVmy7wKFlFg==
$ echo 'VBIyVmy7wKFlFg==' | openssl enc -base64 -d -aes-256-cfb -nosalt -pass pass:secret
password1BUT on another system - HOST2 - with another OpenSSL version installed, the same hash cannot be decrypted. It gives a rubbish. Why?
Code:OpenSSL> version
OpenSSL 1.0.2k-fips 26 Jan 2017
echo 'VBIyVmy7wKFlFg==' | openssl enc -base64 -d -aes-256-cfb -nosalt -pass pass:secret
F}h&
Note! By encrypting the same string on HOST-2, i get different hash. Why?
Code:echo 'password1' | openssl enc -base64 -e -aes-256-cfb -nosalt -pass pass:secret
KpEHgJcsvbg8Og==