Update make_pfx function.
This commit is contained in:
13
run-tests.sh
13
run-tests.sh
@@ -99,3 +99,16 @@ fi
|
||||
|
||||
# List the generated server certificate and key for verification
|
||||
display_certificate "$CERT_DIR/test_cert.pem"
|
||||
|
||||
# Create a PKCS#12 (PFX) file for the server certificate
|
||||
if ! make_pfx --ca-dir "$CA_DIR" --issuing-ca "issuing_ca" --path "$CERT_DIR/test_cert.pem" --password "s3cr3t"; then
|
||||
echo "ERROR: Failed to create PKCS#12 (PFX) file." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Read the generated PKCS#12 (PFX) file to verify its contents
|
||||
echo -e "\nVerifying contents of generated PKCS#12 (PFX) file ($CERT_DIR/test.pfx):"
|
||||
if ! openssl pkcs12 -in "$CERT_DIR/test.pfx" -noout -info -password pass:"s3cr3t"; then
|
||||
echo "ERROR: Failed to read PKCS#12 (PFX) file." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user