blob: 95896b2de6cfc213fb3e4a5ddf8ddae61e11f47a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
From 777e396d61c3af7b847fcc9ebc490f1e5f3969b9 Mon Sep 17 00:00:00 2001
From: Wenzong Fan <wenzong.fan@windriver.com>
Date: Fri, 15 Jan 2016 03:47:05 -0500
Subject: [PATCH] policy/modules/system/init: make init_t MLS trusted for
lowering/raising the leve of files
Fix security_validate_transition issues:
op=security_validate_transition seresult=denied \
oldcontext=system_u:object_r:device_t:s15:c0.c1023 \
newcontext=system_u:object_r:device_t:s0 \
taskcontext=system_u:system_r:init_t:s0-s15:c0.c1023 \
tclass=dir
op=security_validate_transition seresult=denied \
oldcontext=system_u:object_r:var_run_t:s0 \
newcontext=system_u:object_r:var_log_t:s0-s15:c0.c1023 \
taskcontext=system_u:system_r:init_t:s0-s15:c0.c1023 \
tclass=dir
Upstream-Status: Inappropriate [embedded specific]
Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
policy/modules/system/init.te | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/policy/modules/system/init.te b/policy/modules/system/init.te
index e724c295e..6ffdb547f 100644
--- a/policy/modules/system/init.te
+++ b/policy/modules/system/init.te
@@ -238,6 +238,10 @@ mls_process_write_all_levels(init_t)
mls_fd_use_all_levels(init_t)
mls_process_set_level(init_t)
+# MLS trusted for lowering/raising the level of files
+mls_file_downgrade(init_t)
+mls_file_upgrade(init_t)
+
# the following one is needed for libselinux:is_selinux_enabled()
# otherwise the call fails and sysvinit tries to load the policy
# again when using the initramfs
--
2.25.1
|