landlock-lsm / linux

Linux kernel - See Landlock issues
https://git.kernel.org/pub/scm/linux/kernel/git/mic/linux.git/
Other
33 stars 9 forks source link

Improve Kselftest coverage with fault injection #22

Open l0kod opened 5 months ago

l0kod commented 5 months ago

Fault injection enables to trigger kernel errors (e.g. when calling kmalloc()) and then test rare cases.

It would be useful to improve kernel test coverage by extending currents test cases with kernel fault injections (e.g., thanks to /proc/self/task/<tid>/fail-nth). It would be great to be able to deterministically test all Landlock's related code.

Example: iommufd_fail_nth.c.