-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
oci_conmon: not make accessible dirs if not needed #4859
oci_conmon: not make accessible dirs if not needed #4859
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: giuseppe The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Very cool if this works. |
a2f9a56
to
28a7c73
Compare
28a7c73
to
b38a7cd
Compare
do not change the permissions mask for the rundir and the tmpdir when running a container with a user namespace and the current user is mapped inside the user namespace. The change was introduced with 849548f, that dropped the intermediate mount namespace in favor of allowing root into the user namespace to access these directories. Closes: containers#4846 Signed-off-by: Giuseppe Scrivano <[email protected]>
b38a7cd
to
6818504
Compare
so now I remember where it was failing. If the user is not mapped inside of the user namespace, it won't have access to any temporary file we create (such as hostname, .containerenv, passwd) and the OCI runtime will fail. The correct check is to verify if the current user is mapped inside the user namespace. |
Huh. Neat. LGTM once this goes green. |
/lgtm |
/hold cancel |
do not change the permissions mask for the rundir and the tmpdir when running a container with a user namespace and the current user is mapped inside the user namespace.
The change was introduced with 849548f, that dropped the intermediate mount namespace in favor of allowing root into the user namespace to access these directories.
Closes: #4846
Signed-off-by: Giuseppe Scrivano [email protected]