Skip to content

Commit 72a12c5

Browse files
committed
qm.if: add dbus socket rules
Add SELinux rules to allow a dbus-broker container to create a QM-specific dbus socket at the `/run/dbus/` directory. Signed-off-by: Albert Esteve <[email protected]>
1 parent 64c9bc7 commit 72a12c5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Diff for: qm.if

+7-1
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,14 @@ template(`qm_domain_template',`
3939
type sysctl_irq_t;
4040
type sysctl_t;
4141
type system_dbusd_t;
42+
type systemd_hostnamed_t;
4243
type systemd_logind_t;
4344
type systemd_machined_t;
4445
type unconfined_service_t;
4546
type bpf_t;
4647
type container_devpts_t;
4748
type net_conf_t;
49+
type getty_t;
4850
')
4951

5052
type $1_t;
@@ -397,11 +399,15 @@ template(`qm_domain_template',`
397399

398400
qm_container_template($1, wayland)
399401

400-
allow $1_container_wayland_t $1_file_t:dir { add_name write };
402+
allow $1_container_wayland_t $1_file_t:dir { add_name write watch };
401403
allow $1_container_wayland_t $1_file_t:file { create write };
402404
allow $1_container_wayland_t $1_file_t:sock_file { create write };
405+
allow $1_container_wayland_t $1_t:unix_stream_socket connectto;
403406
dev_read_sysfs($1_container_wayland_t)
404407

408+
allow getty_t $1_file_type:chr_file { read write };
409+
systemd_dbus_chat_hostnamed(systemd_hostnamed_t)
410+
405411
read_files_pattern($1_container_domain, $1_container_ro_file_t,$1_container_ro_file_t)
406412
read_lnk_files_pattern($1_container_domain, $1_container_ro_file_t,$1_container_ro_file_t)
407413
list_dirs_pattern($1_container_domain, $1_container_ro_file_t,$1_container_ro_file_t)

0 commit comments

Comments
 (0)