Skip to content

Conversation

@HorlogeSkynet
Copy link
Contributor

@HorlogeSkynet HorlogeSkynet commented May 1, 2024


(partially) closes #636 (re-submission of #637).

096972f and fc8f593 introduces task personalities retrieval to fix
incorrect /proc files info in some cases.
Linux governs access to personalities based on system ptrace policy,
which may be restricted by an LSM (e.g. Yama).

This patch implements a simple check for init's personality access to
make sure ptrace usage is allowed, and prevent access from containers to
proc files with "Permission denied" error if not.

> closes #636 (follow-up to #553 and #609).

Signed-off-by: Samuel FORESTIER <[email protected]>
@stgraber stgraber requested a review from mihalicyn May 1, 2024 22:16
@stgraber
Copy link
Member

stgraber commented May 1, 2024

@mihalicyn can you review this one?

@mihalicyn
Copy link
Member

Hi @HorlogeSkynet

please, don't close PR each time when you need to update it. (hint: You can use git rebase / git push -f)

Previous PR #637

Copy link
Member

@mihalicyn mihalicyn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stgraber stgraber merged commit 9b873a1 into lxc:main May 2, 2024
@HorlogeSkynet HorlogeSkynet deleted the check_personality_access_policy branch May 2, 2024 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Errors related to personality retrieval with Yama

3 participants