linux/tools/testing/selftests/landlock
Günther Noack dc75f89046
selftests/landlock: Simplify ruleset creation and enforcement in fs_test
* Add enforce_fs() for defining and enforcing a ruleset in one step
* In some places, dropped "ASSERT_LE(0, fd)" checks after
  create_ruleset() call -- create_ruleset() already checks that.
* In some places, rename "file_fd" to "fd" if it is not needed to
  disambiguate any more.

Signed-off-by: Günther Noack <gnoack3000@gmail.com>
Link: https://lore.kernel.org/r/20260327164838.38231-12-gnoack3000@gmail.com
[mic: Tweak subjet]
Signed-off-by: Mickaël Salaün <mic@digikod.net>
2026-04-07 18:51:10 +02:00
..
.gitignore selftests/landlock: Add filesystem access benchmark 2026-02-10 16:46:42 +01:00
audit_test.c selftests/landlock: Skip stale records in audit_match_record() 2026-04-07 18:51:02 +02:00
audit.h selftests/landlock: Skip stale records in audit_match_record() 2026-04-07 18:51:02 +02:00
base_test.c landlock: Control pathname UNIX domain socket resolution by path 2026-04-07 18:51:06 +02:00
common.h selftests/landlock: Fix TCP bind(AF_UNSPEC) test case 2025-12-26 20:38:57 +01:00
config selftests/landlock: Add tests for audit flags and domain IDs 2025-03-26 13:59:45 +01:00
config.um selftests/landlock: Add hostfs tests 2023-06-12 21:26:23 +02:00
fs_bench.c selftests/landlock: Add filesystem access benchmark 2026-02-10 16:46:42 +01:00
fs_test.c selftests/landlock: Simplify ruleset creation and enforcement in fs_test 2026-04-07 18:51:10 +02:00
Makefile selftests/landlock: Add filesystem access benchmark 2026-02-10 16:46:42 +01:00
net_test.c selftests/landlock: Fix format warning for __u64 in net_test 2026-04-07 18:51:03 +02:00
ptrace_test.c selftests/landlock: Drain stale audit records on init 2026-04-07 18:51:01 +02:00
sandbox-and-launch.c selftests/landlock: Add layout1.umount_sandboxer tests 2025-01-17 19:05:38 +01:00
scoped_abstract_unix_test.c selftests/landlock: Drain stale audit records on init 2026-04-07 18:51:01 +02:00
scoped_base_variants.h selftests/landlock: Use scoped_base_variants.h for ptrace_test 2025-12-29 16:19:39 +01:00
scoped_common.h selftests/landlock: Test abstract UNIX socket scoping 2024-09-16 23:50:48 +02:00
scoped_multiple_domain_variants.h selftests/landlock: Test abstract UNIX socket scoping 2024-09-16 23:50:48 +02:00
scoped_signal_test.c selftests/landlock: Add a new test for setuid() 2025-03-26 13:59:32 +01:00
scoped_test.c landlock: Add signal scoping 2024-09-16 23:50:52 +02:00
true.c
tsync_test.c landlock: Allow TSYNC with LOG_SUBDOMAINS_OFF and fd=-1 2026-04-07 18:51:00 +02:00
wait-pipe-sandbox.c selftests/landlock: Test audit with restrict flags 2025-03-26 13:59:46 +01:00
wait-pipe.c selftests/landlock: Add layout1.umount_sandboxer tests 2025-01-17 19:05:38 +01:00
wrappers.h selftests/landlock: Add wrappers.h 2025-01-17 19:05:38 +01:00