syzbot


KCSAN: data-race in search_nested_keyrings / search_nested_keyrings

Status: auto-closed as invalid on 2020/01/23 16:46
Subsystems: keyrings lsm
[Documentation on labels]
First crash: 1689d, last: 1677d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in search_nested_keyrings / search_nested_keyrings (2) keyrings lsm 1 58d 58d 0/27 auto-obsoleted due to no activity on 2024/05/25 15:41

Sample crash report:
==================================================================
BUG: KCSAN: data-race in search_nested_keyrings / search_nested_keyrings

write to 0xffff888126ad6a60 of 8 bytes by task 8790 on cpu 1:
 search_nested_keyrings+0x4ca/0x880 security/keys/keyring.c:861
 keyring_search_rcu+0x111/0x160 security/keys/keyring.c:926
 get_user_session_keyring_rcu+0x189/0x1f0 security/keys/process_keys.c:208
 search_cred_keyrings_rcu+0x194/0x270 security/keys/process_keys.c:500
 search_process_keyrings_rcu+0x2a/0x1c0 security/keys/process_keys.c:544
 lookup_user_key+0x774/0xb30 security/keys/process_keys.c:762
 keyctl_restrict_keyring+0x44/0x160 security/keys/keyctl.c:1661
 __do_sys_keyctl security/keys/keyctl.c:1823 [inline]
 __se_sys_keyctl security/keys/keyctl.c:1714 [inline]
 __x64_sys_keyctl+0x3a1/0x3e0 security/keys/keyctl.c:1714
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

write to 0xffff888126ad6a60 of 8 bytes by task 8788 on cpu 0:
 search_nested_keyrings+0x4ca/0x880 security/keys/keyring.c:861
 keyring_search_rcu+0x111/0x160 security/keys/keyring.c:926
 keyring_search+0x168/0x1f0 security/keys/keyring.c:968
 look_up_user_keyrings+0x140/0x4d0 security/keys/process_keys.c:102
 lookup_user_key+0x8d8/0xb30 security/keys/process_keys.c:670
 __do_sys_add_key security/keys/keyctl.c:124 [inline]
 __se_sys_add_key security/keys/keyctl.c:72 [inline]
 __x64_sys_add_key+0x1a2/0x380 security/keys/keyctl.c:72
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 8788 Comm: syz-executor.2 Not tainted 5.4.0-rc7+ #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/11/14 16:44 https://github.com/google/ktsan.git kcsan 7f2955e0d056 048f2d49 .config console log report ci2-upstream-kcsan-gce
2019/11/09 22:03 https://github.com/google/ktsan.git kcsan 94c006602e13 1e35461e .config console log report ci2-upstream-kcsan-gce
2019/11/03 05:59 https://github.com/google/ktsan.git kcsan 05f2236801fe d603afc9 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.