diff options
Diffstat (limited to 'meta-rcar-gen3/recipes-core/systemd')
-rw-r--r-- | meta-rcar-gen3/recipes-core/systemd/systemd/add-non-owned-item-for-safe-transitioning.patch | 14 | ||||
-rw-r--r-- | meta-rcar-gen3/recipes-core/systemd/systemd_%.bbappend | 5 |
2 files changed, 19 insertions, 0 deletions
diff --git a/meta-rcar-gen3/recipes-core/systemd/systemd/add-non-owned-item-for-safe-transitioning.patch b/meta-rcar-gen3/recipes-core/systemd/systemd/add-non-owned-item-for-safe-transitioning.patch new file mode 100644 index 0000000..631db30 --- /dev/null +++ b/meta-rcar-gen3/recipes-core/systemd/systemd/add-non-owned-item-for-safe-transitioning.patch @@ -0,0 +1,14 @@ +diff --git a/src/basic/fs-util.c b/src/basic/fs-util.c +index b2ac648..553a77a 100644 +--- a/src/basic/fs-util.c ++++ b/src/basic/fs-util.c +@@ -668,6 +668,9 @@ static bool unsafe_transition(const struct stat *a, const struct stat *b) { + if (a->st_uid == 0) /* Transitioning from privileged to unprivileged is always fine */ + return false; + ++ if (b->st_uid == 65534) /* Transitioning to a non-owned is OK too */ ++ return false; ++ + return a->st_uid != b->st_uid; /* Otherwise we need to stay within the same UID */ + } + diff --git a/meta-rcar-gen3/recipes-core/systemd/systemd_%.bbappend b/meta-rcar-gen3/recipes-core/systemd/systemd_%.bbappend index 9f5978c..b77e9bd 100644 --- a/meta-rcar-gen3/recipes-core/systemd/systemd_%.bbappend +++ b/meta-rcar-gen3/recipes-core/systemd/systemd_%.bbappend @@ -1 +1,6 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" + +SRC_URI_append_rcar-gen3 = " file://add-non-owned-item-for-safe-transitioning.patch" + PACKAGECONFIG_remove_rcar-gen3 = "timesyncd" + |