diff options
Diffstat (limited to 'meta/recipes-extended/shadow')
-rw-r--r-- | meta/recipes-extended/shadow/files/CVE-2019-19882.patch | 55 | ||||
-rw-r--r-- | meta/recipes-extended/shadow/shadow.inc | 1 |
2 files changed, 56 insertions, 0 deletions
diff --git a/meta/recipes-extended/shadow/files/CVE-2019-19882.patch b/meta/recipes-extended/shadow/files/CVE-2019-19882.patch new file mode 100644 index 0000000000..894d867680 --- /dev/null +++ b/meta/recipes-extended/shadow/files/CVE-2019-19882.patch | |||
@@ -0,0 +1,55 @@ | |||
1 | From 66b7bc0dcfda12d7f58eba993bd02872cae1d713 Mon Sep 17 00:00:00 2001 | ||
2 | From: Dave Reisner <dreisner@archlinux.org> | ||
3 | Date: Mon, 16 Dec 2019 14:11:23 -0500 | ||
4 | Subject: [PATCH] Don't auto-enable ACCT_TOOLS_SETUID if PAM is detected | ||
5 | |||
6 | Here's a sad story: | ||
7 | |||
8 | * 70971457 is merged into shadow, allowing newgidmap/newuidmap to be | ||
9 | installed with file caps rather than setuid. | ||
10 | * https://bugs.archlinux.org/task/63248 is filed to take advantage of | ||
11 | this. | ||
12 | * The arch maintainer of the 'shadow' package notices that this doesn't | ||
13 | work, and submits a pull request to fix this in shadow. | ||
14 | * edf7547ad5 is merged, fixing the post install hooks. | ||
15 | |||
16 | The problem here is that distros have been building shadow with PAM for | ||
17 | O(years), but the install hooks have silently failed due to the | ||
18 | combination of the directory mismatch (suidubins vs suidsbins) and later | ||
19 | success with setuid'ing newgidmap/newuidmap. | ||
20 | |||
21 | With the install hooks fixed, those of us (Arch[1] and Gentoo[2] so far) | ||
22 | who never built shadow explicitly with --enable-account-tools-setuid are | ||
23 | now getting setuid account tools, and don't have PAM configuration | ||
24 | suitable for use with setuid account management tools. | ||
25 | |||
26 | It's entirely unclear to me why you'd want this, but I assume there's | ||
27 | some reason out there for it existing. Regardless, setuid binaries are | ||
28 | dangerous and shouldn't be enabled by default without good reason. | ||
29 | |||
30 | [1] https://bugs.archlinux.org/task/64836 | ||
31 | [2] https://bugs.gentoo.org/702252 | ||
32 | |||
33 | Upstream-Status: Backport | ||
34 | CVE: CVE-2019-19882 | ||
35 | Signed-off-by: Li Zhou <li.zhou@windriver.com> | ||
36 | --- | ||
37 | configure.ac | 2 +- | ||
38 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
39 | |||
40 | diff --git a/configure.ac b/configure.ac | ||
41 | index e3ed3b43..d6e2bfbd 100644 | ||
42 | --- a/configure.ac | ||
43 | +++ b/configure.ac | ||
44 | @@ -226,7 +226,7 @@ AC_ARG_ENABLE(account-tools-setuid, | ||
45 | *) AC_MSG_ERROR(bad value ${enableval} for --enable-account-tools-setuid) | ||
46 | ;; | ||
47 | esac], | ||
48 | - [enable_acct_tools_setuid="maybe"] | ||
49 | + [enable_acct_tools_setuid="no"] | ||
50 | ) | ||
51 | |||
52 | AC_ARG_ENABLE(utmpx, | ||
53 | -- | ||
54 | 2.17.1 | ||
55 | |||
diff --git a/meta/recipes-extended/shadow/shadow.inc b/meta/recipes-extended/shadow/shadow.inc index 267d2324c5..3bfa39e6ff 100644 --- a/meta/recipes-extended/shadow/shadow.inc +++ b/meta/recipes-extended/shadow/shadow.inc | |||
@@ -13,6 +13,7 @@ SRC_URI = "https://github.com/shadow-maint/shadow/releases/download/${PV}/${BP}. | |||
13 | file://shadow-4.1.3-dots-in-usernames.patch \ | 13 | file://shadow-4.1.3-dots-in-usernames.patch \ |
14 | ${@bb.utils.contains('PACKAGECONFIG', 'pam', '${PAM_SRC_URI}', '', d)} \ | 14 | ${@bb.utils.contains('PACKAGECONFIG', 'pam', '${PAM_SRC_URI}', '', d)} \ |
15 | file://shadow-relaxed-usernames.patch \ | 15 | file://shadow-relaxed-usernames.patch \ |
16 | file://CVE-2019-19882.patch \ | ||
16 | " | 17 | " |
17 | 18 | ||
18 | SRC_URI_append_class-target = " \ | 19 | SRC_URI_append_class-target = " \ |