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

Kernel+Userland: Add immutable mounts #24915

Closed

Conversation

supercomputer7
Copy link
Member

No description provided.

@supercomputer7 supercomputer7 marked this pull request as ready for review August 9, 2024 15:50
@github-actions github-actions bot added the 👀 pr-needs-review PR needs review from a maintainer or community member label Aug 9, 2024
Immutable mounts are mounts that can't be changed in any aspect, if the
VFSRootContext that hold them is used by a process. This includes two
operations on a mount:
1. Trying to remove the mount from the mount table.
2. Trying to change the flags of the mount.

The condition of a VFSRootContext being held by a process or not is
crucial, as the intention is to allow removal of mounts that marked as
immutable if the VFSRootContext is not being used anymore (for example,
if the container that was created with such context stopped).

Marking mounts as immutable on the first VFS root context essentially
ensures they will never be modified because there will be a process
using that context (which is the "main" VFS root context in the system
runtime).

It should be noted that setting a mount as immutable can be done in
creation time of the mount by passing the MS_IMMUTABLE flag, or by doing
a remount with MS_IMMUTABLE flag.
These mounts are the base set of mounts we need for a fully functional
system. The bind mounts are also there for protection from malicious
software or accidental overwrite/deletion of files.

Therefore, marking these mounts as immutable makes sense, because they
should not be changed during runtime anyway.
Copy link

stale bot commented Sep 6, 2024

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions!

@stale stale bot added the stale label Sep 6, 2024
@supercomputer7
Copy link
Member Author

Not stale…

@stale stale bot removed the stale label Sep 6, 2024
Copy link

stale bot commented Sep 28, 2024

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions!

@stale stale bot added the stale label Sep 28, 2024
@supercomputer7
Copy link
Member Author

This is stale and sadly I don't have the time right now to keep it open. I might re-open it sometime in the future, if it seems like an interesting feature to someone in the project :)

@github-actions github-actions bot removed the 👀 pr-needs-review PR needs review from a maintainer or community member label Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant