// https://syzkaller.appspot.com/bug?id=9c74fee9d6ceabfff73819e94328a18723217cf9 // autogenerated by syzkaller (https://github.com/google/syzkaller) #define _GNU_SOURCE #include #include #include #include #include #include #include #include #include #include uint64_t r[2] = {0xffffffffffffffff, 0xffffffffffffffff}; int main(void) { syscall(SYS_mmap, 0x20000000ul, 0x1000000ul, 7ul, 0x1012ul, -1, 0ul); intptr_t res = 0; memcpy((void*)0x20000140, "/dev/crypto\000", 12); res = syscall(SYS_openat, 0xffffffffffffff9cul, 0x20000140ul, 0ul, 0ul); if (res != -1) r[0] = res; *(uint32_t*)0x20000440 = 0x10; *(uint32_t*)0x20000444 = 0xf; *(uint32_t*)0x20000448 = 1; *(uint64_t*)0x20000450 = 0x20000380; memset((void*)0x20000380, 60, 1); *(uint32_t*)0x20000458 = 0; *(uint64_t*)0x20000460 = 0; *(uint32_t*)0x20000468 = 0; *(uint32_t*)0x2000046c = 0xfdffffff; *(uint32_t*)0x20000470 = 0; *(uint32_t*)0x20000474 = 0; *(uint32_t*)0x20000478 = 0; *(uint32_t*)0x2000047c = 0; syscall(SYS_ioctl, r[0], 0xc040636aul, 0x20000440ul); res = syscall(SYS_dup2, r[0], r[0]); if (res != -1) r[1] = res; *(uint32_t*)0x200000c0 = 0; *(uint16_t*)0x200000c4 = 1; *(uint16_t*)0x200000c6 = 5; *(uint32_t*)0x200000c8 = 0x200; *(uint32_t*)0x200000cc = 0xa; *(uint32_t*)0x200000d0 = 0; *(uint64_t*)0x200000d8 = 0x20000280; *(uint64_t*)0x200000e0 = 0; *(uint64_t*)0x200000e8 = 0x20000480; *(uint64_t*)0x200000f0 = 0x20000180; *(uint64_t*)0x200000f8 = 0; syscall(SYS_ioctl, r[1], 0xc040636dul, 0x200000c0ul); return 0; }