// https://syzkaller.appspot.com/bug?id=a743c25030c86d41c8b2cf6a0651603155c48245 // autogenerated by syzkaller (https://github.com/google/syzkaller) #define _GNU_SOURCE #include #include #include #include #include #include #include #include #ifndef __NR_mmap #define __NR_mmap 192 #endif #ifndef __NR_openat #define __NR_openat 295 #endif #ifndef __NR_write #define __NR_write 4 #endif #undef __NR_mmap #define __NR_mmap __NR_mmap2 uint64_t r[1] = {0xffffffffffffffff}; int main(void) { syscall(__NR_mmap, 0x20000000, 0x1000000, 3, 0x32, -1, 0); intptr_t res = 0; memcpy((void*)0x20001780, "/selinux/load\000", 14); res = syscall(__NR_openat, 0xffffff9c, 0x20001780, 2, 0); if (res != -1) r[0] = res; memcpy((void*)0x20000100, "\x8c\xff\x7c\xf9\x08\x00\x00\x00\x53\x45\x20\x4c\x69\x6e\x75\x78\x12" "\x00\x00\x00\x00\xc4\x6f\x00\x06\x00\x00\x00\x07\x00\x00\x00\x3c\x9f" "\x0b\x00\x02\x00\x00\x00\x75\xa4\x57\x53\xac\x30\xd8\x68\x09\x8f\xe8" "\xba\xb7\x29\xe0\xc9\x25\x40\x5a\xb6\x97\x55\x68\xad\x4f\x17", 66); syscall(__NR_write, (intptr_t)r[0], 0x20000100, 0xff); return 0; }