// https://syzkaller.appspot.com/bug?id=a804169bb1a5b3ed9fcee2914b4d733f16528cff // 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 #include #include #include #include #include #include #include #include #ifndef __NR_memfd_create #define __NR_memfd_create 319 #endif static unsigned long long procid; 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; } static void use_temporary_dir(void) { char tmpdir_template[] = "./syzkaller.XXXXXX"; char* tmpdir = mkdtemp(tmpdir_template); if (!tmpdir) exit(1); if (chmod(tmpdir, 0777)) exit(1); if (chdir(tmpdir)) exit(1); } static void thread_start(void* (*fn)(void*), void* arg) { pthread_t th; pthread_attr_t attr; pthread_attr_init(&attr); pthread_attr_setstacksize(&attr, 128 << 10); int i = 0; for (; i < 100; i++) { if (pthread_create(&th, &attr, fn, arg) == 0) { pthread_attr_destroy(&attr); return; } if (errno == EAGAIN) { usleep(50); continue; } break; } exit(1); } typedef struct { int state; } event_t; static void event_init(event_t* ev) { ev->state = 0; } static void event_reset(event_t* ev) { ev->state = 0; } static void event_set(event_t* ev) { if (ev->state) exit(1); __atomic_store_n(&ev->state, 1, __ATOMIC_RELEASE); syscall(SYS_futex, &ev->state, FUTEX_WAKE | FUTEX_PRIVATE_FLAG, 1000000); } static void event_wait(event_t* ev) { while (!__atomic_load_n(&ev->state, __ATOMIC_ACQUIRE)) syscall(SYS_futex, &ev->state, FUTEX_WAIT | FUTEX_PRIVATE_FLAG, 0, 0); } static int event_isset(event_t* ev) { return __atomic_load_n(&ev->state, __ATOMIC_ACQUIRE); } static int event_timedwait(event_t* ev, uint64_t timeout) { uint64_t start = current_time_ms(); uint64_t now = start; for (;;) { uint64_t remain = timeout - (now - start); struct timespec ts; ts.tv_sec = remain / 1000; ts.tv_nsec = (remain % 1000) * 1000 * 1000; syscall(SYS_futex, &ev->state, FUTEX_WAIT | FUTEX_PRIVATE_FLAG, 0, &ts); if (__atomic_load_n(&ev->state, __ATOMIC_ACQUIRE)) return 1; now = current_time_ms(); if (now - start > timeout) return 0; } } 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; } //% This code is derived from puff.{c,h}, found in the zlib development. The //% original files come with the following copyright notice: //% Copyright (C) 2002-2013 Mark Adler, all rights reserved //% version 2.3, 21 Jan 2013 //% This software is provided 'as-is', without any express or implied //% warranty. In no event will the author be held liable for any damages //% arising from the use of this software. //% Permission is granted to anyone to use this software for any purpose, //% including commercial applications, and to alter it and redistribute it //% freely, subject to the following restrictions: //% 1. The origin of this software must not be misrepresented; you must not //% claim that you wrote the original software. If you use this software //% in a product, an acknowledgment in the product documentation would be //% appreciated but is not required. //% 2. Altered source versions must be plainly marked as such, and must not be //% misrepresented as being the original software. //% 3. This notice may not be removed or altered from any source distribution. //% Mark Adler madler@alumni.caltech.edu //% BEGIN CODE DERIVED FROM puff.{c,h} #define MAXBITS 15 #define MAXLCODES 286 #define MAXDCODES 30 #define MAXCODES (MAXLCODES + MAXDCODES) #define FIXLCODES 288 struct puff_state { unsigned char* out; unsigned long outlen; unsigned long outcnt; const unsigned char* in; unsigned long inlen; unsigned long incnt; int bitbuf; int bitcnt; jmp_buf env; }; static int puff_bits(struct puff_state* s, int need) { long val = s->bitbuf; while (s->bitcnt < need) { if (s->incnt == s->inlen) longjmp(s->env, 1); val |= (long)(s->in[s->incnt++]) << s->bitcnt; s->bitcnt += 8; } s->bitbuf = (int)(val >> need); s->bitcnt -= need; return (int)(val & ((1L << need) - 1)); } static int puff_stored(struct puff_state* s) { s->bitbuf = 0; s->bitcnt = 0; if (s->incnt + 4 > s->inlen) return 2; unsigned len = s->in[s->incnt++]; len |= s->in[s->incnt++] << 8; if (s->in[s->incnt++] != (~len & 0xff) || s->in[s->incnt++] != ((~len >> 8) & 0xff)) return -2; if (s->incnt + len > s->inlen) return 2; if (s->outcnt + len > s->outlen) return 1; for (; len--; s->outcnt++, s->incnt++) { if (s->in[s->incnt]) s->out[s->outcnt] = s->in[s->incnt]; } return 0; } struct puff_huffman { short* count; short* symbol; }; static int puff_decode(struct puff_state* s, const struct puff_huffman* h) { int first = 0; int index = 0; int bitbuf = s->bitbuf; int left = s->bitcnt; int code = first = index = 0; int len = 1; short* next = h->count + 1; while (1) { while (left--) { code |= bitbuf & 1; bitbuf >>= 1; int count = *next++; if (code - count < first) { s->bitbuf = bitbuf; s->bitcnt = (s->bitcnt - len) & 7; return h->symbol[index + (code - first)]; } index += count; first += count; first <<= 1; code <<= 1; len++; } left = (MAXBITS + 1) - len; if (left == 0) break; if (s->incnt == s->inlen) longjmp(s->env, 1); bitbuf = s->in[s->incnt++]; if (left > 8) left = 8; } return -10; } static int puff_construct(struct puff_huffman* h, const short* length, int n) { int len; for (len = 0; len <= MAXBITS; len++) h->count[len] = 0; int symbol; for (symbol = 0; symbol < n; symbol++) (h->count[length[symbol]])++; if (h->count[0] == n) return 0; int left = 1; for (len = 1; len <= MAXBITS; len++) { left <<= 1; left -= h->count[len]; if (left < 0) return left; } short offs[MAXBITS + 1]; offs[1] = 0; for (len = 1; len < MAXBITS; len++) offs[len + 1] = offs[len] + h->count[len]; for (symbol = 0; symbol < n; symbol++) if (length[symbol] != 0) h->symbol[offs[length[symbol]]++] = symbol; return left; } static int puff_codes(struct puff_state* s, const struct puff_huffman* lencode, const struct puff_huffman* distcode) { static const short lens[29] = {3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258}; static const short lext[29] = {0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0}; static const short dists[30] = { 1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577}; static const short dext[30] = {0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13}; int symbol; do { symbol = puff_decode(s, lencode); if (symbol < 0) return symbol; if (symbol < 256) { if (s->outcnt == s->outlen) return 1; if (symbol) s->out[s->outcnt] = symbol; s->outcnt++; } else if (symbol > 256) { symbol -= 257; if (symbol >= 29) return -10; int len = lens[symbol] + puff_bits(s, lext[symbol]); symbol = puff_decode(s, distcode); if (symbol < 0) return symbol; unsigned dist = dists[symbol] + puff_bits(s, dext[symbol]); if (dist > s->outcnt) return -11; if (s->outcnt + len > s->outlen) return 1; while (len--) { if (dist <= s->outcnt && s->out[s->outcnt - dist]) s->out[s->outcnt] = s->out[s->outcnt - dist]; s->outcnt++; } } } while (symbol != 256); return 0; } static int puff_fixed(struct puff_state* s) { static int virgin = 1; static short lencnt[MAXBITS + 1], lensym[FIXLCODES]; static short distcnt[MAXBITS + 1], distsym[MAXDCODES]; static struct puff_huffman lencode, distcode; if (virgin) { lencode.count = lencnt; lencode.symbol = lensym; distcode.count = distcnt; distcode.symbol = distsym; short lengths[FIXLCODES]; int symbol; for (symbol = 0; symbol < 144; symbol++) lengths[symbol] = 8; for (; symbol < 256; symbol++) lengths[symbol] = 9; for (; symbol < 280; symbol++) lengths[symbol] = 7; for (; symbol < FIXLCODES; symbol++) lengths[symbol] = 8; puff_construct(&lencode, lengths, FIXLCODES); for (symbol = 0; symbol < MAXDCODES; symbol++) lengths[symbol] = 5; puff_construct(&distcode, lengths, MAXDCODES); virgin = 0; } return puff_codes(s, &lencode, &distcode); } static int puff_dynamic(struct puff_state* s) { static const short order[19] = {16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15}; int nlen = puff_bits(s, 5) + 257; int ndist = puff_bits(s, 5) + 1; int ncode = puff_bits(s, 4) + 4; if (nlen > MAXLCODES || ndist > MAXDCODES) return -3; short lengths[MAXCODES]; int index; for (index = 0; index < ncode; index++) lengths[order[index]] = puff_bits(s, 3); for (; index < 19; index++) lengths[order[index]] = 0; short lencnt[MAXBITS + 1], lensym[MAXLCODES]; struct puff_huffman lencode = {lencnt, lensym}; int err = puff_construct(&lencode, lengths, 19); if (err != 0) return -4; index = 0; while (index < nlen + ndist) { int symbol; int len; symbol = puff_decode(s, &lencode); if (symbol < 0) return symbol; if (symbol < 16) lengths[index++] = symbol; else { len = 0; if (symbol == 16) { if (index == 0) return -5; len = lengths[index - 1]; symbol = 3 + puff_bits(s, 2); } else if (symbol == 17) symbol = 3 + puff_bits(s, 3); else symbol = 11 + puff_bits(s, 7); if (index + symbol > nlen + ndist) return -6; while (symbol--) lengths[index++] = len; } } if (lengths[256] == 0) return -9; err = puff_construct(&lencode, lengths, nlen); if (err && (err < 0 || nlen != lencode.count[0] + lencode.count[1])) return -7; short distcnt[MAXBITS + 1], distsym[MAXDCODES]; struct puff_huffman distcode = {distcnt, distsym}; err = puff_construct(&distcode, lengths + nlen, ndist); if (err && (err < 0 || ndist != distcode.count[0] + distcode.count[1])) return -8; return puff_codes(s, &lencode, &distcode); } static int puff(unsigned char* dest, unsigned long* destlen, const unsigned char* source, unsigned long sourcelen) { struct puff_state s = { .out = dest, .outlen = *destlen, .outcnt = 0, .in = source, .inlen = sourcelen, .incnt = 0, .bitbuf = 0, .bitcnt = 0, }; int err; if (setjmp(s.env) != 0) err = 2; else { int last; do { last = puff_bits(&s, 1); int type = puff_bits(&s, 2); err = type == 0 ? puff_stored(&s) : (type == 1 ? puff_fixed(&s) : (type == 2 ? puff_dynamic(&s) : -1)); if (err != 0) break; } while (!last); } *destlen = s.outcnt; return err; } //% END CODE DERIVED FROM puff.{c,h} #define ZLIB_HEADER_WIDTH 2 static int puff_zlib_to_file(const unsigned char* source, unsigned long sourcelen, int dest_fd) { if (sourcelen < ZLIB_HEADER_WIDTH) return 0; source += ZLIB_HEADER_WIDTH; sourcelen -= ZLIB_HEADER_WIDTH; const unsigned long max_destlen = 132 << 20; void* ret = mmap(0, max_destlen, PROT_WRITE | PROT_READ, MAP_PRIVATE | MAP_ANON, -1, 0); if (ret == MAP_FAILED) return -1; unsigned char* dest = (unsigned char*)ret; unsigned long destlen = max_destlen; int err = puff(dest, &destlen, source, sourcelen); if (err) { munmap(dest, max_destlen); errno = -err; return -1; } if (write(dest_fd, dest, destlen) != (ssize_t)destlen) { munmap(dest, max_destlen); return -1; } return munmap(dest, max_destlen); } static int setup_loop_device(unsigned char* data, unsigned long size, const char* loopname, int* loopfd_p) { int err = 0, loopfd = -1; int memfd = syscall(__NR_memfd_create, "syzkaller", 0); if (memfd == -1) { err = errno; goto error; } if (puff_zlib_to_file(data, size, memfd)) { err = errno; goto error_close_memfd; } loopfd = open(loopname, O_RDWR); if (loopfd == -1) { err = errno; goto error_close_memfd; } if (ioctl(loopfd, LOOP_SET_FD, memfd)) { if (errno != EBUSY) { err = errno; goto error_close_loop; } ioctl(loopfd, LOOP_CLR_FD, 0); usleep(1000); if (ioctl(loopfd, LOOP_SET_FD, memfd)) { err = errno; goto error_close_loop; } } close(memfd); *loopfd_p = loopfd; return 0; error_close_loop: close(loopfd); error_close_memfd: close(memfd); error: errno = err; return -1; } static void reset_loop_device(const char* loopname) { int loopfd = open(loopname, O_RDWR); if (loopfd == -1) { return; } if (ioctl(loopfd, LOOP_CLR_FD, 0)) { } close(loopfd); } static long syz_mount_image(volatile long fsarg, volatile long dir, volatile long flags, volatile long optsarg, volatile long change_dir, volatile unsigned long size, volatile long image) { unsigned char* data = (unsigned char*)image; int res = -1, err = 0, need_loop_device = !!size; char* mount_opts = (char*)optsarg; char* target = (char*)dir; char* fs = (char*)fsarg; char* source = NULL; char loopname[64]; if (need_loop_device) { int loopfd; memset(loopname, 0, sizeof(loopname)); snprintf(loopname, sizeof(loopname), "/dev/loop%llu", procid); if (setup_loop_device(data, size, loopname, &loopfd) == -1) return -1; close(loopfd); source = loopname; } mkdir(target, 0777); char opts[256]; memset(opts, 0, sizeof(opts)); if (strlen(mount_opts) > (sizeof(opts) - 32)) { } strncpy(opts, mount_opts, sizeof(opts) - 32); if (strcmp(fs, "iso9660") == 0) { flags |= MS_RDONLY; } else if (strncmp(fs, "ext", 3) == 0) { bool has_remount_ro = false; char* remount_ro_start = strstr(opts, "errors=remount-ro"); if (remount_ro_start != NULL) { char after = *(remount_ro_start + strlen("errors=remount-ro")); char before = remount_ro_start == opts ? '\0' : *(remount_ro_start - 1); has_remount_ro = ((before == '\0' || before == ',') && (after == '\0' || after == ',')); } if (strstr(opts, "errors=panic") || !has_remount_ro) strcat(opts, ",errors=continue"); } else if (strcmp(fs, "xfs") == 0) { strcat(opts, ",nouuid"); } else if (strncmp(fs, "gfs2", 4) == 0 && (strstr(opts, "errors=panic") || strstr(opts, "debug"))) { strcat(opts, ",errors=withdraw"); } res = mount(source, target, fs, flags, opts); if (res == -1) { err = errno; goto error_clear_loop; } res = open(target, O_RDONLY | O_DIRECTORY); if (res == -1) { err = errno; goto error_clear_loop; } if (change_dir) { res = chdir(target); if (res == -1) { err = errno; } } error_clear_loop: if (need_loop_device) reset_loop_device(loopname); errno = err; return res; } #define FS_IOC_SETFLAGS _IOW('f', 2, long) static void remove_dir(const char* dir) { int iter = 0; DIR* dp = 0; const int umount_flags = MNT_FORCE | UMOUNT_NOFOLLOW; retry: while (umount2(dir, umount_flags) == 0) { } dp = opendir(dir); if (dp == NULL) { if (errno == EMFILE) { exit(1); } exit(1); } struct dirent* ep = 0; while ((ep = readdir(dp))) { if (strcmp(ep->d_name, ".") == 0 || strcmp(ep->d_name, "..") == 0) continue; char filename[FILENAME_MAX]; snprintf(filename, sizeof(filename), "%s/%s", dir, ep->d_name); while (umount2(filename, umount_flags) == 0) { } struct stat st; if (lstat(filename, &st)) exit(1); if (S_ISDIR(st.st_mode)) { remove_dir(filename); continue; } int i; for (i = 0;; i++) { if (unlink(filename) == 0) break; if (errno == EPERM) { int fd = open(filename, O_RDONLY); if (fd != -1) { long flags = 0; if (ioctl(fd, FS_IOC_SETFLAGS, &flags) == 0) { } close(fd); continue; } } if (errno == EROFS) { break; } if (errno != EBUSY || i > 100) exit(1); if (umount2(filename, umount_flags)) exit(1); } } closedir(dp); for (int i = 0;; i++) { if (rmdir(dir) == 0) break; if (i < 100) { if (errno == EPERM) { int fd = open(dir, O_RDONLY); if (fd != -1) { long flags = 0; if (ioctl(fd, FS_IOC_SETFLAGS, &flags) == 0) { } close(fd); continue; } } if (errno == EROFS) { break; } if (errno == EBUSY) { if (umount2(dir, umount_flags)) exit(1); continue; } if (errno == ENOTEMPTY) { if (iter < 100) { iter++; goto retry; } } } exit(1); } } 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 reset_loop() { char buf[64]; snprintf(buf, sizeof(buf), "/dev/loop%llu", procid); int loopfd = open(buf, O_RDWR); if (loopfd != -1) { ioctl(loopfd, LOOP_CLR_FD, 0); close(loopfd); } } static void setup_test() { prctl(PR_SET_PDEATHSIG, SIGKILL, 0, 0, 0); setpgrp(); write_file("/proc/self/oom_score_adj", "1000"); if (symlink("/dev/binderfs", "./binderfs")) { } } struct thread_t { int created, call; event_t ready, done; }; static struct thread_t threads[16]; static void execute_call(int call); static int running; static void* thr(void* arg) { struct thread_t* th = (struct thread_t*)arg; for (;;) { event_wait(&th->ready); event_reset(&th->ready); execute_call(th->call); __atomic_fetch_sub(&running, 1, __ATOMIC_RELAXED); event_set(&th->done); } return 0; } static void execute_one(void) { if (write(1, "executing program\n", sizeof("executing program\n") - 1)) { } int i, call, thread; for (call = 0; call < 8; call++) { for (thread = 0; thread < (int)(sizeof(threads) / sizeof(threads[0])); thread++) { struct thread_t* th = &threads[thread]; if (!th->created) { th->created = 1; event_init(&th->ready); event_init(&th->done); event_set(&th->done); thread_start(thr, th); } if (!event_isset(&th->done)) continue; event_reset(&th->done); th->call = call; __atomic_fetch_add(&running, 1, __ATOMIC_RELAXED); event_set(&th->ready); event_timedwait(&th->done, 50 + (call == 7 ? 4000 : 0)); break; } } for (i = 0; i < 100 && __atomic_load_n(&running, __ATOMIC_RELAXED); i++) sleep_ms(1); } static void execute_one(void); #define WAIT_FLAGS __WALL static void loop(void) { int iter = 0; for (;; iter++) { char cwdbuf[32]; sprintf(cwdbuf, "./%d", iter); if (mkdir(cwdbuf, 0777)) exit(1); reset_loop(); int pid = fork(); if (pid < 0) exit(1); if (pid == 0) { if (chdir(cwdbuf)) exit(1); 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; } remove_dir(cwdbuf); } } uint64_t r[2] = {0xffffffffffffffff, 0xffffffffffffffff}; void execute_call(int call) { intptr_t res = 0; switch (call) { case 0: // ioctl$KVM_SET_MSRS arguments: [ // fd: fd_kvmcpu (resource) // cmd: const = 0x4008ae89 (4 bytes) // arg: ptr[in, kvm_msrs] { // kvm_msrs { // nmsrs: len = 0x1 (4 bytes) // pad: const = 0x0 (4 bytes) // entries: array[kvm_msr_entry] { // kvm_msr_entry { // index: msr_index = 0x4000009c (4 bytes) // reserv: const = 0x0 (4 bytes) // data: int64 = 0x0 (8 bytes) // } // } // } // } // ] *(uint32_t*)0x200000000200 = 1; *(uint32_t*)0x200000000204 = 0; *(uint32_t*)0x200000000208 = 0x4000009c; *(uint32_t*)0x20000000020c = 0; *(uint64_t*)0x200000000210 = 0; syscall(__NR_ioctl, /*fd=*/(intptr_t)-1, /*cmd=*/0x4008ae89, /*arg=*/0x200000000200ul); break; case 1: // socket$inet6 arguments: [ // domain: const = 0xa (8 bytes) // type: socket_type = 0x80002 (8 bytes) // proto: int32 = 0x0 (4 bytes) // ] // returns sock_in6 res = syscall(__NR_socket, /*domain=*/0xaul, /*type=SOCK_CLOEXEC|SOCK_DGRAM*/ 0x80002ul, /*proto=*/0); if (res != -1) r[0] = res; break; case 2: // setsockopt$sock_linger arguments: [ // fd: sock (resource) // level: const = 0x1 (4 bytes) // optname: const = 0x3c (4 bytes) // optval: nil // optlen: len = 0x0 (8 bytes) // ] syscall(__NR_setsockopt, /*fd=*/r[0], /*level=*/1, /*optname=*/0x3c, /*optval=*/0ul, /*optlen=*/0ul); break; case 3: // mkdirat arguments: [ // fd: fd_dir (resource) // path: ptr[in, buffer] { // buffer: {2e 2f 73 79 73 00} (length 0x6) // } // mode: open_mode = 0x1ff (8 bytes) // ] memcpy((void*)0x200000000000, "./sys\000", 6); syscall( __NR_mkdirat, /*fd=*/0xffffff9c, /*path=*/0x200000000000ul, /*mode=S_IXOTH|S_IWOTH|S_IROTH|S_IXGRP|S_IWGRP|S_IRGRP|S_IXUSR|S_IWUSR|0x100*/ 0x1fful); break; case 4: // mount arguments: [ // src: nil // dst: ptr[in, buffer] { // buffer: {2e 2f 73 79 73 00} (length 0x6) // } // type: ptr[in, buffer] { // buffer: {73 79 73 66 73 00} (length 0x6) // } // flags: mount_flags = 0x0 (8 bytes) // data: nil // ] memcpy((void*)0x200000000000, "./sys\000", 6); memcpy((void*)0x200000000100, "sysfs\000", 6); syscall(__NR_mount, /*src=*/0ul, /*dst=*/0x200000000000ul, /*type=*/0x200000000100ul, /*flags=*/0ul, /*data=*/0ul); break; case 5: // openat arguments: [ // fd: fd_dir (resource) // file: ptr[in, buffer] { // buffer: {2e 2f 73 79 73 2f 62 75 73 2f 70 6c 61 74 66 6f 72 6d 2f 64 // 72 69 76 65 72 73 2f 76 68 63 69 5f 68 63 64 2f 75 6e 62 69 6e 64 // 00} (length 0x2b) // } // flags: open_flags = 0x1 (4 bytes) // mode: open_mode = 0x0 (2 bytes) // ] // returns fd memcpy((void*)0x200000000200, "./sys/bus/platform/drivers/vhci_hcd/unbind\000", 43); res = syscall(__NR_openat, /*fd=*/0xffffff9c, /*file=*/0x200000000200ul, /*flags=O_WRONLY*/ 1, /*mode=*/0); if (res != -1) r[1] = res; break; case 6: // write arguments: [ // fd: fd (resource) // buf: ptr[in, buffer] { // buffer: {76 68 63 69 5f 68 63 64 2e 30} (length 0xa) // } // count: len = 0xa (8 bytes) // ] memcpy((void*)0x200000000300, "vhci_hcd.0", 10); syscall(__NR_write, /*fd=*/r[1], /*buf=*/0x200000000300ul, /*count=*/0xaul); break; case 7: // syz_mount_image$udf arguments: [ // fs: ptr[in, buffer] { // buffer: {75 64 66 00} (length 0x4) // } // dir: ptr[in, buffer] { // buffer: {2e 2f 62 75 73 00} (length 0x6) // } // flags: mount_flags = 0x0 (8 bytes) // opts: ptr[inout, array[ANYUNION]] { // array[ANYUNION] { // union ANYUNION { // ANYBLOB: buffer: {73 68 6f 72 74 61 64 2c 75 6e 64 65 6c 65 74 // 65 2c 73 65 73 73 69 6f 6e 3d 30 30 30 30 00 08 00 00 30 30 30 // 30 30 30 30 30 30 31 39 30 2c 6d 6f 64 65 3d 30 30 30 30 30 30 // 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 35 2c 72 6f 6f // 74 64 69 72 3d 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 30 // 30 30 30 35 2c 64 6d 6f 64 65 3d 30 30 30 30 30 30 30 30 30 30 // 30 30 30 30 30 30 30 30 30 30 30 30 36 2c 69 6f 63 68 61 72 73 // 65 74 3d 63 70 31 32 35 31 2c 69 6f 63 68 61 72 73 65 74 3d 6b // 6f 69 38 2d 72 2c 6e 6f 76 72 73 2c 00 84 f5 b2 3d 82 aa cb ef // d1 de 1d aa b7 39 4a 9b 46 96 46 1d a9 ab 46 f2 d7 1c 89 5d 8c} // (length 0xcc) // } // union ANYUNION { // ANYRESOCT: ANYRES64 (resource) // } // } // } // chdir: int8 = 0x9 (1 bytes) // size: len = 0xc41 (8 bytes) // img: ptr[in, buffer] { // buffer: (compressed buffer with length 0xc41) // } // ] // returns fd_dir memcpy((void*)0x200000000f00, "udf\000", 4); memcpy((void*)0x200000000000, "./bus\000", 6); memcpy( (void*)0x200000001500, "\x73\x68\x6f\x72\x74\x61\x64\x2c\x75\x6e\x64\x65\x6c\x65\x74\x65\x2c" "\x73\x65\x73\x73\x69\x6f\x6e\x3d\x30\x30\x30\x30\x00\x08\x00\x00\x30" "\x30\x30\x30\x30\x30\x30\x30\x30\x31\x39\x30\x2c\x6d\x6f\x64\x65\x3d" "\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30" "\x30\x30\x30\x30\x30\x35\x2c\x72\x6f\x6f\x74\x64\x69\x72\x3d\x30\x30" "\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30" "\x35\x2c\x64\x6d\x6f\x64\x65\x3d\x30\x30\x30\x30\x30\x30\x30\x30\x30" "\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x30\x36\x2c\x69\x6f" "\x63\x68\x61\x72\x73\x65\x74\x3d\x63\x70\x31\x32\x35\x31\x2c\x69\x6f" "\x63\x68\x61\x72\x73\x65\x74\x3d\x6b\x6f\x69\x38\x2d\x72\x2c\x6e\x6f" "\x76\x72\x73\x2c\x00\x84\xf5\xb2\x3d\x82\xaa\xcb\xef\xd1\xde\x1d\xaa" "\xb7\x39\x4a\x9b\x46\x96\x46\x1d\xa9\xab\x46\xf2\xd7\x1c\x89\x5d\x8c", 204); sprintf((char*)0x2000000015cc, "%023llo", (long long)-1); memcpy( (void*)0x200000001b80, "\x78\x9c\xec\xdd\x4f\x6c\x1c\xd7\x7d\x07\xf0\xdf\x1b\x91\xe2\xd2\x6e" "\x2b\xc6\x76\x14\x27\x8d\x8b\x4d\x5b\xa4\xb2\x62\xb9\xfa\x17\x53\xb1" "\x0a\x77\x55\xd3\x6c\x03\xc8\x32\x11\x8a\xb9\x05\xe0\x8a\xa4\xd4\x85" "\x29\x92\x20\xa9\x46\x36\xd2\x82\xee\xa5\x87\x1e\x02\x14\x45\x0f\x39" "\x11\x68\x8d\x02\x29\x1a\x18\x4d\x11\xf4\xc8\xb4\x2e\x90\x5c\x7c\x28" "\x72\xea\x89\x68\x61\x23\x28\x7a\x60\x8b\x00\x39\x05\x0c\x66\xf6\xad" "\xb8\xa4\x49\x9b\x36\xff\x88\xb2\x3e\x1f\x9b\xfa\xee\xce\xbc\x37\xf3" "\xde\xcc\x72\x46\x22\xf8\xe6\x05\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x10\xf1\x07\x2f\x5d\x39\x7b\x2e\xdd\xef\x56\x00" "\x00\x87\xe9\xda\xe8\xd7\xce\x9e\x77\xff\x07\x80\x87\xca\x75\xff\xfe" "\x07\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80\xa3\x2e\x45\x11\x8f" "\x47\x8a\xb9\x6b\x6b\x69\xbc\x7a\xdf\x56\xbb\xda\xea\xbd\x73\x77\x6c" "\x68\x78\xfb\x6a\xfd\xa9\xaa\x79\xac\x2a\x5f\x7e\xd5\xce\x9d\xbf\x70" "\xf1\xcb\xcf\x0d\x5e\xea\xe4\xd5\xd6\xcc\x07\xd4\xdf\x6f\x9f\x8b\x57" "\x46\xaf\x5f\xa9\xbf\x38\x7b\x7b\x6e\x7e\x6a\x61\x61\x6a\xb2\x3e\x36" "\xd3\x9a\x98\x9d\x9c\xda\xf5\x16\xf6\x5a\x7f\xab\xd3\xd5\x01\xa8\xdf" "\x7e\xf5\xce\xe4\xcd\x9b\x0b\xf5\xf3\xcf\x5e\xd8\xb4\xfa\xee\xc0\x7b" "\x7d\x8f\x9e\x1c\xb8\x3c\xf8\xf4\x99\xa7\x3a\x65\xc7\x86\x86\x87\x47" "\x37\x8a\xd4\xba\xcb\xf7\x7c\xec\x86\xb4\xed\x34\xc2\xe3\x78\x14\x71" "\x26\x52\x3c\xf3\xbd\x9f\xa6\x66\x44\x14\xb1\xf7\x63\x51\x3b\xdc\x73" "\xbf\x55\x7f\xd5\x89\xd3\x55\x27\xc6\x86\x86\xab\x8e\x4c\xb7\x9a\x33" "\x8b\xe5\xca\x91\xce\x81\x28\x22\xea\x5d\x95\x1a\x9d\x63\xb4\xfd\xb9" "\x88\x9e\xde\x43\xed\xc3\xce\x1a\x11\x4b\x65\xf3\xcb\x06\x9f\x2e\xbb" "\x37\x3a\xd7\x9c\x6f\xde\x98\x9e\xaa\x8f\x34\xe7\x17\x5b\x8b\xad\xd9" "\x99\x91\xd4\x6e\x6d\xd9\x9f\x7a\x14\x71\x29\x45\x2c\x47\xc4\x6a\xdf" "\xfb\x37\xd7\x1b\x45\xf4\x44\x8a\xef\x9c\x58\x4b\x37\x22\xe2\x58\xe7" "\x38\x7c\xa9\x1a\x18\xbc\x73\x3b\x8a\x03\xec\xe3\x2e\x94\xed\xac\xf7" "\x46\x2c\x17\x0f\xc0\x39\x3b\xc2\xfa\xa2\x88\x97\x23\xc5\xcf\xde\x3e" "\x15\x13\xf9\x3a\x53\x5d\x6b\xbe\x18\xf1\x72\x99\x3f\x88\x78\xb3\xcc" "\x17\x22\x52\xf9\xc1\xb8\x18\xf1\xee\x36\x9f\x23\x1e\x4c\x3d\x51\xc4" "\x5f\x96\xe7\xff\xf2\x5a\x9a\xac\xae\x07\x9d\xeb\xca\xd5\xaf\xd7\xbf" "\x3a\x73\x73\xb6\xab\x6c\xe7\xba\xf2\x11\xef\x0f\xef\xbb\x52\xdc\xa7" "\xfb\x43\xff\x96\x3c\x1c\x47\xfc\xda\x54\x8b\x22\x9a\xd5\x15\x7f\x2d" "\x7d\xfc\xbf\xec\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\xb0\xdf\xfa\xa3\x88\xcf\x46\x8a\x97\xfe\xe3\x4f\xaa\x71\xc5\x51\x8d" "\x4b\x3f\x71\x79\xf0\x0f\x07\x7e\xb5\x7b\xcc\xf8\x93\x1f\xb2\x9d\xb2" "\xec\xb3\x11\xb1\x54\xec\x6e\x4c\xee\xf1\x3c\x30\x70\x24\x8d\xa4\x74" "\x9f\xc7\x12\x3f\xcc\x6a\x51\xc4\x9f\xe6\xf1\x7f\x6f\xdc\xef\xc6\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x3c\xd4\x8a" "\xf8\x49\xa4\x78\xfe\x9d\x53\x69\x39\xba\xe7\x14\x6f\xcd\xdc\xaa\x5f" "\x6f\xde\x98\x6e\xcf\x0a\xdb\x99\xfb\xb7\x33\x67\xfa\xfa\xfa\xfa\x7a" "\x3d\xb5\xb3\x91\x73\x3c\xe7\x52\xce\xe5\x9c\x2b\x39\x57\x73\x46\x91" "\xeb\xe7\x6c\xe4\x1c\xcf\xb9\x94\x73\x39\xe7\x4a\xce\xd5\x9c\x71\x2c" "\xd7\xcf\xd9\xc8\x39\x9e\x73\x29\xe7\x72\xce\x95\x9c\xab\x39\xa3\x27" "\xd7\xcf\xd9\xc8\x39\x9e\x73\x29\xe7\x72\xce\x95\x9c\xab\x39\xe3\x88" "\xcc\xdd\x0b\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf0\x49" "\x52\x44\x11\xbf\x88\x14\xdf\xfe\xe6\x5a\x8a\x14\x11\x8d\x88\xf1\x68" "\xe7\x4a\xdf\xfd\x6e\x1d\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x50\xea\x4b\x45\x7c\x3f\x52\xd4\xff\xa8\x71\x6f\x59\x4f\x44" "\xa4\xea\xff\xb6\x53\xe5\x1f\x17\xa3\x71\xbc\xcc\xc7\xa2\x31\x58\xe6" "\x0b\xd1\xb8\x92\xb3\x59\x65\x4f\xe3\x8d\xfb\xd0\x7e\xf6\xa6\x37\x15" "\xf1\xe3\x48\xd1\x57\x7b\x2b\x52\x4f\x7b\x59\x3e\xff\xbd\xed\x77\xf7" "\x3e\x06\xf1\xe6\xb7\x36\xde\x7d\x2e\x97\x3d\xd6\x59\x39\xf0\x5e\xdf" "\xa3\x27\x4f\x5c\x1e\x1c\xfe\x8d\x27\x77\x7a\x9d\xb6\x6b\xc0\xe9\xab" "\xad\x99\x3b\x77\xeb\x63\x43\xc3\xc3\xa3\x5d\x8b\x7b\xf2\xde\x1f\xeb" "\x5a\x36\x90\xf7\x5b\xec\x53\xdf\x89\x58\x78\xed\xf5\x57\x9b\xd3\xd3" "\x53\xf3\x1f\xff\x45\xf9\x11\xd8\x43\xf5\x07\xe8\x45\xf9\x0d\x72\x04" "\x9a\xe1\xc5\x61\xbd\x88\x9e\x23\xd1\x8c\xfb\xd3\x77\x1e\x02\xe5\xfd" "\xff\xdd\x48\xf1\xbb\xef\xfc\x67\xe7\x86\xdf\xbe\xff\xd7\xe2\x57\xda" "\xef\xee\xdd\xe1\xe3\xe7\x7f\xb6\x71\xff\x7f\x7e\xeb\x86\x76\x79\xff" "\xef\xd9\x5a\x2f\xdf\xff\xcb\x7b\xfa\x76\xf7\xff\xc7\xbb\x96\x3d\x9f" "\xff\x36\xd2\xdb\x13\x51\x5b\xbc\x3d\xd7\x7b\x32\xa2\xb6\xf0\xda\xeb" "\x67\x5a\xb7\x9b\xb7\xa6\x6e\x4d\xcd\x5c\x3c\x7b\xf6\x2b\x83\x83\x5f" "\xb9\x70\xb6\xf7\x78\x44\xed\x66\x6b\x7a\xaa\xeb\xd5\xbe\x1c\x2e\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80\xc3\x93\x8a\xf8\xfd" "\x48\xd1\xfc\xf1\x5a\xaa\x47\xc4\xdd\x6a\xbc\xd6\xc0\xe5\xc1\xa7\xcf" "\x3c\x75\x2c\x8e\x55\xe3\xad\x36\x8d\xdb\x7e\x65\xf4\xfa\x95\xfa\x8b" "\xb3\xb7\xe7\xe6\xa7\x16\x16\xa6\x26\xeb\x63\x33\xad\x89\xd9\xc9\xa9" "\xdd\xee\xae\x56\x0d\xf7\x1a\x1b\x1a\x3e\x90\xce\x7c\xa8\xfe\x03\x6e" "\x7f\x7f\xed\xc5\xd9\xb9\xd7\xe6\x5b\xb7\xfe\x78\x71\xdb\xf5\x8f\xd4" "\xae\xdc\x58\x58\x9c\x6f\x4e\x6c\xbf\x3a\xfa\xa3\x88\x68\x74\x2f\x39" "\x5d\x35\x78\x6c\x68\xb8\x6a\xf4\x74\xab\x39\x53\x55\x1d\xd9\x76\x30" "\xfd\x47\xd7\x9b\x8a\xf8\xaf\x48\x31\x71\xb1\x9e\xbe\x90\x97\xe5\xf1" "\xff\x5b\x47\xf8\x6f\x1a\xff\xbf\xb4\x75\x43\x07\x34\xfe\xff\x53\x5d" "\xcb\xca\x7d\xa6\x54\xc4\xcf\x23\xc5\xef\xfc\xd5\x93\xf1\x85\xaa\x9d" "\x8f\xc4\xfb\x8e\x59\x2e\xf7\x77\x91\xe2\xf4\xa5\xcf\xe7\x72\x71\xbc" "\x2c\xd7\x69\xc3\x63\xd5\x43\x04\xda\x23\x03\xcb\xb2\xff\x17\x29\xfe" "\xe9\x17\x9b\xcb\x76\xc6\x43\xb6\xc7\x20\x56\x65\xcf\xed\xfe\xc8\x3e" "\x18\xca\xf3\x7f\x22\x52\x7c\xff\x2f\xbe\x1b\xbf\x99\x97\x6d\x7e\xfe" "\xc3\xf6\xe7\xff\x91\xad\x1b\x3a\xa0\xf3\xff\x44\xd7\xb2\x47\x36\x3d" "\xaf\x60\xcf\x5d\x27\x9f\xff\x33\x91\xe2\x85\xc7\xdf\x8a\xdf\xca\xcb" "\x3e\xe8\xf9\x1f\x9d\x67\x6f\x9c\xca\x85\xef\x3d\x9f\xe3\x80\xce\xff" "\xa7\xbb\x96\x0d\xe4\xfd\xfe\xf6\xfe\x74\x1d\x00\x00\x00\x00\x00\x00" "\x00\x00\xe0\x81\xd6\x9b\x8a\xf8\xfb\x48\xf1\xc3\xe1\x9e\xf4\x5c\x5e" "\xb6\x9b\xdf\xff\x9b\xdc\xba\xa1\x03\xfa\xfd\xaf\xcf\x74\x2d\x9b\xdc" "\x9f\xf9\x8a\x3e\xf4\xc5\x9e\x0f\x2a\x00\x00\x00\x00\x1c\x11\xbd\xa9" "\x88\x9f\x44\x8a\x5b\x8b\x6f\xdd\x1b\x43\xbd\x79\xfc\x77\xd7\xf8\xcf" "\xdf\xdb\x18\xff\x39\x94\xb6\xac\xad\x7e\xce\xf7\x6b\xd5\x73\x03\xf6" "\xf3\xe7\x7f\xdd\x06\xf2\x7e\xc7\xf7\xde\x6d\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x38\x52\x52\x2a\xe2\xb9\x3c\x9f" "\xfa\x78\x35\x9e\x7f\x72\xc7\xf9\xd4\x57\x22\xc5\x4b\xff\xf3\x4c\x2e" "\x97\x4e\x96\xe5\x3a\xf3\xc0\x0f\x54\x7f\xd6\xae\xcd\xce\x9c\xb9\x32" "\x3d\x3d\x3b\xd1\x5c\x6c\xde\x98\x9e\xaa\x8f\xce\x35\x27\xa6\xca\xba" "\x4f\x44\x8a\xb5\xbf\xfd\x7c\xae\x5b\x54\xf3\xab\x77\xe6\x9b\x6f\xcf" "\xf1\xbe\x31\x17\xfb\x7c\xa4\x18\xfe\x87\x4e\xd9\xf6\x5c\xec\x9d\xb9" "\xc9\x9f\xd8\x28\x7b\xae\x2c\xfb\xa9\x48\xf1\xdf\xff\x98\xcb\xae\xaf" "\x57\x65\x3b\xf3\x58\x7f\x7a\xa3\xec\xf9\xb2\xec\xdf\x44\x8a\x6f\xfc" "\xcb\xe6\xed\x76\xca\x9e\xdc\x28\x7b\xa1\x2c\xfb\xdd\x48\xf1\xa3\x6f" "\xd4\x3b\x65\x1f\x29\xcb\x76\x9e\x8f\xfa\x99\x8d\xb2\xcf\x4e\xcc\x16" "\x07\x70\x56\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x78\xd8\xf4\xa6\x22\xfe\x3c\x52\xfc\xef\xed\xe5\x7b\x63\xf9\xf3" "\xfc\xff\xbd\x5d\x6f\x2b\x6f\x7e\xab\x6b\xbe\xff\x2d\xee\x56\xf3\xfc" "\x0f\x54\xf3\xff\xef\xf4\xfa\xe3\xcc\xff\x5f\x3d\x57\x60\x69\xa7\xbd" "\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xc0\x27\x53" "\x8a\x22\x5e\x8f\x14\x73\xd7\xd6\xd2\x4a\x5f\xf9\xbe\xad\x76\xb5\x35" "\x73\xe7\xee\xd8\xd0\xf0\xf6\xd5\xfa\x53\x55\xf3\x58\x55\xbe\xfc\xaa" "\x9d\x3b\x7f\xe1\xe2\x97\x9f\x1b\xbc\xd4\xc9\x0f\xae\xbf\xdf\x3e\x1b" "\xaf\x8c\x5e\xbf\x52\x7f\x71\xf6\xf6\xdc\xfc\xd4\xc2\xc2\xd4\x64\x7d" "\x6c\xa6\x35\x31\x3b\x39\xb5\xeb\x2d\xec\xb5\xfe\x56\xa7\xab\x03\x50" "\xbf\xfd\xea\x9d\xc9\x9b\x37\x17\xea\xe7\x9f\xbd\xb0\x69\xf5\xdd\x81" "\xf7\xfa\x1e\x3d\x39\x70\x79\xf0\xe9\x33\x4f\x75\xca\x8e\x0d\x0d\x0f" "\x8f\x76\x95\xe9\xe9\xfd\xa8\x3b\x7d\x63\xc7\x35\x69\x87\xe5\xc7\xa3" "\x88\xbf\x8e\x14\xcf\x7c\xef\xa7\xe9\x87\x7d\x11\x45\xec\xfd\x58\x6c" "\xfb\xd9\xe9\xdb\x7d\x2f\xf6\xa8\xbf\xea\xc4\xe9\xaa\x13\x63\x43\xc3" "\x55\x47\xa6\x5b\xcd\x99\xc5\x72\xe5\x48\xe7\x40\x14\x11\xf5\xae\x4a" "\x8d\xce\x31\xda\xb7\x73\x71\x40\x1a\x11\x4b\x65\xf3\xcb\x06\x9f\x2e" "\xbb\x37\x3a\xd7\x9c\x6f\xde\x98\x9e\xaa\x8f\x34\xe7\x17\x5b\x8b\xad" "\xd9\x99\x91\xd4\x6e\x6d\xd9\x9f\x7a\x14\x71\x29\x45\x2c\x47\xc4\xea" "\x36\xe7\xa0\x37\x8a\x78\x35\x52\x7c\xe7\xc4\x5a\xfa\xd7\xbe\x88\x63" "\x9d\xe3\xf0\xa5\x6b\xa3\x5f\x3b\x7b\x7e\xe7\x76\x14\x07\xd8\xc7\x5d" "\x28\xdb\x59\xef\x8d\x58\x2e\x1e\x80\x73\x76\x84\xf5\x45\x11\xff\x1c" "\x29\x7e\xf6\xf6\xa9\xf8\xb7\xbe\x88\x9e\x68\x7f\xc5\x17\x23\x5e\x2e" "\xf3\x07\x11\x6f\x46\xfb\x7c\xa7\xf2\x83\x71\x31\xe2\xdd\xc3\xfb\x5e" "\xe6\x80\xf5\x44\x11\xff\x5f\x9e\xff\xcb\x6b\xe9\xed\xbe\xf2\x7a\xd0" "\xb9\xae\x5c\xfd\x7a\xfd\xab\x33\x37\x67\xbb\xca\x76\xae\x2b\x07\x72" "\x7f\x38\x3c\xfd\x87\xba\xb7\x23\x7e\x6d\xaa\x45\x11\x3f\xaa\xae\xf8" "\x6b\xe9\xdf\x7d\x5f\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x1c\x21\x45\xfc\x7a\xa4\x78\xfe\x9d\x53\xa9\x1a\x1f\x7c\x6f\x4c" "\x71\x6b\xe6\x56\xfd\x7a\xf3\xc6\x74\x7b\x58\x5f\x67\xec\x5f\x67\xcc" "\xf4\xfa\xfa\xfa\x7a\x3d\xb5\xb3\x91\x73\x3c\xe7\x52\xce\xe5\x9c\x2b" "\x39\x57\x73\x46\x91\xeb\xe7\x6c\x94\x59\x5b\x5f\x1f\xcf\xef\x97\x72" "\x2e\xe7\x5c\xc9\xb9\x9a\x33\x8e\xe5\xfa\x39\x1b\x39\xc7\x73\x2e\xe5" "\x5c\xce\xb9\x92\x73\x35\x67\xf4\xe4\xfa\x39\x1b\x39\xc7\x73\x2e\xe5" "\x5c\xce\xb9\x92\x73\x35\x67\x1c\x91\xb1\x7b\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\xc0\x27\x4b\x51\xfd\x97\xe2\xdb\xdf" "\x5c\x4b\xeb\x7d\xed\xf9\xa5\xc7\xa3\x9d\x2b\xe6\x03\xfd\xc4\xfb\x65" "\x00\x00\x00\xff\xff\x1b\x6d\xfb\x37", 3137); syz_mount_image(/*fs=*/0x200000000f00, /*dir=*/0x200000000000, /*flags=*/0, /*opts=*/0x200000001500, /*chdir=*/9, /*size=*/0xc41, /*img=*/0x200000001b80); break; } } int main(void) { syscall(__NR_mmap, /*addr=*/0x1ffffffff000ul, /*len=*/0x1000, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/(intptr_t)-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x200000000000ul, /*len=*/0x1000000, /*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=*/0x1000, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/(intptr_t)-1, /*offset=*/0ul); const char* reason; (void)reason; for (procid = 0; procid < 5; procid++) { if (fork() == 0) { use_temporary_dir(); loop(); } } sleep(1000000); return 0; }