lxd: update to 3.14

This commit is contained in:
Julio Galvan 2019-06-23 21:54:55 -07:00 committed by Helmut Pozimski
parent b30d8f3229
commit 85158746b9
2 changed files with 43 additions and 2 deletions

View file

@ -0,0 +1,41 @@
lxc/lxd@a181ed4 [PATCH] seccomp: define __NR_mknod if missing
lxc/lxd@c655ed5 [PATCH] seccomp: rework missing syscall number definitions
---
lxd/seccomp.go | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/lxd/seccomp.go b/lxd/seccomp.go
index 0afad7cacc..32397b9729 100644
--- lxd/seccomp.go
+++ lxd/seccomp.go
@@ -109,6 +109,14 @@
return -EPERM;
}
+#ifndef __NR_mknodat
+ #error missing kernel headers
+#else
+ #ifdef __NR_mknod
+ #define LXD_MUST_CHECK_MKNOD
+ #endif
+#endif
+
static int seccomp_notify_mknod_set_response(int fd_mem, struct seccomp_notify_proxy_msg *msg,
char *buf, size_t size,
mode_t *mode, dev_t *dev,
@@ -124,6 +132,7 @@ static int seccomp_notify_mknod_set_response(int fd_mem, struct seccomp_notify_p
resp->val = 0;
switch (req->data.nr) {
+#ifdef LXD_MUST_CHECK_MKNOD
case __NR_mknod:
resp->error = device_allowed(req->data.args[2], req->data.args[1]);
if (resp->error) {
@@ -143,6 +149,7 @@ static int seccomp_notify_mknod_set_response(int fd_mem, struct seccomp_notify_p
*pid = req->pid;
break;
+#endif
case __NR_mknodat:
if (req->data.args[0] != AT_FDCWD) {
errno = EINVAL;

View file

@ -1,6 +1,6 @@
# Template file for 'lxd'
pkgname=lxd
version=3.13
version=3.14
revision=1
build_style=go
go_import_path=github.com/lxc/lxd
@ -15,7 +15,7 @@ maintainer="Cameron Nemo <camerontnorman@gmail.com>"
license="Apache-2.0"
homepage="https://linuxcontainers.org/lxd"
distfiles="https://linuxcontainers.org/downloads/lxd/lxd-${version}.tar.gz"
checksum=025138d2ac7ade6e34446f90f2d25ded86aedcad726d85ba8f2b7188dab75acd
checksum=409e4758cbeb43b098d0265c4ce05aeeac5ae73f8914ceb1006e6a6d89fe1fe5
system_groups="lxd"
do_configure() {