openssl x509

The OpenSSL command for displaying, converting and signing X.509 certificates.

In more detail

With -noout and field options it prints parts of a certificate, such as the issuer, subject, serial number, dates and subject alternative names, which is the everyday way to inspect one. With -req it acts as a simple certificate authority, turning a signing request into a certificate signed by a given authority key. It also converts between PEM and binary formats.

Examples

openssl x509 -req -in www.csr -CA ca.pem -CAkey ca.key -out www.pem -copy_extensions copy -set_serial 4096
openssl x509 -in cert.pem -noout -subject -issuer -dates -ext subjectAltName

Related terms

Taught in

References