Move all to deprecated folder.

This commit is contained in:
2016-11-16 21:57:57 +01:00
parent 01738a7684
commit 05de7d6c04
9777 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,44 @@
When PAM is enabled, openssh makes its own static versions of pthreads
functions. But when built with a uclibc toolchain, pthreads.h gets
indirectly included. The clashing exported and static definitions of
the pthreads functions then cause a compile error. This patch fixes
the problem by changing the static pthread function names with macros
when the static functions are defined.
Signed-off-by: Danomi Manchego <danomimanchego123@gmail.com>
diff -urN openssh-6.1p1.orig/auth-pam.c openssh-6.1p1/auth-pam.c
--- openssh-6.1p1.orig/auth-pam.c 2009-07-12 08:07:21.000000000 -0400
+++ openssh-6.1p1/auth-pam.c 2012-09-15 19:49:47.677288199 -0400
@@ -166,6 +166,7 @@
sigdie("PAM: authentication thread exited uncleanly");
}
+#define pthread_exit pthread_exit_AVOID_UCLIBC_PTHREAD_CLASH
/* ARGSUSED */
static void
pthread_exit(void *value)
@@ -173,6 +174,7 @@
_exit(0);
}
+#define pthread_create pthread_create_AVOID_UCLIBC_PTHREAD_CLASH
/* ARGSUSED */
static int
pthread_create(sp_pthread_t *thread, const void *attr,
@@ -200,6 +202,7 @@
}
}
+#define pthread_cancel pthread_cancel_AVOID_UCLIBC_PTHREAD_CLASH
static int
pthread_cancel(sp_pthread_t thread)
{
@@ -207,6 +210,7 @@
return (kill(thread, SIGTERM));
}
+#define pthread_join pthread_join_AVOID_UCLIBC_PTHREAD_CLASH
/* ARGSUSED */
static int
pthread_join(sp_pthread_t thread, void **value)

View File

@@ -0,0 +1,49 @@
Update patch from 2fea21799223d41605556858a95b55e69e9960ca to openssh
version 6.8p1
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
diff -Nura openssh-6.8p1.orig/openbsd-compat/bsd-poll.c openssh-6.8p1/openbsd-compat/bsd-poll.c
--- openssh-6.8p1.orig/openbsd-compat/bsd-poll.c 2015-03-18 07:11:46.184620677 -0300
+++ openssh-6.8p1/openbsd-compat/bsd-poll.c 2015-03-18 07:12:29.120094555 -0300
@@ -19,6 +19,7 @@
#include "includes.h"
#if !defined(HAVE_POLL)
+#include <sys/param.h>
#include <sys/types.h>
#include <sys/time.h>
#ifdef HAVE_SYS_SELECT_H
diff -Nura openssh-6.8p1.orig/sshd.c openssh-6.8p1/sshd.c
--- openssh-6.8p1.orig/sshd.c 2015-03-18 07:11:46.187620780 -0300
+++ openssh-6.8p1/sshd.c 2015-03-18 07:13:11.889562735 -0300
@@ -44,6 +44,7 @@
#include "includes.h"
+#include <sys/param.h>
#include <sys/types.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
diff -Nura openssh-6.8p1.orig/ssh-keyscan.c openssh-6.8p1/ssh-keyscan.c
--- openssh-6.8p1.orig/ssh-keyscan.c 2015-03-18 07:11:46.180620539 -0300
+++ openssh-6.8p1/ssh-keyscan.c 2015-03-18 07:13:32.092256248 -0300
@@ -9,6 +9,7 @@
#include "includes.h"
+#include <sys/param.h>
#include <sys/types.h>
#include "openbsd-compat/sys-queue.h"
#include <sys/resource.h>
diff -Nura openssh-6.8p1.orig/ssh-pkcs11-helper.c openssh-6.8p1/ssh-pkcs11-helper.c
--- openssh-6.8p1.orig/ssh-pkcs11-helper.c 2015-03-18 07:11:46.182620608 -0300
+++ openssh-6.8p1/ssh-pkcs11-helper.c 2015-03-18 07:13:43.620651993 -0300
@@ -17,6 +17,7 @@
#include "includes.h"
+#include <sys/param.h>
#include <sys/types.h>
#ifdef HAVE_SYS_TIME_H
# include <sys/time.h>

View File

@@ -0,0 +1,10 @@
config BR2_PACKAGE_OPENSSH
bool "openssh"
depends on BR2_USE_MMU # fork()
select BR2_PACKAGE_OPENSSL
select BR2_PACKAGE_ZLIB
help
A free version of the SSH protocol suite of network connectivity
tools. The standard 'ssh', 'sshd', 'scp', and friends.
http://www.openssh.com/

View File

@@ -0,0 +1,47 @@
#!/bin/sh
#
# sshd Starts sshd.
#
# Make sure the ssh-keygen progam exists
[ -f /usr/bin/ssh-keygen ] || exit 0
# Create any missing keys
/usr/bin/ssh-keygen -A
umask 077
start() {
printf "Starting sshd: "
/usr/sbin/sshd
touch /var/lock/sshd
echo "OK"
}
stop() {
printf "Stopping sshd: "
killall sshd
rm -f /var/lock/sshd
echo "OK"
}
restart() {
stop
start
}
case "$1" in
start)
start
;;
stop)
stop
;;
restart|reload)
restart
;;
*)
echo "Usage: $0 {start|stop|restart}"
exit 1
esac
exit $?

View File

@@ -0,0 +1,3 @@
# Locally calculated after checking pgp signature
# Also from http://www.openssh.com/txt/release-7.1p2
sha256 dd75f024dcf21e06a0d6421d582690bf987a1f6323e32ad6619392f3bfde6bbd openssh-7.1p2.tar.gz

View File

@@ -0,0 +1,70 @@
################################################################################
#
# openssh
#
################################################################################
OPENSSH_VERSION = 7.1p2
OPENSSH_SITE = http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable
OPENSSH_LICENSE = BSD-3c BSD-2c Public Domain
OPENSSH_LICENSE_FILES = LICENCE
OPENSSH_CONF_ENV = LD="$(TARGET_CC)" LDFLAGS="$(TARGET_CFLAGS)"
OPENSSH_CONF_OPTS = \
--sysconfdir=/etc/ssh \
--disable-lastlog \
--disable-utmp \
--disable-utmpx \
--disable-wtmp \
--disable-wtmpx \
--disable-strip
define OPENSSH_USERS
sshd -1 sshd -1 * - - - SSH drop priv user
endef
# uClibc toolchain for ARC doesn't support PIE at the moment
ifeq ($(BR2_arc),y)
OPENSSH_CONF_OPTS += --without-pie
endif
# PIE and static does not work on Linux
ifeq ($(BR2_STATIC_LIBS),y)
OPENSSH_CONF_OPTS += --without-pie
endif
OPENSSH_DEPENDENCIES = zlib openssl
ifeq ($(BR2_PACKAGE_LINUX_PAM),y)
define OPENSSH_INSTALL_PAM_CONF
$(INSTALL) -D -m 644 $(@D)/contrib/sshd.pam.generic $(TARGET_DIR)/etc/pam.d/sshd
$(SED) '\%password required /lib/security/pam_cracklib.so%d' $(TARGET_DIR)/etc/pam.d/sshd
$(SED) 's/\#UsePAM no/UsePAM yes/' $(TARGET_DIR)/etc/ssh/sshd_config
endef
OPENSSH_DEPENDENCIES += linux-pam
OPENSSH_CONF_OPTS += --with-pam
OPENSSH_POST_INSTALL_TARGET_HOOKS += OPENSSH_INSTALL_PAM_CONF
else
OPENSSH_CONF_OPTS += --without-pam
endif
ifeq ($(BR2_PACKAGE_LIBSELINUX),y)
OPENSSH_DEPENDENCIES += libselinux
OPENSSH_CONF_OPTS += --with-selinux
else
OPENSSH_CONF_OPTS += --without-selinux
endif
define OPENSSH_INSTALL_INIT_SYSTEMD
$(INSTALL) -D -m 644 package/openssh/sshd.service \
$(TARGET_DIR)/usr/lib/systemd/system/sshd.service
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
ln -fs ../../../../usr/lib/systemd/system/sshd.service \
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/sshd.service
endef
define OPENSSH_INSTALL_INIT_SYSV
$(INSTALL) -D -m 755 package/openssh/S50sshd \
$(TARGET_DIR)/etc/init.d/S50sshd
endef
$(eval $(autotools-package))

View File

@@ -0,0 +1,11 @@
[Unit]
Description=OpenSSH server daemon
After=syslog.target network.target auditd.service
[Service]
ExecStartPre=/usr/bin/ssh-keygen -A
ExecStart=/usr/sbin/sshd -D -e
ExecReload=/bin/kill -HUP $MAINPID
[Install]
WantedBy=multi-user.target