syzbot


general protection fault in selinux_socket_unix_may_send

Status: auto-obsoleted due to no activity on 2023/06/24 04:52
Subsystems: selinux
[Documentation on labels]
Reported-by: syzbot+8a837fa30ef7cc2d748e@syzkaller.appspotmail.com
First crash: 396d, last: 396d

Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc0060000070: 0000 [#1] PREEMPT SMP KASAN
KASAN: probably user-memory-access in range [0x0000000300000380-0x0000000300000387]
CPU: 0 PID: 4422 Comm: klogd Not tainted 6.3.0-rc3-syzkaller-00322-g4bdec23f971b #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
RIP: 0010:selinux_socket_unix_may_send+0x101/0x270 security/selinux/hooks.c:4998
Code: c1 ea 03 80 3c 02 00 0f 85 61 01 00 00 48 b8 00 00 00 00 00 fc ff df 4c 8b 65 18 49 8d bc 24 80 04 00 00 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 30 01 00 00 49 8b ac 24 80 04 00 00 31 c0 b9 07
RSP: 0018:ffffc900030cfa38 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: 1ffff92000619f48 RCX: 0000000000000000
RDX: 0000000060000070 RSI: ffffffff83c9980e RDI: 0000000300000380
RBP: ffff88805a20d040 R08: 0000000000000003 R09: 0000000000000005
R10: 0000000000000002 R11: 0000000000000000 R12: 00000002ffffff00
R13: ffff88807f7ee4c0 R14: ffff88802756d700 R15: 0000000000000002
FS:  00007f995b784800(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007faa1c8e6fc0 CR3: 000000007e6ec000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 security_unix_may_send+0x4c/0xa0 security/security.c:2262
 unix_dgram_sendmsg+0xbc0/0x1950 net/unix/af_unix.c:2035
 sock_sendmsg_nosec net/socket.c:724 [inline]
 sock_sendmsg+0xde/0x190 net/socket.c:747
 __sys_sendto+0x23a/0x340 net/socket.c:2142
 __do_sys_sendto net/socket.c:2154 [inline]
 __se_sys_sendto net/socket.c:2150 [inline]
 __x64_sys_sendto+0xe1/0x1b0 net/socket.c:2150
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f995b9200ac
Code: 89 02 48 c7 c0 ff ff ff ff eb b8 0f 1f 00 41 89 ca 64 8b 04 25 18 00 00 00 85 c0 75 19 45 31 c9 45 31 c0 b8 2c 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 64 c3 0f 1f 00 55 48 83 ec 20 48 89 54 24 10
RSP: 002b:00007ffe8c94c498 EFLAGS: 00000246 ORIG_RAX: 000000000000002c
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f995b9200ac
RDX: 00000000000000a0 RSI: 0000555ef28a3140 RDI: 0000000000000003
RBP: 0000555ef28972c0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000004000 R11: 0000000000000246 R12: 0000000000000014
R13: 0000000000000001 R14: 00007f995ba9b77d R15: 00007ffe8c94c5a8
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:selinux_socket_unix_may_send+0x101/0x270 security/selinux/hooks.c:4998
Code: c1 ea 03 80 3c 02 00 0f 85 61 01 00 00 48 b8 00 00 00 00 00 fc ff df 4c 8b 65 18 49 8d bc 24 80 04 00 00 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 30 01 00 00 49 8b ac 24 80 04 00 00 31 c0 b9 07
RSP: 0018:ffffc900030cfa38 EFLAGS: 00010202

RAX: dffffc0000000000 RBX: 1ffff92000619f48 RCX: 0000000000000000
RDX: 0000000060000070 RSI: ffffffff83c9980e RDI: 0000000300000380
RBP: ffff88805a20d040 R08: 0000000000000003 R09: 0000000000000005
R10: 0000000000000002 R11: 0000000000000000 R12: 00000002ffffff00
R13: ffff88807f7ee4c0 R14: ffff88802756d700 R15: 0000000000000002
FS:  00007f995b784800(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007faa1c8e6fc0 CR3: 000000007e6ec000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	c1 ea 03             	shr    $0x3,%edx
   3:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1)
   7:	0f 85 61 01 00 00    	jne    0x16e
   d:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  14:	fc ff df
  17:	4c 8b 65 18          	mov    0x18(%rbp),%r12
  1b:	49 8d bc 24 80 04 00 	lea    0x480(%r12),%rdi
  22:	00
  23:	48 89 fa             	mov    %rdi,%rdx
  26:	48 c1 ea 03          	shr    $0x3,%rdx
* 2a:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1) <-- trapping instruction
  2e:	0f 85 30 01 00 00    	jne    0x164
  34:	49 8b ac 24 80 04 00 	mov    0x480(%r12),%rbp
  3b:	00
  3c:	31 c0                	xor    %eax,%eax
  3e:	b9                   	.byte 0xb9
  3f:	07                   	(bad)

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/03/26 04:51 upstream 4bdec23f971b fbf0499a .config console log report info ci-upstream-kasan-gce-selinux-root general protection fault in selinux_socket_unix_may_send
* Struck through repros no longer work on HEAD.