LTP test catalog

About Linux Test Project

Version: 20220930-129-g4fefdf340

Default timeout: 300 seconds

Test filtered by used flags

.dev_extra_opts

Tests containing .dev_extra_opts flag.

.dev_fs_opts

Tests containing .dev_fs_opts flag.

.dev_min_size

Tests containing .dev_min_size flag.

.forks_child

Tests containing .forks_child flag.

.min_cpus

Tests containing .min_cpus flag.

.min_mem_avail

Tests containing .min_mem_avail flag.

.mnt_data

Tests containing .mnt_data flag.

.mnt_flags

Tests containing .mnt_flags flag.

.needs_cgroup_ver

Tests containing .needs_cgroup_ver flag.

.needs_devfs

Tests containing .needs_devfs flag.

.needs_hugetlbfs

Tests containing .needs_hugetlbfs flag.

.needs_overlay

Tests containing .needs_overlay flag.

.needs_root

Tests containing .needs_root flag.

.needs_tmpdir

Tests containing .needs_tmpdir flag.

.restore_wallclock

Tests containing .restore_wallclock flag.

.skip_in_compat

Tests containing .skip_in_compat flag.

.skip_in_lockdown

Tests containing .skip_in_lockdown flag.

.supported_archs

Tests containing .supported_archs flag.

.tags

glibc-git

Tests containing .tags glibc-git flag.

known-fail

Tests containing .tags known-fail flag.

linux-git

Tests containing .tags linux-git flag.

linux-stable-git

Tests containing .tags linux-stable-git flag.

All tests

Total 1079 tests.

a b c d e f g h i k l m n o p q r s t u v w z

sbrk03 sched_get_priority_max01 sched_get_priority_max02 sched_get_priority_min01 sched_get_priority_min02 sched_getaffinity01 sched_getparam01 sched_getparam03 sched_getscheduler01 sched_getscheduler02 sched_rr_get_interval01 sched_rr_get_interval02 sched_rr_get_interval03 sched_setaffinity01 sched_setparam01 sched_setparam02 sched_setparam03 sched_setparam04 sched_setparam05 sched_setscheduler01 sched_setscheduler02 sched_setscheduler03 sctp_big_chunk select01 select02 select03 select04 sem_comm sem_nstest semctl01 semctl02 semctl03 semctl04 semctl05 semctl07 semctl08 semctl09 semop01 semop02 semop03 semtest_2ns send02 sendfile02 sendfile03 sendfile04 sendfile05 sendfile06 sendfile07 sendfile08 sendfile09 sendmmsg01 sendmmsg02 sendmsg03 sendto02 sendto03 set_mempolicy01 set_mempolicy02 set_mempolicy03 set_mempolicy04 set_mempolicy05 setdomainname01 setdomainname02 setdomainname03 setegid01 setegid02 setfsgid01 setfsgid02 setfsuid01 setfsuid02 setfsuid03 setgid01 setgid02 setgid03 setitimer01 setitimer02 setns01 setns02 setpgid02 setpgid03 setpriority01 setpriority02 setregid01 setregid02 setregid03 setregid04 setresgid02 setresgid03 setresuid01 setresuid02 setresuid03 setreuid02 setreuid03 setreuid05 setrlimit02 setrlimit03 setrlimit04 setrlimit05 setrlimit06 setsockopt01 setsockopt02 setsockopt03 setsockopt04 setsockopt05 setsockopt06 setsockopt07 setsockopt08 setsockopt09 settimeofday01 settimeofday02 setuid01 setuid03 setuid04 setxattr01 setxattr02 setxattr03 shm_comm shmat01 shmat02 shmat03 shmctl01 shmctl02 shmctl03 shmctl04 shmctl05 shmctl06 shmctl07 shmctl08 shmdt01 shmdt02 shmem_2nstest shmget02 shmget03 shmget04 shmget05 shmget06 shmnstest sighold02 signal01 signal02 signal03 signal04 signal05 sigpending02 sigsuspend01 sigtimedwait01 sigwait01 sigwaitinfo01 snd_seq01 snd_timer01 socket01 socket02 socketcall01 socketcall02 socketcall03 socketpair01 socketpair02 splice01 splice02 splice03 splice04 splice05 squashfs01 stack_clash stat01 stat02 stat03 statfs02 statx01 statx02 statx03 statx04 statx05 statx06 statx07 statx08 statx09 stime01 stime02 swapoff01 swapoff02 swapon01 swapon02 swapon03 swapping01 sync01 sync_file_range01 sync_file_range02 syncfs01 syscall01 sysctl01 sysctl03 sysctl04 sysfs01 sysfs02 sysfs03 sysfs04 sysfs05 sysinfo03 syslog11 syslog12

a

abort01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Checks that process which called abort() gets killed by SIGIOT and dumps core.

Algorithm

  • Fork child.

  • Child calls abort.

  • Parent checks return status.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


accept01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that accept() returns the proper errno for various failure cases.

Test timeout defaults to 300 seconds


accept02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test for CVE-2017-8890

In Kernels up to 4.10.15 missing commit 657831ff the multicast group information of a socket gets copied over to a newly created socket when using the accept() syscall. This will cause a double free when closing the original and the cloned socket.

WARNING: There is a high chance that this test will cause an unstable system if it does not succeed!

For more information about this CVE see: https://www.suse.com/security/cve/CVE-2017-8890/

Test timeout defaults to 300 seconds

Key Value

.needs_checkpoints

1

.needs_tmpdir

1

Tag Info

CVE

2017-8890

linux-git

657831ff ("dccp/tcp: do not inherit mc_list from parent")


accept4_01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


access01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1


access02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1


access03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1


access04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_rofs

1

.needs_root

1


acct01

a b c d e f g h i k l m n o p q r s t u v w z

Documentation

Verify that acct() returns proper errno on failure.

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


acct02

a b c d e f g h i k l m n o p q r s t u v w z

Documentation

This tests if the kernel writes correct data to the process accounting file.

First, system-wide process accounting is turned on and the output gets directed to a defined file. After that a dummy program is run in order to generate data and the process accounting gets turned off again.

To verify the written data, the entries of the accounting file get parsed into the corresponding acct structure. Since it cannot be guaranteed that only the command issued by this test gets written into the accounting file, the contents get parsed until the correct entry is found, or EOF is reached.

This is also accidental regression test for: 4d9570158b626 kernel/acct.c: fix the acct→needcheck check in check_free_space()

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_BSD_PROCESS_ACCT

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

4d9570158b626 ("kernel/acct.c: fix the acct→needcheck check in check_free_space()")


add_key01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


add_key02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

CVE

2017-15274

linux-git

5649645d725c ("KEYS: fix dereferencing NULL payload with nonzero length")


add_key03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

Tag Info

linux-git

237bbd29f7a0 ("KEYS: prevent creating a different user’s keyrings")


add_key04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

CVE

2017-12193

linux-git

ea6789980fda ("assoc_array: Fix a buggy node-splitting case")


add_key05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_cmds

useradd, userdel, groupdel

.needs_root

1

.save_restore

?/proc/sys/kernel/keys/gc_delay 1

?/proc/sys/kernel/keys/maxkeys 200

?/proc/sys/kernel/keys/maxbytes 20000

Tag Info

linux-git

a08bf91ce28 ("KEYS: allow reaching the keys quotas exactly")

linux-git

2e356101e72 ("KEYS: reaching the keys quotas correctly")


adjtimex01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


adjtimex02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests for adjtimex() error conditions:

  • EPERM with SET_MODE as nobody

  • EFAULT with SET_MODE and invalid timex pointer

  • EINVAL with ADJ_TICK greater than max tick

  • EINVAL with ADJ_TICK smaller than min tick

On kernels older than 2.6.26:

  • EINVAL with AJD_OFFSET smaller than min offset

  • EINVAL with AJD_OFFSET greater than max offset

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.test_variants

3


adjtimex03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

CVE

2018-11508

linux-git

0a0b98734479 ("compat: fix 4-byte infoleak via uninitialized struct field")


af_alg03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

linux-git

e57121d08c38 ("crypto: chacha20poly1305 - validate the digest size")


af_alg04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

linux-git

bb2964810233 ("crypto: vmac - separate tfm and request context")


af_alg06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

linux-git

8f9c46934848 ("crypto: authenc - fix parsing key with misaligned rta_len")


aio02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


aiocp

a b c d e f g h i k l m n o p q r s t u v w z

Description

Copy file by using an async I/O state machine.

  • Start read request

  • When read completes turn it into a write request

  • When write completes decrement counter and free up resources

Test timeout defaults to 300 seconds

Key Value

.max_runtime

1800

.needs_root

1

.needs_tmpdir

1

.options

b: str_aio_blksize Size of writing blocks (default 1K)

s: str_filesize Size of file (default 10M)

n: str_aionum Number of Async IO blocks (default 16)

f: str_oflag Open flag: SYNC | DIRECT (default O_CREAT only)


aiodio_append

a b c d e f g h i k l m n o p q r s t u v w z

Description

Append zeroed data to a file using libaio while other processes are doing buffered reads and check if the buffer reads always see zero.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of threads (default 16)

s: str_writesize Size of the file to write (default 64K)

c: str_appends Number of appends (default 1000)

b: str_numaio Number of async IO blocks (default 16)

.skip_filesystems

tmpfs


aiodio_sparse

a b c d e f g h i k l m n o p q r s t u v w z

Description

Create a sparse file and write zeroes to it using libaio while other processes are doing buffered reads and check if the buffer reads always see zero.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of threads (default 16)

w: str_writesize Size of writing blocks (default 1K)

s: str_filesize Size of file (default 100M)

o: str_numaio Number of AIO control blocks (default 16)

.skip_filesystems

tmpfs


alarm02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that alarm() returns: - zero when there was no previously scheduled alarm - number of seconds remaining until any previously scheduled alarm

Test timeout defaults to 300 seconds


alarm03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that alarms created by alarm() are not inherited by children created via fork.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


alarm05

a b c d e f g h i k l m n o p q r s t u v w z

Description

The return value of the alarm system call should be equal to the
amount previously remaining in the alarm clock.
A SIGALRM signal should be received after the specified amount of
time has elapsed.

Test timeout defaults to 300 seconds


alarm06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that any pending alarm() is canceled when seconds is zero.

Test timeout defaults to 300 seconds


alarm07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that SIGALRM signal scheduled by alarm() in the parent process is not delivered to the child process.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


b


bind01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


bind02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


bind03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


bind04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


bind05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


bind06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

300

.needs_kconfigs

CONFIG_USER_NS=y, CONFIG_NET_NS=y

.save_restore

?/proc/sys/user/max_user_namespaces

.taint_check

TST_TAINT_W

Tag Info

CVE

2018-18559

linux-git

15fe076edea7 ("net/packet: fix a race in packet_bind() and packet_notifier()")


bpf_map01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.19


bpf_prog01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.19


bpf_prog02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.min_kver

3.18

Tag Info

linux-git

3612af783cf5 ("bpf: fix sanitation rewrite in case of non-pointers")


bpf_prog03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.min_kver

3.18

Tag Info

CVE

2017-16995

linux-git

95a762e2c8c9 ("bpf: fix incorrect sign extension in check_alu_op()")


bpf_prog04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.min_kver

3.18

.taint_check

TST_TAINT_W

Tag Info

CVE

2018-18445

linux-git

b799207e1e18 ("bpf: 32-bit RSH verification must truncate input before the ALU op")


bpf_prog05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Compare the effects of 32-bit div/mod by zero with the "expected" behaviour.

The commit "bpf: fix subprog verifier bypass by div/mod by 0 exception", changed div/mod by zero from exiting the current program to setting the destination register to zero (div) or leaving it untouched (mod).

This solved one verfier bug which allowed dodgy pointer values, but it turned out that the source register was being 32-bit truncated when it should not be. Also the destination register for mod was not being truncated when it should be.

So then we have the following two fixes: "bpf: Fix 32 bit src register truncation on div/mod" "bpf: Fix truncation handling for mod32 dst reg wrt zero"

Testing for all of these issues is a problem. Not least because division by zero is undefined, so in theory any result is acceptable so long as the verifier and runtime behaviour match.

However to keep things simple we just check if the source and destination register runtime values match the current upstream behaviour at the time of writing.

If the test fails you may have one or more of the above patches missing. In this case it is possible that you are not vulnerable depending on what other backports and fixes have been applied. If upstream changes the behaviour of division by zero, then the test will need updating.

Note that we use r6 as the src register and r7 as the dst. w6 and w7 are the same registers treated as 32bit.

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, ), TST_CAP, (, TST_CAP_DROP, CAP_BPF, )

.min_kver

3.18

.taint_check

TST_TAINT_W

Tag Info

CVE

CVE-2021-3444

linux-git

f6b1b3bf0d5f ("bpf: fix subprog verifier bypass by div/mod by 0 exception")

linux-git

468f6eafa6c4 ("bpf: fix 32-bit ALU op verification")

linux-git

e88b2c6e5a4d ("bpf: Fix 32 bit src register truncation on div/mod")

linux-git

9b00f1b78809 ("bpf: Fix truncation handling for mod32 dst reg wrt zero")


bpf_prog06

a b c d e f g h i k l m n o p q r s t u v w z

Description

ringbuf_submit takes a pointer to a ringbuf record, but not the size of this record. The verifier only validates offset ptrs[1] passed to functions if the function has a size parameter. So we can perform a wide range of ptr arithmetic on this record ptr.

ringbuf_submit updates some data (i.e. the length) in the ringbuf header which is calculated from the record ptr. So this can be used to corrupt memory.

This test does not try to cause a crash. Howver it does run the eBPF if it can. This will result in an instant crash or memory corruption which may later cause a crash.

This test is adapted from a full reproducer which can be found here: https://github.com/tr3ee/CVE-2021-4204

It’s recommended to disable unprivileged eBPF by setting /proc/sys/kernel/unprivileged_bpf_disabled. Also there is a specific fix for this issue:

commit 64620e0a1e712a778095bd35cbb277dc2259281f Author: Daniel Borkmann <daniel@iogearbox.net> Date: Tue Jan 11 14:43:41 2022 +0000

bpf: Fix out of bounds access for ringbuf helpers

[1]: Depending on the ptr/reg type

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, ), TST_CAP, (, TST_CAP_DROP, CAP_BPF, )

.min_kver

5.8

.taint_check

TST_TAINT_W

Tag Info

CVE

CVE-2021-4204

linux-git

64620e0a1e71 ("bpf: Fix out of bounds access for ringbuf helpers")


bpf_prog07

a b c d e f g h i k l m n o p q r s t u v w z

Description

The verifier did not properly restrict some *_OR_NULL pointer types. Including RET_PTR_TO_ALLOC_MEM_OR_NULL which is returned by ringbuf_reserve. Somehow this means they can be used to perform arbitrary pointer arithmetic.

The test tries to do some pointer arithmetic on the return value of ringbuf_reserve. Possibly with a trick to make the verifier believe the pointer (in r1) is NULL. The test will pass if the eBPF is rejected and will fail otherwise.

This test does not try to cause a crash. Howver it does run the eBPF if it can. This will result in an instant crash or memory corruption which may later cause a crash.

This test is adapted from a full reproducer which can be found here: https://github.com/tr3ee/CVE-2022-23222

It’s recommended to disable unprivileged eBPF by setting /proc/sys/kernel/unprivileged_bpf_disabled. Also there is a specific fix for this issue:

commit 64620e0a1e712a778095bd35cbb277dc2259281f Author: Daniel Borkmann <daniel@iogearbox.net> Date: Tue Jan 11 14:43:41 2022 +0000

bpf: Fix out of bounds access for ringbuf helpers

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, ), TST_CAP, (, TST_CAP_DROP, CAP_BPF, )

.min_kver

5.8

.taint_check

TST_TAINT_W

Tag Info

CVE

CVE-2022-23222

linux-git

64620e0a1e71 ("bpf: Fix out of bounds access for ringbuf helpers")


brk01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


brk02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Expand brk() by at least 2 pages to ensure there is a newly created VMA and not expanding the original due to multiple anon pages. mprotect() that new VMA then brk() back to the original address therefore causing a munmap of at least one full VMA.

Test timeout defaults to 300 seconds

c


cacheflush01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


can_bcm01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

30

.needs_drivers

vcan, can-bcm

.needs_root

1

.skip_in_compat

1

.taint_check

TST_TAINT_W

Tag Info

CVE

2021-3609

linux-git

d5f9023fa61e ("can: bcm: delay release of struct bcm_op after synchronize_rcu()")


can_filter

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_REQ, CAP_NET_RAW, ), TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.needs_drivers

vcan, can-raw

.options

D: can_dev_name CAN device name


can_rcv_own_msgs

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_REQ, CAP_NET_RAW, ), TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.needs_drivers

vcan, can-raw

.options

D: can_dev_name CAN device name


capget01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_NET_RAW, )


capget02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


capset01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


capset02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


capset03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


capset04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


cfs_bandwidth01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Creates a multi-level CGroup hierarchy with the cpu controller enabled. The leaf groups are populated with "busy" processes which simulate intermittent cpu load. They spin for some time then sleep then repeat.

Both the trunk and leaf groups are set cpu bandwidth limits. The busy processes will intermittently exceed these limits. Causing them to be throttled. When they begin sleeping this will then cause them to be unthrottle.

The test is known to reproduce an issue with an update to SLE-15-SP1 (kernel 4.12.14-197.64, bsc#1179093).

Also as an reproducer for another bug:

commit fdaba61ef8a268d4136d0a113d153f7a89eb9984
Author: Rik van Riel <riel@surriel.com>
Date:   Mon Jun 21 19:43:30 2021 +0200
sched/fair: Ensure that the CFS parent is added after unthrottling

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

20

.needs_cgroup_ctrls

cpu

.needs_checkpoints

1

.needs_kconfigs

CONFIG_CFS_BANDWIDTH

.needs_tmpdir

1

.taint_check

TST_TAINT_W

Tag Info

linux-git

39f23ce07b93 ("sched/fair: Fix unthrottle_cfs_rq() for leaf_cfs_rq list")

linux-git

b34cb07dde7c ("sched/fair: Fix enqueue_task_fair() warning some more")

linux-git

fe61468b2cbc ("sched/fair: Fix enqueue_task_fair warning")

linux-git

5ab297bab984 ("sched/fair: Fix reordering of enqueue/dequeue_task_fair()")

linux-git

6d4d22468dae ("sched/fair: Reorder enqueue/dequeue_task_fair path")

linux-git

fdaba61ef8a2 ("sched/fair: Ensure that the CFS parent is added after unthrottling")


cgroup_core01

a b c d e f g h i k l m n o p q r s t u v w z

Description

When a task is writing to an fd opened by a different task, the perm check should use the credentials of the latter task.

It is copy from kernel selftests cgroup test_core test_cgcore_lesser_euid_open subcase. The difference is that kernel selftest only supports cgroup v2 but here we also support cgroup v1 and v2.

It is a regression test for

commit e57457641613fef0d147ede8bd6a3047df588b95 Author: Tejun Heo <tj@kernel.org> Date: Thu Jan 6 11:02:29 2022 -1000

cgroup: Use open-time cgroup namespace for process migration perm checks

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_cgroup_ctrls

memory

.needs_root

1

Tag Info

CVE

2021-4197

linux-git

e57457641613 ("cgroup: Use open-time cgroup namespace for process migration perm checks")


chdir01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


chdir04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to test whether chdir(2) sets errno correctly.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


chmod01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that chmod(2) succeeds when used to change the mode permissions of a file or directory.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

.test_variants

2


chmod03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, chmod(2) will succeed to change the mode of a file or directory and set the sticky bit on it if invoked by non-root (uid != 0) process with the following constraints:

  • the process is the owner of the file or directory.

  • the effective group ID or one of the supplementary group ID’s of the process is equal to the group ID of the file or directory.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chmod05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chmod06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


chmod07

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chown01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for chown(). Calls chown() on a file and expects it to pass.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


chown02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that chown(2) invoked by super-user: - clears setuid and setgid bits set on an executable file - preserves setgid bit set on a non-group-executable file

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chown03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, chown(2) succeeds to change the group of a file specified by path when called by non-root user with the following constraints:

  • euid of the process is equal to the owner of the file.

  • the intended gid is either egid, or one of the supplementary gids of the process.

Also verify that chown() clears the setuid/setgid bits set on the file.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chown04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that:

  1. Chown() returns -1 and sets errno to EPERM if the effective user id of process does not match the owner of the file and the process is not super user.

  2. Chown() returns -1 and sets errno to EACCES if search permission is denied on a component of the path prefix.

  3. Chown() returns -1 and sets errno to EFAULT if pathname points outside user’s accessible address space.

  4. Chown() returns -1 and sets errno to ENAMETOOLONG if the pathname component is too long.

  5. Chown() returns -1 and sets errno to ENOENT if the specified file does not exists.

  6. Chown() returns -1 and sets errno to ENOTDIR if the directory component in pathname is not a directory.

  7. Chown() returns -1 and sets errno to ELOOP if too many symbolic links were encountered in resolving pathname.

  8. Chown() returns -1 and sets errno to EROFS if the named file resides on a read-only filesystem.

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


chown05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, chown(2) succeeds to change the owner and group of a file specified by path to any numeric owner(uid)/group(gid) values when invoked by super-user.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chroot01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check the whether chroot sets errno to EPERM.

As a non-root user attempt to perform chroot() to a directory. The chroot() call should fail with EPERM

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


chroot02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic chroot() functionality test.

  • Create a file in the temporary directory

  • Change the root to this temporary directory

  • Check whether this file can be accessed in the new root directory

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1


chroot03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to test whether chroot(2) sets errno correctly.

  • to test whether chroot() is setting ENAMETOOLONG if the pathname is more than VFS_MAXNAMELEN.

  • to test whether chroot() is setting ENOTDIR if the argument is not a directory.

  • to test whether chroot() is setting ENOENT if the directory does not exist.

  • attempt to chroot to a path pointing to an invalid address and expect EFAULT as errno.

  • to test whether chroot() is setting ELOOP if the two symbolic directory who point to each other.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


chroot04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check that chroot sets errno to EACCES.

As a non-root user attempt to perform chroot() to a directory that the user does not have a search permission for. The chroot() call should fail with EACESS.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


clock_adjtime01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.restore_wallclock

1

.test_variants

3


clock_adjtime02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.restore_wallclock

1

.test_variants

3


clock_getres01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

7


clock_gettime01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.test_variants

4


clock_gettime02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.test_variants

3


clock_gettime03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_kconfigs

CONFIG_TIME_NS=y

.needs_root

1

.test_variants

4


clock_gettime04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check time difference between successive readings and report a bug if difference found to be over 5 ms.

This test reports a s390x BUG which has been fixed in:

commit 5b43bd184530af6b868d8273b0a743a138d37ee8
Author: Heiko Carstens <hca@linux.ibm.com>
Date:   Wed Mar 24 20:23:55 2021 +0100
s390/vdso: fix initializing and updating of vdso_data

Test timeout defaults to 300 seconds

Tag Info

linux-git

5b43bd184530 ("s390/vdso: fix initializing and updating of vdso_data")


clock_nanosleep01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

4


clock_nanosleep02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.sample

sample_fn

.scall

clock_nanosleep()


clock_nanosleep03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test that clock_nanosleep() adds correctly an offset with absolute timeout and CLOCK_MONOTONIC inside of a timer namespace.

After a call to unshare(CLONE_NEWTIME) a new timer namespace is created, the process that has called the unshare() can adjust offsets for CLOCK_MONOTONIC and CLOCK_BOOTTIME for its children by writing to the '/proc/self/timens_offsets'.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_kconfigs

CONFIG_TIME_NS=y

.needs_root

1

.test_variants

4


clock_nanosleep04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

4


clock_settime01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.restore_wallclock

1

.test_variants

4


clock_settime02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.restore_wallclock

1

.test_variants

3


clock_settime03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.restore_wallclock

1

.test_variants

3


clone01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic clone() test.

Use clone() to create a child process, and wait for the child process to exit, verify that the child process pid is correct.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


clone03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check for equality of getpid() from a child and return value of clone(2)

Test timeout defaults to 300 seconds


clone04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that clone(2) fails with

  • EINVAL if child stack is set to NULL

Test timeout defaults to 300 seconds


clone05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Call clone() with CLONE_VFORK flag set. verify that execution of parent is suspended until child finishes

Test timeout defaults to 300 seconds


clone06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test to verify inheritance of environment variables by child.

Test timeout defaults to 300 seconds


clone07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test for a libc bug where exiting child function by returning from it caused SIGSEGV.

Test timeout defaults to 300 seconds


clone08

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


clone09

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

2.6.24

.needs_root

1


clone301

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic clone3() test.

Test timeout defaults to 300 seconds

Key Value

.needs_checkpoints

1

.needs_root

1

.needs_tmpdir

1


clone302

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic clone3() test to check various failures.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


close01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test that closing a file/pipe/socket works correctly.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


close02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Call close(-1) and expects it to return EBADF.

Test timeout defaults to 300 seconds


close_range01

a b c d e f g h i k l m n o p q r s t u v w z

Description

We check that close_range()

  • closes FDs

  • UNSHARES some FDs before closing them

  • it sets CLOEXEC (in both cloned process and parent)

  • combination of CLOEXEC and UNSHARE.

The final test is the actual bug reproducer. Note that we call clone directly to share the file table.

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_ADMIN, )

.forks_child

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.taint_check

TST_TAINT_W

Tag Info

linux-git

fec8a6a69103 ("close_range: unshare all fds for CLOSE_RANGE_UNSHARE | CLOSE_RANGE_CLOEXEC")


close_range02

a b c d e f g h i k l m n o p q r s t u v w z

Description

  • First check close_range works on a valid range.

  • Then check close_range does not accept invalid paramters.

  • Then check it accepts a large lower fd.

  • Finally check CLOEXEC works

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


confstr01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test confstr(3) 700 (X/Open 7) functionality — POSIX 2008.

Test timeout defaults to 300 seconds


copy_file_range01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.max_runtime

5

.mount_device

1

.needs_device

1

.needs_tmpdir

1

.test_variants

2


copy_file_range02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.test_variants

2


copy_file_range03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

.test_variants

2


cpuset01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

2.6.32

.needs_cgroup_ctrls

cpuset

.needs_root

1


creat01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


creat03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


creat04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1


creat05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


creat06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


creat07

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1

.resource_files

TEST_APP


creat08

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that the group ID and setgid bit are set correctly when a new file is created.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


creat09

a b c d e f g h i k l m n o p q r s t u v w z

Description

CVE-2018-13405

Check for possible privilege escalation through creating files with setgid bit set inside a setgid directory owned by a group which the user does not belong to.

Fixed in:

commit 0fa3ecd87848c9c93c2c828ef4c3a8ca36ce46c7
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Tue Jul 3 17:10:19 2018 -0700
Fix up non-directory creation in SGID directories

This fix is incomplete if file is on xfs filesystem.

Fixed in:

commit 01ea173e103edd5ec41acec65b9261b87e123fc2
Author: Christoph Hellwig <hch@lst.de>
Date:   Fri Jan 22 16:48:18 2021 -0800
xfs: fix up non-directory creation in SGID directories

When use acl or umask, it still has bug.

Fixed in:

commit 1639a49ccdce58ea248841ed9b23babcce6dbb0b
Author: Yang Xu <xuyang2018.jy@fujitsu.com>
Date:   Thu July 14 14:11:27 2022 +0800
fs: move S_ISGID stripping into the vfs_*() helpers

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

exfat, ntfs, vfat

Tag Info

CVE

2018-13405

CVE

2021-4037

linux-git

0fa3ecd87848 ("Fix up non-directory creation in SGID directories")

linux-git

01ea173e103e ("xfs: fix up non-directory creation in SGID directories")

linux-git

1639a49ccdce ("fs: move S_ISGID stripping into the vfs_*() helpers")

linux-git

426b4ca2d6a5 ("Merge tag 'fs.setgid.v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux")


crypto_user02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

Tag Info

linux-git

21d4120ec6f5 ("crypto: user - prevent operating on larval algorithms")


cve-2014-0196

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

60

Tag Info

CVE

2014-0196

linux-git

4291086b1f08 ("n_tty: Fix n_tty_write crash when echoing in raw mode")


cve-2016-10044

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

2.6.8

Tag Info

CVE

2016-10044

linux-git

22f6b4d34fcf ("aio: mark AIO pseudo-fs noexec")


cve-2016-7042

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

CVE

2016-7042

linux-git

03dab869b7b2 ("KEYS: Fix short sprintf buffer in /proc/keys show function")


cve-2016-7117

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

60

.min_kver

2.6.33

Tag Info

CVE

2016-7117

linux-git

a2e2725541fa ("net: Introduce recvmmsg socket syscall")


cve-2017-16939

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Tag Info

CVE

2017-16939

linux-git

1137b5e2529a ("ipsec: Fix aborted xfrm policy dump crash")


cve-2017-17052

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

CVE

2017-17052

linux-git

2b7e8665b4ff ("fork: fix incorrect fput of →exe_file causing use-after-free")


cve-2017-17053

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.taint_check

TST_TAINT_W

Tag Info

CVE

2017-17053

linux-git

ccd5b3235180 ("x86/mm: Fix use-after-free of ldt_struct")


cve-2017-2618

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

CVE

2017-2618

linux-git

0c461cb727d1 ("selinux: fix off-by-one in setprocattr")


cve-2017-2671

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

40

.needs_root

1

Tag Info

CVE

2017-2671

linux-git

43a6684519ab ("ping: implement proper locking")

d


delete_module01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


delete_module02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


delete_module03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


dio_append

a b c d e f g h i k l m n o p q r s t u v w z

Description

Appends zeroed data to a file using O_DIRECT while a child processes are doing buffered reads after seeking to the end of the file and checks if the buffer reads always see zero.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of processes (default 16)

w: str_writesize Write size for each append (default 64K)

c: str_appends Number of appends (default 1000)

.skip_filesystems

tmpfs


dio_read

a b c d e f g h i k l m n o p q r s t u v w z

Description

Create a file using buffered writes while other processes are doing O_DIRECT reads and check if the buffer reads always see zero.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of threads (default 8)

w: str_writesize Size of writing blocks (default 32M)

r: str_readsize Size of reading blocks (default 32M)

s: str_filesize File size (default 128M)

.skip_filesystems

tmpfs


dio_sparse

a b c d e f g h i k l m n o p q r s t u v w z

Description

Create a sparse file using O_DIRECT while other processes are doing buffered reads and check if the buffer reads always see zero.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of threads (default 16)

w: str_writesize Size of writing blocks (default 1K)

s: str_filesize Size of file (default 100M)

o: str_offset File offset (default 0)

.skip_filesystems

tmpfs


dio_truncate

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test is mixing direct I/O and truncate operations checking if they can be used together at the same time. Multiple children are spawned to read a file that is written to using direct I/O and truncated in a loop.

Algorithm

  • Spawn multiple children which start to read on 'file'

  • Parent start to fill and truncate 'file' many times with zero char when children are reading

  • Parent start to fill and truncate a junk file many times with non-zero char

If no issues occur on direct IO/truncate operations and the file always contains zero characters, test PASS. Otherwise, test will FAIL.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

1800

.needs_tmpdir

1

.options

n: str_numchildren Number of threads (default 16)

s: str_filesize Size of file (default 64K)

a: str_numappends Number of appends (default 100)

c: str_numwrites Number of append & truncate (default 100)

.skip_filesystems

tmpfs


dirtypipe

a b c d e f g h i k l m n o p q r s t u v w z

Description

Proof-of-concept exploit for the Dirty Pipe vulnerability (CVE-2022-0847) caused by an uninitialized "pipe_buffer.flags" variable. It demonstrates how to overwrite any file contents in the page cache, even if the file is not permitted to be written, immutable or on a read-only mount.

This exploit requires Linux 5.8 or later; the code path was made reachable by commit f6dd975583bd ("pipe: merge anon_pipe_buf*_ops"). The commit did not introduce the bug, it was there before, it just provided an easy way to exploit it.

There are two major limitations of this exploit: the offset cannot be on a page boundary (it needs to write one byte before the offset to add a reference to this page to the pipe), and the write cannot cross a page boundary.

Example: ./write_anything /root/.ssh/authorized_keys 1 $'\nssh-ed25519 AAA…​…​\n'

Further explanation: https://dirtypipe.cm4all.com/

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

Tag Info

CVE

CVE-2022-0847

linux-git

9d2231c5d74e ("lib/iov_iter: initialize "flags" in new pipe_buffer")


dup01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Negative test for dup(2) with bad fds.

Algorithm

Call dup(2) with invalid argument and make sure it returns -1 with errno set to EBADF.

Test timeout defaults to 300 seconds


dup03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Negative test for dup(2) (too many fds).

Algorithm

Open the maximum allowed number of file descriptors and then try to call dup() once more and verify it fails with EMFILE.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for dup(2) of a system pipe descriptor.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for dup(2) of a named pipe descriptor

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup201

a b c d e f g h i k l m n o p q r s t u v w z

Description

Negative tests for dup2() with bad fd (EBADF).

  • First fd argument is less than 0

  • First fd argument is getdtablesize()

  • Second fd argument is less than 0

  • Second fd argument is getdtablesize()

Test timeout defaults to 300 seconds


dup202

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test whether the access mode are the same for both file descriptors.

Create file with mode, dup2, [change mode], check mode

  • read only, dup2, read only ? "0444"

  • write only, dup2, write only ? "0222"

  • read/write, dup2 read/write ? "0666"

  • read/write/execute, dup2, set read only, read only ? "0444"

  • read/write/execute, dup2, set write only, write only ? "0222"

  • read/write/execute, dup2, set read/write, read/write ? "0666"

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup203

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check the basic functionality of dup2().

  • Attempt to dup2() on an open file descriptor.

  • Attempt to dup2() on a close file descriptor.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup204

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test whether the inode number are the same for both file descriptors.

Test timeout defaults to 300 seconds


dup205

a b c d e f g h i k l m n o p q r s t u v w z

Description

Negative test for dup2() with max open file descriptors.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup206

a b c d e f g h i k l m n o p q r s t u v w z

Description

If oldfd is a valid file descriptor, and newfd has the same value as oldfd, then dup2() does nothing, and returns newfd.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup207

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test whether the file offset are the same for both file descriptors.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


dup3_01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check whether dup3() supports O_CLOEXEC flag.

Test timeout defaults to 300 seconds


dup3_02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test for various EINVAL error.

  • oldfd is equal to newfd without using O_CLOEXEC flag

  • oldfd is equal to newfd with using O_CLOEXEC flag

  • flags contain an invalid value

Test timeout defaults to 300 seconds

e


endian_switch01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

2.6.26


epoll_create01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_create return a nonnegative file descriptor on success.

The size argument informed the kernel of the number of file descriptors that the caller expected to add to the epoll instance, but it is no longer required.

Test timeout defaults to 300 seconds

Key Value

.test_variants

2


epoll_create02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_create returns -1 and set errno to EINVAL if size is not greater than zero.

Test timeout defaults to 300 seconds

Key Value

.test_variants

2


epoll_create1_01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_create1 sets the close-on-exec flag for the returned file descriptor with EPOLL_CLOEXEC.

Test timeout defaults to 300 seconds

Key Value

.min_kver

2.6.27


epoll_create1_02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_create1 returns -1 and set errno to EINVAL with an invalid value specified in flags.

Test timeout defaults to 300 seconds


epoll_ctl01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check the basic functionality of the epoll_ctl:

  • When epoll_ctl succeeds to register fd on the epoll instance and associates event with fd, epoll_wait will get registered fd and event correctly.

  • When epoll_ctl succeeds to change event which is related to fd, epoll_wait will get changed event correctly.

  • When epoll_ctl succeeds to deregister fd from the epoll instance epoll_wait won’t get deregistered fd and event.

Test timeout defaults to 300 seconds


epoll_ctl02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_ctl() fails with:

  • EBADF if epfd is an invalid fd.

  • EPERM if fd does not support epoll.

  • EBADF if fd is an invalid fd.

  • EINVAL if op is not supported.

  • EINVAL if fd is the same as epfd.

  • EINVAL if events is NULL.

  • ENOENT if fd is not registered with EPOLL_CTL_DEL.

  • ENOENT if fd is not registered with EPOLL_CTL_MOD.

  • EEXIST if fd is already registered with EPOLL_CTL_ADD.

Test timeout defaults to 300 seconds


epoll_ctl03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that epoll_ctl returns zero with different combinations of events on success.

Test timeout defaults to 300 seconds

Key Value

.min_kver

2.6.17


epoll_ctl04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that the maximum number of nesting allowed inside epoll sets is 5, otherwise epoll_ctl fails with EINVAL.

Test timeout defaults to 300 seconds


epoll_ctl05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that epoll_ctl() fails with ELOOP if fd refers to an epoll instance and this EPOLL_CTL_ADD operation would result in a circular loop of epoll instances monitoring one another.

Test timeout defaults to 300 seconds


epoll_pwait01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for epoll_pwait() and epoll_pwait2().

  • With a sigmask a signal is ignored and the syscall safely waits until either a file descriptor becomes ready or the timeout expires.

  • Without sigmask if signal arrives a syscall is iterrupted by a signal. The call should return -1 and set errno to EINTR.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

2


epoll_pwait02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for epoll_pwait and epoll_pwait2. Checks if data avaiable in a file descriptor are reported correctly in the syscall return value.

Test timeout defaults to 300 seconds

Key Value

.test_variants

2


epoll_pwait03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that epoll_pwait and epoll_pwait2 timeouts correctly.

Test timeout defaults to 300 seconds

Key Value

.sample

sample_fn

.scall

do_epoll_pwait()

.test_variants

2


epoll_pwait04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, epoll_pwait() and epoll_pwait2() return -1 and set errno to EFAULT with a sigmask points outside user’s accessible address space.

Test timeout defaults to 300 seconds

Key Value

.test_variants

2


epoll_pwait05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, epoll_pwait2() return -1 and set errno to EINVAL with an invalid timespec.

Test timeout defaults to 300 seconds


epoll_wait01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for epoll_wait. Check that epoll_wait works for EPOLLOUT and EPOLLIN events on an epoll instance and that struct epoll_event is set correctly.

Test timeout defaults to 300 seconds


epoll_wait02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that epoll_wait(2) timeouts correctly.

Test timeout defaults to 300 seconds

Key Value

.sample

sample_fn

.scall

epoll_wait()


epoll_wait03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for epoll_wait:

  • epoll_wait fails with EBADF if epfd is not a valid file descriptor.

  • epoll_wait fails with EINVAL if epfd is not an epoll file descriptor.

  • epoll_wait fails with EINVAL if maxevents is less than zero.

  • epoll_wait fails with EINVAL if maxevents is equal to zero.

  • epoll_wait fails with EFAULT if the memory area pointed to by events is not accessible with write permissions.

Test timeout defaults to 300 seconds


epoll_wait04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that a timeout equal to zero causes epoll_wait() to return immediately.

Test timeout defaults to 300 seconds


event_generator

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


execl01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


execle01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


execlp01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


execv01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


execve01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


execve02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

.needs_root

1

.needs_tmpdir

1

.resource_files

TEST_APP


execve03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.needs_root

1

.needs_tmpdir

1


execve04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1

.resource_files

TEST_APP


execve05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1

.options

n: opt_nchild Numbers of children

.resource_files

TEST_APP


execve06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test that kernel adds dummy argv[0] if empty argument list was passed to execve(). This fixes at least one CVE where userspace programs start to process argument list blindly from argv[1] such as polkit pkexec CVE-2021-4034.

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

Tag Info

CVE

2021-4034

linux-git

dcd46d897adb ("exec: Force single empty string when argv is empty")


execveat01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

.needs_tmpdir

1

.resource_files

TEST_APP


execveat02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1

.needs_tmpdir

1

.resource_files

TEST_APP


execvp01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.child_needs_reinit

1

.forks_child

1


exit02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1

f


fallocate04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.options

v verbose Turns on verbose mode


fallocate05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fallocate06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests misaligned fallocate()

Test scenario:

  1. write() several blocks worth of data

  2. fallocate() some more space (not aligned to FS blocks)

  3. try to write() into the allocated space

  4. deallocate misaligned part of file range written in step 1

  5. read() the deallocated range and check that it was zeroed

Subtests:

  • fill filesystem between step 2 and 3

  • disable copy-on-write on test file

  • combinations of above subtests

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

e093c4be760e ("xfs: Fix tail rounding in xfs_alloc_file_space()")

linux-git

6d4572a9d71d ("btrfs: allow btrfs_truncate_block() to fallback to nocow for data space reservation")


fanotify01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify work for a file.

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify work for children of a directory.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fanotify03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify permission events work.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.resource_files

resource_files


fanotify04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check various fanotify special flags.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fanotify05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify overflow event is properly generated.

Algorithm

Generate enough events without reading them and check that overflow event is generated.

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify properly merges ignore mask of an inode and mountpoint.

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

8edc6e1688fc ("fanotify: fix notification of groups with inode & mount marks")

linux-git

d989903058a8 ("ovl: do not generate duplicate fsnotify events for "fake" path")


fanotify07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify permission events are handled properly on instance destruction.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1


fanotify08

a b c d e f g h i k l m n o p q r s t u v w z

Description

Sanity check fanotify_init flag FAN_CLOEXEC by fcntl.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


fanotify10

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify properly merges ignore mask of a mount mark with a mask of an inode mark on the same group. Unlike the prototype test fanotify06, do not use FAN_MODIFY event for the test mask, because it hides the bug.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.resource_files

TEST_APP

.test_variants

2

Tag Info

linux-git

9bdda4e9cf2d ("fsnotify: fix ignore mask logic in fsnotify()")

linux-git

2f02fd3fa13e ("fanotify: fix ignore mask logic for events on child and on dir")


fanotify11

a b c d e f g h i k l m n o p q r s t u v w z

Description

After fanotify_init adds flags FAN_REPORT_TID, check whether the program can accurately identify which thread id in the multithreaded program triggered the event.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fanotify12

a b c d e f g h i k l m n o p q r s t u v w z

Description

Validate that the newly introduced FAN_OPEN_EXEC mask functions as expected. The idea is to generate a sequence of open related actions to ensure that the correct event flags are being set depending on what event mask was requested when the object was marked.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1

.needs_tmpdir

1

.resource_files

TEST_APP


fanotify13

a b c d e f g h i k l m n o p q r s t u v w z

Description

Validate that the values returned within an event when FAN_REPORT_FID is specified matches those that are obtained via explicit invocation to system calls statfs(2) and name_to_handle_at(2).

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

c285a2f01d69 ("fanotify: update connector fsid cache on add mark")


fanotify14

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test file has been designed to ensure that the fanotify system calls fanotify_init(2) and fanotify_mark(2) return the correct error code to the calling process when an invalid flag or mask value has been specified in conjunction with FAN_REPORT_FID.

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

ceaf69f8eadc ("fanotify: do not allow setting dirent events in mask of non-dir")

linux-git

8698e3bab4dd ("fanotify: refine the validation checks on non-dir inode mask")


fanotify15

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test file that has been purposely designed to verify FAN_REPORT_FID functionality while using newly defined dirent events.

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

f367a62a7cad ("fanotify: merge duplicate events on parent and child")


fanotify16

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check fanotify directory entry modification events, events on child and on self with group init flags:

  • FAN_REPORT_DFID_NAME (dir fid + name)

  • FAN_REPORT_DIR_FID (dir fid)

  • FAN_REPORT_DIR_FID | FAN_REPORT_FID (dir fid + child fid)

  • FAN_REPORT_DFID_NAME | FAN_REPORT_FID (dir fid + name + child fid)

  • FAN_REPORT_DFID_NAME_TARGET (dir fid + name + created/deleted file fid)

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify17

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that fanotify groups and marks limits are enforced correctly. If user ns is supported, verify that global limit and per user ns limits are both enforced. Otherwise, we only check that global groups limit is enforced.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify18

a b c d e f g h i k l m n o p q r s t u v w z

Description

This set of tests is to ensure that the unprivileged listener feature of fanotify is functioning as expected. The objective this test case file is to validate whether any forbidden flags that are passed by an unprivileged user return the correct error result.

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify19

a b c d e f g h i k l m n o p q r s t u v w z

Description

This set of tests is to ensure that the unprivileged listener feature of fanotify is functioning as expected. The objective of this test file is to generate a sequence of events and ensure that the returned events contain the limited values that an unprivileged listener is expected to receive.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

a8b98c808eab ("fanotify: fix permission model of unprivileged group")


fanotify20

a b c d e f g h i k l m n o p q r s t u v w z

Description

This source file contains a test case which ensures that the fanotify API returns an expected error code when provided an invalid initialization flag alongside FAN_REPORT_PIDFD. Additionally, it checks that the operability with existing FAN_REPORT_* flags is maintained and functioning as intended.

Note
FAN_REPORT_PIDFD support was added in v5.15-rc1 in af579beb666a ("fanotify: add pidfd support to the fanotify API").

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify21

a b c d e f g h i k l m n o p q r s t u v w z

Description

A test which verifies whether the returned struct fanotify_event_info_pidfd in FAN_REPORT_PIDFD mode contains the expected set of information.

Note
FAN_REPORT_PIDFD support was added in v5.15-rc1 in af579beb666a ("fanotify: add pidfd support to the fanotify API").

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.forks_child

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fanotify22

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check fanotify FAN_ERROR_FS events triggered by intentionally corrupted filesystems:

  • Generate a broken filesystem

  • Start FAN_FS_ERROR monitoring group

  • Make the file system notice the error through ordinary operations

  • Observe the event generated

Test timeout defaults to 300 seconds

Key Value

.dev_fs_type

ext4

.format_device

1

.mount_device

1

.needs_cmds

debugfs

.needs_device

1

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

124e7c61deb2 ("ext4: fix error code saved on super block during file system abort")


fanotify23

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check evictable fanotify inode marks.

Test timeout defaults to 300 seconds

Key Value

.dev_fs_type

ext2

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fchdir01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fchdir02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


fchdir03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchmod01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fchmod02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchmod03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, fchmod(2) will succeed to change the mode of a file and set the sticky bit on it if invoked by non-root (uid != 0) process with the following constraints, - the process is the owner of the file. - the effective group ID or one of the supplementary group ID’s of the process is equal to the group ID of the file.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchmod04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, fchmod(2) will succeed to change the mode of a directory and set the sticky bit on it if invoked by non-root (uid != 0) process with the following constraints, - the process is the owner of the directory. - the effective group ID or one of the supplementary group ID’s of the process is equal to the group ID of the directory.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchmod05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchmod06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


fchmodat01

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test case will verify basic function of fchmodat.

Test timeout defaults to 300 seconds

Key Value

.min_kver

2.6.16

.needs_tmpdir

1


fchown01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for fchown(). Call fchown() on a fd and expect it to pass.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fchown02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that fchown(2) invoked by super-user: - clears setuid and setgid bits set on an executable file - preserves setgid bit set on a non-group-executable file

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchown03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, fchown(2) succeeds to change the group of a file specified by path when called by non-root user with the following constraints:

  • euid of the process is equal to the owner of the file

  • the intended gid is either egid, or one of the supplementary gids of the process.

Also verify that fchown() clears the setuid/setgid bits set on the file.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fchown04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that:

  1. fchown() returns -1 and sets errno to EPERM if the effective user id of process does not match the owner of the file and the process is not super user.

  2. fchown() returns -1 and sets errno to EBADF if the file descriptor of the specified file is not valid.

  3. fchown() returns -1 and sets errno to EROFS if the named file resides on a read-only file system.

Test timeout defaults to 300 seconds

Key Value

.needs_rofs

1

.needs_root

1


fchown05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that, fchown() succeeds to change the owner and group of a file specified by file descriptor to any numeric owner(uid)/group(gid) values when invoked by super-user.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


fcntl02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fcntl03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fcntl04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fcntl05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for fcntl(2) using F_GETLK argument.

If the lock could be placed, fcntl() does not actually place it, but returns F_UNLCK in the l_type field of lock and leaves the other field of the structure unchanged.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fcntl12

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests basic error handling of the fcntl syscall.

  • EMFILE when cmd is F_DUPFD and the per-process limit on the number of open file descriptors has been reached.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fcntl13

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests basic error handling of the fcntl syscall.

  • EFAULT when lock is outside your accessible address space

  • EINVAL when cmd argument is not recognized by this kernel

  • EINVAL when cmd argument is F_SETLK and flock.l_whence is not equal to SEET_CUR,SEEK_SET,SEEK_END

  • EBADF when fd refers to an invalid file descriptor

Test timeout defaults to 300 seconds


fcntl15

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that file locks are removed when a file descriptor is closed, three different tests are implemented.

Parent opens a file and duplicates the file descriptor, places locks using both file descriptors then closes one descriptor, all locks should be removed.

Open same file twice using open, place locks using both descriptors then close one descriptor, all lock should be removed.

Open file twice, each in a different process, set the locks and the child check the locks. Close the first file descriptor and have child check locks again. Only locks set on first file descriptor should have been removed.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1


fcntl33

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_checkpoints

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

tmpfs, ramfs, nfs


fcntl34

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.15.0

.needs_tmpdir

1


fcntl35

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

2.6.35

.needs_root

1

Tag Info

linux-git

086e774a57fb ("pipe: cap initial pipe capacity according to pipe-max-size limit")


fcntl36

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.15

.needs_tmpdir

1


fcntl37

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_DROP, CAP_SYS_RESOURCE, )


fcntl38

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_DNOTIFY=y

.needs_tmpdir

1


fcntl39

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that dnotify DN_RENAME event is reported only on rename inside same parent.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_DNOTIFY=y

.needs_tmpdir

1


fdatasync03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

tmpfs


fgetxattr01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fgetxattr02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_devfs

1

.needs_root

1


fgetxattr03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


finit_module01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic finit_module() tests.

Algorithm

Inserts a simple module after opening and mmaping the module file.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


finit_module02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic finit_module() failure tests.

Algorithm

Tests various failure scenarios for finit_module().

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

032146cda855 ("vfs: check fd has read access in kernel_read_file_from_fd()")

linux-git

39d637af5aa7 ("vfs: forbid write access when reading a file into memory")


flistxattr01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


flistxattr02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


flistxattr03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


flock01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


flock02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


flock03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1


flock04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


flock06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fork01

a b c d e f g h i k l m n o p q r s t u v w z

Description

  • fork returns without error

  • fork returns the pid of the child

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fork07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that all children inherit parent’s file descriptor.

Parent opens a file and forks children. Each child reads a byte and checks that the value is correct. Parent checks that correct number of bytes was consumed from the file.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fork08

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that the parent’s file descriptors will not be affected by being closed in the child.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fork13

a b c d e f g h i k l m n o p q r s t u v w z

Description

A race in pid generation that causes pids to be reused immediately

From the mainline commit 5fdee8c4a5e1800489ce61963208f8cc55e42ea1:

A program that repeatedly forks and waits is susceptible to having the same pid repeated, especially when it competes with another instance of the same program. This is really bad for bash implementation. Furthermore, many shell scripts assume that pid numbers will not be used for some length of time.

Race description

A                                B

// pid == offset == n            // pid == offset == n + 1
test_and_set_bit(offset, map->page)
                                 test_and_set_bit(offset, map->page);
                                 pid_ns->last_pid = pid;
pid_ns->last_pid = pid;
                                 // pid == n + 1 is freed (wait())

                                 // Next fork()...
                                 last = pid_ns->last_pid; // == n
                                 pid = last + 1;

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

600

.needs_root

1

.save_restore

!/proc/sys/kernel/pid_max PID_MAX_STR

Tag Info

linux-git

5fdee8c4a5e1 ("pids: fix a race in pid generation that causes pids to be reused immediately")


fremovexattr01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fremovexattr02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fs_fill

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fsconfig01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fsconfig02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fsetxattr01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fsetxattr02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_devfs

1

.needs_drivers

brd

.needs_root

1


fsmount01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fsmount02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fsopen01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fsopen02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fspick01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fspick02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

fuse


fstat02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests if fstat() returns correctly and reports correct file information using the stat structure.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fstat03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fstatfs02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check if fstatfs() sets errno correctly.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


fsync01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


fsync02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

300

.needs_tmpdir

1


fsync03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


fsync04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

tmpfs


ftruncate01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


ftruncate03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that ftruncate(2) system call returns appropriate error number:

  1. EINVAL — the file is a socket

  2. EINVAL — the file descriptor was opened with O_RDONLY

  3. EINVAL — the length is negative

  4. EBADF — the file descriptor is invalid

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


ftruncate04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.format_device

1

.mount_device

1

.needs_checkpoints

1

.needs_device

1

.needs_kconfigs

CONFIG_MANDATORY_FILE_LOCKING=y

.needs_root

1

.needs_tmpdir

1


futex_cmp_requeue01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

3


futex_cmp_requeue02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3

Tag Info

CVE

2018-6927

linux-git

fbe0e839d1e2 ("futex: Prevent overflow by strengthen input validation")


futex_wait01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


futex_wait02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

3


futex_wait03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


futex_wait04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


futex_wait05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.sample

sample_fn

.scall

futex_wait()


futex_wait_bitset01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


futex_waitv01

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test verifies EINVAL for futex_waitv syscall.

Test timeout defaults to 300 seconds

Key Value

.min_kver

5.16


futex_waitv02

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test verifies futex_waitv syscall using private data.

Test timeout defaults to 300 seconds

Key Value

.min_kver

5.16

.options

n: str_numfutex Number of futex (default 30)

.test_variants

2


futex_waitv03

a b c d e f g h i k l m n o p q r s t u v w z

Description

This test verifies futex_waitv syscall using shared data.

Test timeout defaults to 300 seconds

Key Value

.min_kver

5.16

.options

n: str_numfutex Number of futex (default 30)

.test_variants

2


futex_wake01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


futex_wake02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

3


futex_wake03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.test_variants

3


futex_wake04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

1, TST_NEEDS

.min_kver

2.6.32

.needs_root

1

.needs_tmpdir

1

.test_variants

3

g


get_mempolicy01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that get_mempolicy() returns a proper return value and errno for various cases.

Test timeout defaults to 300 seconds


get_mempolicy02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that get_mempolicy() returns a proper return errno for failure cases.

Test timeout defaults to 300 seconds


getaddrinfo_01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic getaddrinfo() tests.

The test adds LTP specific addresses and names to /etc/hosts to avoid DNS, hostname setup issues and conflicts with existing configuration.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1


getcontext01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for getcontext().

Calls a getcontext() then jumps back with a setcontext().

Test timeout defaults to 300 seconds


getcpu01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getcwd01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getcwd02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getcwd03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


getcwd04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_cpus

2

.needs_tmpdir

1


getdents01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic getdents() test that checks if directory listing is correct and complete.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

.test_variants

4


getdents02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that:

  • getdents() fails with EBADF if file descriptor fd is invalid

  • getdents() fails with EINVAL if result buffer is too small

  • getdents() fails with ENOTDIR if file descriptor does not refer to a directory

  • getdents() fails with ENOENT if directory was unlinked()

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

.test_variants

4


getdomainname01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic test for getdomainname(2)

This is a Phase I test for the getdomainname(2) system call. It is intended to provide a limited exposure of the system call.

Test timeout defaults to 300 seconds


getgid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Call getgid() and expects that the gid returned correctly.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


getgid03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Testcase to check the basic functionality of getgid().

Algorithm

For functionality test the return value from getgid() is compared to passwd entry.

Test timeout defaults to 300 seconds


gethostid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test the basic functionality of the sethostid() and gethostid() system call.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


getitimer01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that a correct call to getitimer() succeeds.

Test timeout defaults to 300 seconds


getitimer02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that getitimer() call fails:

  1. EFAULT with invalid itimerval pointer

  2. EINVAL when called with an invalid first argument

Test timeout defaults to 300 seconds


getpagesize01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that getpagesize(2) returns the number of bytes in a memory page as expected.

Test timeout defaults to 300 seconds


getpid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that getpid() system call returns process ID in range 2 …​ PID_MAX

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


getpid02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that: - fork() in parent returns the same pid as getpid() in child - getppid() in child returns the same pid as getpid() in parent

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


getppid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test whether parent process id that getppid() returns is out of range.

Test timeout defaults to 300 seconds


getppid02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that getppid() in child returns the same pid as getpid() in parent.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


getpriority01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getpriority02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrandom01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrandom02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrandom03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrandom04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrlimit01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that getrlimit(2) call will be successful for all possible resource types.

Test timeout defaults to 300 seconds


getrlimit02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test for checking error conditions for getrlimit(2) 1) getrlimit(2) returns -1 and sets errno to EFAULT if an invalid address is given for address parameter. 2) getrlimit(2) returns -1 and sets errno to EINVAL if an invalid resource type (RLIM_NLIMITS is a out of range resource type) is passed.

Test timeout defaults to 300 seconds


getrlimit03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


getrusage01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test that getrusage() with RUSAGE_SELF and RUSAGE_CHILDREN succeeds.

Test timeout defaults to 300 seconds


getrusage02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that getrusage() fails with:

  • EINVAL with invalid who

  • EFAULT with invalid usage pointer

Test timeout defaults to 300 seconds

Key Value

.test_variants

3


getrusage03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ru_maxrss behaviors in struct rusage.

This test program is backported from upstream commit: 1f10206cf8e9, which fills ru_maxrss value in struct rusage according to rss hiwater mark. To make sure this feature works correctly, a series of tests are executed in this program.

Test timeout defaults to 300 seconds

Key Value

.caps

TST_CAP, (, TST_CAP_REQ, CAP_IPC_LOCK, )

.child_needs_reinit

1

.forks_child

1

.min_kver

2.6.32

.min_mem_avail

512

.needs_tmpdir

1

.resource_files

resource

Tag Info

linux-git

1f10206cf8e9 ("getrusage: fill ru_maxrss value")


getrusage03_child

a b c d e f g h i k l m n o p q r s t u v w z

Description

Child program executed by getrusage03.

Test timeout defaults to 300 seconds


getsid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that session IDs returned by getsid() (with argument pid=0) are same in parent and child process.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


getsid02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that getsid(2) fails with ESRCH errno when there is no process found with process ID pid.

Test timeout defaults to 300 seconds


getsockopt02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_checkpoints

1

.needs_tmpdir

1


gettimeofday02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

10


getuid01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check the basic functionality of the getuid() system call.

Test timeout defaults to 300 seconds


getuid03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that getuid() return value matches value from /proc/self/status.

Test timeout defaults to 300 seconds


getxattr05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

3.8

.needs_root

1

.needs_tmpdir

1

h


hugemmap01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

H: Hopt Location of hugetlbfs, i.e. -H /var/hugetlbfs

s: nr_opt Set the number of the been allocated hugepages


hugemmap02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

H: Hopt Location of hugetlbfs, i.e. -H /var/hugetlbfs

s: nr_opt Set the number of the been allocated hugepages


hugemmap04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

H: Hopt Location of hugetlbfs, i.e. -H /var/hugetlbfs

s: nr_opt Set the number of the been allocated hugepages


hugemmap05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

NR_HPAGES, TST_NEEDS

.needs_root

1

.needs_tmpdir

1

.options

s opt_sysfs Setup hugepages from sysfs

m opt_shmid Reserve hugepages by shmget

a: opt_alloc Number of overcommint hugepages


hugemmap07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Certain kernels have a bug where brk() does not perform the same checks that a MAP_FIXED mmap() will, allowing brk() to create a normal page VMA in a hugepage only address region. This can lead to oopses or other badness.

Test timeout defaults to 300 seconds

Key Value

.hugepages

1, TST_NEEDS

.needs_hugetlbfs

1

.needs_root

1

.taint_check

TST_TAINT_D


hugemmap08

a b c d e f g h i k l m n o p q r s t u v w z

Description

Some kernel versions after hugepage demand allocation was added used a dubious heuristic to check if there was enough hugepage space available for a given mapping. The number of not-already-instantiated pages in the mapping was compared against the total hugepage free pool. It was very easy to confuse this heuristic into overcommitting by allocating hugepage memory in chunks, each less than the total available pool size but together more than available. This would generally lead to OOM SIGKILLs of one process or another when it tried to instantiate pages beyond the available pool.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.hugepages

3, TST_NEEDS

.needs_hugetlbfs

1

.needs_root

1

.save_restore

PATH_OC_HPAGES


hugemmap09

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test sanity of cow optimization on page cache. If a page in page cache has only 1 ref count, it is mapped for a private mapping directly and is overwritten freely, so next time we access the page, we can see corrupt data.

Test timeout defaults to 300 seconds

Key Value

.hugepages

2, TST_NEEDS

.needs_hugetlbfs

1

.needs_root

1


hugeshmat01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmat02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmat03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmat04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.hugepages

1, TST_NEEDS

.min_mem_avail

2048

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

c5c99429fa57 ("fix hugepages leak due to pagetable page sharing")


hugeshmctl01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.hugepages

128, TST_REQUEST

.needs_checkpoints

1

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmctl02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmctl03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.hugepages

128, TST_REQUEST

.needs_root

1

.needs_tmpdir

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmdt01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmget01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmget02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmget03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.options

s: nr_opt Set the number of the been allocated hugepages


hugeshmget05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.hugepages

128, TST_REQUEST

.needs_root

1

.options

s: nr_opt Set the number of the been allocated hugepages

i


icmp_rate_limit01

a b c d e f g h i k l m n o p q r s t u v w z

CVE-2020-25705

Test of ICMP rate limiting behavior that may be abused for DNS cache poisoning attack. Send a few batches of 100 packets to a closed UDP port and count the ICMP errors. If the number of errors is always the same for each batch (not randomized), the system is vulnerable. Send packets from multiple IP addresses to bypass per-address ICMP throttling.

Fixed in:

commit b38e7819cae946e2edf869e604af1e65a5d241c5
Author: Eric Dumazet <edumazet@google.com>
Date:   Thu Oct 15 11:42:00 2020 -0700
icmp: randomize the global rate limiter

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_VETH, CONFIG_USER_NS=y, CONFIG_NET_NS=y

.save_restore

?/proc/sys/user/max_user_namespaces

Tag Info

CVE

2020-25705

linux-git

b38e7819cae9 ("icmp: randomize the global rate limiter")


ima_boot_aggregate

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.options

options


ima_mmap

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.options

f: filename File to mmap


in6_01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


in6_02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


init_module01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic init_module() tests.

Algorithm

Inserts a simple module after opening and mmaping the module file.

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


init_module02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Basic init_module() failure tests.

Algorithm

Tests various failure scenarios for init_module().

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


inotify01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


inotify02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


inotify03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


inotify04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


inotify05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


inotify06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.max_runtime

600

.needs_root

1

.needs_tmpdir

1


inotify07

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_overlay

1

.needs_root

1

.needs_tmpdir

1


inotify08

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.mount_device

1

.needs_device

1

.needs_overlay

1

.needs_root

1

.needs_tmpdir

1


inotify09

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

150

.needs_tmpdir

1

Tag Info

linux-git

d90a10e2444b ("fsnotify: Fix fsnotify_mark_connector race")


inotify10

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1

Tag Info

linux-git

fecc4559780d ("fsnotify: fix events reported to watching parent and child")


inotify11

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test opening files after receiving IN_DELETE.

Kernel v5.13 has a regression allowing files to be open after IN_DELETE.

The problem has been fixed by commit: a37d9a17f099 "fsnotify: invalidate dcache before IN_DELETE event".

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1

Tag Info

linux-git

a37d9a17f099 ("fsnotify: invalidate dcache before IN_DELETE event")


inotify12

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test special inotify mask flags.

Regression test for kernel commit: a32e697cda27 ("inotify: show inotify mask flags in proc fdinfo")

Test timeout defaults to 300 seconds

Key Value

.max_runtime

10

.needs_tmpdir

1

Tag Info

linux-git

a32e697cda27 ("inotify: show inotify mask flags in proc fdinfo")


inotify_init1_01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that inotify_init1() returns a file descriptor and sets the close-on-exec (FD_CLOEXEC) flag on the new file descriptor only when called with IN_CLOEXEC.

Test timeout defaults to 300 seconds


inotify_init1_02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Verify that inotify_init1() returns a file descriptor and sets the O_NONBLOCK file status flag on the open file description referred to by the new file descriptor only when called with IN_NONBLOCK.

Test timeout defaults to 300 seconds


io_cancel01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_cancel invoked via syscall(2) with one of pointers set to invalid address and expects it to return EFAULT.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_cancel02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_cancel invoked via libaio with one of the data structures points to invalid data and expects it to return -EFAULT.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_control01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Perform some I/O on a file and check if at least some of it is recorded by the I/O controller.

The exact amount of I/O performed is dependent on the file system, page cache, scheduler and block driver. We call sync and drop the file’s page cache to force reading and writing. We also write random data to try to prevent compression.

The pagecache is a particular issue for reading. If the call to fadvise is ignored then the data may only be read from the cache. So that no I/O requests are made.

Test timeout defaults to 300 seconds

Key Value

.all_filesystems

1

.format_device

1

.mount_device

1

.needs_cgroup_ctrls

io

.needs_cgroup_ver

TST_CG_V2

.needs_device

1

.needs_tmpdir

1

.skip_filesystems

ntfs, tmpfs


io_destroy01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_destroy invoked via libaio with invalid ctx and expects it to return -EINVAL.

Test timeout defaults to 300 seconds


io_destroy02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_destroy invoked via syscall(2) with an invalid ctx and expects it to return EINVAL.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_getevents01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_getevents invoked via syscall(2) with invalid ctx and expects it to return EINVAL.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_getevents02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_getevents invoked via libaio with invalid ctx and expects it to return -EINVAL.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_pgetevents01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.18

.needs_tmpdir

1

.test_variants

3


io_pgetevents02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.18

.needs_tmpdir

1

.test_variants

3


io_setup01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_setup invoked via libaio:

  • io_setup succeeds if both nr_events and ctxp are valid.

  • io_setup fails and returns -EINVAL if ctxp is not initialized to 0.

  • io_setup fails and returns -EINVAL if nr_events is invalid.

  • io_setup fails and returns -EFAULT if ctxp is NULL.

  • io_setup fails and returns -EAGAIN if nr_events exceeds the limit 1of available events.

Test timeout defaults to 300 seconds


io_setup02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_setup invoked via syscall(2):

  • io_setup fails and returns EFAULT if ctxp is NULL.

  • io_setup fails and returns EINVAL if ctxp is not initialized to 0.

  • io_setup fails and returns EINVAL if nr_events is -1.

  • io_setup fails and returns EAGAIN if nr_events exceeds the limit of available events.

  • io_setup succeeds if both nr_events and ctxp are valid.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y


io_submit01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_submit() invoked via libaio:

  • io_submit fails and returns -EINVAL if ctx is invalid.

  • io_submit fails and returns -EINVAL if nr is invalid.

  • io_submit fails and returns -EFAULT if iocbpp pointer is invalid.

  • io_submit fails and returns -EBADF if fd is invalid.

  • io_submit succeeds and returns the number of iocbs submitted.

  • io_submit succeeds and returns 0 if nr is zero.

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


io_submit02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_submit invoked via syscall(2):

  1. io_submit() returns the number of iocbs submitted.

  2. io_submit() returns 0 if nr is zero.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y

.needs_tmpdir

1


io_submit03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test io_submit invoked via syscall(2):

  1. io_submit fails and returns EINVAL if ctx is invalid.

  2. io_submit fails and returns EINVAL if nr is invalid.

  3. io_submit fails and returns EFAULT if iocbpp pointer is invalid.

  4. io_submit fails and returns EBADF if fd is invalid.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_AIO=y

.needs_tmpdir

1


io_uring01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_tmpdir

1


ioctl01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.needs_tmpdir

1

.options

D: device Tty device. For example, /dev/tty[0-9]


ioctl03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1


ioctl04

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.format_device

1

.needs_device

1

.needs_root

1

.needs_tmpdir

1


ioctl05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_device

1

.needs_root

1

.needs_tmpdir

1


ioctl06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_device

1

.needs_root

1

.needs_tmpdir

1


ioctl07

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.options

f: s_fuzz Fuzz factor for valid match (default 2)


ioctl08

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.dev_fs_type

btrfs

.format_device

1

.min_kver

4.5

.mount_device

1

.needs_device

1

.needs_drivers

btrfs

.needs_root

1

.needs_tmpdir

1


ioctl09

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_cmds

parted

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1


ioctl_loop01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LO_FLAGS_AUTOCLEAR and LO_FLAGS_PARTSCAN flags.

For LO_FLAGS_AUTOCLEAR flag, only checks autoclear field value in sysfs and also gets lo_flags by using LOOP_GET_STATUS.

For LO_FLAGS_PARTSCAN flag, it is the same as LO_FLAGS_AUTOCLEAR flag. But also checks whether it can scan partition table correctly i.e. checks whether /dev/loopnp1 and /sys/bloclk/loop0/loop0p1 existed.

For LO_FLAGS_AUTOCLEAR flag, it can be clear. For LO_FLAGS_PARTSCAN flag, it cannot be clear. Test checks this.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

10c70d95c0f2 ("block: remove the bd_openers checks in blk_drop_partitions")

linux-git

6ac92fb5cdff ("loop: Fix wrong masking of status flags")


ioctl_loop02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LO_FLAGS_READ_ONLY (similar as losetup -r) and LOOP_CHANGE_FD flags.

For LOOP_CHANGE_FD, this operation is possible only if the loop device is read-only and the new backing store is the same size and type as the old backing store.

When using LOOP_CONFIGURE ioctl(), it can set LO_FLAGS_READ_ONLY flag even though backing file with write mode.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1


ioctl_loop03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LOOP_CHANGE_FD flag.

Tests whether LOOP_CHANGE_FD can not succeed (get EINVAL error) when loop_dev is not read only.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1


ioctl_loop04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LOOP_SET_CAPACITY flag.

Tests whether LOOP_SET_CAPACITY can update a live loop device size after change the size of the underlying backing file. Also checks sysfs value.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1


ioctl_loop05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LOOP_SET_DIRECT_IO flag.

Tests whether LOOP_SET_DIRECT_IO can update a live loop device dio mode. It requires the backing file also supports dio mode and the lo_offset is aligned with the logical block size.

The direct I/O error handling is a bit messy on Linux, some filesystems return error when it coudln’t be enabled, some silently fall back to regular buffered I/O.

The LOOP_SET_DIRECT_IO ioctl() may ignore all checks if it cannot get the logical block size which is the case if the block device pointer in the backing file inode is not set. In this case the direct I/O appears to be enabled but falls back to buffered I/O later on. This is the case at least for Btrfs. Because of that the test passes both with failure as well as success with non-zero offset.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1

.skip_filesystems

tmpfs, overlayfs


ioctl_loop06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests invalid block size of loopdevice by using ioctl() with LOOP_SET_BLOCK_SIZE and LOOP_CONFIGURE flags.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1


ioctl_loop07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Tests ioctl() on loopdevice with LOOP_SET_STATUS64 and LOOP_GET_STATUS64 flags.

Tests lo_sizelimit field. If lo_sizelimit is 0, it means max available. If sizelimit is less than loop_size, loopsize will be truncated.

Also uses LOOP_CONFIGURE ioctl to test lo_sizelimit field.

Test timeout defaults to 300 seconds

Key Value

.needs_drivers

loop

.needs_root

1

.needs_tmpdir

1

Tag Info

linux-git

79e5dc59e297 ("loop: Set correct device size when using LOOP_CONFIGURE")


ioctl_ns01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_PARENT request.

Parent process tries to get parent of initial namespace, which should fail with EPERM because it has no parent.

Child process has a new pid namespace, which should make the call fail with EPERM error.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

4.9

.needs_root

1


ioctl_ns02

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_PARENT request.

Test tries to get namespace parent for UTS namespace, which should make the call fail with EINVAL, being a nonhierarchical namespace.

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.9


ioctl_ns03

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_OWNER_UID request.

Calls ioctl for a UTS namespace, which isn’t a user namespace. This should make the call fail with EINVAL.

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.11


ioctl_ns04

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_USERNS request.

Owning user namespace of process calling ioctl is out of scope, which should make the call fail with EPERM.

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.9


ioctl_ns05

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_PARENT request.

Child cloned with the CLONE_NEWPID flag is created in a new pid namespace. That’s checked by comparing its /proc/self/ns/pid symlink and the parent’s one. Also child thinks its pid is 1.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

4.9

.needs_checkpoints

1

.needs_root

1

.needs_tmpdir

1


ioctl_ns06

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_USERNS request.

After the call to clone with the CLONE_NEWUSER flag, child is created in a new user namespace. That’s checked by comparing its /proc/self/ns/user symlink and the parent’s one, which should be different.

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

4.9

.needs_checkpoints

1

.needs_root

1

.needs_tmpdir

1


ioctl_ns07

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test ioctl_ns with NS_GET_* request for file descriptors that aren’t namespaces.

Calling ioctl with test directory’s file descriptor should make the call fail with ENOTTY.

Test timeout defaults to 300 seconds

Key Value

.min_kver

4.11

.needs_tmpdir

1


ioctl_sg01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

3600

Tag Info

CVE

2018-1000204

linux-git

a45b599ad808 ("scsi: sg: allocate with __GFP_ZERO in sg_build_indirect()")


ioperm01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


ioperm02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


iopl01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


iopl02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.needs_root

1

.skip_in_lockdown

1


ioprio_get01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


ioprio_set01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


ioprio_set02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


ioprio_set03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


irqbalance01

a b c d e f g h i k l m n o p q r s t u v w z

Description

Check that something (e.g. irqbalance daemon) is performing IRQ load balancing.

On many systems userland needs to set /proc/irq/$IRQ/smp_affinity to prevent many IRQs being delivered to the same CPU.

Note some drivers and IRQ controllers will distribute IRQs evenly. Some systems will have housekeeping CPUs configured. Some IRQs can not be masked etc. So this test is not appropriate for all scenarios.

Furthermore, exactly how IRQs should be distributed is a performance and/or security issue. This is only a generic smoke test. It will hopefully detect misconfigured systems and total balancing failures which are often silent errors.

Heuristic: Evidence of Change

  1. Find IRQs with a non-zero count

  2. Check if they are now disallowed

There are two sources of information we need to parse:

  1. /proc/interrupts

  2. /proc/irq/$IRQ/smp_affinity

We get the active IRQs and CPUs from /proc/interrupts. It also contains the per-CPU IRQ counts and info we do not care about.

We get the IRQ masks from each active IRQ’s smp_affinity file. This is a bitmask written out in hexadecimal format. It shows which CPUs an IRQ may be received by.

Test timeout defaults to 300 seconds

Key Value

.min_cpus

2

k


kcmp01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

3.5.0

.needs_tmpdir

1


kcmp02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.5.0

.needs_tmpdir

1


kcmp03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.min_kver

3.5.0


keyctl01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


keyctl02

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.max_runtime

60

.needs_root

1

Tag Info

linux-git

b4a1b4f5047e ("KEYS: Fix race between read and revoke")


keyctl05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

linux-git

63a0b0509e70 ("KEYS: fix freeing uninitialized memory in key_update()")


keyctl07

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

Tag Info

CVE

2017-12912

linux-git

37863c43b2c6 ("KEYS: prevent KEYCTL_READ on negative key")


keyctl09

a b c d e f g h i k l m n o p q r s t u v w z

Description

Test that encrypted keys can be instantiated using user-provided decrypted data that is hex-ascii encoded.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_USER_DECRYPTED_DATA=y


kill03

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds


kill05

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_root

1


kill06

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1


kill11

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.forks_child

1

.needs_tmpdir

1


kill13

a b c d e f g h i k l m n o p q r s t u v w z

Description

Reproducer of CVE-2018-10124; INT_MIN negation.

On most two’s complement CPUs negation of INT_MIN will result in INT_MIN because ~((unsigned)INT_MIN) + 1 overflows to INT_MIN (unless trapped). On one’s complement ~((unsigned)INT_MIN) = INT_MAX.

Without UBSAN kill will always return ESRCH. Regardless of if the bug is present as INT_MIN/INT_MAX are invalid PIDs. It checks the PID before the signal number so we can not cause EINVAL. A trivial test of kill is performed elsewhere. So we don’t run the test without UBSAN to avoid giving the impression we have actually tested for the bug.

Test timeout defaults to 300 seconds

Key Value

.needs_kconfigs

CONFIG_UBSAN_SIGNED_OVERFLOW

.taint_check

TST_TAINT_W

Tag Info

CVE

CVE-2018-10124

linux-git

4ea77014af0d ("kernel/signal.c: avoid undefined behaviour in kill_something_info")


kmsg01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value

.min_kver

3.5.0

.needs_root

1


ksm01

a b c d e f g h i k l m n o p q r s t u v w z

Test timeout defaults to 300 seconds

Key Value