Skip to contentSkip to conversation

domain: unconfined access to bpf

PATCH In review Dominick Grift 2 participants 2 messages Sep 3, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 domain: unconfined access to bpf

---
 policy/modules/kernel/domain.te | 3 +++
 1 file changed, 3 insertions(+)
policy/modules/kernel/domain.te +3 -0
index 1a55e3d2..a4c78af9 100644
@@ -152,6 +152,9 @@ optional_policy(`
 # is handled in the interface as typeattribute cannot
 # be used on an attribute.
 
+# unconfined access to bpf
+allow unconfined_domain_type domain:bpf { map_create map_read map_write prog_load prog_run };
+
 # Use/sendto/connectto sockets created by any domain.
 allow unconfined_domain_type domain:{ socket_class_set socket key_socket } { create_stream_socket_perms send_msg lock relabelto name_bind recv_msg map sendto recvfrom relabelfrom };
 allow unconfined_domain_type domain:rawip_socket node_bind;
Signature · 1 line
2.23.0
#1 lore raw
Quoted 10 lines · Dominick Grift
---
  policy/modules/kernel/domain.te | 3 +++
  1 file changed, 3 insertions(+)
policy/modules/kernel/domain.te +0 -0
index 1a55e3d2..a4c78af9 100644

policy/modules/kernel/domain.te optional_policy(` · line 160

Quoted 9 lines
policy/modules/kernel/domain.te +3 -0
@@ -152,6 +152,9 @@ optional_policy(`
  # is handled in the interface as typeattribute cannot
  # be used on an attribute.
 
+# unconfined access to bpf
+allow unconfined_domain_type domain:bpf { map_create map_read map_write prog_load prog_run };
+
  # Use/sendto/connectto sockets created by any domain.
  allow unconfined_domain_type domain:{ socket_class_set socket key_socket } { create_stream_socket_perms send_msg lock relabelto name_bind recv_msg map sendto recvfrom relabelfrom };
  allow unconfined_domain_type domain:rawip_socket node_bind;

Merged.

Signature · 1 line
Chris PeBenito