Patch review
cover Patch review
Please review this set of changes for kirkstone and have comments back by end of day Thursday, December 19
Passed a-full on autobuilder:
https://valkyrie.yoctoproject.org/#/builders/29/builds/663
The following changes since commit b132b817f5931b290e5348dd4a17fbfdc5c6e2c4:
dbus: disable assertions and enable only modular tests (2024-12-10 05:38:29 -0800)
are available in the Git repository at:
https://git.openembedded.org/openembedded-core-contrib stable/kirkstone-nut
https://git.openembedded.org/openembedded-core-contrib/log/?h=stable/kirkstone-nut
Alex Kiernan (1):
base-passwd: Add the sgx group
Alexandre Belloni (1):
base-passwd: fix patchreview warning
Ernst Persson (1):
package.bbclass: Use shlex instead of deprecated pipes
Jiaying Song (1):
subversion: fix CVE-2024-46901
Louis Rannou (1):
base-passwd: add the wheel group
Peter Kjellerstedt (3):
base-passwd: Regenerate the patches
base-passwd: Update to 3.5.52
base-passwd: Update the status for two patches
Yogita Urade (1):
xserver-xorg: fix CVE-2024-9632
meta/classes/package.bbclass | 4 +-
.../0001-Add-a-shutdown-group.patch | 26 +++
.../0001-base-passwd-Add-the-sgx-group.patch | 30 ++++
...nstead-of-bin-bash-for-the-root-user.patch | 23 +++
...t-since-we-do-not-have-an-etc-shadow.patch | 21 +++
...put-group-for-the-dev-input-devices.patch} | 17 +-
.../{kvm.patch => 0005-Add-kvm-group.patch} | 2 +-
...ble-to-build-without-debconf-support.patch | 129 ++++++++++++++
...-to-disable-the-generation-of-the-do.patch | 46 +++++
.../base-passwd/0008-Add-wheel-group.patch | 20 +++
.../base-passwd/add_shutdown.patch | 19 ---
.../base-passwd/disable-docs.patch | 24 ---
.../base-passwd/disable-shell.patch | 57 -------
.../base-passwd/base-passwd/nobash.patch | 15 --
.../base-passwd/base-passwd/noshadow.patch | 14 --
...passwd_3.5.29.bb => base-passwd_3.5.52.bb} | 30 ++--
.../subversion/CVE-2024-46901.patch | 161 ++++++++++++++++++
.../subversion/subversion_1.14.2.bb | 3 +-
.../xserver-xorg/CVE-2024-9632.patch | 58 +++++++
.../xorg-xserver/xserver-xorg_21.1.8.bb | 1 +
20 files changed, 547 insertions(+), 153 deletions(-)
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0001-Add-a-shutdown-group.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0001-base-passwd-Add-the-sgx-group.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch
rename meta/recipes-core/base-passwd/base-passwd/{input.patch => 0004-Add-an-input-group-for-the-dev-input-devices.patch} (42%)
rename meta/recipes-core/base-passwd/base-passwd/{kvm.patch => 0005-Add-kvm-group.patch} (88%)
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0006-Make-it-possible-to-build-without-debconf-support.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0007-Make-it-possible-to-disable-the-generation-of-the-do.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0008-Add-wheel-group.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/add_shutdown.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/disable-docs.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/disable-shell.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/nobash.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/noshadow.patch
rename meta/recipes-core/base-passwd/{base-passwd_3.5.29.bb => base-passwd_3.5.52.bb} (79%)
create mode 100644 meta/recipes-devtools/subversion/subversion/CVE-2024-46901.patch
create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-9632.patchSignature · 1 line
2.34.1
PATCH 1/9 xserver-xorg: fix CVE-2024-9632
From: Yogita Urade <[email protected]>
A flaw was found in the X.org server. Due to improperly tracked allocation size in _XkbSetCompatMap, a local attacker may be able to trigger a buffer overflow condition via a specially crafted payload, leading to denial of service or local privilege escalation in distributions where the X.org server is run with root privileges.
Reference:
https://nvd.nist.gov/vuln/detail/CVE-2024-9632
Upstream patch:
https://gitlab.freedesktop.org/xorg/xserver/-/commit/ba1d14f8eff2a123bd7ff4d48c02e1d5131358e0
--- .../xserver-xorg/CVE-2024-9632.patch | 58 +++++++++++++++++++ .../xorg-xserver/xserver-xorg_21.1.8.bb | 1 + 2 files changed, 59 insertions(+) create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-9632.patch
meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2024-9632.patch new file +58 -0
@@ -0,0 +1,58 @@ +From ba1d14f8eff2a123bd7ff4d48c02e1d5131358e0 Mon Sep 17 00:00:00 2001 +From: Matthieu Herrb <[email protected]> +Date: Thu, 10 Oct 2024 10:37:28 +0200 +Subject: [PATCH] xkb: Fix buffer overflow in _XkbSetCompatMap() + +The _XkbSetCompatMap() function attempts to resize the `sym_interpret` +buffer. + +However, It didn't update its size properly. It updated `num_si` only, +without updating `size_si`. + +This may lead to local privilege escalation if the server is run as root +or remote code execution (e.g. x11 over ssh). + +CVE-2024-9632, ZDI-CAN-24756 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Reviewed-by: Peter Hutterer <[email protected]> +Tested-by: Peter Hutterer <[email protected]> +Reviewed-by: José Expósito <[email protected]> +(cherry picked from commit 85b77657) + +Part-of: <!1734> + +CVE: CVE-2024-9632 +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/ba1d14f8eff2a123bd7ff4d48c02e1d5131358e0] + +Signed-off-by: Yogita Urade <[email protected]> +--- + xkb/xkb.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/xkb/xkb.c b/xkb/xkb.c +index 276dc19..7da00a0 100644 +--- a/xkb/xkb.c ++++ b/xkb/xkb.c +@@ -2992,13 +2992,13 @@ _XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, + XkbSymInterpretPtr sym; + unsigned int skipped = 0; + +- if ((unsigned) (req->firstSI + req->nSI) > compat->num_si) { +- compat->num_si = req->firstSI + req->nSI; ++ if ((unsigned) (req->firstSI + req->nSI) > compat->size_si) { ++ compat->num_si = compat->size_si = req->firstSI + req->nSI; + compat->sym_interpret = reallocarray(compat->sym_interpret, +- compat->num_si, ++ compat->size_si, + sizeof(XkbSymInterpretRec)); + if (!compat->sym_interpret) { +- compat->num_si = 0; ++ compat->num_si = compat->size_si = 0; + return BadAlloc; + } + } +-- +2.40.0
meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.8.bb +1 -0
@@ -21,6 +21,7 @@ SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.pat file://CVE-2024-31082.patch \ file://CVE-2024-31083-0001.patch \ file://CVE-2024-31083-0002.patch \ + file://CVE-2024-9632.patch \ " SRC_URI[sha256sum] = "38aadb735650c8024ee25211c190bf8aad844c5f59632761ab1ef4c4d5aeb152"
Signature · 1 line
2.34.1
PATCH 2/9 subversion: fix CVE-2024-46901
In reply to Steve SakomanFrom: Jiaying Song <[email protected]>
Insufficient validation of filenames against control characters in Apache Subversion repositories served via mod_dav_svn allows authenticated users with commit access to commit a corrupted revision, leading to disruption for users of the repository. All versions of Subversion up to and including Subversion 1.14.4 are affected if serving repositories via mod_dav_svn. Users are recommended to upgrade to version 1.14.5, which fixes this issue. Repositories served via other access methods are not affected.
References:
https://nvd.nist.gov/vuln/detail/CVE-2024-46901
Upstream patches:
https://subversion.apache.org/security/CVE-2024-46901-advisory.txt
--- .../subversion/CVE-2024-46901.patch | 161 ++++++++++++++++++ .../subversion/subversion_1.14.2.bb | 3 +- 2 files changed, 163 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-devtools/subversion/subversion/CVE-2024-46901.patch
meta/recipes-devtools/subversion/subversion/CVE-2024-46901.patch new file +161 -0
@@ -0,0 +1,161 @@ +From 149e299cd7eaadc8248480300b6e13b097c5b3fa Mon Sep 17 00:00:00 2001 +From: Jiaying Song <[email protected]> +Date: Fri, 13 Dec 2024 12:19:43 +0800 +Subject: [PATCH] Fix CVE-2024-46901 + +It has been discovered that the patch for CVE-2013-1968 was incomplete and unintentionally left mod_dav_svn vulnerable to control characters in filenames. + +Upstream-Status: Backport +[https://subversion.apache.org/security/CVE-2024-46901-advisory.txt] + +CVE: CVE-2024-46901 + +Signed-off-by: Jiaying Song <[email protected]> +--- + .../include/private/svn_repos_private.h | 8 +++++ + subversion/libsvn_repos/commit.c | 3 +- + subversion/libsvn_repos/repos.c | 10 +++++++ + subversion/mod_dav_svn/lock.c | 7 +++++ + subversion/mod_dav_svn/repos.c | 29 +++++++++++++++++++ + 5 files changed, 55 insertions(+), 2 deletions(-) + +diff --git a/subversion/include/private/svn_repos_private.h b/subversion/include/private/svn_repos_private.h +index 1fd34e8..1d5fc9c 100644 +--- a/subversion/include/private/svn_repos_private.h ++++ b/subversion/include/private/svn_repos_private.h +@@ -390,6 +390,14 @@ svn_repos__get_dump_editor(const svn_delta_editor_t **editor, + const char *update_anchor_relpath, + apr_pool_t *pool); + ++/* Validate that the given PATH is a valid pathname that can be stored in ++ * a Subversion repository, according to the name constraints used by the ++ * svn_repos_* layer. ++ */ ++svn_error_t * ++svn_repos__validate_new_path(const char *path, ++ apr_pool_t *scratch_pool); ++ + #ifdef __cplusplus + } + #endif /* __cplusplus */ +diff --git a/subversion/libsvn_repos/commit.c b/subversion/libsvn_repos/commit.c +index 515600d..aad37ee 100644 +--- a/subversion/libsvn_repos/commit.c ++++ b/subversion/libsvn_repos/commit.c +@@ -308,8 +308,7 @@ add_file_or_directory(const char *path, + svn_boolean_t was_copied = FALSE; + const char *full_path, *canonicalized_path; + +- /* Reject paths which contain control characters (related to issue #4340). */ +- SVN_ERR(svn_path_check_valid(path, pool)); ++ SVN_ERR(svn_repos__validate_new_path(path, pool)); + + SVN_ERR(svn_relpath_canonicalize_safe(&canonicalized_path, NULL, path, + pool, pool)); +diff --git a/subversion/libsvn_repos/repos.c b/subversion/libsvn_repos/repos.c +index 2189de8..119f04b 100644 +--- a/subversion/libsvn_repos/repos.c ++++ b/subversion/libsvn_repos/repos.c +@@ -2092,3 +2092,13 @@ svn_repos__fs_type(const char **fs_type, + svn_dirent_join(repos_path, SVN_REPOS__DB_DIR, pool), + pool); + } ++ ++svn_error_t * ++svn_repos__validate_new_path(const char *path, ++ apr_pool_t *scratch_pool) ++{ ++ /* Reject paths which contain control characters (related to issue #4340). */ ++ SVN_ERR(svn_path_check_valid(path, scratch_pool)); ++ ++ return SVN_NO_ERROR; ++} +diff --git a/subversion/mod_dav_svn/lock.c b/subversion/mod_dav_svn/lock.c +index 7e9c94b..d2a6aa9 100644 +--- a/subversion/mod_dav_svn/lock.c ++++ b/subversion/mod_dav_svn/lock.c +@@ -36,6 +36,7 @@ + #include "svn_pools.h" + #include "svn_props.h" + #include "private/svn_log.h" ++#include "private/svn_repos_private.h" + + #include "dav_svn.h" + +@@ -717,6 +718,12 @@ append_locks(dav_lockdb *lockdb, + + /* Commit a 0-byte file: */ + ++ if ((serr = svn_repos__validate_new_path(resource->info->repos_path, ++ resource->pool))) ++ return dav_svn__convert_err(serr, HTTP_BAD_REQUEST, ++ "Request specifies an invalid path.", ++ resource->pool); ++ + if ((serr = dav_svn__get_youngest_rev(&rev, repos, resource->pool))) + return dav_svn__convert_err(serr, HTTP_INTERNAL_SERVER_ERROR, + "Could not determine youngest revision", +diff --git a/subversion/mod_dav_svn/repos.c b/subversion/mod_dav_svn/repos.c +index 8cbd5e7..778ae9b 100644 +--- a/subversion/mod_dav_svn/repos.c ++++ b/subversion/mod_dav_svn/repos.c +@@ -2928,6 +2928,15 @@ open_stream(const dav_resource *resource, + + if (kind == svn_node_none) /* No existing file. */ + { ++ serr = svn_repos__validate_new_path(resource->info->repos_path, ++ resource->pool); ++ ++ if (serr != NULL) ++ { ++ return dav_svn__convert_err(serr, HTTP_BAD_REQUEST, ++ "Request specifies an invalid path.", ++ resource->pool); ++ } + serr = svn_fs_make_file(resource->info->root.root, + resource->info->repos_path, + resource->pool); +@@ -4120,6 +4129,14 @@ create_collection(dav_resource *resource) + return err; + } + ++ if ((serr = svn_repos__validate_new_path(resource->info->repos_path, ++ resource->pool)) != NULL) ++ { ++ return dav_svn__convert_err(serr, HTTP_BAD_REQUEST, ++ "Request specifies an invalid path.", ++ resource->pool); ++ } ++ + if ((serr = svn_fs_make_dir(resource->info->root.root, + resource->info->repos_path, + resource->pool)) != NULL) +@@ -4193,6 +4210,12 @@ copy_resource(const dav_resource *src, + if (err) + return err; + } ++ ++ serr = svn_repos__validate_new_path(dst->info->repos_path, dst->pool); ++ if (serr) ++ return dav_svn__convert_err(serr, HTTP_BAD_REQUEST, ++ "Request specifies an invalid path.", ++ dst->pool); + + src_repos_path = svn_repos_path(src->info->repos->repos, src->pool); + dst_repos_path = svn_repos_path(dst->info->repos->repos, dst->pool); +@@ -4430,6 +4453,12 @@ move_resource(dav_resource *src, + if (err) + return err; + ++ serr = svn_repos__validate_new_path(dst->info->repos_path, dst->pool); ++ if (serr) ++ return dav_svn__convert_err(serr, HTTP_BAD_REQUEST, ++ "Request specifies an invalid path.", ++ dst->pool); ++ + /* Copy the src to the dst. */ + serr = svn_fs_copy(src->info->root.root, /* the root object of src rev*/ + src->info->repos_path, /* the relative path of src */ +-- +2.25.1 +
meta/recipes-devtools/subversion/subversion_1.14.2.bb +2 -1
@@ -10,7 +10,8 @@ DEPENDS:append:class-native = " file-replacement-native" SRC_URI = "${APACHE_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \ file://serfmacro.patch \ - " + file://CVE-2024-46901.patch \ + " SRC_URI[sha256sum] = "c9130e8d0b75728a66f0e7038fc77052e671830d785b5616aad53b4810d3cc28"
Signature · 1 line
2.34.1
PATCH 3/9 package.bbclass: Use shlex instead of deprecated pipes
In reply to Steve SakomanFrom: Ernst Persson <[email protected]>
The pipes library is deprecated in Python 3.11 and will be removed in Python 3.13. pipes.quote is just an import of shlex.quote anyway.
--- meta/classes/package.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
meta/classes/package.bbclass +2 -2
@@ -1850,7 +1850,7 @@ SHLIBSWORKDIR = "${PKGDESTWORK}/${MLPREFIX}shlibs2" python package_do_shlibs() { import itertools - import re, pipes + import re, shlex import subprocess exclude_shlibs = d.getVar('EXCLUDE_FROM_SHLIBS', False)
@@ -1894,7 +1894,7 @@ python package_do_shlibs() { sonames = set() renames = [] ldir = os.path.dirname(file).replace(pkgdest + "/" + pkg, '') - cmd = d.getVar('OBJDUMP') + " -p " + pipes.quote(file) + " 2>/dev/null" + cmd = d.getVar('OBJDUMP') + " -p " + shlex.quote(file) + " 2>/dev/null" fd = os.popen(cmd) lines = fd.readlines() fd.close()
Signature · 1 line
2.34.1
PATCH 4/9 base-passwd: Regenerate the patches
In reply to Steve SakomanFrom: Peter Kjellerstedt <[email protected]>
---
.../0001-Add-a-shutdown-group.patch | 26 +++++++++++++++++++
...nstead-of-bin-bash-for-the-root-user.patch | 23 ++++++++++++++++
...-since-we-do-not-have-an-etc-shadow.patch} | 15 ++++++++---
...put-group-for-the-dev-input-devices.patch} | 17 ++++++------
.../{kvm.patch => 0005-Add-kvm-group.patch} | 2 +-
...006-Disable-shell-for-default-users.patch} | 5 +---
...ble-generation-of-the-documentation.patch} | 22 +++++++++++-----
.../base-passwd/add_shutdown.patch | 19 --------------
.../base-passwd/base-passwd/nobash.patch | 15 -----------
.../base-passwd/base-passwd_3.5.29.bb | 14 +++++-----
10 files changed, 93 insertions(+), 65 deletions(-)
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0001-Add-a-shutdown-group.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch
rename meta/recipes-core/base-passwd/base-passwd/{noshadow.patch => 0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch} (40%)
rename meta/recipes-core/base-passwd/base-passwd/{input.patch => 0004-Add-an-input-group-for-the-dev-input-devices.patch} (42%)
rename meta/recipes-core/base-passwd/base-passwd/{kvm.patch => 0005-Add-kvm-group.patch} (88%)
rename meta/recipes-core/base-passwd/base-passwd/{disable-shell.patch => 0006-Disable-shell-for-default-users.patch} (96%)
rename meta/recipes-core/base-passwd/base-passwd/{disable-docs.patch => 0007-Disable-generation-of-the-documentation.patch} (40%)
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/add_shutdown.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/nobash.patchmeta/recipes-core/base-passwd/base-passwd/0001-Add-a-shutdown-group.patch new file +26 -0
@@ -0,0 +1,26 @@ +From 8f3ace87df3aaad85946c22cae240532ea3e73b8 Mon Sep 17 00:00:00 2001 +From: Saul Wold <[email protected]> +Date: Fri, 29 Apr 2022 13:32:27 +0000 +Subject: [PATCH] Add a shutdown group + +We need to have a shutdown group to allow the shutdown icon to work +correctly. Any users that want to use shutdown like the xuser should +be added to this group. + +Upstream-Status: Inappropriate [Embedded] +Signed-off-by: Saul Wold <[email protected]> +--- + group.master | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/group.master b/group.master +index ad1dd2d..1b5e2fb 100644 +--- a/group.master ++++ b/group.master +@@ -35,5 +35,6 @@ sasl:*:45: + plugdev:*:46: + staff:*:50: + games:*:60: ++shutdown:*:70: + users:*:100: + nogroup:*:65534:
meta/recipes-core/base-passwd/base-passwd/0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch new file +23 -0
@@ -0,0 +1,23 @@ +From 4411fc0df77566d52bee11ec0bad4be30a96e99e Mon Sep 17 00:00:00 2001 +From: Scott Garman <[email protected]> +Date: Fri, 29 Apr 2022 13:32:27 +0000 +Subject: [PATCH] Use /bin/sh instead of /bin/bash for the root user + +/bin/bash may not be included in some images such as minimal. + +Upstream-Status: Inappropriate [configuration] +Signed-off-by: Scott Garman <[email protected]> +--- + passwd.master | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/passwd.master b/passwd.master +index a01a6aa..b54ff51 100644 +--- a/passwd.master ++++ b/passwd.master +@@ -1,4 +1,4 @@ +-root:*:0:0:root:/root:/bin/bash ++root:*:0:0:root:/root:/bin/sh + daemon:*:1:1:daemon:/usr/sbin:/bin/sh + bin:*:2:2:bin:/bin:/bin/sh + sys:*:3:3:sys:/dev:/bin/sh
meta/recipes-core/base-passwd/base-passwd/0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch renamed from meta/recipes-core/base-passwd/base-passwd/noshadow.patch +11 -4
@@ -1,11 +1,18 @@ -remove "*" for root since we don't have a /etc/shadow so far. +From 13a1a284a134d18a454625a5b4485c0d99079ae9 Mon Sep 17 00:00:00 2001 +From: Scott Garman <[email protected]> +Date: Fri, 29 Apr 2022 13:32:28 +0000 +Subject: [PATCH] Remove "*" for root since we do not have an /etc/shadow Upstream-Status: Inappropriate [configuration] - Signed-off-by: Scott Garman <[email protected]> +--- + passwd.master | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) ---- base-passwd/passwd.master~nobash -+++ base-passwd/passwd.master +diff --git a/passwd.master b/passwd.master +index b54ff51..e1c32ff 100644 +--- a/passwd.master ++++ b/passwd.master @@ -1,4 +1,4 @@ -root:*:0:0:root:/root:/bin/sh +root::0:0:root:/root:/bin/sh
meta/recipes-core/base-passwd/base-passwd/0004-Add-an-input-group-for-the-dev-input-devices.patch renamed from meta/recipes-core/base-passwd/base-passwd/input.patch +9 -8
@@ -1,17 +1,18 @@ -Add an input group for the /dev/input/* devices. +From c5f012750f8102ff54af73ccc2d2b7bfa1f26db4 Mon Sep 17 00:00:00 2001 +From: Darren Hart <[email protected]> +Date: Fri, 29 Apr 2022 13:32:28 +0000 +Subject: [PATCH] Add an input group for the /dev/input/* devices Upstream-Status: Inappropriate [configuration] - Signed-off-by: Darren Hart <[email protected]> - --- - group.master | 1 + + group.master | 1 + 1 file changed, 1 insertion(+) -Index: base-passwd-3.5.26/group.master -=================================================================== ---- base-passwd-3.5.26.orig/group.master -+++ base-passwd-3.5.26/group.master +diff --git a/group.master b/group.master +index 1b5e2fb..cea9d60 100644 +--- a/group.master ++++ b/group.master @@ -12,6 +12,7 @@ uucp:*:10: man:*:12: proxy:*:13:
meta/recipes-core/base-passwd/base-passwd/0005-Add-kvm-group.patch renamed from meta/recipes-core/base-passwd/base-passwd/kvm.patch +1 -1
@@ -1,4 +1,4 @@ -From 6355278b9f744291864c373a32a8da8f84aaaf37 Mon Sep 17 00:00:00 2001 +From 6cf19461fb31d7a7a3010629aae9aab49c26a01b Mon Sep 17 00:00:00 2001 From: Jacob Kroon <[email protected]> Date: Wed, 30 Jan 2019 04:53:48 +0000 Subject: [PATCH] Add kvm group
meta/recipes-core/base-passwd/base-passwd/0006-Disable-shell-for-default-users.patch renamed from meta/recipes-core/base-passwd/base-passwd/disable-shell.patch +1 -4
@@ -1,4 +1,4 @@ -From 91e0db96741359173ddf2be083aafcc1a3c32472 Mon Sep 17 00:00:00 2001 +From f35eb24213475d3024ad45297fd855c6abfbbac0 Mon Sep 17 00:00:00 2001 From: Jiaqing Zhao <[email protected]> Date: Mon, 18 Apr 2022 11:22:43 +0800 Subject: [PATCH] Disable shell for default users
@@ -52,6 +52,3 @@ index e1c32ff..0cd5ffd 100644 +irc:*:39:39:ircd:/var/run/ircd:/sbin/nologin +gnats:*:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/sbin/nologin +nobody:*:65534:65534:nobody:/nonexistent:/sbin/nologin --- -2.32.0 -
meta/recipes-core/base-passwd/base-passwd/0007-Disable-generation-of-the-documentation.patch renamed from meta/recipes-core/base-passwd/base-passwd/disable-docs.patch +15 -7
@@ -1,14 +1,22 @@ -Disable documentation for now as it uses tools currently not supported -by OE-Core. It uses sgmltools and po4a. +From 7ccf8227cb10d78f1958a7a7feed75a390a6b133 Mon Sep 17 00:00:00 2001 +From: Saul Wold <[email protected]> +Date: Fri, 29 Apr 2022 13:32:28 +0000 +Subject: [PATCH] Disable generation of the documentation + +It uses tools currently not supported by OE-Core. It uses sgmltools +and po4a. Upstream-Status: Inappropriate [OE-Core specific] Signed-off-by: Saul Wold <[email protected]> +--- + Makefile.in | 3 --- + 1 file changed, 3 deletions(-) -Index: base-passwd-3.5.28/Makefile.in -=================================================================== ---- base-passwd-3.5.28.orig/Makefile.in -+++ base-passwd-3.5.28/Makefile.in -@@ -25,13 +25,10 @@ gen_configure = config.cache config.stat +diff --git a/Makefile.in b/Makefile.in +index 9ba097c..d3ea47c 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -25,13 +25,10 @@ gen_configure = config.cache config.status config.log \ confdefhs.h config.h Makefile all: update-passwd
meta/recipes-core/base-passwd/base-passwd/add_shutdown.patch deleted +0 -19
@@ -1,19 +0,0 @@ - -We need to have a shutdown group to allow the shutdown icon -to work correctly. Any users that want to use shutdown like -the xuser should be added to this group. - -Upstream-Status: Inappropriate [Embedded] - -Signed-off-by: Saul Wold <[email protected]> -Index: base-passwd-3.5.26/group.master -=================================================================== ---- base-passwd-3.5.26.orig/group.master -+++ base-passwd-3.5.26/group.master -@@ -36,5 +36,6 @@ sasl:*:45: - plugdev:*:46: - staff:*:50: - games:*:60: -+shutdown:*:70: - users:*:100: - nogroup:*:65534:
meta/recipes-core/base-passwd/base-passwd/nobash.patch deleted +0 -15
@@ -1,15 +0,0 @@ -use /bin/sh instead of /bin/bash, since the latter may not be included in -some images such as minimal - -Upstream-Status: Inappropriate [configuration] - -Signed-off-by: Scott Garman <[email protected]> - ---- base-passwd/passwd.master~nobash -+++ base-passwd/passwd.master -@@ -1,4 +1,4 @@ --root:*:0:0:root:/root:/bin/bash -+root:*:0:0:root:/root:/bin/sh - daemon:*:1:1:daemon:/usr/sbin:/bin/sh - bin:*:2:2:bin:/bin:/bin/sh - sys:*:3:3:sys:/dev:/bin/sh
meta/recipes-core/base-passwd/base-passwd_3.5.29.bb +7 -7
@@ -8,13 +8,13 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a" RECIPE_NO_UPDATE_REASON = "Version 3.5.38 requires cdebconf for update-passwd utility" SRC_URI = "https://launchpad.net/debian/+archive/primary/+files/${BPN}_${PV}.tar.gz \ - file://add_shutdown.patch \ - file://nobash.patch \ - file://noshadow.patch \ - file://input.patch \ - file://disable-docs.patch \ - file://kvm.patch \ - file://disable-shell.patch \ + file://0001-Add-a-shutdown-group.patch \ + file://0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch \ + file://0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch \ + file://0004-Add-an-input-group-for-the-dev-input-devices.patch \ + file://0005-Add-kvm-group.patch \ + file://0006-Disable-shell-for-default-users.patch \ + file://0007-Disable-generation-of-the-documentation.patch \ " SRC_URI[md5sum] = "6beccac48083fe8ae5048acd062e5421"
Signature · 1 line
2.34.1
PATCH 5/9 base-passwd: Update to 3.5.52
In reply to Steve SakomanFrom: Peter Kjellerstedt <[email protected]>
* Add a patch to allow the use of debconf to be disabled.
* Replace 0007-Disable-generation-of-the-documentation.patch with a new patch to disable the generation of the documentation using a configuration option.
* Replace 0006-Disable-shell-for-default-users.patch with a sed expression that uses a variable, NOLOGIN, to specify what command to use for users that are not expected to login. This allows to use some other command than "nologin", e.g., "false". Also, by using ${base_sbindir}, it adheres to usrmerge being configured.
---
...nstead-of-bin-bash-for-the-root-user.patch | 8 +-
...t-since-we-do-not-have-an-etc-shadow.patch | 8 +-
...0006-Disable-shell-for-default-users.patch | 54 --------
...ble-to-build-without-debconf-support.patch | 129 ++++++++++++++++++
...able-generation-of-the-documentation.patch | 32 -----
...-to-disable-the-generation-of-the-do.patch | 46 +++++++
...passwd_3.5.29.bb => base-passwd_3.5.52.bb} | 18 ++-
7 files changed, 194 insertions(+), 101 deletions(-)
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/0006-Disable-shell-for-default-users.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0006-Make-it-possible-to-build-without-debconf-support.patch
delete mode 100644 meta/recipes-core/base-passwd/base-passwd/0007-Disable-generation-of-the-documentation.patch
create mode 100644 meta/recipes-core/base-passwd/base-passwd/0007-Make-it-possible-to-disable-the-generation-of-the-do.patch
rename meta/recipes-core/base-passwd/{base-passwd_3.5.29.bb => base-passwd_3.5.52.bb} (89%)meta/recipes-core/base-passwd/base-passwd/0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch +4 -4
@@ -12,12 +12,12 @@ Signed-off-by: Scott Garman <[email protected]> 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passwd.master b/passwd.master -index a01a6aa..b54ff51 100644 +index 7cd4e24..041685a 100644 --- a/passwd.master +++ b/passwd.master @@ -1,4 +1,4 @@ -root:*:0:0:root:/root:/bin/bash +root:*:0:0:root:/root:/bin/sh - daemon:*:1:1:daemon:/usr/sbin:/bin/sh - bin:*:2:2:bin:/bin:/bin/sh - sys:*:3:3:sys:/dev:/bin/sh + daemon:*:1:1:daemon:/usr/sbin:/usr/sbin/nologin + bin:*:2:2:bin:/bin:/usr/sbin/nologin + sys:*:3:3:sys:/dev:/usr/sbin/nologin
meta/recipes-core/base-passwd/base-passwd/0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch +4 -4
@@ -10,12 +10,12 @@ Signed-off-by: Scott Garman <[email protected]> 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passwd.master b/passwd.master -index b54ff51..e1c32ff 100644 +index 041685a..31a84d4 100644 --- a/passwd.master +++ b/passwd.master @@ -1,4 +1,4 @@ -root:*:0:0:root:/root:/bin/sh +root::0:0:root:/root:/bin/sh - daemon:*:1:1:daemon:/usr/sbin:/bin/sh - bin:*:2:2:bin:/bin:/bin/sh - sys:*:3:3:sys:/dev:/bin/sh + daemon:*:1:1:daemon:/usr/sbin:/usr/sbin/nologin + bin:*:2:2:bin:/bin:/usr/sbin/nologin + sys:*:3:3:sys:/dev:/usr/sbin/nologin
meta/recipes-core/base-passwd/base-passwd/0006-Disable-shell-for-default-users.patch deleted +0 -54
54 lines not on this page · raw message
meta/recipes-core/base-passwd/base-passwd/0006-Make-it-possible-to-build-without-debconf-support.patch new file +129 -0
129 lines not on this page · raw message
meta/recipes-core/base-passwd/base-passwd/0007-Disable-generation-of-the-documentation.patch deleted +0 -32
@@ -1,32 +0,0 @@ -From 7ccf8227cb10d78f1958a7a7feed75a390a6b133 Mon Sep 17 00:00:00 2001 -From: Saul Wold <[email protected]> -Date: Fri, 29 Apr 2022 13:32:28 +0000 -Subject: [PATCH] Disable generation of the documentation - -It uses tools currently not supported by OE-Core. It uses sgmltools -and po4a. - -Upstream-Status: Inappropriate [OE-Core specific] -Signed-off-by: Saul Wold <[email protected]> ---- - Makefile.in | 3 --- - 1 file changed, 3 deletions(-) - -diff --git a/Makefile.in b/Makefile.in -index 9ba097c..d3ea47c 100644 ---- a/Makefile.in -+++ b/Makefile.in -@@ -25,13 +25,10 @@ gen_configure = config.cache config.status config.log \ - confdefhs.h config.h Makefile - - all: update-passwd -- $(MAKE) -C doc all -- $(MAKE) -C man all - - install: all - mkdir -p $(DESTDIR)$(sbindir) - $(INSTALL) update-passwd $(DESTDIR)$(sbindir)/ -- $(MAKE) -C man install - - update-passwd.o: version.h -
meta/recipes-core/base-passwd/base-passwd/0007-Make-it-possible-to-disable-the-generation-of-the-do.patch new file +46 -0
46 lines not on this page · raw message
meta/recipes-core/base-passwd/base-passwd_3.5.52.bb renamed from meta/recipes-core/base-passwd/base-passwd_3.5.29.bb +11 -7
@@ -5,27 +5,30 @@ SECTION = "base" LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a" -RECIPE_NO_UPDATE_REASON = "Version 3.5.38 requires cdebconf for update-passwd utility" - -SRC_URI = "https://launchpad.net/debian/+archive/primary/+files/${BPN}_${PV}.tar.gz \ +SRC_URI = "https://launchpad.net/debian/+archive/primary/+files/${BPN}_${PV}.tar.xz \ file://0001-Add-a-shutdown-group.patch \ file://0002-Use-bin-sh-instead-of-bin-bash-for-the-root-user.patch \ file://0003-Remove-for-root-since-we-do-not-have-an-etc-shadow.patch \ file://0004-Add-an-input-group-for-the-dev-input-devices.patch \ file://0005-Add-kvm-group.patch \ - file://0006-Disable-shell-for-default-users.patch \ - file://0007-Disable-generation-of-the-documentation.patch \ + file://0006-Make-it-possible-to-build-without-debconf-support.patch \ + file://0007-Make-it-possible-to-disable-the-generation-of-the-do.patch \ " -SRC_URI[md5sum] = "6beccac48083fe8ae5048acd062e5421" -SRC_URI[sha256sum] = "f0b66388b2c8e49c15692439d2bee63bcdd4bbbf7a782c7f64accc55986b6a36" +SRC_URI[sha256sum] = "5dfec6556b5a16ecf14dd3f7c95b591d929270289268123f31a3d6317f95ccea" # the package is taken from launchpad; that source is static and goes stale # so we check the latest upstream from a directory that does get updated UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/b/base-passwd/" +S = "${WORKDIR}/work" + inherit autotools +EXTRA_OECONF += "--disable-debconf --disable-docs" + +NOLOGIN ?= "${base_sbindir}/nologin" + do_install () { install -d -m 755 ${D}${sbindir} install -o root -g root -p -m 755 ${B}/update-passwd ${D}${sbindir}/
@@ -37,6 +40,7 @@ do_install () { install -d -m 755 ${D}${datadir}/base-passwd install -o root -g root -p -m 644 ${S}/passwd.master ${D}${datadir}/base-passwd/ sed -i 's#:/root:#:${ROOT_HOME}:#' ${D}${datadir}/base-passwd/passwd.master + sed -i 's#/usr/sbin/nologin#${NOLOGIN}#' ${D}${datadir}/base-passwd/passwd.master install -o root -g root -p -m 644 ${S}/group.master ${D}${datadir}/base-passwd/ install -d -m 755 ${D}${docdir}/${BPN}
Signature · 1 line
2.34.1
PATCH 6/9 base-passwd: Update the status for two patches
In reply to Steve SakomanFrom: Peter Kjellerstedt <[email protected]>
The two patches to disable use of debconf and generation of documentation have been merged upstream.
--- ...0006-Make-it-possible-to-build-without-debconf-support.patch | 2 +- ...7-Make-it-possible-to-disable-the-generation-of-the-do.patch | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
meta/recipes-core/base-passwd/base-passwd/0006-Make-it-possible-to-build-without-debconf-support.patch +1 -1
@@ -5,7 +5,7 @@ Subject: [PATCH] Make it possible to build without debconf support Not all systems have the debconfclient library available. -Upstream-Status: Submitted [https://salsa.debian.org/debian/base-passwd/-/merge_requests/11] +Upstream-Status: Backport [https://salsa.debian.org/debian/base-passwd/-/commit/c72aa5dd25a952da25e307761f4526db2c8c39ec] Signed-off-by: Peter Kjellerstedt <[email protected]> --- Makefile.am | 1 -
meta/recipes-core/base-passwd/base-passwd/0007-Make-it-possible-to-disable-the-generation-of-the-do.patch +1 -1
@@ -6,7 +6,7 @@ Subject: [PATCH] Make it possible to disable the generation of the Not all systems have docbook and po4a available. -Upstream-Status: Submitted [https://salsa.debian.org/debian/base-passwd/-/merge_requests/11] +Upstream-Status: Backport [https://salsa.debian.org/debian/base-passwd/-/commit/2a6d16e595c93084e279d0dcbef37d960b44fd1a] Signed-off-by: Peter Kjellerstedt <[email protected]> --- Makefile.am | 2 ++
Signature · 1 line
2.34.1
PATCH 7/9 base-passwd: add the wheel group
In reply to Steve SakomanFrom: Louis Rannou <[email protected]>
The wheel group is not declared while it can be used to access the systemd journal and to configure printers in CUPS. It can also be used for su and sudo permissions.
So far it was created later in the rootfs postcommand systemd_create_users.
--- .../base-passwd/0008-Add-wheel-group.patch | 20 +++++++++++++++++++ .../base-passwd/base-passwd_3.5.52.bb | 1 + 2 files changed, 21 insertions(+) create mode 100644 meta/recipes-core/base-passwd/base-passwd/0008-Add-wheel-group.patch
meta/recipes-core/base-passwd/base-passwd/0008-Add-wheel-group.patch new file +20 -0
@@ -0,0 +1,20 @@ + +We need to have a wheel group which has some system privileges to consult the +systemd journal or manage printers with cups. + +Upstream status says the group does not exist by default. + +Upstream-Status: Inappropriate [enable feature] + +Signed-off-by: Louis Rannou <[email protected]> +Index: base-passwd-3.5.26/group.master +=================================================================== +--- base-passwd-3.5.29.orig/group.master ++++ base-passwd-3.5.29/group.master +@@ -38,5 +38,6 @@ + staff:*:50: + games:*:60: + shutdown:*:70: ++wheel:*:80: + users:*:100: + nogroup:*:65534:
meta/recipes-core/base-passwd/base-passwd_3.5.52.bb +1 -0
@@ -13,6 +13,7 @@ SRC_URI = "https://launchpad.net/debian/+archive/primary/+files/${BPN}_${PV}.tar file://0005-Add-kvm-group.patch \ file://0006-Make-it-possible-to-build-without-debconf-support.patch \ file://0007-Make-it-possible-to-disable-the-generation-of-the-do.patch \ + file://0008-Add-wheel-group.patch \ " SRC_URI[sha256sum] = "5dfec6556b5a16ecf14dd3f7c95b591d929270289268123f31a3d6317f95ccea"
Signature · 1 line
2.34.1
PATCH 8/9 base-passwd: fix patchreview warning
In reply to Steve SakomanFrom: Alexandre Belloni <[email protected]>
Fix:
Malformed Upstream-Status 'Upstream status' (meta/recipes-core/base-passwd/base-passwd/0007-Add-wheel-group.patch) Unknown Upstream-Status value 'says' (meta/recipes-core/base-passwd/base-passwd/0007-Add-wheel-group.patch)
--- .../base-passwd/base-passwd/0008-Add-wheel-group.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-core/base-passwd/base-passwd/0008-Add-wheel-group.patch +1 -1
@@ -2,7 +2,7 @@ We need to have a wheel group which has some system privileges to consult the systemd journal or manage printers with cups. -Upstream status says the group does not exist by default. +Upstream says the group does not exist by default. Upstream-Status: Inappropriate [enable feature]
Signature · 1 line
2.34.1
PATCH 9/9 base-passwd: Add the sgx group
In reply to Steve SakomanFrom: Alex Kiernan <[email protected]>
To avoid errors from eudev/udev we need an sgx group, but if we add it via groupadd that causes shadow login to be brought into an image, which causes images which have CONFIG_MULTIUSER unset to fail with `setgid:
Function not implemented` as shadow's login doesn't implement the heuristics which busybox has to handle this kernel configuration.
--- .../0001-base-passwd-Add-the-sgx-group.patch | 30 +++++++++++++++++++ .../base-passwd/base-passwd_3.5.52.bb | 1 + 2 files changed, 31 insertions(+) create mode 100644 meta/recipes-core/base-passwd/base-passwd/0001-base-passwd-Add-the-sgx-group.patch
meta/recipes-core/base-passwd/base-passwd/0001-base-passwd-Add-the-sgx-group.patch new file +30 -0
@@ -0,0 +1,30 @@ +From 9e57771d138ac423d5139b984b8c869122ce4976 Mon Sep 17 00:00:00 2001 +From: Alex Kiernan <[email protected]> +Date: Fri, 28 Jul 2023 10:28:57 +0100 +Subject: [PATCH] base-passwd: Add the sgx group + +To avoid errors from eudev/udev we need an sgx group, but if we add it +via groupadd that causes shadow login to be brought into an image, which +causes images which have CONFIG_MULTIUSER unset to fail with `setgid: +Function not implemented` as shadow's login doesn't implement the +heuristics which busybox has to handle this kernel configuration. + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Alex Kiernan <[email protected]> +--- + group.master | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/group.master b/group.master +index d34d2b832d43..e54fd1d2c6dc 100644 +--- a/group.master ++++ b/group.master +@@ -34,6 +34,7 @@ video:*:44: + sasl:*:45: + plugdev:*:46: + kvm:*:47: ++sgx:*:48: + staff:*:50: + games:*:60: + shutdown:*:70:
meta/recipes-core/base-passwd/base-passwd_3.5.52.bb +1 -0
@@ -14,6 +14,7 @@ SRC_URI = "https://launchpad.net/debian/+archive/primary/+files/${BPN}_${PV}.tar file://0006-Make-it-possible-to-build-without-debconf-support.patch \ file://0007-Make-it-possible-to-disable-the-generation-of-the-do.patch \ file://0008-Add-wheel-group.patch \ + file://0001-base-passwd-Add-the-sgx-group.patch \ " SRC_URI[sha256sum] = "5dfec6556b5a16ecf14dd3f7c95b591d929270289268123f31a3d6317f95ccea"
Signature · 1 line
2.34.1