Passer au contenu principal

Générer un certificat auto-signé sous Windows 🇬🇧

Source: How to Generate a Self-Signed Certificate and Private Key using OpenSSL – GSX Help Center

Generating a private key and self-signed certificate can be accomplished in a few simple steps using OpenSSL. We provide here detailed instructions on how to create a private key and self-signed certificate valid for 365 days.

Follow this article if you need to generate a private key and a self-signed certificate, such as to secure GSX Gizmo access using HTTPS.  

Instructions

Generating a self-signed certificate with OpenSSL:  

Win32 OpenSSL v1.1.0+ for Windows can be found here.

  1. Open Windows File Explorer.
  2. Navigate to the OpenSSL bin directory.
    • c:\OpenSSL\bin\ in our example.
  3. Right-click the openssl.exe file and select Run as administrator.
  4. Enter the following command to begin generating a certificate and private key:
    • req -x509 -sha256 -nodes -days 365 -newkey rsa:2048 -keyout privateKey.key -out certificate.crt
  5. You will then be prompted to enter applicable Distinguished Name (DN) information, totaling seven fields:
    OpenSSL_Cert_Generation_command_steps.png
  6. Once completed, you will find the certificate.crt and privateKey.key files created under the \OpenSSL\bin\ directory. Certificate-privateKey_created.png

Congratulations, you now have a private key and self-signed certificate! 

External OpenSSL related articles