Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

container_ro_file_t ? #75

Closed
AkihiroSuda opened this issue Sep 16, 2019 · 5 comments
Closed

container_ro_file_t ? #75

AkihiroSuda opened this issue Sep 16, 2019 · 5 comments

Comments

@AkihiroSuda
Copy link
Contributor

# cat /etc/selinux/targeted/contexts/lxc_contexts 
process = "system_u:system_r:container_t:s0"
content = "system_u:object_r:virt_var_lib_t:s0"
file = "system_u:object_r:container_file_t:s0"
ro_file="system_u:object_r:container_ro_file_t:s0"
sandbox_kvm_process = "system_u:system_r:svirt_qemu_net_t:s0"
sandbox_kvm_process = "system_u:system_r:svirt_qemu_net_t:s0"
sandbox_lxc_process = "system_u:system_r:container_t:s0"

RHEL 8.0 lxc_contexts contains reference to system_u:object_r:container_ro_file_t:s0, but the type doesn't seem defined in this repo and yet doesn't seem used by Podman and Docker.

Maybe the type should be removed from lxc_contexts?

@rhatdan
Copy link
Member

rhatdan commented Sep 16, 2019

Yes, the type is actually container_share_t.

@rhatdan
Copy link
Member

rhatdan commented Sep 16, 2019

@wrabcak Could you make the change.

@wrabcak
Copy link
Member

wrabcak commented Sep 16, 2019

@rhatdan, is it big issue to keep it there? Did podman/docker use this reference in past?

Thanks,
Lukas.

@rhatdan
Copy link
Member

rhatdan commented Sep 16, 2019

No I know of nothing that uses this. and I guess it is ok, since it is defined and their is a relationship between container domains and this file type.

@rhatdan
Copy link
Member

rhatdan commented Sep 16, 2019

sesearch -A -s container_t -t container_ro_file_t -c file -p read

allow svirt_sandbox_domain container_ro_file_t:file { execmod execute execute_no_trans getattr ioctl lock map open read };

@AkihiroSuda Looks like we have it in policy. The issue is no tools read
ro_file="system_u:object_r:container_ro_file_t:s0"
that I know of. (I added that many years ago (2012?) when we were working on virt-sandbox, prior to Docker)

@rhatdan rhatdan closed this as completed Sep 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants