// https://syzkaller.appspot.com/bug?id=4fd44e65e3eefc00ec5ac7d3d6f86171f7f25a11 // 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_bpf #define __NR_bpf 321 #endif #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 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"); } 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; } 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"); } 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) { int i, call, thread; for (call = 0; call < 9; 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 == 0 ? 4000 : 0) + (call == 5 ? 4000 : 0) + (call == 8 ? 500 : 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++) { reset_loop(); 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 (;;) { if (waitpid(-1, &status, WNOHANG | WAIT_FLAGS) == pid) break; sleep_ms(1); if (current_time_ms() - start < 5000) continue; kill_and_wait(pid, &status); break; } } } uint64_t r[1] = {0xffffffffffffffff}; void execute_call(int call) { intptr_t res = 0; switch (call) { case 0: memcpy((void*)0x20000000, "ext4\000", 5); memcpy((void*)0x20000300, "./bus\000", 6); *(uint8_t*)0x20000040 = 0; memcpy( (void*)0x20000340, "\x78\x9c\xec\xdd\xdd\x6b\x5b\xe7\x19\x00\xf0\xe7\xc8\x52\xe4\x38\xd9" "\xec\xc1\x60\xcb\xae\x0c\x83\xcd\x10\x22\xcf\x89\x97\x6c\xb0\x8b\x8c" "\x5d\x8c\x41\x02\x81\xed\x7a\x89\x91\x15\x93\x59\xb6\x82\x25\x87\xd8" "\x18\xb6\xb0\x16\x7a\x53\x68\x4b\x2f\x0a\xed\x4d\xae\xfb\x91\xde\xf5" "\xb6\x1f\x57\x85\xf4\xbf\xe8\x45\x49\x48\x1b\x27\xd4\xa1\x94\xe2\x72" "\xf4\xe1\x38\xb6\xe4\xd8\xb1\x62\xb9\xf1\xef\x07\xc7\x7e\xdf\x73\x5e" "\xe9\x79\x1f\x9d\x0f\xbd\x3a\xe7\x20\x05\x70\x60\x0d\xa7\x7f\x32\x11" "\xc7\x22\xe2\xb5\x24\x62\xb0\x39\x3f\x89\x88\x5c\xbd\x94\x8d\x38\xdb" "\x68\xb7\xb2\xbc\x54\x4c\xa7\x24\x56\x57\xff\xf9\x4d\x52\x6f\xf3\x70" "\x79\xa9\x78\x78\xdd\x63\x52\x47\x9a\x95\x5f\x47\xc4\xa7\x2f\x47\x1c" "\xcf\x6c\x8e\x5b\x5d\x58\x9c\x9e\x28\x97\x4b\x73\xcd\xfa\x68\x6d\xe6" "\xea\x68\x75\x61\xf1\xc4\x95\x99\x89\xa9\xd2\x54\x69\xf6\xf4\xd8\xf8" "\xf8\xc9\x33\x7f\x3c\x73\x7a\xb7\x19\xe6\xd7\x4a\xdf\x7e\xb1\x78\xf4" "\xee\xeb\x7f\xff\xfd\x07\x67\xbf\xfb\xff\xaf\x6e\xbd\xfa\x59\x12\x67" "\xe3\x68\x73\x59\x9a\xc7\x6e\x23\x6d\x34\x1c\xc3\xcd\xd7\x24\x97\xbe" "\x84\x4f\xf8\x5b\xb7\x83\xf5\x58\xb2\xc3\xf6\xff\x7d\x4e\xfd\x60\x67" "\xd2\x5d\xb3\xaf\xb1\x97\xc7\xb1\x18\x8c\xbe\x7a\x09\x00\x78\x91\xa5" "\xe3\xb0\x55\x00\xe0\x80\x49\xbc\xff\x03\xc0\x01\xd3\x3a\x0f\xf0\x70" "\x79\xa9\xd8\x9a\xd6\x4e\x0e\x9c\xeb\xd5\x59\x89\xbd\x73\xef\xaf\x11" "\xd1\xdf\xc8\xbf\x75\x7d\xb3\xb1\x24\xdb\xbc\x66\xd7\x5f\xbf\x0e\x3a" "\xf0\x30\x79\xe2\xca\x48\x12\x11\x43\x5d\x88\x3f\x1c\x11\xef\x7c\xf4" "\xef\xf7\xd2\x29\xb6\x71\x1d\x32\xd7\x85\x98\x00\xa9\xff\xdd\x88\x88" "\x4b\x43\xc3\x9b\x8f\xff\xc9\xa6\x7b\x16\x76\xea\x0f\xdb\x68\x33\xbc" "\xa1\xfe\x3c\xee\xc3\x00\xda\xfb\x38\x1d\xff\xfc\xa9\xdd\xf8\x2f\xb3" "\x36\xfe\x89\x36\xe3\x9f\x7c\x9b\x7d\xf7\x59\x3c\x7d\xff\xcf\xdc\xe9" "\x42\x98\x8e\xd2\xf1\xdf\x5f\xd6\xdd\xdb\xb6\xb2\x2e\xff\xa6\xa1\xbe" "\x66\xed\x67\xf5\x31\x5f\x2e\xb9\x7c\xa5\x5c\x4a\x8f\x6d\x3f\x8f\x88" "\x91\xc8\xe5\xd3\xfa\x58\xab\x75\xff\xe6\x18\x23\x0f\x7e\x78\xd0\x29" "\xfe\xfa\xf1\xdf\xfd\x37\xfe\xf3\x6e\x1a\x3f\xfd\xff\xb8\x45\xe6\x4e" "\x36\xff\xe4\x63\x26\x27\x6a\x13\xbb\xcd\xbb\xe5\xde\x8d\x88\xdf\x64" "\xdb\xe5\xdf\x3a\xfe\xf7\xd7\x3f\x24\xb4\x1b\xff\x5e\xd8\x66\x8c\x7f" "\xfc\xf9\x95\xb7\x3b\x2d\x4b\xf3\x4f\xf3\x4d\xa7\xd6\xd8\x36\x2d\x27" "\x7b\x34\xd6\x5d\xbd\x19\xf1\xbb\xb6\xeb\xff\xf1\x1d\x6d\xc9\x96\xf7" "\x27\x8e\xd6\x37\x87\xd1\xd6\x46\xd1\xc6\x87\x5f\xbe\x35\xd0\x29\xfe" "\xfa\xf5\x9f\x4e\x69\xfc\xd6\x67\x81\xbd\x90\xae\xff\x81\xad\xf3\x1f" "\x4a\xd6\xdf\xaf\x59\xdd\x79\x8c\xdb\x37\x07\x3f\xe9\xb4\x6c\x78\xed" "\xec\x73\xa7\xfc\xdb\x6f\xff\x87\x92\x7f\xd5\xcb\x87\x9a\xf3\xae\x4f" "\xd4\x6a\x73\x63\x11\x87\x92\x73\x9b\xe7\x9f\x6c\x3d\x32\x9d\xdb\xa8" "\xb7\xda\xa7\xf9\x8f\xfc\xb6\xfd\xfe\xdf\x3a\xfe\x25\x6d\xb6\xff\x74" "\xdb\xbc\xb4\xcd\xfc\xb3\x77\xbf\x7e\x7f\xc3\xac\xfb\x8f\xf3\xef\xfd" "\xfa\x9f\xdc\xd1\xfa\xdf\x58\x48\x92\x8e\x8b\x9a\x85\x5b\x2b\xd3\x7d" "\x9d\xe2\x6f\x91\xff\xe7\x2f\x35\x36\x8c\x3b\xd9\xfc\x78\xbd\xed\x48" "\xf3\x31\xf5\xe3\xdf\x83\xad\x87\x89\x5b\x74\xa7\x5c\x9a\x3b\x1c\xcf" "\xbe\x35\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\xc0\xce\x65\x22\xe2\x68\x24\x99\xc2\x5a\x39\x93\x29" "\x14\x1a\xbf\xe1\xfd\xcb\x18\xc8\x94\x2b\xd5\xda\xf1\xcb\x95\xf9\xd9" "\xc9\xa8\xff\x56\xf6\x50\xe4\x32\xad\xaf\xba\x1c\x5c\xf7\x7d\xa8\x63" "\xcd\xef\xc3\x6f\xd5\x4f\x6e\xa8\x9f\x8a\x88\x5f\x44\xc4\x9b\xf9\xc3" "\xf5\x7a\xa1\x58\x29\x4f\xf6\x3a\x79\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x68\x3a\xd2\xe1\xf7\xff\x53\x5f\xe5\x1f\xad" "\x36\xf4\xba\x97\x00\x40\xd7\xf5\xf7\xba\x03\x00\xc0\x9e\xf3\xfe\x0f" "\x00\x07\x8f\xf7\x7f\x00\x38\x78\xbc\xff\x03\xc0\xc1\x73\x3b\xd3\xeb" "\x1e\x00\x00\x7b\xed\xd9\x3e\xff\xe7\xbb\xde\x0f\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x5e\x58\x17\xce\x9f" "\x4f\xa7\xd5\x47\xcb\x4b\xc5\xb4\x3e\x79\x6d\x61\x7e\xba\x72\xed\xc4" "\x64\xa9\x3a\x5d\x98\x99\x2f\x16\x8a\x95\xb9\xab\x85\xa9\x4a\x65\xaa" "\x5c\x2a\x14\x2b\x33\x4f\x7b\xbe\x72\xa5\x72\x75\x3c\x66\xe7\xaf\x8f" "\xd6\x4a\xd5\xda\x68\x75\x61\xf1\xe2\x4c\x65\x7e\xb6\x76\xf1\xca\xcc" "\xc4\x54\xe9\x62\x29\xb7\x27\x59\x01\x00\x00\x00\x00\x00\x00\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\xce\x54\x17\x16\xa7\x27\xca\xe5\xd2\xdc\xee" "\x0b\x99\x88\x68\xbb\x28\xdb\xfd\x58\xfb\xad\xd0\x1f\xfb\xa2\x1b\xdb" "\x2b\x9c\x5a\x69\xac\x8f\xae\x3e\x73\xb6\xab\x4f\xf8\xfd\xbe\x78\xa1" "\x9e\x4f\x21\xb7\x3f\xba\xf1\xb4\x42\x2f\x8f\x4a\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x3f\x1d\x3f\x06\x00\x00\xff\xff\x59\x00\x31\xdf", 2002); syz_mount_image( /*fs=*/0x20000000, /*dir=*/0x20000300, /*flags=MS_I_VERSION|MS_SYNCHRONOUS|MS_MANDLOCK|MS_DIRSYNC*/ 0x8000d0, /*opts=*/0x20000040, /*chdir=*/1, /*size=*/0x7d2, /*img=*/0x20000340); break; case 1: memcpy((void*)0x20000100, "./bus\000", 6); syscall(__NR_open, /*file=*/0x20000100ul, /*flags=O_SYNC|O_NOCTTY|O_NOATIME|O_CREAT|FASYNC|0x2*/ 0x143142ul, /*mode=*/0ul); break; case 2: memcpy((void*)0x20000380, "/dev/loop", 9); *(uint8_t*)0x20000389 = 0x30 + procid * 1; *(uint8_t*)0x2000038a = 0; memcpy((void*)0x20000140, "./bus\000", 6); syscall(__NR_mount, /*src=*/0x20000380ul, /*dst=*/0x20000140ul, /*type=*/0ul, /*flags=MS_BIND*/ 0x1000ul, /*data=*/0ul); break; case 3: memcpy((void*)0x20000080, "./bus\000", 6); res = syscall(__NR_open, /*file=*/0x20000080ul, /*flags=O_SYNC|O_NOCTTY|O_DIRECT|O_CLOEXEC|O_RDWR*/ 0x185102ul, /*mode=*/0ul); if (res != -1) r[0] = res; break; case 4: syscall(__NR_mmap, /*addr=*/0x20000000ul, /*len=*/0xb36000ul, /*prot=PROT_WRITE*/ 2ul, /*flags=MAP_STACK|MAP_POPULATE|MAP_FIXED|MAP_SHARED*/ 0x28011ul, /*fd=*/r[0], /*offset=*/0ul); break; case 5: memcpy((void*)0x20000040, "ext4\000", 5); memcpy((void*)0x20000000, "./file0\000", 8); *(uint8_t*)0x20000dc0 = 0; memcpy( (void*)0x20000080, "\x78\x9c\xec\xdd\xcf\x6f\x1b\x59\x1d\x00\xf0\xaf\x9d\x5f\x6e\x36\xbb" "\xc9\x2e\x7b\x00\x04\x6c\x58\x16\x0a\xaa\xea\x24\xee\x6e\xb4\xda\x03" "\x5b\x4e\x08\xa1\x95\x10\x7b\x04\xa9\x0d\x89\x1b\x45\xb1\xe3\x28\x76" "\x4a\x13\x7a\x48\xff\x07\x24\x2a\x71\x82\x23\x7f\x00\xe7\x9e\xb8\x73" "\x41\x70\xe3\x52\x0e\x48\x05\x22\x50\x53\x89\x83\xd1\x8c\x27\xad\x9b" "\xd8\x8d\x69\x5a\x3b\xb2\x3f\x1f\x69\x34\xf3\xde\xd8\xf3\x7d\xaf\xee" "\xbc\x57\x7f\xed\xfa\x05\x30\xb2\xe6\x23\xe2\x20\x22\x26\x23\xe2\x66" "\x44\xcc\x66\xf5\xb9\x6c\x8b\xeb\xad\x2d\x79\xdc\xe3\xc3\xbb\xab\x47" "\x87\x77\x57\x73\xd1\x6c\x7e\xfe\xcf\x5c\x7a\x3e\xa9\x8b\xb6\xe7\x24" "\xde\xc8\xae\x59\x88\x88\x1f\x7f\x3f\xe2\x67\xb9\xd3\x71\xeb\x7b\xfb" "\x9b\x2b\x95\x4a\x79\x27\x2b\x2f\x34\xaa\xdb\x0b\xf5\xbd\xfd\xab\x1b" "\xd5\x95\xf5\xf2\x7a\x79\xab\x54\x5a\x5e\x5a\x5e\xfc\xf8\xda\x47\xa5" "\x57\xd6\xd7\xf7\xaa\x93\xd9\xd1\x57\x1f\xfe\xf1\xe0\x3b\xbf\x48\x9a" "\x35\x93\xd5\xb4\xf7\xe3\xe5\x7c\xda\xb1\xb6\xd5\xf5\x89\xa7\x71\x12" "\xe3\x11\xf1\xc3\xf3\x05\xbb\x30\xc6\xb2\xfe\x4c\x0e\xba\x21\xbc\x94" "\x7c\x44\xbc\x13\x11\xef\xa7\xf7\xff\x6c\x8c\xa5\xaf\x26\x00\x30\xcc" "\x9a\xcd\xd9\x68\xce\xb6\x97\x01\x80\x61\x97\x4f\x73\x60\xb9\x7c\x31" "\xcb\x05\xcc\x44\x3e\x5f\x2c\xb6\x72\x78\xef\xc6\x74\xbe\x52\xab\x37" "\xae\xdc\xaa\xed\x6e\xad\xb5\x72\x65\x73\x31\x91\xbf\xb5\x51\x29\x2f" "\x66\xb9\xc2\xb9\x98\xc8\x25\xe5\xa5\xf4\xf8\x59\xb9\x74\xa2\x7c\x2d" "\x22\xde\x8e\x88\x5f\x4e\x5d\x4a\xcb\xc5\xd5\x5a\x65\x6d\x90\xff\xf0" "\x01\x80\x11\xf6\xc6\x89\xf9\xff\x3f\x53\xad\xf9\x1f\x00\x18\x72\x85" "\x41\x37\x00\x00\xe8\x3b\xf3\x3f\x00\x8c\x1e\xf3\x3f\x00\x8c\x1e\xf3" "\x3f\x00\x8c\x1e\xf3\x3f\x00\x8c\x1e\xf3\x3f\x00\x8c\x1e\xf3\x3f\x00" "\x8c\x94\x1f\x7d\xf6\x59\xb2\x35\x8f\xb2\xdf\xbf\x5e\xbb\xbd\xb7\xbb" "\x59\xbb\x7d\x75\xad\x5c\xdf\x2c\x56\x77\x57\x8b\xab\xb5\x9d\xed\xe2" "\x7a\xad\xb6\x9e\xfe\x66\x4f\xf5\xac\xeb\x55\x6a\xb5\xed\xa5\x0f\x63" "\xf7\xce\xdc\x77\xb7\xeb\x8d\x85\xfa\xde\xfe\x8d\x6a\x6d\x77\xab\x71" "\x23\xfd\x5d\xef\x1b\xe5\x89\xbe\xf4\x0a\x00\x78\x91\xb7\xdf\x7b\xf0" "\x97\x5c\x44\x1c\x7c\x72\x29\xdd\xa2\x6d\x2d\x07\x73\x35\x0c\xb7\xfc" "\xa0\x1b\x00\x0c\xcc\x58\xc7\xda\xf9\xbe\xb7\x03\xe8\x3f\xab\x7d\xc1" "\xe8\x3a\xc7\x7b\x7c\xe9\x01\x18\x12\x1d\x96\xe8\x7d\x4e\x21\x22\x2e" "\x9d\xac\x6c\x36\x9b\xcd\xd7\xd7\x24\xe0\x35\xbb\xfc\xa5\x0e\xf9\xff" "\x83\xd6\x39\x13\x3c\x0c\xb7\xb6\xfc\xbf\x6f\x01\xc3\x88\xe9\x9c\xff" "\x07\x46\x81\xfc\x3f\x8c\xae\x66\x33\xd7\xeb\x9a\xff\xd1\xeb\x03\x01" "\x80\x8b\x4d\x8e\x1f\xe8\xf2\xf9\xff\x3b\xd9\xfe\x77\xd9\x87\x03\x3f" "\x5d\x3b\xf9\x88\xfb\xbd\x5c\xfd\xd4\x37\x07\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x60\x28\x1c\xaf\xff\x5b\xcc\xd6\x02\x9f\x89\x7c\xbe\x58\x8c\x78" "\x33\x22\xe6\x62\x22\x77\x6b\xa3\x52\x5e\x8c\x88\xb7\x22\xe2\xcf\x53" "\x13\x53\x49\x79\x69\xc0\x6d\x06\x00\xce\x2b\xff\xf7\x5c\xb6\xfe\xd7" "\xe5\xd9\x0f\x66\x4e\x9e\x9d\xcc\x3d\x99\x4a\xf7\x11\xf1\xf3\x5f\x7f" "\xfe\xab\x3b\x2b\x8d\xc6\xce\x9f\x92\xfa\x7f\x3d\xad\x6f\xdc\xcf\xea" "\x4b\x83\x68\x3f\x00\x70\x96\xe3\x79\x3a\xdd\xb7\xbd\x91\x7f\x7c\x78" "\x77\xf5\x78\xeb\x67\x7b\x1e\x7d\x2f\x22\x0a\xad\xf8\x47\x87\x93\x71" "\xf4\x34\xfe\x78\x8c\xa7\xfb\x42\x4c\x44\xc4\xf4\xbf\x73\x59\xb9\x25" "\xd7\x96\xbb\x38\x8f\x83\x7b\x11\xf1\xc5\x4e\xfd\xcf\xc5\x4c\x9a\x03" "\x69\xad\x7c\x7a\x32\x7e\x12\xfb\xcd\xbe\xc6\xcf\x3f\x17\x3f\x9f\x9e" "\x6b\xed\x93\x3f\x8b\x2f\xbc\x82\xb6\xc0\xa8\x79\x90\x8c\x3f\xd7\x3b" "\xdd\x7f\xf9\x98\x4f\xf7\x9d\xef\xff\x42\x3a\x42\x9d\x5f\x36\xfe\x25" "\x97\x5a\x3d\x4a\xc7\xc0\x67\xf1\x8f\xc7\xbf\xb1\x2e\xe3\xdf\x7c\xaf" "\x31\x3e\xfc\xc3\x0f\x5a\x47\xa7\xd7\x61\x7e\x74\x2f\xe2\xcb\xe3\x11" "\xc7\xb1\x8f\xda\xc6\x9f\xe3\xf8\xb9\x2e\xf1\x3f\xe8\x31\xfe\x5f\xbf" "\xf2\xb5\xf7\xbb\x9d\x6b\xfe\x26\xe2\x72\x74\x8e\xdf\x1e\x6b\xa1\x51" "\xdd\x5e\xa8\xef\xed\x5f\xdd\xa8\xae\xac\x97\xd7\xcb\x5b\xa5\xd2\xf2" "\xd2\xf2\xe2\xc7\xd7\x3e\x2a\x2d\xa4\x39\xea\x85\xee\xb3\xc1\x3f\x3e" "\xb9\xf2\x56\xb7\x73\x49\xff\xa7\xbb\xc4\x2f\x9c\xd1\xff\x6f\xf6\xd8" "\xff\xdf\xfe\xf7\xe6\x4f\xbe\xfe\x82\xf8\xdf\xfe\x46\xa7\xf8\xf9\x78" "\xf7\x05\xf1\x93\x39\xf1\x5b\x3d\xc6\x5f\x99\xfe\x7d\xa1\xdb\xb9\x24" "\xfe\x5a\x97\xfe\x9f\xf5\xfa\x5f\xe9\x31\xfe\xc3\xbf\xed\x9f\x5a\x36" "\x1c\x00\x18\x9c\xfa\xde\xfe\xe6\x4a\xa5\x52\xde\x71\xe0\xe0\xe2\x1f" "\x24\x7f\x65\x2f\x40\x33\x3a\x1e\x7c\xda\xaf\x58\x93\xf1\x7f\x3d\xab" "\xd9\x7c\xa9\x58\xdd\x46\x8c\x57\x91\x75\x03\x2e\x82\xf4\x5e\xbf\x5e" "\x29\xef\x44\xc4\x93\x41\x37\x06\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\xe8\xa8\x1f\xff\x63\x69\xd0\x7d\x04\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\x00\x00\x00\x60\x78\xfd\x2f\x00\x00\xff\xff\x2c" "\xde\xd2\xf4", 1278); syz_mount_image( /*fs=*/0x20000040, /*dir=*/0x20000000, /*flags=MS_POSIXACL|MS_SYNCHRONOUS|MS_RELATIME|MS_NOSUID|0x80c*/ 0x21081e, /*opts=*/0x20000dc0, /*chdir=*/1, /*size=*/0x4fe, /*img=*/0x20000080); break; case 6: *(uint32_t*)0x20000400 = -1; *(uint64_t*)0x20000408 = 0; *(uint64_t*)0x20000410 = 0x20000000; *(uint64_t*)0x20000418 = 0; syscall(__NR_bpf, /*cmd=*/2ul, /*arg=*/0x20000400ul, /*size=*/0x20ul); break; case 7: memcpy((void*)0x20000140, "./file0/file0\000", 14); syscall(__NR_creat, /*file=*/0x20000140ul, /*mode=*/0ul); break; case 8: *(uint32_t*)0x20000440 = 7; *(uint32_t*)0x20000444 = 5; *(uint64_t*)0x20000448 = 0; *(uint64_t*)0x20000450 = 0; *(uint32_t*)0x20000458 = 3; *(uint32_t*)0x2000045c = 0; *(uint64_t*)0x20000460 = 0; *(uint32_t*)0x20000468 = 0; *(uint32_t*)0x2000046c = 0; memset((void*)0x20000470, 0, 16); *(uint32_t*)0x20000480 = 0; *(uint32_t*)0x20000484 = 0; *(uint32_t*)0x20000488 = -1; *(uint32_t*)0x2000048c = 8; *(uint64_t*)0x20000490 = 0; *(uint32_t*)0x20000498 = 0; *(uint32_t*)0x2000049c = 0x10; *(uint64_t*)0x200004a0 = 0; *(uint32_t*)0x200004a8 = 0; *(uint32_t*)0x200004ac = 0; *(uint32_t*)0x200004b0 = 0; *(uint32_t*)0x200004b4 = 0; *(uint64_t*)0x200004b8 = 0; *(uint64_t*)0x200004c0 = 0; *(uint32_t*)0x200004c8 = 0x10; *(uint32_t*)0x200004cc = 0; syscall(__NR_bpf, /*cmd=*/5ul, /*arg=*/0x20000440ul, /*size=*/0x90ul); break; } } int main(void) { syscall(__NR_mmap, /*addr=*/0x1ffff000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x20000000ul, /*len=*/0x1000000ul, /*prot=PROT_WRITE|PROT_READ|PROT_EXEC*/ 7ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x21000000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=MAP_FIXED|MAP_ANONYMOUS|MAP_PRIVATE*/ 0x32ul, /*fd=*/-1, /*offset=*/0ul); for (procid = 0; procid < 5; procid++) { if (fork() == 0) { loop(); } } sleep(1000000); return 0; }