summaryrefslogtreecommitdiffstats
path: root/recipes-security/refpolicy/refpolicy/0035-policy-modules-system-getty-allow-getty_t-to-search-.patch
blob: 0dfe0eebd1536d0af414097e1cdc6f59d563e5df (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
From 175b493e7fe69de274388a7f251e74ec9cd56c41 Mon Sep 17 00:00:00 2001
From: Yi Zhao <yi.zhao@windriver.com>
Date: Tue, 23 Jun 2020 08:39:44 +0800
Subject: [PATCH] policy/modules/system/getty: allow getty_t to search tmpfs

Fixes:
avc:  denied  { search } for  pid=211 comm="agetty" name="/" dev="tmpfs"
ino=1 scontext=system_u:system_r:getty_t
tcontext=system_u:object_r:tmpfs_t tclass=dir permissive=0

Upstream-Status: Inappropriate [embedded specific]

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 policy/modules/system/getty.te | 1 +
 1 file changed, 1 insertion(+)

diff --git a/policy/modules/system/getty.te b/policy/modules/system/getty.te
index e6e76a93b..c704ddb82 100644
--- a/policy/modules/system/getty.te
+++ b/policy/modules/system/getty.te
@@ -68,6 +68,7 @@ files_read_etc_runtime_files(getty_t)
 files_read_etc_files(getty_t)
 files_search_spool(getty_t)
 files_dontaudit_search_var_lib(getty_t)
+fs_search_tmpfs(getty_t)
 
 fs_search_auto_mountpoints(getty_t)
 # for error condition handling
-- 
2.17.1