Added the openssh post_install keygen script.

Applied with the following Haiku:

Openssh
Uses this bash post install
Script to make the keys
This commit is contained in:
Scott McCreary
2010-04-14 06:35:35 +00:00
parent e76b973dd3
commit 44fa027951

View File

@@ -0,0 +1,20 @@
#!/bin/sh
# generate SSH host keys
ETCSSHDIR=`finddir B_COMMON_ETC_DIRECTORY`/ssh
mkdir -p ${ETCSSHDIR}
hostKeyDir=${ETCSSHDIR}
if [ ! -f "$hostKeyDir/ssh_host_key" ] ; then
ssh-keygen -t rsa1 -f "$hostKeyDir/ssh_host_key" -N ""
fi
if [ ! -f "$hostKeyDir/ssh_host_dsa_key" ] ; then
ssh-keygen -t dsa -f "$hostKeyDir/ssh_host_dsa_key" -N ""
fi
if [ ! -f "$hostKeyDir/ssh_host_rsa_key" ] ; then
ssh-keygen -t rsa -f "$hostKeyDir/ssh_host_rsa_key" -N ""
fi