← history for key_exchange/kx-gen-keypair
3fb2e140key_exchange/kx-gen-keypair15 lines⬡ raw↓ download
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
#! /bin/bash 

cd $(dirname $0)
KEYS_DIR=./keys

if [ "$#" != 1 ]; then
	echo "Usage: $0 <profile>"
	exit 1
fi

test -d ${KEYS_DIR} || mkdir -p ${KEYS_DIR}

profile=$1

openssl genpkey -paramfile ${KEYS_DIR}/dhp.pem -out ${KEYS_DIR}/"${profile}.pem"