1 |
commit: 21ac5d4937112c4cca29d52c36c91b240c2abb5f |
2 |
Author: Kenton Groombridge <me <AT> concord <DOT> sh> |
3 |
AuthorDate: Tue Jan 26 23:08:54 2021 +0000 |
4 |
Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Feb 1 01:21:42 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/hardened-refpolicy.git/commit/?id=21ac5d49 |
7 |
|
8 |
sudo: add tunable for HTTP connections |
9 |
|
10 |
Signed-off-by: Kenton Groombridge <me <AT> concord.sh> |
11 |
Signed-off-by: Jason Zaman <perfinion <AT> gentoo.org> |
12 |
|
13 |
policy/modules/admin/sudo.te | 15 +++++++++++++++ |
14 |
1 file changed, 15 insertions(+) |
15 |
|
16 |
diff --git a/policy/modules/admin/sudo.te b/policy/modules/admin/sudo.te |
17 |
index 2cebeef7..2ac111d6 100644 |
18 |
--- a/policy/modules/admin/sudo.te |
19 |
+++ b/policy/modules/admin/sudo.te |
20 |
@@ -1,5 +1,16 @@ |
21 |
policy_module(sudo, 1.15.0) |
22 |
|
23 |
+## <desc> |
24 |
+## <p> |
25 |
+## Determine whether all sudo domains |
26 |
+## can connect to TCP HTTP ports. This |
27 |
+## is needed if an additional authentication |
28 |
+## mechanism via an HTTP server is |
29 |
+## required for users to use sudo. |
30 |
+## </p> |
31 |
+## </desc> |
32 |
+gen_tunable(sudo_all_tcp_connect_http_port, false) |
33 |
+ |
34 |
######################################## |
35 |
# |
36 |
# Declarations |
37 |
@@ -7,3 +18,7 @@ attribute sudodomain; |
38 |
|
39 |
type sudo_exec_t; |
40 |
application_executable_file(sudo_exec_t) |
41 |
+ |
42 |
+tunable_policy(`sudo_all_tcp_connect_http_port',` |
43 |
+ corenet_tcp_connect_http_port(sudodomain) |
44 |
+') |