Howto openssl
Install openssl
I used git-scm from here https://git-scm.com/download/win Alternative install openssl direcly or use mingw.
Create certificate sign request (.crs file)
- Generate a key used for signing:
openssl genrsa -out client-debal-YOURNAMEHERE.key 4096
generates the key in the current folder
Output:
Generating RSA private key, 2048 bit long modulus (2 primes)
.............................+++++
....................................................................+++++
e is 65537 (0x010001)
The generated file looks like this:
-----BEGIN RSA PRIVATE KEY-----
MIIEowIBAAKCAQEA6s8ObYmliHRZke6S3SIeSExhc1oaWluXFoKx6THWugOh0lTE
tYm/HFHFGE?EFJKOKPOv/WvvLzroO2Y//V442J+6VWNcA/SM0uiXzDC76rC/DpWi
...
Note never show or give this file to anyone else!
- Create sign request:
openssl req -sha512 -out client-debal-YOURNAMEHERE.csr -key client-debal-YOURNAMEHERE.key -new
Output:
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]:de
State or Province Name (full name) [Some-State]:
Locality Name (eg, city) []:
Organization Name (eg, company) [Internet Widgits Pty Ltd]:debal
Organizational Unit Name (eg, section) []:debal
Common Name (e.g. server FQDN or YOUR name) []:debal-YOURNAMEHERE
Email Address []:
Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:
The generated file looks like this:
-----BEGIN CERTIFICATE REQUEST-----
MIICrTCCAZUCAQAwaDELMAkGA1UEBhMCZGUxCzAJBgNVBAgMAmJ3MRIwEAYDVQQH
DAlzdHV0dGdhcnQxDjAMBgNVBAoMBWRlYmFsMQ4wDAYDVQQLDAVkZWJhbDEYMBYG
- Send the csr to sign
- Wait until signed
- You get the following files:
-
debal-YOURNAMEHERE.crt-> Your signed csr -
nexit-openvpn.crt-> the server certificate authority - ta.key -> tls-auth key, used for encryption
- .openvpn file -> general connection information (missing)
- Configure the VPN-Profile
misc
openssl.exe version
OpenSSL 1.1.1h 22 Sep 2020