понедельник, 1 августа 2016 г.

Generate self-signed wildcard ssl certificate

 $ openssl genrsa 2048 > domain.key
Generating RSA private key, 2048 bit long modulus
........+++
..................................+++
e is 65537 (0x10001)
$ openssl req -new -x509 -nodes -sha1 -days 365 -key domain.key > domain.crt
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]:UA
State or Province Name (full name) [Some-State]:Kiev
Locality Name (eg, city) []:
Organization Name (eg, company) [Internet Widgits Pty Ltd]:company
Organizational Unit Name (eg, section) []:operations
Common Name (e.g. server FQDN or YOUR name) []:*.domain.name.com
Email Address []:operations@gmail.com
$ls -al
domain.crt
domain.key

Now you can put these files to your nginx/apache and configure servers.

Комментариев нет:

Отправить комментарий