Created
June 13, 2018 11:47
-
-
Save cnouguier/c5cb4ba99ad45bced4476e2d175342a1 to your computer and use it in GitHub Desktop.
Generate Certificate Authority files for Kaabah
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generate passphrase file | |
$env LC_CTYPE=C < /dev/urandom tr -dc "+=\-%*\!&#':;{}()[]|^~\$_2-9T-Z" | head -c65 > ca.pass | |
# Generate the key pair files | |
$CA_SUBJ="${CA_SUBJ:-"/C=${CA_C:-"FR"}/L=${CA_L:-"Castelnaudary"}/O=${CA_O:-"Kalisio"}/OU=${CA_OU:-"Kaabah"}/CN=${CA_CN:-"*.kalis | |
io.xyz"}"}" | |
$openssl req \ | |
-new -x509 -days 1825 \ | |
-newkey rsa:4096 -keyout ca.key -passout file:ca.pass \ | |
-out ca.cert -subj "${CA_SUBJ}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment