Introduction
Introduction Statistics Contact Development Disclaimer Help
Add script to generate a self-signed certificate and key for testing. - geomyid…
git clone git://bitreich.org/geomyidae/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfri…
Log
Files
Refs
Tags
README
LICENSE
---
commit 08ff73b18394277a0d1de1f83174035b0ef6c0ad
parent 07240d76fd8e1d0a67c49bf7e123bb508613e691
Author: Christoph Lohmann <[email protected]>
Date: Sun, 7 Jun 2020 19:02:49 +0200
Add script to generate a self-signed certificate and key for testing.
Diffstat:
A tls-gen-selfsign-cert.sh | 14 ++++++++++++++
1 file changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/tls-gen-selfsign-cert.sh b/tls-gen-selfsign-cert.sh
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+keyfile="geomyidae.key"
+csrfile="geomyidae.csr"
+certfile="geomyidae.crt"
+
+# Generate the private key.
+openssl genrsa -out "${keyfile}" 4096
+# Generate signing request.
+openssl req -new -key "${keyfile}" -out "${csrfile}"
+# Sign the request ourself.
+openssl x509 -sha256 -req -days 365 -in "${csrfile}" \
+ -signkey "${keyfile}" -out "${certfile}"
+
You are viewing proxied material from bitreich.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.