// https://syzkaller.appspot.com/bug?id=cad640317ca844be3b7adefd2f6c3f4a0ae4ac79 // autogenerated by syzkaller (https://github.com/google/syzkaller) #define _GNU_SOURCE #include #include #include #include #include #include #include #include #ifndef __NR_mkdir #define __NR_mkdir 39 #endif #ifndef __NR_mmap #define __NR_mmap 192 #endif #ifndef __NR_mount #define __NR_mount 21 #endif #ifndef __NR_syslog #define __NR_syslog 103 #endif #undef __NR_mmap #define __NR_mmap __NR_mmap2 int main(void) { syscall(__NR_mmap, 0x20000000, 0x1000000, 3, 0x32, -1, 0); syscall(__NR_syslog, 3, 0x200000c0, 0x1be3c41f); memcpy((void*)0x20000080, "./file0", 8); syscall(__NR_mkdir, 0x20000080, 0); memcpy((void*)0x20000580, "./file0", 8); memcpy((void*)0x200005c0, "./file0", 8); memcpy((void*)0x20000600, "btrfs", 6); syscall(__NR_mount, 0x20000580, 0x200005c0, 0x20000600, 0x4000, 0x20000640); return 0; }