Subject: [alpine-aports] [PATCH] main/openssh: add missing header on s390x

From: "Tuan M. Hoang" <[email-masked]>
Date: Fri, 7 Apr 2017 22:10:25 -0400

Ref : https://bugzilla.redhat.com/show_bug.cgi?id=1434341
Patch from fedora team

---
 main/openssh/APKBUILD                    |  4 +++-
 main/openssh/openssh-7.5p1-sandbox.patch | 23 +++++++++++++++++++++++
 2 files changed, 26 insertions(+), 1 deletion(-)
 create mode 100644 main/openssh/openssh-7.5p1-sandbox.patch

diff --git a/main/openssh/APKBUILD b/main/openssh/APKBUILD
index c25bb21ed1..a20b11149a 100644
--- a/main/openssh/APKBUILD
+++ b/main/openssh/APKBUILD
@@ -28,6 +28,7 @@ source="http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/$pkgname-$_myver.tar
 	sshd.initd
 	sshd.confd
 	sftp-interactive.patch
+	openssh-7.5p1-sandbox.patch
 	"
 # secfixes:
 #   7.4_p1:
@@ -147,4 +148,5 @@ f35fffcd26635249ce5d820e7b3e406e586f2d2d7f6a045f221e2f9fb53aebc1ab1dd1e603b33894
 f2b8daa537ea3f32754a4485492cc6eb3f40133ed46c0a5a29a89e4bcf8583d82d891d94bf2e5eb1c916fa68ec094abf4e6cd641e9737a6c05053808012b3a73  bsd-compatible-realpath.patch
 394a420a36880bb0dd37dfd8727cea91fd9de6534050169e21212a46513ef3aaafe2752c338699b3d4ccd14871b26cf01a152df8060cd37f86ce0665fd53c63f  sshd.initd
 ce0abddbd2004891f88efd8522c4b37a4989290269fab339c0fa9aacc051f7fd3b20813e192e92e0e64315750041cb74012d4321260f4865ff69d7a935b259d4  sshd.confd
-c1d09c65dbc347f0904edc30f91aa9a24b0baee50309536182455b544f1e3f85a8cecfa959e32be8b101d8282ef06dde3febbbc3f315489339dcf04155c859a9  sftp-interactive.patch"
+c1d09c65dbc347f0904edc30f91aa9a24b0baee50309536182455b544f1e3f85a8cecfa959e32be8b101d8282ef06dde3febbbc3f315489339dcf04155c859a9  sftp-interactive.patch
+15c5478bcae56c019a2fbd82ec04808537fd4ba1f1ba4a0a88c0343c16c698c45dbfac59eebc3fcfd3c15b302ebec43e60ffa02442a6c77673b14818ad3f7b60  openssh-7.5p1-sandbox.patch"
diff --git a/main/openssh/openssh-7.5p1-sandbox.patch b/main/openssh/openssh-7.5p1-sandbox.patch
new file mode 100644
index 0000000000..7d09632c8f
--- /dev/null
+++ b/main/openssh/openssh-7.5p1-sandbox.patch
@@ -0,0 +1,23 @@
+diff --git a/sandbox-seccomp-filter.c b/sandbox-seccomp-filter.c
+index 3a1aedce72c2..a8d472a63ccb 100644
+--- a/sandbox-seccomp-filter.c
++++ b/sandbox-seccomp-filter.c
+@@ -50,6 +50,9 @@
+ #include <elf.h>
+ 
+ #include <asm/unistd.h>
++#ifdef __s390__
++#include <asm/zcrypt.h>
++#endif
+ 
+ #include <errno.h>
+ #include <signal.h>
+@@ -235,7 +235,7 @@ static const struct sock_filter preauth_insns[] = {
+ 	 * x86-64 syscall under some circumstances, e.g.
+ 	 * https://bugs.debian.org/849923
+ 	 */
+-	SC_ALLOW(__NR_clock_gettime & ~__X32_SYSCALL_BIT);
++	SC_ALLOW(__NR_clock_gettime & ~__X32_SYSCALL_BIT),
+ #endif
+ 
+ 	/* Default deny */
-- 
2.12.1

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---