From 25af4c48a6840489fe4e717afb3465a4b4c39207 Mon Sep 17 00:00:00 2001 From: Jerome Duval Date: Fri, 25 Dec 2015 11:06:47 +0000 Subject: [PATCH] openssh: generate ed25519 key and eventually missing keys. * remove 6.9 recipe which uses the same script. --- .../openssh/additional-files/sshd_keymaker.sh | 14 +- net-misc/openssh/openssh-6.9p1.recipe | 133 ------------------ net-misc/openssh/openssh-7.0p1.recipe | 2 +- net-misc/openssh/openssh-7.1p1.recipe | 2 +- 4 files changed, 13 insertions(+), 138 deletions(-) delete mode 100644 net-misc/openssh/openssh-6.9p1.recipe diff --git a/net-misc/openssh/additional-files/sshd_keymaker.sh b/net-misc/openssh/additional-files/sshd_keymaker.sh index d6ef0362e..ddd6b165e 100755 --- a/net-misc/openssh/additional-files/sshd_keymaker.sh +++ b/net-misc/openssh/additional-files/sshd_keymaker.sh @@ -27,12 +27,20 @@ if [ ! -f "$hostKeyDir/ssh_host_dsa_key" ] ; then fi if [ ! -f "$hostKeyDir/ssh_host_ecdsa_key" ] ; then - _progress 0.6 "ecdsa" + _progress 0.5 "ecdsa" ssh-keygen -t ecdsa -f "$hostKeyDir/ssh_host_ecdsa_key" -N "" fi if [ ! -f "$hostKeyDir/ssh_host_rsa_key" ] ; then - _progress 0.8 "rsa" + _progress 0.7 "rsa" ssh-keygen -t rsa -f "$hostKeyDir/ssh_host_rsa_key" -N "" - _progress 1.0 "" fi + +if [ ! -f "$hostKeyDir/ssh_host_ed25519_key" ] ; then + _progress 0.8 "ed25519" + ssh-keygen -t ed25519 -f "$hostKeyDir/ssh_host_ed25519_key" -N "" +fi + +# generate what's eventually missing +ssh-keygen -A +_progress 1.0 "" diff --git a/net-misc/openssh/openssh-6.9p1.recipe b/net-misc/openssh/openssh-6.9p1.recipe deleted file mode 100644 index f3e5c1e43..000000000 --- a/net-misc/openssh/openssh-6.9p1.recipe +++ /dev/null @@ -1,133 +0,0 @@ -SUMMARY="Secure Shell Client and Server (Remote Login Program)" -DESCRIPTION=" -OpenSSH is a FREE version of the SSH connectivity tools that technical users \ -of the Internet rely on. Users of telnet, rlogin, and ftp may not realize that \ -their password is transmitted across the Internet unencrypted, but it is. \ -OpenSSH encrypts all traffic (including passwords) to effectively eliminate \ -eavesdropping, connection hijacking, and other attacks. Additionally, OpenSSH \ -provides secure tunneling capabilities and several authentication methods, and \ -supports all SSH protocol versions. -The OpenSSH suite replaces rlogin and telnet with the ssh program, rcp with \ -scp, and ftp with sftp. Also included is sshd (the server side of the \ -package), and the other utilities like ssh-add, ssh-agent, ssh-keysign, \ -ssh-keyscan, ssh-keygen and sftp-server. -" -HOMEPAGE="http://www.openssh.com/" -LICENSE="OpenSSH" -COPYRIGHT="2005-2014 Tatu Ylonen et al." -SOURCE_URI="http://openbsd.mirrorcatalogs.com/pub/OpenBSD/OpenSSH/portable/openssh-$portVersion.tar.gz" -CHECKSUM_SHA256="6e074df538f357d440be6cf93dc581a21f22d39e236f217fcd8eacbb6c896cfe" -REVISION="1" - -ARCHITECTURES="x86_gcc2 x86 x86_64" - -PATCHES="sshd_config.patch - pathnames.patch - bzero.patch" - -ADDITIONAL_FILES="sshd_keymaker.sh" - -PROVIDES=" - openssh = $portVersion compat >= 5 - cmd:scp = $portVersion compat >= 5 - cmd:sftp = $portVersion compat >= 5 - cmd:sftp_server = $portVersion compat >= 5 - cmd:slogin = $portVersion compat >= 5 - cmd:ssh = $portVersion compat >= 5 - cmd:ssh_add = $portVersion compat >= 5 - cmd:ssh_agent = $portVersion compat >= 5 - cmd:ssh_keygen = $portVersion compat >= 5 - cmd:ssh_keyscan = $portVersion compat >= 5 - cmd:ssh_keysign = $portVersion compat >= 5 - cmd:ssh_pkcs11_helper = $portVersion compat >= 5 - cmd:sshd = $portVersion compat >= 5 - " -REQUIRES=" - haiku - cmd:login - cmd:passwd - lib:libcrypto - lib:libedit - lib:libncurses - lib:libssl - lib:libz - " -BUILD_REQUIRES=" - devel:libcrypto - devel:libedit - devel:libncurses - devel:libssl - devel:libz - " -BUILD_PREREQUIRES=" - haiku_devel - cmd:aclocal - cmd:autoconf - cmd:automake - cmd:gcc - cmd:ld - cmd:libtoolize - cmd:make - cmd:pkg_config - " - -GLOBAL_WRITABLE_FILES=" - settings/ssh directory keep-old - " -USER_SETTINGS_FILES=" - settings/ssh directory - " -POST_INSTALL_SCRIPTS=" - $relativePostInstallDir/sshd_keymaker.sh - " -sshdUserHomeDir="/packages/$portVersionedName-$REVISION/.self/$relativeDataDir/openssh/empty" -PACKAGE_USERS=" - sshd real-name \"sshd user\" home \"$sshdUserHomeDir\" shell \"/bin/true\" - " -PACKAGE_GROUPS="sshd" - - -PATCH() -{ - echo 'AC_CONFIG_MACRO_DIR([m4])' >> configure.ac -} - -BUILD() -{ - mkdir -p m4 - aclocal --install -I m4 - libtoolize --force --copy - aclocal -I m4 - autoconf - defaultPath=".:/boot/home/config/non-packaged/bin:/boot/home/config/bin" - defaultPath+=":/boot/common/non-packaged/bin:/boot/common/bin:/bin" - defaultPath+=":/boot/common/apps:/boot/common/preferences:/boot/system/apps" - defaultPath+=":/boot/system/preferences" - - # Note: override sysconfdir and libexecdir since ssh doesn't create - # subdirectories as it should. - PATH_PASSWD_PROG=$portPackageLinksDir/cmd~passwd/bin/passwd \ - LOGIN_PROGRAM=$portPackageLinksDir/cmd~login/bin/login \ - runConfigure ./configure \ - --sysconfdir=$sysconfDir/ssh \ - --libexecdir=$libExecDir/openssh \ - --with-privsep-path=$dataDir/openssh/empty \ - --with-pid-dir=$prefix/var/run \ - --with-default-path="$defaultPath" \ - --with-md5-passwords \ - --disable-utmpx \ - --with-libedit - make $jobArgs -} - -INSTALL() -{ - make install-nokeys - mkdir -p $postInstallDir - cp -f $portDir/additional-files/sshd_keymaker.sh $postInstallDir -} - -TEST() -{ - make tests -} diff --git a/net-misc/openssh/openssh-7.0p1.recipe b/net-misc/openssh/openssh-7.0p1.recipe index c62dbb02c..1eab3f4c7 100644 --- a/net-misc/openssh/openssh-7.0p1.recipe +++ b/net-misc/openssh/openssh-7.0p1.recipe @@ -16,7 +16,7 @@ ssh-keyscan, ssh-keygen and sftp-server." HOMEPAGE="http://www.openssh.com/" COPYRIGHT="2005-2015 Tatu Ylonen et al." LICENSE="OpenSSH" -REVISION="1" +REVISION="2" SOURCE_URI="http://ftp.fr.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-$portVersion.tar.gz" CHECKSUM_SHA256="fd5932493a19f4c81153d812ee4e042b49bbd3b759ab3d9344abecc2bc1485e5" PATCHES="sshd_config.patch diff --git a/net-misc/openssh/openssh-7.1p1.recipe b/net-misc/openssh/openssh-7.1p1.recipe index a8b8937f0..c430aca98 100644 --- a/net-misc/openssh/openssh-7.1p1.recipe +++ b/net-misc/openssh/openssh-7.1p1.recipe @@ -16,7 +16,7 @@ ssh-keyscan, ssh-keygen and sftp-server." HOMEPAGE="http://www.openssh.com/" COPYRIGHT="2005-2015 Tatu Ylonen et al." LICENSE="OpenSSH" -REVISION="3" +REVISION="4" SOURCE_URI="http://ftp.fr.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-$portVersion.tar.gz" CHECKSUM_SHA256="fc0a6d2d1d063d5c66dffd952493d0cda256cad204f681de0f84ef85b2ad8428" PATCHES="sshd_config.patch