Skip to content

Instantly share code, notes, and snippets.

View Menayer's full-sized avatar

Amr El Menayer Menayer

View GitHub Profile
[req]
default_bits = 2048
default_keyfile = server-key.pem
distinguished_name = subject
req_extensions = req_ext
x509_extensions = x509_ext
string_mask = utf8only
[subject]
@echo off
set /p domain="Enter Domain: "
set OPENSSL_CONF=../conf/openssl.cnf
REM
REM Read the "cert-template.conf" file and replace all {{DOMAIN}} placeholders by the entered domain.
REM Write the result into a new file called "cert.conf".
REM
REM @see https://stackoverflow.com/questions/5273937/how-to-replace-substrings-in-windows-batch-file#20227248
REM