Unix

Various Unix stuff

OpenSSL commands

Various OpenSSL commands

Create a self signed certificate + keys

openssl req -x509 -nodes -days 1000000 -newkey rsa:4096 -keyout nandev2.key -subj "/C=IS/ST=Reykjavik/L=Reykjavik/O=IT/CN=devopswiki.nanitor.dev"  -out nandev2.crt

Dump text information

openssl x509 -in certificate.pem -text -noout

PEM to pfx / pkcs12

openssl pkcs12 -inkey key.pem -in certificate.pem -export -out certificate.p12

Validate pfx / pkcs12

openssl pkcs12 -in certificate.p12 -noout -info