// https://syzkaller.appspot.com/bug?id=ff834988a0e05a23199aa0230d9afa4b010c69d2 // 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 #ifndef __NR_memfd_create #define __NR_memfd_create 319 #endif static unsigned long long procid; //% 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, 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 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, loopfd = -1, 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) { memset(loopname, 0, sizeof(loopname)); snprintf(loopname, sizeof(loopname), "/dev/loop%llu", procid); if (setup_loop_device(data, size, loopname, &loopfd) == -1) return -1; 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) { ioctl(loopfd, LOOP_CLR_FD, 0); close(loopfd); } errno = err; return res; } uint64_t r[1] = {0xffffffffffffffff}; int main(void) { syscall(__NR_mmap, /*addr=*/0x1ffff000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=*/0x32ul, /*fd=*/-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x20000000ul, /*len=*/0x1000000ul, /*prot=*/7ul, /*flags=*/0x32ul, /*fd=*/-1, /*offset=*/0ul); syscall(__NR_mmap, /*addr=*/0x21000000ul, /*len=*/0x1000ul, /*prot=*/0ul, /*flags=*/0x32ul, /*fd=*/-1, /*offset=*/0ul); intptr_t res = 0; memcpy((void*)0x200004c0, "udf\000", 4); memcpy((void*)0x20000000, "./file1\000", 8); *(uint64_t*)0x20000100 = 0; memcpy( (void*)0x20000a40, "\x78\x9c\xec\xdb\x4b\x6c\x1b\x45\x1c\xc7\xf1\xdf\x6c\x6c\xd7\x71\x2b\xea" "\xa6\x49\x5a\x50\x45\x2d\xb5\xa8\x55\x11\x51\x1e\x4d\x52\x14\x04\x0a\x49" "\x83\x90\x9a\x14\x92\xa6\x02\x44\x2b\x85\xd8\x09\x56\x9d\x07\x71\x4a\x9b" "\x8a\x47\x6f\xa8\x27\x04\x52\x0f\x48\x5c\x91\x10\x42\x55\xe8\x0d\x24\x8e" "\x48\xdc\x91\x7a\x41\x3d\xc2\x85\x8b\x0f\x95\x38\x21\xa1\x59\xef\x7a\xd7" "\x89\xd3\x24\x75\xec\x3c\xfa\xfd\x48\x89\xc7\xeb\xff\xee\xce\xce\xec\xec" "\x8c\x77\xc7\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\xd2\xeb\xe7" "\xfb\xdb\x3b\xcc\x76\xe7\x02\x00\x00\xd4\xd3\xc8\xd8\x68\x7b\x27\xfd\x3f" "\x00\x00\x4f\x95\x4b\x7c\xff\x07\x00\x00\x78\x9a\x18\x39\x2a\xc8\xe8\xcb" "\xe3\x05\x33\xec\xbe\x2f\x8a\x5f\xc8\xce\x5e\xbf\x39\x3e\x38\x54\x79\xb5" "\x46\xe3\xae\xd9\xe0\xc6\xdb\xbf\x78\x47\x67\xd7\xd9\xee\x9e\xde\x73\xfe" "\xeb\xe3\xd7\xdf\x6a\xcf\xea\xe2\xd8\xa5\xfe\xd4\xc0\xdc\xcc\xfc\x42\x26" "\x9f\xcf\xa4\x53\xe3\xb3\xd9\xc9\xb9\x74\x66\xc3\x5b\xa8\x76\xfd\x95\xce" "\xb8\x05\x90\x9a\xb9\x76\x3d\x3d\x35\x95\x4f\x75\xb6\x75\x95\x7d\x7c\x33" "\xf9\xf7\xbe\xfd\xad\xc9\xbe\xde\x68\x6b\xd2\x8f\x1d\x1f\x1c\x1a\x1a\x0b" "\xc5\x44\xa2\x4f\xbc\xf7\x55\xd6\x1a\xe1\xc7\xe4\xe8\x0b\x19\x15\xbe\xba" "\x67\x46\x24\x39\xaa\xbe\x2c\xd6\x39\x77\x6a\xad\xd1\x3d\x88\x33\xee\x41" "\x8c\x0f\x0e\xb9\x07\x92\xcb\x4e\xcc\x2e\xda\x0f\x8d\x5f\x10\x4e\x79\x99" "\xc4\xfc\x32\xaa\x43\x5d\x54\xa5\x59\xb2\xf9\x32\xb1\xad\xf9\xce\x16\x95" "\xa3\xbc\x8c\x5a\x5a\x0b\xe6\xa2\xa4\x06\xbf\x1c\x5e\x74\x6f\x0c\xaf\xbf" "\x01\x67\x4b\xb2\xb1\x69\x36\x9f\x57\x24\xa5\xb4\x0b\xea\x6c\x07\xdb\x27" "\x47\xdd\x32\xfa\xfa\xe5\xa4\xde\xb2\x65\xe6\xd7\x7f\x44\xfa\x74\xbb\x33" "\x87\x9a\x8b\xc8\xd1\x3d\x19\x9d\x7a\xb5\x60\xde\x76\xaf\x07\xb6\x3d\xd9" "\xcb\xe6\x85\xcb\xa9\x37\x67\xa7\xe6\x42\xb1\xc6\x78\x2d\x6a\xb7\xf7\x0f" "\xf5\xb4\xc3\xaf\x4d\x71\x39\x1a\x71\x5b\x7c\xc1\x8c\x6e\x77\x66\x50\x77" "\x76\xb0\xd4\x24\xa3\xa3\x2f\x7c\xec\x8e\x2b\xe4\x8e\x4b\x0f\xf6\xf5\x9e" "\x1c\x38\x19\x1e\x61\x1c\x59\x67\x3b\x36\xb6\xcd\x7b\xdd\x48\x9f\x1c\x0d" "\x0d\x1d\xcc\x36\x8d\x21\x00\x00\x00\x00\x00\x00\x80\xbd\x2e\x6e\x1c\x5d" "\x95\xd1\x37\x3f\xc5\xdd\xf7\x29\xef\x19\x90\xa4\xdb\x6b\xaf\xe5\x44\xea" "\x94\x3d\xd4\x9a\x71\x34\x21\xa3\x47\x37\x0a\xee\xa3\xf1\xf0\xbc\x84\x86" "\xd0\xfc\x8e\x92\xdd\xfe\xec\xa7\xb6\xf9\x6f\x8c\x0f\xcc\xcd\x2f\x2d\x64" "\xa7\x3f\x5c\xac\xf8\x79\x22\xde\xff\x41\x7e\x71\x61\x62\xb2\xf2\xc7\x6a" "\xb4\x8d\xaf\xec\x76\xf8\x7a\xf3\x18\xaa\x14\x35\x8e\x86\x65\xf4\xc6\xe8" "\xf7\xc1\x6d\xf8\xa4\xb1\x79\xf0\xda\x78\x43\x29\xf6\xbb\x57\x82\xbc\xc5" "\x57\xee\xdf\x3d\x6f\x9e\x29\xce\x67\xf1\x9f\x21\x9c\x78\xaf\x25\x9c\xae" "\x98\xe5\x4d\x3c\x1f\xb3\xfb\x34\xc6\xd1\x6b\x32\x9a\xfa\xe5\xa8\x9b\x17" "\xa3\x84\x56\x95\x99\x8a\x71\xcd\x32\x7a\xff\xee\x31\x2f\xce\x89\x85\x0e" "\x4a\xc9\xe2\x16\xa7\xb2\xb9\x4c\xbb\x8d\xfd\x4f\x46\x4d\xbf\xfb\xb1\xee" "\xb4\x18\xbb\x65\xd7\xe1\x20\xb6\xc3\xc6\x7e\x24\xa3\x3b\xbf\x95\xc7\xee" "\xf7\x62\x9b\x83\xd8\x4e\x1b\xfb\x40\x46\x0f\x1f\x54\x8e\x6d\x09\x62\xbb" "\x6c\xec\x0d\x19\xe5\x1f\xa6\xfc\xd8\x84\x4d\x3c\xef\xc5\xb6\x06\xb1\x6d" "\x93\x73\xb9\x74\xa5\xa2\x04\x36\xcb\xb6\xff\xb4\x3d\x47\xdf\x4d\x19\xaf" "\x6d\x1c\x57\xf1\xfc\x5b\xdd\xfe\x3f\x09\xfa\x82\x55\x83\x83\x52\x3b\xef" "\x6c\x59\x2b\xfd\x24\xed\x3f\x19\x5a\x76\xdb\x6b\xd7\x7f\xd9\xf6\x7f\xf5" "\xa8\x37\x57\x25\xe1\x36\xfe\x4a\xed\xff\x8e\x8c\x96\xfe\x39\xe6\xcf\x69" "\x71\xdb\x9e\x7f\x59\x39\xe4\xfe\x0f\xda\x7f\x4e\x46\xf7\xef\x96\xc7\xfa" "\x13\x05\x9a\x82\xd8\x8e\x0d\x17\xec\x2e\x61\xeb\xff\xb4\xbd\xf6\xbd\xb3" "\x5c\x2a\x1b\xaf\x0c\xbc\xb7\x41\xad\x85\xeb\xff\xb9\x95\x67\x47\x8d\xea" "\xff\x50\x68\x59\xd2\xdb\x6f\x6c\x6b\x0e\x1d\x92\xf2\x4b\xb7\xae\x4d\xe4" "\x72\x99\x05\x12\x24\x48\x90\x28\x25\xca\xaf\x13\x4c\xd1\xd9\x9b\x6c\xff" "\xff\xb3\x8c\x0e\xfe\xfa\x67\x69\xbc\xe3\xf5\xff\x07\x8a\xef\x82\xf1\xdf" "\xbf\x9f\x05\xfd\x7f\xdf\xca\x0d\xd5\xa8\xff\x6f\x0a\x2d\xeb\xf3\x46\x23" "\xd1\x88\x14\x5f\x9c\x99\x8f\x1e\x91\xe2\xf9\xa5\x5b\x2f\x65\x67\x26\xa6" "\x33\xd3\x99\x7d\x92\xce\xf5\x74\xf7\xf6\x74\x9d\x8d\xc6\xfc\xc1\x5d\x90" "\xaa\xba\xac\xf6\x22\x5b\xff\xf7\x65\x74\x7e\xf9\x87\xd2\xf7\xdd\xf2\xf1" "\x5f\xe5\xf1\x7f\x62\xe5\x86\x2a\xd6\x79\xf5\xdf\xff\x0f\x87\x96\x25\xca" "\xc6\x2b\x55\x1f\x3a\x6c\xfd\xc7\xa4\x47\x32\xfa\xe3\xca\x72\xe9\xbe\xc4" "\xe3\xc6\xff\x7e\x3f\x70\xfa\x44\xf1\xb5\xd4\x3e\xd7\xa8\xf3\x6a\xeb\xbf" "\x39\xb4\x2c\xe9\xed\xf7\xc0\xd6\x1c\x3a\x00\x00\x00\x00\x00\x00\x00\x00" "\x00\x00\x00\x00\x00\xec\x6a\x51\xe3\xe8\x47\x19\x5d\x3e\x13\x31\xfe\x6f" "\xcd\x36\x32\xff\x6f\xd5\x0f\xd0\x6a\x34\xff\xab\x35\xb4\x2c\x5d\xa7\xdf" "\x2b\x54\x5d\xa8\x00\x00\xec\x70\x8e\x1c\x7d\x2b\xa3\x53\x2a\x98\xcf\xed" "\x82\x03\xd2\x70\xf8\x15\x7b\xda\xff\x01\x00\x00\xff\xff\xc3\x87\x1d" "\x2f", 1170); syz_mount_image(/*fs=*/0x200004c0, /*dir=*/0x20000000, /*flags=*/0, /*opts=*/0x20000100, /*chdir=*/1, /*size=*/0x492, /*img=*/0x20000a40); memcpy((void*)0x200005c0, "./bus\000", 6); syscall(__NR_open, /*file=*/0x200005c0ul, /*flags=*/0x68842ul, /*mode=*/0ul); memcpy((void*)0x20000140, "./bus\000", 6); syscall(__NR_mount, /*src=*/0x20000000ul, /*dst=*/0x20000140ul, /*type=*/0ul, /*flags=*/0x1000ul, /*data=*/0ul); memcpy((void*)0x20000400, "./bus\000", 6); res = syscall(__NR_open, /*file=*/0x20000400ul, /*flags=*/0x14113eul, /*mode=*/0ul); if (res != -1) r[0] = res; syscall(__NR_write, /*fd=*/r[0], /*data=*/0x20000000ul, /*len=*/0x208e24bul); return 0; }