| // KASAN: use-after-free Read in kfree_skb |
| // https://syzkaller.appspot.com/bug?id=2efb3f8aeca9b3509b31ea45d339cddc928c9a6a |
| // status:open |
| // autogenerated by syzkaller (https://github.com/google/syzkaller) |
| |
| #define _GNU_SOURCE |
| |
| #include <endian.h> |
| #include <stdint.h> |
| #include <stdio.h> |
| #include <stdlib.h> |
| #include <string.h> |
| #include <sys/syscall.h> |
| #include <sys/types.h> |
| #include <unistd.h> |
| |
| uint64_t r[1] = {0xffffffffffffffff}; |
| |
| int main(void) |
| { |
| syscall(__NR_mmap, 0x20000000, 0x1000000, 3, 0x32, -1, 0); |
| intptr_t res = 0; |
| memcpy((void*)0x20000040, "/dev/ptmx\000", 10); |
| res = syscall(__NR_openat, 0xffffffffffffff9c, 0x20000040, 0, 0); |
| if (res != -1) |
| r[0] = res; |
| *(uint32_t*)0x200000c0 = 0xf; |
| syscall(__NR_ioctl, r[0], 0x5423, 0x200000c0); |
| syscall(__NR_ioctl, r[0], 0x400455c8, 1); |
| syscall(__NR_unshare, 0x40000000); |
| return 0; |
| } |