openssl自簽名證書

生成自簽名證書git

$ openssl genrsa -out server.key 1024ui

Generating RSA private key, 1024 bit long modulus
.........................++++++
.........................++++++
e is 65537 (0x10001)

$ openssl req -new -key server.key -out server.csrcode

You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:CN
State or Province Name (full name) [Some-State]:123
Locality Name (eg, city) []:123
Organization Name (eg, company) [Internet Widgits Pty Ltd]:123
Organizational Unit Name (eg, section) []:123
Common Name (e.g. server FQDN or YOUR name) []:192.168.59.103
Email Address []:

Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:

$ openssl x509 -req -days 3650 -in server.csr -signkey server.key -out server.crtorm

Signature ok
subject=/C=CN/ST=123/L=123/O=123/OU=123/CN=192.168.59.103
Getting Private key
相關文章
相關標籤/搜索