mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 19:50:05 +02:00
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:
20
net-misc/openssh/boot/post_install/ssh.sh
Executable file
20
net-misc/openssh/boot/post_install/ssh.sh
Executable 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
|
||||
Reference in New Issue
Block a user