From 0f564771788082824dc8f09f11944e916ab27ddc Mon Sep 17 00:00:00 2001 From: shane doucette Date: Wed, 20 Sep 2023 10:26:01 -0600 Subject: [PATCH] Added explicit path to openssl calls --- EncryptedStrings_Bash.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/EncryptedStrings_Bash.sh b/EncryptedStrings_Bash.sh index c7bacf1..da1bbf4 100755 --- a/EncryptedStrings_Bash.sh +++ b/EncryptedStrings_Bash.sh @@ -8,9 +8,9 @@ function GenerateEncryptedString() { # Usage ~$ GenerateEncryptedString "String" local STRING="${1}" - local SALT=$(openssl rand -hex 8) - local K=$(openssl rand -hex 12) - local ENCRYPTED=$(echo "${STRING}" | openssl enc -aes256 -md md5 -a -A -S "${SALT}" -k "${K}") + local SALT=$(/usr/bin/openssl rand -hex 8) + local K=$(/usr/bin/openssl rand -hex 12) + local ENCRYPTED=$(echo "${STRING}" | /usr/bin/openssl enc -aes256 -md md5 -a -A -S "${SALT}" -k "${K}") echo "Encrypted String: ${ENCRYPTED}" echo "Salt: ${SALT} | Passphrase: ${K}" } @@ -28,4 +28,4 @@ function DecryptString() { local SALT="" local K="" echo "${1}" | /usr/bin/openssl enc -aes256 -md md5 -d -a -A -S "$SALT" -k "$K" -} \ No newline at end of file +}