diff options
Diffstat (limited to 'recipes-security/refpolicy/refpolicy-git/poky-policy-allow-nfsd-to-exec-shell-commands.patch')
-rw-r--r-- | recipes-security/refpolicy/refpolicy-git/poky-policy-allow-nfsd-to-exec-shell-commands.patch | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/recipes-security/refpolicy/refpolicy-git/poky-policy-allow-nfsd-to-exec-shell-commands.patch b/recipes-security/refpolicy/refpolicy-git/poky-policy-allow-nfsd-to-exec-shell-commands.patch new file mode 100644 index 0000000..e77a730 --- /dev/null +++ b/recipes-security/refpolicy/refpolicy-git/poky-policy-allow-nfsd-to-exec-shell-commands.patch | |||
@@ -0,0 +1,58 @@ | |||
1 | From 22cd030a8118faae37c0835eb7875e482efe5dc1 Mon Sep 17 00:00:00 2001 | ||
2 | From: Xin Ouyang <Xin.Ouyang@windriver.com> | ||
3 | Date: Thu, 22 Aug 2013 13:37:23 +0800 | ||
4 | Subject: [PATCH] allow nfsd to exec shell commands. | ||
5 | |||
6 | Upstream-Status: Inappropriate [only for Poky] | ||
7 | |||
8 | Signed-off-by: Xin Ouyang <Xin.Ouyang@windriver.com> | ||
9 | --- | ||
10 | policy/modules/contrib/rpc.te | 2 +- | ||
11 | policy/modules/kernel/kernel.if | 18 ++++++++++++++++++ | ||
12 | 2 files changed, 19 insertions(+), 1 deletions(-) | ||
13 | |||
14 | diff --git a/policy/modules/contrib/rpc.te b/policy/modules/contrib/rpc.te | ||
15 | index 9566932..5605205 100644 | ||
16 | --- a/policy/modules/contrib/rpc.te | ||
17 | +++ b/policy/modules/contrib/rpc.te | ||
18 | @@ -203,7 +203,7 @@ kernel_read_network_state(nfsd_t) | ||
19 | kernel_dontaudit_getattr_core_if(nfsd_t) | ||
20 | kernel_setsched(nfsd_t) | ||
21 | kernel_request_load_module(nfsd_t) | ||
22 | -# kernel_mounton_proc(nfsd_t) | ||
23 | +kernel_mounton_proc(nfsd_t) | ||
24 | |||
25 | corenet_sendrecv_nfs_server_packets(nfsd_t) | ||
26 | corenet_tcp_bind_nfs_port(nfsd_t) | ||
27 | diff --git a/policy/modules/kernel/kernel.if b/policy/modules/kernel/kernel.if | ||
28 | index 649e458..8a669c5 100644 | ||
29 | --- a/policy/modules/kernel/kernel.if | ||
30 | +++ b/policy/modules/kernel/kernel.if | ||
31 | @@ -804,6 +804,24 @@ interface(`kernel_unmount_proc',` | ||
32 | |||
33 | ######################################## | ||
34 | ## <summary> | ||
35 | +## Mounton a proc filesystem. | ||
36 | +## </summary> | ||
37 | +## <param name="domain"> | ||
38 | +## <summary> | ||
39 | +## Domain allowed access. | ||
40 | +## </summary> | ||
41 | +## </param> | ||
42 | +# | ||
43 | +interface(`kernel_mounton_proc',` | ||
44 | + gen_require(` | ||
45 | + type proc_t; | ||
46 | + ') | ||
47 | + | ||
48 | + allow $1 proc_t:dir mounton; | ||
49 | +') | ||
50 | + | ||
51 | +######################################## | ||
52 | +## <summary> | ||
53 | ## Get the attributes of the proc filesystem. | ||
54 | ## </summary> | ||
55 | ## <param name="domain"> | ||
56 | -- | ||
57 | 1.7.5.4 | ||
58 | |||