diff options
author | Topi Miettinen <topimiettinen@users.noreply.github.com> | 2020-02-28 18:43:28 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-28 18:43:28 +0000 |
commit | 5ce928ecdf89a9b8630c682ec2c0fb90c69784ca (patch) | |
tree | c6f3a8bbe6852902da976650fbd22858aa158464 /src/basic/selinux-util.c | |
parent | 8956caf333ff64aebe56d0e01696e92964dd1a31 (diff) | |
download | systemd-5ce928ecdf89a9b8630c682ec2c0fb90c69784ca.tar.gz |
Revert "namespace: fix MAC labels of /dev when PrivateDevices=yes"revert-14900-fix-privatedevices-dev-mac-label
This reverts commit e6e81ec0a56861b905db975fc32c83e2f2faca7d.
Diffstat (limited to 'src/basic/selinux-util.c')
-rw-r--r-- | src/basic/selinux-util.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/basic/selinux-util.c b/src/basic/selinux-util.c index fd78ce200e..90bb93ed0b 100644 --- a/src/basic/selinux-util.c +++ b/src/basic/selinux-util.c @@ -124,7 +124,7 @@ void mac_selinux_reload(void) { #endif } -int mac_selinux_fix_container(const char *path, const char *inside_path, LabelFixFlags flags) { +int mac_selinux_fix(const char *path, LabelFixFlags flags) { #if HAVE_SELINUX char procfs_path[STRLEN("/proc/self/fd/") + DECIMAL_STR_MAX(int)]; @@ -151,7 +151,7 @@ int mac_selinux_fix_container(const char *path, const char *inside_path, LabelFi if (fstat(fd, &st) < 0) return -errno; - if (selabel_lookup_raw(label_hnd, &fcon, inside_path, st.st_mode) < 0) { + if (selabel_lookup_raw(label_hnd, &fcon, path, st.st_mode) < 0) { r = -errno; /* If there's no label to set, then exit without warning */ @@ -185,7 +185,7 @@ int mac_selinux_fix_container(const char *path, const char *inside_path, LabelFi return 0; fail: - log_enforcing_errno(r, "Unable to fix SELinux security context of %s (%s): %m", path, inside_path); + log_enforcing_errno(r, "Unable to fix SELinux security context of %s: %m", path); if (security_getenforce() == 1) return r; #endif |