From b78b413a24cf97f5ebda73bcf36fcb15ffbe1abf Mon Sep 17 00:00:00 2001 From: Yi Zhao Date: Sat, 13 Mar 2021 13:50:31 +0800 Subject: libselinux: update to 3.2 * Merge inc file into bb file. * Drop obsolete patches: 0001-libselinux-do-not-define-gettid-for-musl.patch libselinux-define-FD_CLOEXEC-as-necessary.patch libselinux-make-O_CLOEXEC-optional.patch libselinux-make-SOCK_CLOEXEC-optional.patch Signed-off-by: Yi Zhao Signed-off-by: Joe MacDonald --- .../libselinux-make-SOCK_CLOEXEC-optional.patch | 38 ---------------------- 1 file changed, 38 deletions(-) delete mode 100644 recipes-security/selinux/libselinux/libselinux-make-SOCK_CLOEXEC-optional.patch (limited to 'recipes-security/selinux/libselinux/libselinux-make-SOCK_CLOEXEC-optional.patch') diff --git a/recipes-security/selinux/libselinux/libselinux-make-SOCK_CLOEXEC-optional.patch b/recipes-security/selinux/libselinux/libselinux-make-SOCK_CLOEXEC-optional.patch deleted file mode 100644 index 77a9136..0000000 --- a/recipes-security/selinux/libselinux/libselinux-make-SOCK_CLOEXEC-optional.patch +++ /dev/null @@ -1,38 +0,0 @@ -From e630805d15a3b8d09330353f87a7e4a9fcc9998a Mon Sep 17 00:00:00 2001 -From: Joe MacDonald -Date: Tue, 15 Oct 2013 10:07:43 -0400 -Subject: [PATCH] libselinux: make SOCK_CLOEXEC optional - -libselinux/src/setrans_client.c checks for the existence of SOCK_CLOEXEC -before using it, however libselinux/src/avc_internal.c does not. Since -SOCK_CLOEXEC suffers the same problem as O_CLOEXEC on some older -platforms, we need to ensure we protect the references it it in the same -way. - -Upstream-Status: Inappropriate - -Signed-off-by: Joe MacDonald - ---- - src/avc_internal.c | 8 +++++++- - 1 file changed, 7 insertions(+), 1 deletion(-) - -diff --git a/src/avc_internal.c b/src/avc_internal.c -index 49cecc9..148cc83 100644 ---- a/src/avc_internal.c -+++ b/src/avc_internal.c -@@ -60,7 +60,13 @@ int avc_netlink_open(int blocking) - int len, rc = 0; - struct sockaddr_nl addr; - -- fd = socket(PF_NETLINK, SOCK_RAW | SOCK_CLOEXEC, NETLINK_SELINUX); -+ fd = socket(PF_NETLINK, SOCK_RAW -+#ifdef SOCK_CLOEXEC -+ | SOCK_CLOEXEC -+#else -+#warning SOCK_CLOEXEC undefined on this platform, this may leak file descriptors -+#endif -+ , NETLINK_SELINUX); - if (fd < 0) { - rc = fd; - goto out; -- cgit v1.2.3-54-g00ecf