@joeschmuck LOL a bit too much time on your hands?
That one went above my head, sorry... :)
An
openssl.cnf, or OpenSSL config, is what one uses to generate a
Certificate
Authority [CA],
Intermediate
Certificate
Authority [ICA], Client Certificate, and Client Certificate Key with OpenSSL. I have an
openssl.cnf in my signature with all commands you'll need at the bottom of the config [4 for CA, 3 for each client cert], along with itemized details explaining what's what. You can download OpenSSL independently, however I always install
OpenVPN, of which includes the OpenSSL binaries.
- If using Windows, add C:\Program Files\OpenVPN\bin to your System Variable Path, allowing you to open any PowerShell/Command terminal and simply type
openssl
to access the program.
- SubjectAltName [SAN] profiles are per certificate, allowing one to assign multiple hosts names/IPs/FQDNs/emails/usernames/OIDs/etc. to the same certificate, allowing the user to choose whatever common name they want, instead of either the IP or FQDN. For example, this would allow the WebGUI cert to have a common name [CN] of "FreeNAS WebGUI", and SANs of "127.0.0.1", "192.168.1.2", "10.10.10.10", and "your.ddns.com".
- The certificate will appear as valid regardless of which of those 4 you navigate to
- Now, let's say you want to SSH into your FreeNAS server from WAN for whatever reason. Once you SSH in, you can tell the SSH server to attach a separate tunnel for the connection to the WebGUI's IP & port. In order to access this tunnel, one would use the loopback IP [127.0.0.1] of their PC as the IP for the tunnel and whatever local [PC] port number they assigned to that tunnel, say 5999. To navigate to the WebGUI using the SSH tunnel, one would type into a browser https:\\127.0.0.1:5999, of which would load the WebGUI while still registering the certificate as valid for that IP.
I wrote an in depth wiki on using my
openssl.cnf for OpenVPN on the OpenWrt forum, and if you start at the
OpenSSL section and read through the
Diffie-Hellman Key section
(i.e. read from OpenSSL - Diffie-Hellman Key), you should have a firm grasp by the time you reach the Diffie-Hellman Key.