You are located in service: Certificates

Generation of a certificate request based on an existing RSA key and certificate

Generation of a certificate request based on an existing RSA key and certificate

It is not recommended (good practise) to reuse an RSA key pair.

If for technical reasons you need to do so (e.g. Key Pinning), then you generate a new Certificate Signing Request CSR (new_request.pem) based on the existing Certificate (cert.crt) and the associated private key file (private.pem), as follows:

openssl x509 -x509toreq -in cert.crt -signkey private.pem -out new_request.pem

Output the generated CSR in plain text:

openssl req -noout -text -in request.pem

last changed on 03/18/2022

How did this content help you?

Creative Commons Lizenzvertrag
This work is licensed under a Creative Commons Attribution - Share Alike 3.0 Germany License