lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CALAgD-72YS4AYHcKNegajDoehaqYQEfHFhtxPb2s8y=A0jXDag@mail.gmail.com>
Date: Wed, 28 Aug 2024 16:48:58 -0700
From: Xingyu Li <xli399@....edu>
To: kuba@...nel.org, davem@...emloft.net, edumazet@...gle.com, 
	pabeni@...hat.com, netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Cc: Yu Hao <yhao016@....edu>
Subject: BUG: unable to handle kernel paging request in bcmp

Hi,

We found a bug in Linux 6.10 using syzkaller. It is possibly a page fault bug.
The bug report is as follows, but unfortunately there is no generated
syzkaller reproducer.

Bug report:

BUG: unable to handle page fault for address: ffffffffffffffe0
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD d936067 P4D d936067 PUD d938067 PMD 0
Oops: Oops: 0000 [#1] PREEMPT SMP KASAN PTI
CPU: 0 PID: 8474 Comm: kworker/0:5 Not tainted 6.10.0 #13
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.15.0-1 04/01/2014
Workqueue: events nsim_fib_event_work
RIP: 0010:memcmp lib/string.c:665 [inline]
RIP: 0010:bcmp+0x50/0x1e0 lib/string.c:697
Code: 00 00 4d 89 fd 4c 89 e3 48 8d 6b 07 48 89 d8 48 c1 e8 03 0f b6
04 10 84 c0 75 65 48 89 e8 48 c1 e8 03 0f b6 04 10 84 c0 75 7b <49> 8b
34 24 49 8d 6d 07 4c 89 e8 48 c1 e8 03 0f b6 04 10 84 c0 0f
RSP: 0018:ffffc9000fb57520 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffffffffffe0 RCX: dffffc0000000000
RDX: dffffc0000000000 RSI: ffffc9000fb579a0 RDI: ffffffffffffffe0
RBP: ffffffffffffffe7 R08: ffffffff869e3a06 R09: ffffffff84569d43
R10: 0000000000000003 R11: 0000000000000000 R12: ffffffffffffffe0
R13: ffffc9000fb579a0 R14: 000000000000001c R15: ffffc9000fb579a0
FS:  0000000000000000(0000) GS:ffff888063a00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffe0 CR3: 000000004521a000 CR4: 0000000000350ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 rhashtable_compare include/linux/rhashtable.h:585 [inline]
 __rhashtable_lookup include/linux/rhashtable.h:610 [inline]
 rhashtable_lookup include/linux/rhashtable.h:646 [inline]
 rhashtable_lookup_fast+0x51b/0x9a0 include/linux/rhashtable.h:672
 nsim_fib_rt_lookup drivers/net/netdevsim/fib.c:271 [inline]
 nsim_fib6_rt_lookup drivers/net/netdevsim/fib.c:594 [inline]
 nsim_fib6_rt_insert drivers/net/netdevsim/fib.c:757 [inline]
 nsim_fib6_event drivers/net/netdevsim/fib.c:856 [inline]
 nsim_fib_event drivers/net/netdevsim/fib.c:889 [inline]
 nsim_fib_event_work+0x28ca/0x4050 drivers/net/netdevsim/fib.c:1492
 process_one_work kernel/workqueue.c:3248 [inline]
 process_scheduled_works+0x977/0x1410 kernel/workqueue.c:3329
 worker_thread+0xaa0/0x1020 kernel/workqueue.c:3409
 kthread+0x2eb/0x380 kernel/kthread.c:389
 ret_from_fork+0x49/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:244
 </TASK>
Modules linked in:
CR2: ffffffffffffffe0
---[ end trace 0000000000000000 ]---
RIP: 0010:memcmp lib/string.c:665 [inline]
RIP: 0010:bcmp+0x50/0x1e0 lib/string.c:697
Code: 00 00 4d 89 fd 4c 89 e3 48 8d 6b 07 48 89 d8 48 c1 e8 03 0f b6
04 10 84 c0 75 65 48 89 e8 48 c1 e8 03 0f b6 04 10 84 c0 75 7b <49> 8b
34 24 49 8d 6d 07 4c 89 e8 48 c1 e8 03 0f b6 04 10 84 c0 0f
RSP: 0018:ffffc9000fb57520 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffffffffffe0 RCX: dffffc0000000000
RDX: dffffc0000000000 RSI: ffffc9000fb579a0 RDI: ffffffffffffffe0
RBP: ffffffffffffffe7 R08: ffffffff869e3a06 R09: ffffffff84569d43
R10: 0000000000000003 R11: 0000000000000000 R12: ffffffffffffffe0
R13: ffffc9000fb579a0 R14: 000000000000001c R15: ffffc9000fb579a0
FS:  0000000000000000(0000) GS:ffff888063a00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffe0 CR3: 000000004521a000 CR4: 0000000000350ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0: 00 00                 add    %al,(%rax)
   2: 4d 89 fd             mov    %r15,%r13
   5: 4c 89 e3             mov    %r12,%rbx
   8: 48 8d 6b 07           lea    0x7(%rbx),%rbp
   c: 48 89 d8             mov    %rbx,%rax
   f: 48 c1 e8 03           shr    $0x3,%rax
  13: 0f b6 04 10           movzbl (%rax,%rdx,1),%eax
  17: 84 c0                 test   %al,%al
  19: 75 65                 jne    0x80
  1b: 48 89 e8             mov    %rbp,%rax
  1e: 48 c1 e8 03           shr    $0x3,%rax
  22: 0f b6 04 10           movzbl (%rax,%rdx,1),%eax
  26: 84 c0                 test   %al,%al
  28: 75 7b                 jne    0xa5
* 2a: 49 8b 34 24           mov    (%r12),%rsi <-- trapping instruction
  2e: 49 8d 6d 07           lea    0x7(%r13),%rbp
  32: 4c 89 e8             mov    %r13,%rax
  35: 48 c1 e8 03           shr    $0x3,%rax
  39: 0f b6 04 10           movzbl (%rax,%rdx,1),%eax
  3d: 84 c0                 test   %al,%al
  3f: 0f                   .byte 0xf



-- 
Yours sincerely,
Xingyu

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ