mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 12:10:06 +02:00
@@ -16,15 +16,10 @@ ssh-keyscan, ssh-keygen and sftp-server."
|
||||
HOMEPAGE="http://www.openssh.com/"
|
||||
COPYRIGHT="2005-2020 Tatu Ylonen et al."
|
||||
LICENSE="OpenSSH"
|
||||
REVISION="1"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://ftp.fr.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="f2befbe0472fe7eb75d23340eb17531cb6b3aac24075e2066b41f814e12387b2"
|
||||
PATCHES="sshd_config.patch
|
||||
pathnames.patch
|
||||
bzero.patch
|
||||
ssh-copy-id.patch
|
||||
sha2-gcc2-build-fix.patch
|
||||
pkcs11-gcc2-build-fix.patch"
|
||||
PATCHES="opensh-$portVersion.patchset"
|
||||
ADDITIONAL_FILES="
|
||||
sshd_keymaker.sh
|
||||
fix_openssh_config_paths.sh
|
||||
|
||||
@@ -1,47 +0,0 @@
|
||||
From 3db15d63ae6a9ceeaad80f367e3a7f9df003dae1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Mon, 24 Nov 2014 18:45:00 +0000
|
||||
Subject: haiku: we define bzero(x, y) but not bzero.
|
||||
|
||||
|
||||
diff --git a/openbsd-compat/explicit_bzero.c b/openbsd-compat/explicit_bzero.c
|
||||
index 3c85a48..a02e35e 100644
|
||||
--- a/openbsd-compat/explicit_bzero.c
|
||||
+++ b/openbsd-compat/explicit_bzero.c
|
||||
@@ -23,6 +23,24 @@ explicit_bzero(void *p, size_t n)
|
||||
|
||||
#else /* HAVE_MEMSET_S */
|
||||
|
||||
+#ifdef __HAIKU__
|
||||
+/* Haiku defines bzero(x, y) but not bzero */
|
||||
+
|
||||
+/*
|
||||
+ * Indirect memset through a volatile pointer to hopefully avoid
|
||||
+ * dead-store optimisation eliminating the call.
|
||||
+ */
|
||||
+static void (* volatile ssh_memset)(void *, int, size_t) = memset;
|
||||
+
|
||||
+void
|
||||
+explicit_bzero(void *p, size_t n)
|
||||
+{
|
||||
+ ssh_memset(p, 0, n);
|
||||
+}
|
||||
+
|
||||
+
|
||||
+#else
|
||||
+
|
||||
/*
|
||||
* Indirect bzero through a volatile pointer to hopefully avoid
|
||||
* dead-store optimisation eliminating the call.
|
||||
@@ -35,6 +53,8 @@ explicit_bzero(void *p, size_t n)
|
||||
ssh_bzero(p, n);
|
||||
}
|
||||
|
||||
+#endif
|
||||
+
|
||||
#endif /* HAVE_MEMSET_S */
|
||||
|
||||
#endif /* HAVE_EXPLICIT_BZERO */
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index b7258bd..d50a413 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -688,6 +688,7 @@ main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16))
|
||||
LIBS="$LIBS -lbsd "
|
||||
AC_CHECK_LIB([network], [socket])
|
||||
AC_DEFINE([HAVE_U_INT64_T])
|
||||
+ CFLAGS="$CFLAGS -D_BSD_SOURCE"
|
||||
MANTYPE=man
|
||||
;;
|
||||
*-*-hpux*)
|
||||
1025
net-misc/openssh/patches/openssh-8.3p1.patchset
Normal file
1025
net-misc/openssh/patches/openssh-8.3p1.patchset
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,13 +0,0 @@
|
||||
diff --git a/pathnames.h b/pathnames.h
|
||||
index ec89fc6..6ad1b64 100644
|
||||
--- a/pathnames.h
|
||||
+++ b/pathnames.h
|
||||
@@ -59,7 +59,7 @@
|
||||
* The directory in user's home directory in which the files reside. The
|
||||
* directory should be world-readable (though not all files are).
|
||||
*/
|
||||
-#define _PATH_SSH_USER_DIR ".ssh"
|
||||
+#define _PATH_SSH_USER_DIR "config/settings/ssh"
|
||||
|
||||
/*
|
||||
* Per-user file containing host keys of known hosts. This file need not be
|
||||
@@ -1,32 +0,0 @@
|
||||
From f41470d95341ab803010de2687fe5aa166378f41 Mon Sep 17 00:00:00 2001
|
||||
From: Augustin Cavalier <waddlesplash@gmail.com>
|
||||
Date: Sat, 11 Apr 2020 13:58:14 -0400
|
||||
Subject: [PATCH] GCC2 build fix.
|
||||
|
||||
---
|
||||
ssh-pkcs11-client.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/ssh-pkcs11-client.c b/ssh-pkcs11-client.c
|
||||
index 8a0ffef..cd75bf2 100644
|
||||
--- a/ssh-pkcs11-client.c
|
||||
+++ b/ssh-pkcs11-client.c
|
||||
@@ -248,6 +248,7 @@ pkcs11_start_helper_methods(void)
|
||||
return (0);
|
||||
|
||||
#ifdef HAVE_EC_KEY_METHOD_NEW
|
||||
+ {
|
||||
int (*orig_sign)(int, const unsigned char *, int, unsigned char *,
|
||||
unsigned int *, const BIGNUM *, const BIGNUM *, EC_KEY *) = NULL;
|
||||
if (helper_ecdsa != NULL)
|
||||
@@ -257,6 +258,7 @@ pkcs11_start_helper_methods(void)
|
||||
return (-1);
|
||||
EC_KEY_METHOD_get_sign(helper_ecdsa, &orig_sign, NULL, NULL);
|
||||
EC_KEY_METHOD_set_sign(helper_ecdsa, orig_sign, NULL, ecdsa_do_sign);
|
||||
+ }
|
||||
#endif /* HAVE_EC_KEY_METHOD_NEW */
|
||||
|
||||
if ((helper_rsa = RSA_meth_dup(RSA_get_default_method())) == NULL)
|
||||
--
|
||||
2.24.1
|
||||
|
||||
@@ -1,58 +0,0 @@
|
||||
From 92ed1dcaa05f0f425b809a7e1972cad5689c6634 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 15 Feb 2020 20:53:00 +0100
|
||||
Subject: [PATCH] gcc2 build fix
|
||||
|
||||
---
|
||||
openbsd-compat/sha2.c | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/openbsd-compat/sha2.c b/openbsd-compat/sha2.c
|
||||
index e36cc24..235d279 100644
|
||||
--- a/openbsd-compat/sha2.c
|
||||
+++ b/openbsd-compat/sha2.c
|
||||
@@ -616,11 +616,13 @@ SHA256Final(u_int8_t digest[SHA256_DIGEST_LENGTH], SHA2_CTX *context)
|
||||
SHA256Pad(context);
|
||||
|
||||
#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
+{
|
||||
int i;
|
||||
|
||||
/* Convert TO host byte order */
|
||||
for (i = 0; i < 8; i++)
|
||||
BE_32_TO_8(digest + i * 4, context->state.st32[i]);
|
||||
+}
|
||||
#else
|
||||
memcpy(digest, context->state.st32, SHA256_DIGEST_LENGTH);
|
||||
#endif
|
||||
@@ -897,11 +899,13 @@ SHA512Final(u_int8_t digest[SHA512_DIGEST_LENGTH], SHA2_CTX *context)
|
||||
SHA512Pad(context);
|
||||
|
||||
#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
+{
|
||||
int i;
|
||||
|
||||
/* Convert TO host byte order */
|
||||
for (i = 0; i < 8; i++)
|
||||
BE_64_TO_8(digest + i * 8, context->state.st64[i]);
|
||||
+}
|
||||
#else
|
||||
memcpy(digest, context->state.st64, SHA512_DIGEST_LENGTH);
|
||||
#endif
|
||||
@@ -954,11 +958,13 @@ SHA384Final(u_int8_t digest[SHA384_DIGEST_LENGTH], SHA2_CTX *context)
|
||||
SHA384Pad(context);
|
||||
|
||||
#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
+{
|
||||
int i;
|
||||
|
||||
/* Convert TO host byte order */
|
||||
for (i = 0; i < 6; i++)
|
||||
BE_64_TO_8(digest + i * 8, context->state.st64[i]);
|
||||
+}
|
||||
#else
|
||||
memcpy(digest, context->state.st64, SHA384_DIGEST_LENGTH);
|
||||
#endif
|
||||
--
|
||||
2.24.0
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
diff --git a/contrib/ssh-copy-id b/contrib/ssh-copy-id
|
||||
old mode 100644
|
||||
new mode 100755
|
||||
index b83b836..f468018
|
||||
--- a/contrib/ssh-copy-id
|
||||
+++ b/contrib/ssh-copy-id
|
||||
@@ -56,8 +56,8 @@ then
|
||||
fi
|
||||
fi
|
||||
|
||||
-most_recent_id="$(cd "$HOME" ; ls -t .ssh/id*.pub 2>/dev/null | grep -v -- '-cert.pub$' | head -n 1)"
|
||||
-DEFAULT_PUB_ID_FILE="${most_recent_id:+$HOME/}$most_recent_id"
|
||||
+most_recent_id="$(cd `finddir B_USER_SETTINGS_DIRECTORY`/ ; ls -t ssh/id*.pub 2>/dev/null | grep -v -- '-cert.pub$' | head -n 1)"
|
||||
+DEFAULT_PUB_ID_FILE="${most_recent_id:+`finddir B_USER_SETTINGS_DIRECTORY`/}$most_recent_id"
|
||||
|
||||
usage () {
|
||||
printf 'Usage: %s [-h|-?|-f|-n] [-i [identity_file]] [-p port] [[-o <ssh -o options>] ...] [user@]hostname\n' "$0" >&2
|
||||
@@ -218,7 +218,7 @@ populate_new_ids() {
|
||||
eval set -- "$SSH_OPTS"
|
||||
|
||||
umask 0177
|
||||
- local L_TMP_ID_FILE=$(mktemp ~/.ssh/ssh-copy-id_id.XXXXXXXXXX)
|
||||
+ local L_TMP_ID_FILE=$(mktemp `finddir B_USER_SETTINGS_DIRECTORY`/ssh/ssh-copy-id_id.XXXXXXXXXX)
|
||||
if test $? -ne 0 || test "x$L_TMP_ID_FILE" = "x" ; then
|
||||
printf '%s: ERROR: mktemp failed\n' "$0" >&2
|
||||
exit 1
|
||||
@@ -1,13 +0,0 @@
|
||||
diff --git a/sshd_config b/sshd_config
|
||||
index e9045bc..0835873 100644
|
||||
--- a/sshd_config
|
||||
+++ b/sshd_config
|
||||
@@ -51,7 +51,7 @@
|
||||
|
||||
# The default is to check both .ssh/authorized_keys and .ssh/authorized_keys2
|
||||
# but this is overridden so installations will only check .ssh/authorized_keys
|
||||
-AuthorizedKeysFile .ssh/authorized_keys
|
||||
+AuthorizedKeysFile config/settings/ssh/authorized_keys
|
||||
|
||||
#AuthorizedPrincipalsFile none
|
||||
|
||||
Reference in New Issue
Block a user