Files
goproxy/cmd/https_to_https_proxy/generate_cert.bat
2025-03-13 17:40:01 +08:00

14 lines
401 B
Batchfile
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@echo off
REM 生成自签名SSL证书的批处理脚本
echo 正在为HTTPS代理生成自签名证书...
openssl req -x509 -newkey rsa:4096 -keyout server.key -out server.crt -days 365 -nodes -subj "/CN=localhost"
echo.
echo 证书生成完成!
echo 证书文件server.crt
echo 密钥文件server.key
echo.
echo 现在您可以运行go run main.go -cert=server.crt -key=server.key
pause