Skip to content

Commit f15c1a1

Browse files
authored
Merge pull request #34 from JuliaCI/fe/pkeyutl
Use pkeyutl instead of deprecated rsautl
2 parents 5d046c7 + 97677d3 commit f15c1a1

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

hooks/environment.agent

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ function set_cryptic_privileged() {
144144
readarray -d';' -t ADHOC_PAIR <<<"${!LONG_ADHOC_NAME}"
145145

146146
# Take the key, decrypt it with our RSA private key
147-
base64dec <<<"${ADHOC_PAIR[0]}" | openssl rsautl -decrypt -inkey "${AGENT_PRIVATE_KEY_PATH}" > "${TEMP_KEYFILE}"
147+
base64dec <<<"${ADHOC_PAIR[0]}" | openssl pkeyutl -decrypt -inkey "${AGENT_PRIVATE_KEY_PATH}" > "${TEMP_KEYFILE}"
148148

149149
# Make sure the AES key is the right length
150150
if [[ $(wc -c <"${TEMP_KEYFILE}") != "128" ]]; then

lib/common.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,11 @@ function randbase64() {
128128

129129
# Encrypt something using RSA with the RSA public key as the first argument
130130
function encrypt_rsa() {
131-
openssl rsautl -encrypt -pubin -inkey "${1}"
131+
openssl pkeyutl -encrypt -pubin -inkey "${1}"
132132
}
133133
# Decrypt something using RSA with the RSA private key as the first argument
134134
function decrypt_rsa() {
135-
openssl rsautl -decrypt -inkey "${1}"
135+
openssl pkeyutl -decrypt -inkey "${1}"
136136
}
137137

138138
# Sign something using RSA with the RSA key as the first argument

0 commit comments

Comments
 (0)