Skip to content

Instantly share code, notes, and snippets.

@alvissqn
Forked from turtlepod/make-cert.bat
Last active June 28, 2019 02:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alvissqn/493ea494fae5de3b16f7fd5015033009 to your computer and use it in GitHub Desktop.
Save alvissqn/493ea494fae5de3b16f7fd5015033009 to your computer and use it in GitHub Desktop.
@echo off
set /p domain="Enter Domain: "
set OPENSSL_CONF=../conf/openssl.cnf
if not exist .\%domain% mkdir .\%domain%
..\bin\openssl req -config cert.conf -new -sha256 -newkey rsa:2048 -nodes -keyout %domain%\server.key -x509 -days 365 -out %domain%\server.crt
echo.
echo -----
echo The certificate was provided.
echo.
pause
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment