-
Notifications
You must be signed in to change notification settings - Fork 107
DRAFT: Add landlock support #723
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
base: main
Are you sure you want to change the base?
Conversation
Note that the test failed due to the missing permissions. |
2a81e96
to
c6cbf6e
Compare
91103b1
to
2b9da1e
Compare
Updated the branch to align with version 0.6.1 and added pseudo code that I had in mind to finish this feature. |
For the scope of this PR, I think it's OK for this to only be activated for Linux >=5.19, which should be the limitation for the Landlock V2. I'm also suffering from low free time to put on this, so I 100% comprehend this being stale. |
25c4ff9
to
61599df
Compare
Ok this is now a step further and works with -d option as well. Todo:
|
This feature should now work and is ready for some testing by those interested. At the moment the flowing cases are supported:
TODO:
Future improvements: Add landlock for compression?
|
The CI currently fails due to #852 If we fix the overwrite behavior to avoid the recreation of the target directory, it should work as expected |
This PR adds landlock filesystem isolation to ouch as discussed in #722
At the moment this is just a quickly hacked implementation to demonstrate the use of landlock in ouch.
It restricts the entire filesystem to be read only and only permits write actions in the current working directory of the process.
In order to test the isolation feature, use the
-d
option to write the decompressed files to a path outside of$PWD
A final implementation would address the
-d
option as well to allow writing to specified output directories, but I left it untouched for now to allow an easy demonstration/test of the landlock feature.Todo: