Skip to content

Commit

Permalink
Command revoke: Do not remove duplicate certificate by serial
Browse files Browse the repository at this point in the history
Signed-off-by: Richard T Bonhomme <[email protected]>
  • Loading branch information
TinCanTech committed Jun 26, 2024
1 parent e84ec69 commit 3da7f66
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions easyrsa3/easyrsa
Original file line number Diff line number Diff line change
Expand Up @@ -3050,10 +3050,6 @@ Request was expected at:
ssl_cert_serial "$crt_in" cert_serial || \
die "$cmd: Failed to get cert serial number!"

# Duplicate cert by serial file
dup_dir="$EASYRSA_PKI/certs_by_serial"
dup_crt_by_serial="$dup_dir/${cert_serial}.pem"

# Set out_dir
out_dir="$EASYRSA_PKI/revoked"
crt_out="$out_dir/certs_by_serial/${cert_serial}.crt"
Expand Down Expand Up @@ -3096,10 +3092,7 @@ All PKCS files for commonName : $file_name_base

The inline credentials files:
* $creds_in
* $inline_in

The duplicate certificate:
* $dup_crt_by_serial"
* $inline_in"

confirm " Continue with revocation: " "yes" "
Please confirm that you wish to revoke the certificate
Expand Down Expand Up @@ -3168,13 +3161,6 @@ revoke_move() {
fi
done

# remove the duplicate certificate
if [ -e "$dup_crt_by_serial" ]; then
rm "$dup_crt_by_serial" || warn "\
Failed to remove the duplicate certificate:
* $dup_crt_by_serial"
fi

# remove credentials file
if [ -e "$creds_in" ]; then
rm "$creds_in" || warn "\
Expand Down

0 comments on commit 3da7f66

Please sign in to comment.