Skip to content

Instantly share code, notes, and snippets.

@leizongmin
Created September 25, 2012 02:40
Show Gist options
  • Save leizongmin/3779675 to your computer and use it in GitHub Desktop.
Save leizongmin/3779675 to your computer and use it in GitHub Desktop.
创建PEM格式的SSH证书
@echo off
openssl genrsa -out ca-key.pem 2048
openssl req -new -out ca-req.csr -key ca-key.pem
openssl x509 -req -in ca-req.csr -out ca-cert.pem -signkey ca-key.pem -days 7300
openssl pkcs12 -export -in ca-cert.pem -out ca-cert.p12 -inkey ca-key.pem
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment