Posted on 07-28-2023 06:22 PM
Hi
I've been using this function to decrypt api account password in one of my scripts, and i can see it failing to decrypt in some machines. Different versions of macOS, i really can't see a pattern. Anyone seen something similar?
function decrypt_string() {
apipass=$(echo "$encrypted_string" | openssl enc -aes-256-cbc -d -salt -base64 -A -S "$salt" -k "$passphrase" )
}
Solved! Go to Solution.
Posted on 07-30-2023 10:39 AM
I suggest taking a look at this thread. It may explain the issue and what you need to do to make it work.
FYI: Using EncryptedStrings method for Classic API... - Jamf Nation Community - 257606
Posted on 07-30-2023 10:39 AM
I suggest taking a look at this thread. It may explain the issue and what you need to do to make it work.
FYI: Using EncryptedStrings method for Classic API... - Jamf Nation Community - 257606
Posted on 07-31-2023 03:37 AM
Yep, it was exactly that. Seems that the change was made with 2.9.1 version of Libressl. https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-2.9.1-relnotes.txt
Thanks!