// https://syzkaller.appspot.com/bug?id=729e4916dabef2efe7f4b4ea31a476284cac9336 // autogenerated by syzkaller (https://github.com/google/syzkaller) #define _GNU_SOURCE #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include static void sleep_ms(uint64_t ms) { usleep(ms * 1000); } static uint64_t current_time_ms(void) { struct timespec ts; if (clock_gettime(CLOCK_MONOTONIC, &ts)) exit(1); return (uint64_t)ts.tv_sec * 1000 + (uint64_t)ts.tv_nsec / 1000000; } #define BITMASK(bf_off, bf_len) (((1ull << (bf_len)) - 1) << (bf_off)) #define STORE_BY_BITMASK(type, htobe, addr, val, bf_off, bf_len) \ *(type*)(addr) = \ htobe((htobe(*(type*)(addr)) & ~BITMASK((bf_off), (bf_len))) | \ (((type)(val) << (bf_off)) & BITMASK((bf_off), (bf_len)))) static bool write_file(const char* file, const char* what, ...) { char buf[1024]; va_list args; va_start(args, what); vsnprintf(buf, sizeof(buf), what, args); va_end(args); buf[sizeof(buf) - 1] = 0; int len = strlen(buf); int fd = open(file, O_WRONLY | O_CLOEXEC); if (fd == -1) return false; if (write(fd, buf, len) != len) { int err = errno; close(fd); errno = err; return false; } close(fd); return true; } static void kill_and_wait(int pid, int* status) { kill(-pid, SIGKILL); kill(pid, SIGKILL); for (int i = 0; i < 100; i++) { if (waitpid(-1, status, WNOHANG | __WALL) == pid) return; usleep(1000); } DIR* dir = opendir("/sys/fs/fuse/connections"); if (dir) { for (;;) { struct dirent* ent = readdir(dir); if (!ent) break; if (strcmp(ent->d_name, ".") == 0 || strcmp(ent->d_name, "..") == 0) continue; char abort[300]; snprintf(abort, sizeof(abort), "/sys/fs/fuse/connections/%s/abort", ent->d_name); int fd = open(abort, O_WRONLY); if (fd == -1) { continue; } if (write(fd, abort, 1) < 0) { } close(fd); } closedir(dir); } else { } while (waitpid(-1, status, __WALL) != pid) { } } static void setup_test() { prctl(PR_SET_PDEATHSIG, SIGKILL, 0, 0, 0); setpgrp(); write_file("/proc/self/oom_score_adj", "1000"); } static void execute_one(void); #define WAIT_FLAGS __WALL static void loop(void) { int iter = 0; for (;; iter++) { int pid = fork(); if (pid < 0) exit(1); if (pid == 0) { setup_test(); execute_one(); exit(0); } int status = 0; uint64_t start = current_time_ms(); for (;;) { sleep_ms(10); if (waitpid(-1, &status, WNOHANG | WAIT_FLAGS) == pid) break; if (current_time_ms() - start < 5000) continue; kill_and_wait(pid, &status); break; } } } uint64_t r[3] = {0xffffffffffffffff, 0xffffffffffffffff, 0xffffffffffffffff}; void execute_one(void) { intptr_t res = 0; if (write(1, "executing program\n", sizeof("executing program\n") - 1)) { } // perf_event_open arguments: [ // attr: ptr[in, perf_event_attr] { // perf_event_attr { // type: perf_event_type = 0x2 (4 bytes) // size: len = 0x80 (4 bytes) // config0: int8 = 0x29 (1 bytes) // config1: int8 = 0x1 (1 bytes) // config2: int8 = 0x0 (1 bytes) // config3: int8 = 0x0 (1 bytes) // config4: const = 0x0 (4 bytes) // sample_freq: int64 = 0x4 (8 bytes) // sample_type: perf_sample_type = 0x510 (8 bytes) // read_format: perf_read_format = 0x0 (8 bytes) // disabled: int64 = 0x0 (0 bytes) // inherit: int64 = 0x0 (0 bytes) // pinned: int64 = 0x0 (0 bytes) // exclusive: int64 = 0x0 (0 bytes) // exclude_user: int64 = 0x0 (0 bytes) // exclude_kernel: int64 = 0x0 (0 bytes) // exclude_hv: int64 = 0x0 (0 bytes) // exclude_idle: int64 = 0x0 (0 bytes) // mmap: int64 = 0x0 (0 bytes) // comm: int64 = 0x0 (0 bytes) // freq: int64 = 0x0 (0 bytes) // inherit_stat: int64 = 0x0 (0 bytes) // enable_on_exec: int64 = 0x0 (0 bytes) // task: int64 = 0x0 (0 bytes) // watermark: int64 = 0x0 (0 bytes) // precise_ip: int64 = 0x0 (0 bytes) // mmap_data: int64 = 0x0 (0 bytes) // sample_id_all: int64 = 0x0 (0 bytes) // exclude_host: int64 = 0x0 (0 bytes) // exclude_guest: int64 = 0x0 (0 bytes) // exclude_callchain_kernel: int64 = 0x0 (0 bytes) // exclude_callchain_user: int64 = 0x0 (0 bytes) // mmap2: int64 = 0x0 (0 bytes) // comm_exec: int64 = 0x0 (0 bytes) // use_clockid: int64 = 0x0 (0 bytes) // context_switch: int64 = 0x0 (0 bytes) // write_backward: int64 = 0x0 (0 bytes) // namespaces: int64 = 0x0 (0 bytes) // ksymbol: int64 = 0x0 (0 bytes) // bpf_event: int64 = 0x0 (0 bytes) // aux_output: int64 = 0x0 (0 bytes) // cgroup: int64 = 0x0 (0 bytes) // text_poke: int64 = 0x0 (0 bytes) // build_id: int64 = 0x0 (0 bytes) // inherit_thread: int64 = 0x0 (0 bytes) // remove_on_exec: int64 = 0x0 (0 bytes) // sigtrap: int64 = 0x0 (0 bytes) // __reserved_1: const = 0x0 (8 bytes) // wakeup_events: int32 = 0x2 (4 bytes) // bp_type: perf_bp_type = 0x2 (4 bytes) // bp_config: union perf_bp_config { // perf_config_ext: perf_config_ext { // config1: int64 = 0xce5 (8 bytes) // config2: int64 = 0xc (8 bytes) // } // } // branch_sample_type: perf_branch_sample_type = 0x0 (8 bytes) // sample_regs_user: int64 = 0xfffe (8 bytes) // sample_stack_user: int32 = 0x0 (4 bytes) // clockid: clock_type = 0x3 (4 bytes) // sample_regs_intr: int64 = 0x8 (8 bytes) // aux_watermark: int32 = 0x20005 (4 bytes) // sample_max_stack: int16 = 0x0 (2 bytes) // __reserved_2: const = 0x0 (2 bytes) // aux_sample_size: int32 = 0x0 (4 bytes) // __reserved_3: const = 0x0 (4 bytes) // sig_data: int64 = 0x3 (8 bytes) // } // } // pid: pid (resource) // cpu: intptr = 0xffffffffffffffff (8 bytes) // group: fd_perf (resource) // flags: perf_flags = 0x2 (8 bytes) // ] // returns fd_perf *(uint32_t*)0x200000000340 = 2; *(uint32_t*)0x200000000344 = 0x80; *(uint8_t*)0x200000000348 = 0x29; *(uint8_t*)0x200000000349 = 1; *(uint8_t*)0x20000000034a = 0; *(uint8_t*)0x20000000034b = 0; *(uint32_t*)0x20000000034c = 0; *(uint64_t*)0x200000000350 = 4; *(uint64_t*)0x200000000358 = 0x510; *(uint64_t*)0x200000000360 = 0; STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 0, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 1, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 2, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 3, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 4, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 5, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 6, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 7, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 8, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 9, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 10, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 11, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 12, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 13, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 14, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 15, 2); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 17, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 18, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 19, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 20, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 21, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 22, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 23, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 24, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 25, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 26, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 27, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 28, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 29, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 30, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 31, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 32, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 33, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 34, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 35, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 36, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 37, 1); STORE_BY_BITMASK(uint64_t, , 0x200000000368, 0, 38, 26); *(uint32_t*)0x200000000370 = 2; *(uint32_t*)0x200000000374 = 2; *(uint64_t*)0x200000000378 = 0xce5; *(uint64_t*)0x200000000380 = 0xc; *(uint64_t*)0x200000000388 = 0; *(uint64_t*)0x200000000390 = 0xfffe; *(uint32_t*)0x200000000398 = 0; *(uint32_t*)0x20000000039c = 3; *(uint64_t*)0x2000000003a0 = 8; *(uint32_t*)0x2000000003a8 = 0x20005; *(uint16_t*)0x2000000003ac = 0; *(uint16_t*)0x2000000003ae = 0; *(uint32_t*)0x2000000003b0 = 0; *(uint32_t*)0x2000000003b4 = 0; *(uint64_t*)0x2000000003b8 = 3; syscall(__NR_perf_event_open, /*attr=*/0x200000000340ul, /*pid=*/0, /*cpu=*/(intptr_t)-1, /*group=*/(intptr_t)-1, /*flags=PERF_FLAG_FD_OUTPUT*/ 2ul); // perf_event_open arguments: [ // attr: ptr[in, perf_event_attr] { // perf_event_attr { // type: perf_event_type = 0x2 (4 bytes) // size: len = 0x80 (4 bytes) // config0: int8 = 0x8a (1 bytes) // config1: int8 = 0x3 (1 bytes) // config2: int8 = 0x0 (1 bytes) // config3: int8 = 0x3 (1 bytes) // config4: const = 0x0 (4 bytes) // sample_freq: int64 = 0x10000000000 (8 bytes) // sample_type: perf_sample_type = 0x8880 (8 bytes) // read_format: perf_read_format = 0x6 (8 bytes) // disabled: int64 = 0x0 (0 bytes) // inherit: int64 = 0x0 (0 bytes) // pinned: int64 = 0x0 (0 bytes) // exclusive: int64 = 0x0 (0 bytes) // exclude_user: int64 = 0x0 (0 bytes) // exclude_kernel: int64 = 0x0 (0 bytes) // exclude_hv: int64 = 0x0 (0 bytes) // exclude_idle: int64 = 0x0 (0 bytes) // mmap: int64 = 0x0 (0 bytes) // comm: int64 = 0x0 (0 bytes) // freq: int64 = 0x0 (0 bytes) // inherit_stat: int64 = 0x0 (0 bytes) // enable_on_exec: int64 = 0x0 (0 bytes) // task: int64 = 0x0 (0 bytes) // watermark: int64 = 0x0 (0 bytes) // precise_ip: int64 = 0x0 (0 bytes) // mmap_data: int64 = 0x0 (0 bytes) // sample_id_all: int64 = 0x0 (0 bytes) // exclude_host: int64 = 0x0 (0 bytes) // exclude_guest: int64 = 0x0 (0 bytes) // exclude_callchain_kernel: int64 = 0x0 (0 bytes) // exclude_callchain_user: int64 = 0x0 (0 bytes) // mmap2: int64 = 0x0 (0 bytes) // comm_exec: int64 = 0x0 (0 bytes) // use_clockid: int64 = 0x0 (0 bytes) // context_switch: int64 = 0x0 (0 bytes) // write_backward: int64 = 0x0 (0 bytes) // namespaces: int64 = 0x0 (0 bytes) // ksymbol: int64 = 0x0 (0 bytes) // bpf_event: int64 = 0x0 (0 bytes) // aux_output: int64 = 0x0 (0 bytes) // cgroup: int64 = 0x0 (0 bytes) // text_poke: int64 = 0x0 (0 bytes) // build_id: int64 = 0x0 (0 bytes) // inherit_thread: int64 = 0x0 (0 bytes) // remove_on_exec: int64 = 0x0 (0 bytes) // sigtrap: int64 = 0x0 (0 bytes) // __reserved_1: const = 0x0 (8 bytes) // wakeup_events: int32 = 0x3ff (4 bytes) // bp_type: perf_bp_type = 0x4 (4 bytes) // bp_config: union perf_bp_config { // perf_bp: perf_bp { // bp_addr: nil // bp_len: perf_bp_lens = 0x6 (8 bytes) // } // } // branch_sample_type: perf_branch_sample_type = 0x4008 (8 bytes) // sample_regs_user: int64 = 0x3 (8 bytes) // sample_stack_user: int32 = 0x0 (4 bytes) // clockid: clock_type = 0x6 (4 bytes) // sample_regs_intr: int64 = 0x7 (8 bytes) // aux_watermark: int32 = 0x4 (4 bytes) // sample_max_stack: int16 = 0x2 (2 bytes) // __reserved_2: const = 0x0 (2 bytes) // aux_sample_size: int32 = 0x3 (4 bytes) // __reserved_3: const = 0x0 (4 bytes) // sig_data: int64 = 0x0 (8 bytes) // } // } // pid: pid (resource) // cpu: intptr = 0x0 (8 bytes) // group: fd_perf (resource) // flags: perf_flags = 0x18 (8 bytes) // ] // returns fd_perf *(uint32_t*)0x200000000380 = 2; *(uint32_t*)0x200000000384 = 0x80; *(uint8_t*)0x200000000388 = 0x8a; *(uint8_t*)0x200000000389 = 3; *(uint8_t*)0x20000000038a = 0; *(uint8_t*)0x20000000038b = 3; *(uint32_t*)0x20000000038c = 0; *(uint64_t*)0x200000000390 = 0x10000000000; *(uint64_t*)0x200000000398 = 0x8880; *(uint64_t*)0x2000000003a0 = 6; STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 0, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 1, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 2, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 3, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 4, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 5, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 6, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 7, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 8, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 9, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 10, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 11, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 12, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 13, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 14, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 15, 2); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 17, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 18, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 19, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 20, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 21, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 22, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 23, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 24, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 25, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 26, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 27, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 28, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 29, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 30, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 31, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 32, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 33, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 34, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 35, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 36, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 37, 1); STORE_BY_BITMASK(uint64_t, , 0x2000000003a8, 0, 38, 26); *(uint32_t*)0x2000000003b0 = 0x3ff; *(uint32_t*)0x2000000003b4 = 4; *(uint64_t*)0x2000000003b8 = 0; *(uint64_t*)0x2000000003c0 = 6; *(uint64_t*)0x2000000003c8 = 0x4008; *(uint64_t*)0x2000000003d0 = 3; *(uint32_t*)0x2000000003d8 = 0; *(uint32_t*)0x2000000003dc = 6; *(uint64_t*)0x2000000003e0 = 7; *(uint32_t*)0x2000000003e8 = 4; *(uint16_t*)0x2000000003ec = 2; *(uint16_t*)0x2000000003ee = 0; *(uint32_t*)0x2000000003f0 = 3; *(uint32_t*)0x2000000003f4 = 0; *(uint64_t*)0x2000000003f8 = 0; syscall(__NR_perf_event_open, /*attr=*/0x200000000380ul, /*pid=*/0, /*cpu=*/0ul, /*group=*/(intptr_t)-1, /*flags=PERF_FLAG_FD_CLOEXEC|0x10*/ 0x18ul); // socketpair$unix arguments: [ // domain: const = 0x1 (8 bytes) // type: unix_socket_type = 0x5 (8 bytes) // proto: const = 0x0 (4 bytes) // fds: ptr[out, unix_pair] { // unix_pair { // fd0: sock_unix (resource) // fd1: sock_unix (resource) // } // } // ] res = syscall(__NR_socketpair, /*domain=*/1ul, /*type=SOCK_SEQPACKET*/ 5ul, /*proto=*/0, /*fds=*/0x2000000029c0ul); if (res != -1) { r[0] = *(uint32_t*)0x2000000029c0; r[1] = *(uint32_t*)0x2000000029c4; } // close arguments: [ // fd: fd (resource) // ] syscall(__NR_close, /*fd=*/r[1]); // recvmsg$unix arguments: [ // fd: sock_unix (resource) // msg: ptr[inout, recv_msghdr_un] { // recv_msghdr_un { // addr: nil // addrlen: len = 0x4b (4 bytes) // pad = 0x0 (4 bytes) // vec: nil // vlen: len = 0x0 (8 bytes) // ctrl: ptr[out, array[cmsghdr_un]] { // array[cmsghdr_un] { // union cmsghdr_un { // rights: cmsghdr_t[SOL_SOCKET, SCM_RIGHTS, array[fd]] { // unaligned: cmsghdr_unaligned[SOL_SOCKET, SCM_RIGHTS, // array[fd]] { // cmsg_len: len = 0x14 (8 bytes) // cmsg_level: const = 0x1 (4 bytes) // cmsg_type: const = 0x1 (4 bytes) // data: array[fd] { // fd (resource) // } // } // } // } // } // } // ctrllen: bytesize = 0x18 (8 bytes) // f: const = 0x0 (4 bytes) // pad = 0x0 (4 bytes) // } // } // f: recv_flags = 0x0 (8 bytes) // ] *(uint64_t*)0x200000000400 = 0; *(uint32_t*)0x200000000408 = 0x4b; *(uint64_t*)0x200000000410 = 0; *(uint64_t*)0x200000000418 = 0; *(uint64_t*)0x200000000420 = 0x2000000003c0; *(uint64_t*)0x200000000428 = 0x18; *(uint32_t*)0x200000000430 = 0; res = syscall(__NR_recvmsg, /*fd=*/r[0], /*msg=*/0x200000000400ul, /*f=*/0ul, 0); if (res != -1) r[2] = *(uint32_t*)0x2000000003d0; // ioctl$PERF_EVENT_IOC_SET_FILTER arguments: [ // fd: fd_perf (resource) // cmd: const = 0x5452 (4 bytes) // filter: ptr[in, buffer] { // buffer: {02 3b e5 08 00 1c 9c 00 00 00 00 00 00 91 ec 42 dc 5a e5 bd // 24 05 90 a9 f3 c7 cb b7 f0 a1 3b 23 98 39 e9 12 df 5e 36 54 df cd 02 // c5 b0 ba 12 27 51 58 70 09 fc f3 01 02 bc bf c0 f0 10 ee d3 5c 79 79 // a4 f9 e8 00 dd e9 37 20 30 5f e4 5d 57 f7 7e ac 56 4b c9 74 9e 2b 3a // 85 ef 94 0e 19 9c 56 5b 4e 2e eb 9f 4a 3e d9 99 88 d8 dd b8 59 c3 24 // c6 93 0b 04 52 45 59 f4 ea f2 cd cd 2e 16 86 31 a1 0b 8d 8e 84 52 a6 // 83 84 c0 01 65 c3 c8 cc 3f c8 3f 19 b2 a2 e1 ac 3c e9 66 11 ff 33 c7 // 19 9e 19 f5 2d fe bd ae bb 52 82 16 f9 15 53 03 55 e0 d8 74 e3 25 39 // 36} (length 0xb6) // } // ] memcpy( (void*)0x2000000006c0, "\002;\345\b\000\034\234\000\000\000\000\000\000\221\354B\334Z\345\275$" "\005\220\251\363\307\313\267\360\241;#\2309\351\022\337^" "6T\337\315\002\305\260\272\022\'QXp\t\374\363\001\002\274\277\300\360" "\020\356\323\\yy\244\371\350\000\335\3517 " "0_\344]W\367~\254VK\311t\236+:\205\357\224\016\031\234V[N.\353\237J>" "\331\231\210\330\335\270Y\303$\306\223\v\004REY\364\352\362\315\315." "\026\2061\241\v\215\216\204R\246\203\204\300\001e\303\310\314?\310?" "\031\262\242\341\254<\351f\021\3773\307\031\236\031\365-" "\376\275\256\273R\202\026\371\025S\003U\340\330t\343%96", 182); syscall(__NR_ioctl, /*fd=*/r[2], /*cmd=*/0x5452, /*filter=*/0x2000000006c0ul); } int main(void) { syscall(__NR_mmap, /*addr=*/0x1ffffffff000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/(intptr_t)-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x200000000000ul, /*len=*/0x1000000ul, /*prot=PROT_WRITE|PROT_READ|PROT_EXEC*/ 7ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/(intptr_t)-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x200001000000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/(intptr_t)-1, /*offset=*/0ul); const char* reason; (void)reason; loop(); return 0; }