Re-instate subshell for build_full() -> sign_req()

Subshell is required due to use of die() in sign_req().
Otherwise, on error sign_req() errors out without removing input files.

Revert part of commit: 15429df9fdd5c63c6e33dba141ff2e9a77ed0855

Signed-off-by: Richard T Bonhomme <tincantech@protonmail.com>
This commit is contained in:
Richard T Bonhomme 2022-06-16 12:03:51 +01:00
parent 2bc89f7658
commit 23558ae81d
No known key found for this signature in database
GPG Key ID: 2D767DB92FB6C246

View File

@ -1637,12 +1637,10 @@ Matching file found at: "
gen_req "$name" batch ${nopass+ nopass}
# Sign it
if sign_req "$crt_type" "$name" batch; then
: # ok
else
rm -f "$req_out" "$key_out"
( sign_req "$crt_type" "$name" batch ) || {
rm -f "$crt_out" "$req_out" "$key_out"
die "Failed to sign '$name' - See error messages above for details."
fi
}
# inline it
if [ "$EASYRSA_INLINE" ]; then