You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A sandboxed process is currently not restricted to send signals (e.g. SIGKILL) to processes outside the sandbox. A simple way to control that would be to scope signals the same way ptrace is restricted (but this time it would be opt-in).
I have little idea about what it entails as I have experimented with
signals prior but I am still reading up on what the task is all about. Do
you have any route or path I should go searching for?
I have little idea about what it entails as I have experimented with signals prior but I am still reading up on what the task is all about. Do you have any route or path I should go searching for?
You first need to familiarize yourself with the Linux kernel development as explained in the Outreachy documentation. Then, you can start tweaking the code and test it with the test tools. If you have questions about that, please send emails to the Outreachy mailing list (CCing me and @pcmoore).
Before patching the kernel, you can start by thinking about attack scenarios using signals, describing them, and write such tests in a new file here.
About the kernel changes, we need to add a new scoped field to the landlock_ruleset_attr struct. This field will optionally contain a LANDLOCK_RULESET_SCOPED_SIGNAL flag to specify that this ruleset will deny any signal from within the sandbox to its parents (i.e. any parent sandbox or not-sandboxed processes).
This kind of restriction should be pretty similar to the ptrace ones, but we need to keep in mind that not all layers (i.e. nested sandboxes) of a Landlock domain may have this restriction. It could be seen as a roadblock for signals.
There is an LSM hook dedicated to control signals, and the Landlock scope logic is defined in ptrace.c (being renamed to task.c).
This GitHub issue is dedicated to track progress on signal control. As a reminder, no Linux kernel code change nor review should happen on GitHub because kernel reviewers are only following the dedicated mailing lists.
Activity
[-]Signal control[/-][+]Signals control[/+]maryagiamah commentedon Mar 6, 2024
Hello, can I work on this ?
l0kod commentedon Mar 6, 2024
Hi @maryagiamah! Yes, you can start working on signals control.
l0kod commentedon Mar 7, 2024
What is your plan to work on this?
maryagiamah commentedon Mar 7, 2024
l0kod commentedon Mar 7, 2024
You first need to familiarize yourself with the Linux kernel development as explained in the Outreachy documentation. Then, you can start tweaking the code and test it with the test tools. If you have questions about that, please send emails to the Outreachy mailing list (CCing me and @pcmoore).
Before patching the kernel, you can start by thinking about attack scenarios using signals, describing them, and write such tests in a new file here.
About the kernel changes, we need to add a new
scopedfield to thelandlock_ruleset_attrstruct. This field will optionally contain aLANDLOCK_RULESET_SCOPED_SIGNALflag to specify that this ruleset will deny any signal from within the sandbox to its parents (i.e. any parent sandbox or not-sandboxed processes).This kind of restriction should be pretty similar to the ptrace ones, but we need to keep in mind that not all layers (i.e. nested sandboxes) of a Landlock domain may have this restriction. It could be seen as a roadblock for signals.
There is an LSM hook dedicated to control signals, and the Landlock scope logic is defined in ptrace.c (being renamed to task.c).
This GitHub issue is dedicated to track progress on signal control. As a reminder, no Linux kernel code change nor review should happen on GitHub because kernel reviewers are only following the dedicated mailing lists.
l0kod commentedon Mar 27, 2024
Any news @maryagiamah?
20 remaining items
perf trace: Fix runtime error of index out of bounds
nfsd: clear acl_access/acl_default after releasing them
perf trace: Fix runtime error of index out of bounds
nfsd: clear acl_access/acl_default after releasing them
nfsd: clear acl_access/acl_default after releasing them
bpf, test_run: Fix use-after-free issue in eth_skb_pkt_type()
landlock: Add signal scoping
landlock: Add signal scoping
ice: fix NULL pointer dereference in ice_reset_all_vfs()
ice: fix NULL pointer dereference in ice_reset_all_vfs()
libbpf: Fix UAF in strset__add_str()
libbpf: Fix UAF in strset__add_str()