// https://syzkaller.appspot.com/bug?id=47ca2ff42f9c5d5d353149ecc97f29de7828bbfd // 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 #ifndef SYS_mmap #define SYS_mmap 197 #endif static unsigned long long procid; static void kill_and_wait(int pid, int* status) { kill(pid, SIGKILL); while (waitpid(-1, status, 0) != pid) { } } 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 __attribute__((noinline)) remove_dir(const char* dir) { DIR* dp = opendir(dir); if (dp == NULL) { if (errno == EACCES) { if (rmdir(dir)) exit(1); return; } 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); struct stat st; if (lstat(filename, &st)) exit(1); if (S_ISDIR(st.st_mode)) { remove_dir(filename); continue; } if (unlink(filename)) exit(1); } closedir(dp); if (rmdir(dir)) 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 { pthread_mutex_t mu; pthread_cond_t cv; int state; } event_t; static void event_init(event_t* ev) { if (pthread_mutex_init(&ev->mu, 0)) exit(1); if (pthread_cond_init(&ev->cv, 0)) exit(1); ev->state = 0; } static void event_reset(event_t* ev) { ev->state = 0; } static void event_set(event_t* ev) { pthread_mutex_lock(&ev->mu); if (ev->state) exit(1); ev->state = 1; pthread_mutex_unlock(&ev->mu); pthread_cond_broadcast(&ev->cv); } static void event_wait(event_t* ev) { pthread_mutex_lock(&ev->mu); while (!ev->state) pthread_cond_wait(&ev->cv, &ev->mu); pthread_mutex_unlock(&ev->mu); } static int event_isset(event_t* ev) { pthread_mutex_lock(&ev->mu); int res = ev->state; pthread_mutex_unlock(&ev->mu); return res; } static int event_timedwait(event_t* ev, uint64_t timeout) { uint64_t start = current_time_ms(); uint64_t now = start; pthread_mutex_lock(&ev->mu); for (;;) { if (ev->state) break; uint64_t remain = timeout - (now - start); struct timespec ts; ts.tv_sec = remain / 1000; ts.tv_nsec = (remain % 1000) * 1000 * 1000; pthread_cond_timedwait(&ev->cv, &ev->mu, &ts); now = current_time_ms(); if (now - start > timeout) break; } int res = ev->state; pthread_mutex_unlock(&ev->mu); return res; } #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)))) struct usb_endpoint_descriptor { uint8_t bLength; uint8_t bDescriptorType; uint8_t bEndpointAddress; uint8_t bmAttributes; uint16_t wMaxPacketSize; uint8_t bInterval; uint8_t bRefresh; uint8_t bSynchAddress; } __attribute__((packed)); struct usb_device_descriptor { uint8_t bLength; uint8_t bDescriptorType; uint16_t bcdUSB; uint8_t bDeviceClass; uint8_t bDeviceSubClass; uint8_t bDeviceProtocol; uint8_t bMaxPacketSize0; uint16_t idVendor; uint16_t idProduct; uint16_t bcdDevice; uint8_t iManufacturer; uint8_t iProduct; uint8_t iSerialNumber; uint8_t bNumConfigurations; } __attribute__((packed)); struct usb_config_descriptor { uint8_t bLength; uint8_t bDescriptorType; uint16_t wTotalLength; uint8_t bNumInterfaces; uint8_t bConfigurationValue; uint8_t iConfiguration; uint8_t bmAttributes; uint8_t bMaxPower; } __attribute__((packed)); struct usb_interface_descriptor { uint8_t bLength; uint8_t bDescriptorType; uint8_t bInterfaceNumber; uint8_t bAlternateSetting; uint8_t bNumEndpoints; uint8_t bInterfaceClass; uint8_t bInterfaceSubClass; uint8_t bInterfaceProtocol; uint8_t iInterface; } __attribute__((packed)); struct usb_ctrlrequest { uint8_t bRequestType; uint8_t bRequest; uint16_t wValue; uint16_t wIndex; uint16_t wLength; } __attribute__((packed)); struct usb_qualifier_descriptor { uint8_t bLength; uint8_t bDescriptorType; uint16_t bcdUSB; uint8_t bDeviceClass; uint8_t bDeviceSubClass; uint8_t bDeviceProtocol; uint8_t bMaxPacketSize0; uint8_t bNumConfigurations; uint8_t bRESERVED; } __attribute__((packed)); #define USB_TYPE_MASK (0x03 << 5) #define USB_TYPE_STANDARD (0x00 << 5) #define USB_TYPE_CLASS (0x01 << 5) #define USB_TYPE_VENDOR (0x02 << 5) #define USB_TYPE_RESERVED (0x03 << 5) #define USB_DT_DEVICE 0x01 #define USB_DT_CONFIG 0x02 #define USB_DT_STRING 0x03 #define USB_DT_INTERFACE 0x04 #define USB_DT_ENDPOINT 0x05 #define USB_DT_DEVICE_QUALIFIER 0x06 #define USB_DT_OTHER_SPEED_CONFIG 0x07 #define USB_DT_INTERFACE_POWER 0x08 #define USB_DT_OTG 0x09 #define USB_DT_DEBUG 0x0a #define USB_DT_INTERFACE_ASSOCIATION 0x0b #define USB_DT_SECURITY 0x0c #define USB_DT_KEY 0x0d #define USB_DT_ENCRYPTION_TYPE 0x0e #define USB_DT_BOS 0x0f #define USB_DT_DEVICE_CAPABILITY 0x10 #define USB_DT_WIRELESS_ENDPOINT_COMP 0x11 #define USB_DT_WIRE_ADAPTER 0x21 #define USB_DT_RPIPE 0x22 #define USB_DT_CS_RADIO_CONTROL 0x23 #define USB_DT_PIPE_USAGE 0x24 #define USB_DT_SS_ENDPOINT_COMP 0x30 #define USB_DT_SSP_ISOC_ENDPOINT_COMP 0x31 #define USB_REQ_GET_STATUS 0x00 #define USB_REQ_CLEAR_FEATURE 0x01 #define USB_REQ_SET_FEATURE 0x03 #define USB_REQ_SET_ADDRESS 0x05 #define USB_REQ_GET_DESCRIPTOR 0x06 #define USB_REQ_SET_DESCRIPTOR 0x07 #define USB_REQ_GET_CONFIGURATION 0x08 #define USB_REQ_SET_CONFIGURATION 0x09 #define USB_REQ_GET_INTERFACE 0x0A #define USB_REQ_SET_INTERFACE 0x0B #define USB_REQ_SYNCH_FRAME 0x0C #define USB_REQ_SET_SEL 0x30 #define USB_REQ_SET_ISOCH_DELAY 0x31 #define USB_REQ_SET_ENCRYPTION 0x0D #define USB_REQ_GET_ENCRYPTION 0x0E #define USB_REQ_RPIPE_ABORT 0x0E #define USB_REQ_SET_HANDSHAKE 0x0F #define USB_REQ_RPIPE_RESET 0x0F #define USB_REQ_GET_HANDSHAKE 0x10 #define USB_REQ_SET_CONNECTION 0x11 #define USB_REQ_SET_SECURITY_DATA 0x12 #define USB_REQ_GET_SECURITY_DATA 0x13 #define USB_REQ_SET_WUSB_DATA 0x14 #define USB_REQ_LOOPBACK_DATA_WRITE 0x15 #define USB_REQ_LOOPBACK_DATA_READ 0x16 #define USB_REQ_SET_INTERFACE_DS 0x17 #define USB_REQ_GET_PARTNER_PDO 20 #define USB_REQ_GET_BATTERY_STATUS 21 #define USB_REQ_SET_PDO 22 #define USB_REQ_GET_VDM 23 #define USB_REQ_SEND_VDM 24 #define USB_MAX_IFACE_NUM 4 #define USB_MAX_EP_NUM 32 #define USB_MAX_FDS 6 struct usb_endpoint_index { struct usb_endpoint_descriptor desc; int handle; }; struct usb_iface_index { struct usb_interface_descriptor* iface; uint8_t bInterfaceNumber; uint8_t bAlternateSetting; uint8_t bInterfaceClass; struct usb_endpoint_index eps[USB_MAX_EP_NUM]; int eps_num; }; struct usb_device_index { struct usb_device_descriptor* dev; struct usb_config_descriptor* config; uint8_t bDeviceClass; uint8_t bMaxPower; int config_length; struct usb_iface_index ifaces[USB_MAX_IFACE_NUM]; int ifaces_num; int iface_cur; }; struct usb_info { int fd; struct usb_device_index index; }; static struct usb_info usb_devices[USB_MAX_FDS]; static int usb_devices_num; static bool parse_usb_descriptor(const char* buffer, size_t length, struct usb_device_index* index) { if (length < sizeof(*index->dev) + sizeof(*index->config)) return false; memset(index, 0, sizeof(*index)); index->dev = (struct usb_device_descriptor*)buffer; index->config = (struct usb_config_descriptor*)(buffer + sizeof(*index->dev)); index->bDeviceClass = index->dev->bDeviceClass; index->bMaxPower = index->config->bMaxPower; index->config_length = length - sizeof(*index->dev); index->iface_cur = -1; size_t offset = 0; while (true) { if (offset + 1 >= length) break; uint8_t desc_length = buffer[offset]; uint8_t desc_type = buffer[offset + 1]; if (desc_length <= 2) break; if (offset + desc_length > length) break; if (desc_type == USB_DT_INTERFACE && index->ifaces_num < USB_MAX_IFACE_NUM) { struct usb_interface_descriptor* iface = (struct usb_interface_descriptor*)(buffer + offset); index->ifaces[index->ifaces_num].iface = iface; index->ifaces[index->ifaces_num].bInterfaceNumber = iface->bInterfaceNumber; index->ifaces[index->ifaces_num].bAlternateSetting = iface->bAlternateSetting; index->ifaces[index->ifaces_num].bInterfaceClass = iface->bInterfaceClass; index->ifaces_num++; } if (desc_type == USB_DT_ENDPOINT && index->ifaces_num > 0) { struct usb_iface_index* iface = &index->ifaces[index->ifaces_num - 1]; if (iface->eps_num < USB_MAX_EP_NUM) { memcpy(&iface->eps[iface->eps_num].desc, buffer + offset, sizeof(iface->eps[iface->eps_num].desc)); iface->eps_num++; } } offset += desc_length; } return true; } static struct usb_device_index* add_usb_index(int fd, const char* dev, size_t dev_len) { int i = __atomic_fetch_add(&usb_devices_num, 1, __ATOMIC_RELAXED); if (i >= USB_MAX_FDS) return NULL; if (!parse_usb_descriptor(dev, dev_len, &usb_devices[i].index)) return NULL; __atomic_store_n(&usb_devices[i].fd, fd, __ATOMIC_RELEASE); return &usb_devices[i].index; } static struct usb_device_index* lookup_usb_index(int fd) { for (int i = 0; i < USB_MAX_FDS; i++) { if (__atomic_load_n(&usb_devices[i].fd, __ATOMIC_ACQUIRE) == fd) return &usb_devices[i].index; } return NULL; } struct vusb_connect_string_descriptor { uint32_t len; char* str; } __attribute__((packed)); struct vusb_connect_descriptors { uint32_t qual_len; char* qual; uint32_t bos_len; char* bos; uint32_t strs_len; struct vusb_connect_string_descriptor strs[0]; } __attribute__((packed)); static const char default_string[] = {8, USB_DT_STRING, 's', 0, 'y', 0, 'z', 0}; static const char default_lang_id[] = {4, USB_DT_STRING, 0x09, 0x04}; static bool lookup_connect_response_in(int fd, const struct vusb_connect_descriptors* descs, const struct usb_ctrlrequest* ctrl, char** response_data, uint32_t* response_length) { struct usb_device_index* index = lookup_usb_index(fd); uint8_t str_idx; if (!index) return false; switch (ctrl->bRequestType & USB_TYPE_MASK) { case USB_TYPE_STANDARD: switch (ctrl->bRequest) { case USB_REQ_GET_DESCRIPTOR: switch (ctrl->wValue >> 8) { case USB_DT_DEVICE: *response_data = (char*)index->dev; *response_length = sizeof(*index->dev); return true; case USB_DT_CONFIG: *response_data = (char*)index->config; *response_length = index->config_length; return true; case USB_DT_STRING: str_idx = (uint8_t)ctrl->wValue; if (descs && str_idx < descs->strs_len) { *response_data = descs->strs[str_idx].str; *response_length = descs->strs[str_idx].len; return true; } if (str_idx == 0) { *response_data = (char*)&default_lang_id[0]; *response_length = default_lang_id[0]; return true; } *response_data = (char*)&default_string[0]; *response_length = default_string[0]; return true; case USB_DT_BOS: *response_data = descs->bos; *response_length = descs->bos_len; return true; case USB_DT_DEVICE_QUALIFIER: if (!descs->qual) { struct usb_qualifier_descriptor* qual = (struct usb_qualifier_descriptor*)response_data; qual->bLength = sizeof(*qual); qual->bDescriptorType = USB_DT_DEVICE_QUALIFIER; qual->bcdUSB = index->dev->bcdUSB; qual->bDeviceClass = index->dev->bDeviceClass; qual->bDeviceSubClass = index->dev->bDeviceSubClass; qual->bDeviceProtocol = index->dev->bDeviceProtocol; qual->bMaxPacketSize0 = index->dev->bMaxPacketSize0; qual->bNumConfigurations = index->dev->bNumConfigurations; qual->bRESERVED = 0; *response_length = sizeof(*qual); return true; } *response_data = descs->qual; *response_length = descs->qual_len; return true; default: break; } break; default: break; } break; default: break; } return false; } typedef bool (*lookup_connect_out_response_t)( int fd, const struct vusb_connect_descriptors* descs, const struct usb_ctrlrequest* ctrl, bool* done); static bool lookup_connect_response_out_generic( int fd, const struct vusb_connect_descriptors* descs, const struct usb_ctrlrequest* ctrl, bool* done) { switch (ctrl->bRequestType & USB_TYPE_MASK) { case USB_TYPE_STANDARD: switch (ctrl->bRequest) { case USB_REQ_SET_CONFIGURATION: *done = true; return true; default: break; } break; } return false; } static int vhci_open(void) { char path[1024]; snprintf(path, sizeof(path), "/dev/vhci%llu", procid); return open(path, O_RDWR); } static int vhci_setport(int fd, u_int port) { struct vhci_ioc_set_port args; args.port = port; return ioctl(fd, VHCI_IOC_SET_PORT, &args); } static int vhci_usb_attach(int fd) { return ioctl(fd, VHCI_IOC_USB_ATTACH, NULL); } static int vhci_usb_recv(int fd, void* buf, size_t size) { uint8_t* ptr = (uint8_t*)buf; while (1) { ssize_t done = read(fd, ptr, size); if (done < 0) return -1; if ((size_t)done == size) return 0; size -= done; ptr += done; } } static int vhci_usb_send(int fd, void* buf, size_t size) { uint8_t* ptr = (uint8_t*)buf; while (1) { ssize_t done = write(fd, ptr, size); if (done <= 0) return -1; if ((size_t)done == size) return 0; size -= done; ptr += done; } } static volatile long syz_usb_connect_impl(int fd, uint64_t speed, uint64_t dev_len, const char* dev, const struct vusb_connect_descriptors* descs, lookup_connect_out_response_t lookup_connect_response_out) { struct usb_device_index* index = add_usb_index(fd, dev, dev_len); if (!index) { return -1; } if (vhci_setport(fd, 1)) exit(1); if (vhci_usb_attach(fd)) { return -1; } bool done = false; while (!done) { vhci_request_t req; if (vhci_usb_recv(fd, &req, sizeof(req))) { return -1; } if (req.type != VHCI_REQ_CTRL) { return -1; } char* response_data = NULL; uint32_t response_length = 0; char data[4096]; if (req.u.ctrl.bmRequestType & UE_DIR_IN) { if (!lookup_connect_response_in( fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &response_data, &response_length)) { return -1; } } else { if (!lookup_connect_response_out( fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &done)) { return -1; } response_data = NULL; response_length = UGETW(req.u.ctrl.wLength); } if ((req.u.ctrl.bmRequestType & USB_TYPE_MASK) == USB_TYPE_STANDARD && req.u.ctrl.bRequest == USB_REQ_SET_CONFIGURATION) { } if (response_length > sizeof(data)) response_length = 0; if ((uint32_t)UGETW(req.u.ctrl.wLength) < response_length) response_length = UGETW(req.u.ctrl.wLength); if (response_data) memcpy(data, response_data, response_length); else memset(data, 0, response_length); int rv = 0; if (req.u.ctrl.bmRequestType & UE_DIR_IN) { if (response_length > 0) { vhci_response_t res; res.size = response_length; rv = vhci_usb_send(fd, &res, sizeof(res)); if (rv == 0) rv = vhci_usb_send(fd, data, response_length); } } else { rv = vhci_usb_recv(fd, data, response_length); } if (rv < 0) { return -1; } } sleep_ms(200); return fd; } static volatile long syz_usb_connect(volatile long a0, volatile long a1, volatile long a2, volatile long a3) { uint64_t speed = a0; uint64_t dev_len = a1; const char* dev = (const char*)a2; const struct vusb_connect_descriptors* descs = (const struct vusb_connect_descriptors*)a3; if (!dev) { return -1; } int fd = vhci_open(); if (fd < 0) exit(1); long res = syz_usb_connect_impl(fd, speed, dev_len, dev, descs, &lookup_connect_response_out_generic); close(fd); return res; } static void sandbox_common() { struct rlimit rlim; rlim.rlim_cur = rlim.rlim_max = 8 << 20; setrlimit(RLIMIT_MEMLOCK, &rlim); rlim.rlim_cur = rlim.rlim_max = 1 << 20; setrlimit(RLIMIT_FSIZE, &rlim); rlim.rlim_cur = rlim.rlim_max = 1 << 20; setrlimit(RLIMIT_STACK, &rlim); rlim.rlim_cur = rlim.rlim_max = 0; setrlimit(RLIMIT_CORE, &rlim); rlim.rlim_cur = rlim.rlim_max = 256; setrlimit(RLIMIT_NOFILE, &rlim); } static void loop(); static int do_sandbox_none(void) { sandbox_common(); loop(); return 0; } 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 < 4; 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); if (call == 1) break; event_timedwait(&th->done, 50 + (call == 0 ? 3000 : 0) + (call == 1 ? 3000 : 0) + (call == 2 ? 3000 : 0) + (call == 3 ? 3000 : 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 0 static void loop(void) { int iter = 0; for (;; iter++) { char cwdbuf[32]; sprintf(cwdbuf, "./%d", iter); if (mkdir(cwdbuf, 0777)) exit(1); int pid = fork(); if (pid < 0) exit(1); if (pid == 0) { if (chdir(cwdbuf)) exit(1); 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; } remove_dir(cwdbuf); } } void execute_call(int call) { switch (call) { case 0: *(uint8_t*)0x20000e40 = 0x12; *(uint8_t*)0x20000e41 = 1; *(uint16_t*)0x20000e42 = 0x300; *(uint8_t*)0x20000e44 = 0; *(uint8_t*)0x20000e45 = 0; *(uint8_t*)0x20000e46 = 0; *(uint8_t*)0x20000e47 = 8; *(uint16_t*)0x20000e48 = 0x1d6b; *(uint16_t*)0x20000e4a = 0x101; *(uint16_t*)0x20000e4c = 0x40; *(uint8_t*)0x20000e4e = 1; *(uint8_t*)0x20000e4f = 2; *(uint8_t*)0x20000e50 = 3; *(uint8_t*)0x20000e51 = 1; *(uint8_t*)0x20000e52 = 9; *(uint8_t*)0x20000e53 = 2; *(uint16_t*)0x20000e54 = 0x97; *(uint8_t*)0x20000e56 = 3; *(uint8_t*)0x20000e57 = 1; *(uint8_t*)0x20000e58 = 4; *(uint8_t*)0x20000e59 = 0x30; *(uint8_t*)0x20000e5a = 4; *(uint8_t*)0x20000e5b = 9; *(uint8_t*)0x20000e5c = 4; *(uint8_t*)0x20000e5d = 0; *(uint8_t*)0x20000e5e = 0; *(uint8_t*)0x20000e5f = 0; *(uint8_t*)0x20000e60 = 1; *(uint8_t*)0x20000e61 = 1; *(uint8_t*)0x20000e62 = 0; *(uint8_t*)0x20000e63 = 0; *(uint8_t*)0x20000e64 = 0xa; *(uint8_t*)0x20000e65 = 0x24; *(uint8_t*)0x20000e66 = 1; *(uint16_t*)0x20000e67 = 0xffc0; *(uint8_t*)0x20000e69 = 0x20; *(uint8_t*)0x20000e6a = 2; *(uint8_t*)0x20000e6b = 1; *(uint8_t*)0x20000e6c = 2; *(uint8_t*)0x20000e6d = 9; *(uint8_t*)0x20000e6e = 4; *(uint8_t*)0x20000e6f = 1; *(uint8_t*)0x20000e70 = 0; *(uint8_t*)0x20000e71 = 0; *(uint8_t*)0x20000e72 = 1; *(uint8_t*)0x20000e73 = 2; *(uint8_t*)0x20000e74 = 0; *(uint8_t*)0x20000e75 = 0; *(uint8_t*)0x20000e76 = 9; *(uint8_t*)0x20000e77 = 4; *(uint8_t*)0x20000e78 = 1; *(uint8_t*)0x20000e79 = 1; *(uint8_t*)0x20000e7a = 1; *(uint8_t*)0x20000e7b = 1; *(uint8_t*)0x20000e7c = 2; *(uint8_t*)0x20000e7d = 0; *(uint8_t*)0x20000e7e = 0; *(uint8_t*)0x20000e7f = 9; *(uint8_t*)0x20000e80 = 0x24; *(uint8_t*)0x20000e81 = 2; *(uint8_t*)0x20000e82 = 1; *(uint8_t*)0x20000e83 = 1; *(uint8_t*)0x20000e84 = 2; *(uint8_t*)0x20000e85 = 0xf2; *(uint8_t*)0x20000e86 = 1; memset((void*)0x20000e87, 26, 1); *(uint8_t*)0x20000e88 = 7; *(uint8_t*)0x20000e89 = 0x24; *(uint8_t*)0x20000e8a = 1; *(uint8_t*)0x20000e8b = 0xbf; *(uint8_t*)0x20000e8c = 0x20; *(uint16_t*)0x20000e8d = 4; *(uint8_t*)0x20000e8f = 0xd; *(uint8_t*)0x20000e90 = 0x24; *(uint8_t*)0x20000e91 = 2; *(uint8_t*)0x20000e92 = 2; *(uint16_t*)0x20000e93 = 0x3f; *(uint16_t*)0x20000e95 = 5; *(uint8_t*)0x20000e97 = 1; memcpy((void*)0x20000e98, "\xdf\x3f\x19\xac", 4); *(uint8_t*)0x20000e9c = 9; *(uint8_t*)0x20000e9d = 5; *(uint8_t*)0x20000e9e = 1; *(uint8_t*)0x20000e9f = 9; *(uint16_t*)0x20000ea0 = 0x20; *(uint8_t*)0x20000ea2 = 0x66; *(uint8_t*)0x20000ea3 = 0xb9; *(uint8_t*)0x20000ea4 = 3; *(uint8_t*)0x20000ea5 = 7; *(uint8_t*)0x20000ea6 = 0x25; *(uint8_t*)0x20000ea7 = 1; *(uint8_t*)0x20000ea8 = 1; *(uint8_t*)0x20000ea9 = 0xfe; *(uint16_t*)0x20000eaa = 2; *(uint8_t*)0x20000eac = 9; *(uint8_t*)0x20000ead = 4; *(uint8_t*)0x20000eae = 2; *(uint8_t*)0x20000eaf = 0; *(uint8_t*)0x20000eb0 = 0; *(uint8_t*)0x20000eb1 = 1; *(uint8_t*)0x20000eb2 = 2; *(uint8_t*)0x20000eb3 = 0; *(uint8_t*)0x20000eb4 = 0; *(uint8_t*)0x20000eb5 = 9; *(uint8_t*)0x20000eb6 = 4; *(uint8_t*)0x20000eb7 = 2; *(uint8_t*)0x20000eb8 = 1; *(uint8_t*)0x20000eb9 = 1; *(uint8_t*)0x20000eba = 1; *(uint8_t*)0x20000ebb = 2; *(uint8_t*)0x20000ebc = 0; *(uint8_t*)0x20000ebd = 0; *(uint8_t*)0x20000ebe = 0xd; *(uint8_t*)0x20000ebf = 0x24; *(uint8_t*)0x20000ec0 = 2; *(uint8_t*)0x20000ec1 = 2; *(uint16_t*)0x20000ec2 = 0x7f; *(uint16_t*)0x20000ec4 = 0xc; *(uint8_t*)0x20000ec6 = 7; memcpy((void*)0x20000ec7, "\xe2\x5d\x55\x27", 4); *(uint8_t*)0x20000ecb = 7; *(uint8_t*)0x20000ecc = 0x24; *(uint8_t*)0x20000ecd = 1; *(uint8_t*)0x20000ece = 8; *(uint8_t*)0x20000ecf = 0x3f; *(uint16_t*)0x20000ed0 = 4; *(uint8_t*)0x20000ed2 = 7; *(uint8_t*)0x20000ed3 = 0x24; *(uint8_t*)0x20000ed4 = 1; *(uint8_t*)0x20000ed5 = -1; *(uint8_t*)0x20000ed6 = 0x72; *(uint16_t*)0x20000ed7 = 2; *(uint8_t*)0x20000ed9 = 9; *(uint8_t*)0x20000eda = 5; *(uint8_t*)0x20000edb = 0x82; *(uint8_t*)0x20000edc = 9; *(uint16_t*)0x20000edd = 0; *(uint8_t*)0x20000edf = 0x4b; *(uint8_t*)0x20000ee0 = 4; *(uint8_t*)0x20000ee1 = 1; *(uint8_t*)0x20000ee2 = 7; *(uint8_t*)0x20000ee3 = 0x25; *(uint8_t*)0x20000ee4 = 1; *(uint8_t*)0x20000ee5 = 0x82; *(uint8_t*)0x20000ee6 = 2; *(uint16_t*)0x20000ee7 = 2; *(uint32_t*)0x20000280 = 0xa; *(uint64_t*)0x20000284 = 0x20000140; *(uint8_t*)0x20000140 = 0xa; *(uint8_t*)0x20000141 = 6; *(uint16_t*)0x20000142 = 0x250; *(uint8_t*)0x20000144 = 4; *(uint8_t*)0x20000145 = 0x20; *(uint8_t*)0x20000146 = 5; *(uint8_t*)0x20000147 = 0x20; *(uint8_t*)0x20000148 = 0x1f; *(uint8_t*)0x20000149 = 0; *(uint32_t*)0x2000028c = 0; *(uint64_t*)0x20000290 = 0; *(uint32_t*)0x20000298 = 2; *(uint32_t*)0x2000029c = 0; *(uint64_t*)0x200002a0 = 0; *(uint32_t*)0x200002a8 = 2; *(uint64_t*)0x200002ac = 0x20000200; *(uint8_t*)0x20000200 = 2; *(uint8_t*)0x20000201 = 3; syz_usb_connect(1, 0xa9, 0x20000e40, 0x20000280); break; case 1: *(uint8_t*)0x20000040 = 0x12; *(uint8_t*)0x20000041 = 1; *(uint16_t*)0x20000042 = 0x110; *(uint8_t*)0x20000044 = 2; *(uint8_t*)0x20000045 = 0; *(uint8_t*)0x20000046 = 0; *(uint8_t*)0x20000047 = 0x20; *(uint16_t*)0x20000048 = 0x525; *(uint16_t*)0x2000004a = 0xa4a1; *(uint16_t*)0x2000004c = 0x40; *(uint8_t*)0x2000004e = 1; *(uint8_t*)0x2000004f = 2; *(uint8_t*)0x20000050 = 3; *(uint8_t*)0x20000051 = 1; *(uint8_t*)0x20000052 = 9; *(uint8_t*)0x20000053 = 2; *(uint16_t*)0x20000054 = 0x8c; *(uint8_t*)0x20000056 = 2; *(uint8_t*)0x20000057 = 1; *(uint8_t*)0x20000058 = 0; *(uint8_t*)0x20000059 = 0xe0; *(uint8_t*)0x2000005a = 9; *(uint8_t*)0x2000005b = 9; *(uint8_t*)0x2000005c = 4; *(uint8_t*)0x2000005d = 0; *(uint8_t*)0x2000005e = 0; *(uint8_t*)0x2000005f = 1; *(uint8_t*)0x20000060 = 2; *(uint8_t*)0x20000061 = 0xd; *(uint8_t*)0x20000062 = 0; *(uint8_t*)0x20000063 = 0; *(uint8_t*)0x20000064 = 7; *(uint8_t*)0x20000065 = 0x24; *(uint8_t*)0x20000066 = 6; *(uint8_t*)0x20000067 = 0; *(uint8_t*)0x20000068 = 1; memcpy((void*)0x20000069, "\x01\xce", 2); *(uint8_t*)0x2000006b = 5; *(uint8_t*)0x2000006c = 0x24; *(uint8_t*)0x2000006d = 0; *(uint16_t*)0x2000006e = 0xfb; *(uint8_t*)0x20000070 = 0xd; *(uint8_t*)0x20000071 = 0x24; *(uint8_t*)0x20000072 = 0xf; *(uint8_t*)0x20000073 = 1; *(uint32_t*)0x20000074 = 0xed; *(uint16_t*)0x20000078 = 0x3f; *(uint16_t*)0x2000007a = 6; *(uint8_t*)0x2000007c = 0xef; *(uint8_t*)0x2000007d = 6; *(uint8_t*)0x2000007e = 0x24; *(uint8_t*)0x2000007f = 0x1a; *(uint16_t*)0x20000080 = 0xc03a; *(uint8_t*)0x20000082 = 0x23; *(uint8_t*)0x20000083 = 5; *(uint8_t*)0x20000084 = 0x24; *(uint8_t*)0x20000085 = 1; *(uint8_t*)0x20000086 = 1; *(uint8_t*)0x20000087 = -1; *(uint8_t*)0x20000088 = 8; *(uint8_t*)0x20000089 = 0x24; *(uint8_t*)0x2000008a = 0x1c; *(uint16_t*)0x2000008b = 0; *(uint8_t*)0x2000008d = 9; *(uint16_t*)0x2000008e = 0xfbd; *(uint8_t*)0x20000090 = 0xc; *(uint8_t*)0x20000091 = 0x24; *(uint8_t*)0x20000092 = 7; *(uint8_t*)0x20000093 = 7; *(uint16_t*)0x20000094 = 0xfa; *(uint16_t*)0x20000096 = 0x1c80; *(uint16_t*)0x20000098 = 0x8001; *(uint16_t*)0x2000009a = 0xfffd; *(uint8_t*)0x2000009c = 0x15; *(uint8_t*)0x2000009d = 0x24; *(uint8_t*)0x2000009e = 0x12; *(uint16_t*)0x2000009f = 0xfff; *(uint64_t*)0x200000a1 = 0x14f5e048ba817a3; *(uint64_t*)0x200000a9 = 0x2a397ecbffc007a6; *(uint8_t*)0x200000b1 = 9; *(uint8_t*)0x200000b2 = 5; *(uint8_t*)0x200000b3 = 0x81; *(uint8_t*)0x200000b4 = 3; *(uint16_t*)0x200000b5 = 0x200; *(uint8_t*)0x200000b7 = 8; *(uint8_t*)0x200000b8 = 2; *(uint8_t*)0x200000b9 = 1; *(uint8_t*)0x200000ba = 9; *(uint8_t*)0x200000bb = 4; *(uint8_t*)0x200000bc = 1; *(uint8_t*)0x200000bd = 0; *(uint8_t*)0x200000be = 0; *(uint8_t*)0x200000bf = 2; *(uint8_t*)0x200000c0 = 0xd; *(uint8_t*)0x200000c1 = 0; *(uint8_t*)0x200000c2 = 0; *(uint8_t*)0x200000c3 = 9; *(uint8_t*)0x200000c4 = 4; *(uint8_t*)0x200000c5 = 1; *(uint8_t*)0x200000c6 = 1; *(uint8_t*)0x200000c7 = 2; *(uint8_t*)0x200000c8 = 2; *(uint8_t*)0x200000c9 = 0xd; *(uint8_t*)0x200000ca = 0; *(uint8_t*)0x200000cb = 0; *(uint8_t*)0x200000cc = 9; *(uint8_t*)0x200000cd = 5; *(uint8_t*)0x200000ce = 0x82; *(uint8_t*)0x200000cf = 2; *(uint16_t*)0x200000d0 = 8; *(uint8_t*)0x200000d2 = 0; *(uint8_t*)0x200000d3 = 0x40; *(uint8_t*)0x200000d4 = 9; *(uint8_t*)0x200000d5 = 9; *(uint8_t*)0x200000d6 = 5; *(uint8_t*)0x200000d7 = 3; *(uint8_t*)0x200000d8 = 2; *(uint16_t*)0x200000d9 = 0x3ff; *(uint8_t*)0x200000db = 0x24; *(uint8_t*)0x200000dc = 7; *(uint8_t*)0x200000dd = 1; *(uint32_t*)0x20000fc0 = 0xa; *(uint64_t*)0x20000fc4 = 0x20000100; *(uint8_t*)0x20000100 = 0xa; *(uint8_t*)0x20000101 = 6; *(uint16_t*)0x20000102 = 0x201; *(uint8_t*)0x20000104 = 4; *(uint8_t*)0x20000105 = 0x88; *(uint8_t*)0x20000106 = 6; *(uint8_t*)0x20000107 = 8; *(uint8_t*)0x20000108 = 0xfe; *(uint8_t*)0x20000109 = 0; *(uint32_t*)0x20000fcc = 0x13; *(uint64_t*)0x20000fd0 = 0x20000f00; *(uint8_t*)0x20000f00 = 5; *(uint8_t*)0x20000f01 = 0xf; *(uint16_t*)0x20000f02 = 0x13; *(uint8_t*)0x20000f04 = 2; *(uint8_t*)0x20000f05 = 7; *(uint8_t*)0x20000f06 = 0x10; *(uint8_t*)0x20000f07 = 2; STORE_BY_BITMASK(uint32_t, , 0x20000f08, 0x10, 0, 8); STORE_BY_BITMASK(uint32_t, , 0x20000f09, 8, 0, 4); STORE_BY_BITMASK(uint32_t, , 0x20000f09, 0xb, 4, 4); STORE_BY_BITMASK(uint32_t, , 0x20000f0a, 0x3ff, 0, 16); *(uint8_t*)0x20000f0c = 7; *(uint8_t*)0x20000f0d = 0x10; *(uint8_t*)0x20000f0e = 2; STORE_BY_BITMASK(uint32_t, , 0x20000f0f, 0x18, 0, 8); STORE_BY_BITMASK(uint32_t, , 0x20000f10, 4, 0, 4); STORE_BY_BITMASK(uint32_t, , 0x20000f10, 0xc, 4, 4); STORE_BY_BITMASK(uint32_t, , 0x20000f11, 1, 0, 16); *(uint32_t*)0x20000fd8 = 2; *(uint32_t*)0x20000fdc = 4; *(uint64_t*)0x20000fe0 = 0x20000f40; *(uint8_t*)0x20000f40 = 4; *(uint8_t*)0x20000f41 = 3; *(uint16_t*)0x20000f42 = 0x380a; *(uint32_t*)0x20000fe8 = 4; *(uint64_t*)0x20000fec = 0x20000f80; *(uint8_t*)0x20000f80 = 4; *(uint8_t*)0x20000f81 = 3; *(uint16_t*)0x20000f82 = 0x181a; syz_usb_connect(2, 0x9e, 0x20000040, 0x20000fc0); break; case 2: *(uint8_t*)0x20000000 = 0x12; *(uint8_t*)0x20000001 = 1; *(uint16_t*)0x20000002 = 0x310; *(uint8_t*)0x20000004 = 0; *(uint8_t*)0x20000005 = 0; *(uint8_t*)0x20000006 = 0; *(uint8_t*)0x20000007 = 0x40; *(uint16_t*)0x20000008 = 0x5ac; *(uint16_t*)0x2000000a = 0x223; *(uint16_t*)0x2000000c = 0x40; *(uint8_t*)0x2000000e = 1; *(uint8_t*)0x2000000f = 2; *(uint8_t*)0x20000010 = 3; *(uint8_t*)0x20000011 = 1; *(uint8_t*)0x20000012 = 9; *(uint8_t*)0x20000013 = 2; *(uint16_t*)0x20000014 = 0x24; *(uint8_t*)0x20000016 = 1; *(uint8_t*)0x20000017 = 1; *(uint8_t*)0x20000018 = 0; *(uint8_t*)0x20000019 = 0; *(uint8_t*)0x2000001a = 0; *(uint8_t*)0x2000001b = 9; *(uint8_t*)0x2000001c = 4; *(uint8_t*)0x2000001d = 0; *(uint8_t*)0x2000001e = 0; *(uint8_t*)0x2000001f = 0; *(uint8_t*)0x20000020 = 3; *(uint8_t*)0x20000021 = 1; *(uint8_t*)0x20000022 = 0; *(uint8_t*)0x20000023 = 0; *(uint8_t*)0x20000024 = 9; *(uint8_t*)0x20000025 = 0x21; *(uint16_t*)0x20000026 = 0; *(uint8_t*)0x20000028 = 0; *(uint8_t*)0x20000029 = 1; *(uint8_t*)0x2000002a = 0x22; *(uint16_t*)0x2000002b = 0; *(uint8_t*)0x2000002d = 9; *(uint8_t*)0x2000002e = 5; *(uint8_t*)0x2000002f = 0x81; *(uint8_t*)0x20000030 = 3; *(uint16_t*)0x20000031 = 0; *(uint8_t*)0x20000033 = 0; *(uint8_t*)0x20000034 = 0; *(uint8_t*)0x20000035 = 0; *(uint32_t*)0x20000240 = 0; *(uint64_t*)0x20000244 = 0; *(uint32_t*)0x2000024c = 0; *(uint64_t*)0x20000250 = 0; *(uint32_t*)0x20000258 = 0; syz_usb_connect(2, 0x36, 0x20000000, 0x20000240); break; case 3: *(uint8_t*)0x20000840 = 0x12; *(uint8_t*)0x20000841 = 1; *(uint16_t*)0x20000842 = 0x50; *(uint8_t*)0x20000844 = 2; *(uint8_t*)0x20000845 = 0; *(uint8_t*)0x20000846 = 0; *(uint8_t*)0x20000847 = 0x40; *(uint16_t*)0x20000848 = 0x525; *(uint16_t*)0x2000084a = 0xa4a1; *(uint16_t*)0x2000084c = 0x40; *(uint8_t*)0x2000084e = 1; *(uint8_t*)0x2000084f = 2; *(uint8_t*)0x20000850 = 3; *(uint8_t*)0x20000851 = 1; *(uint8_t*)0x20000852 = 9; *(uint8_t*)0x20000853 = 2; *(uint16_t*)0x20000854 = 0x4e; *(uint8_t*)0x20000856 = 1; *(uint8_t*)0x20000857 = 1; *(uint8_t*)0x20000858 = 0x81; *(uint8_t*)0x20000859 = 0x88; *(uint8_t*)0x2000085a = 0xa3; *(uint8_t*)0x2000085b = 9; *(uint8_t*)0x2000085c = 4; *(uint8_t*)0x2000085d = 0; *(uint8_t*)0x2000085e = 1; *(uint8_t*)0x2000085f = 3; *(uint8_t*)0x20000860 = 2; *(uint8_t*)0x20000861 = 6; *(uint8_t*)0x20000862 = 0; *(uint8_t*)0x20000863 = 7; *(uint8_t*)0x20000864 = 5; *(uint8_t*)0x20000865 = 0x24; *(uint8_t*)0x20000866 = 6; *(uint8_t*)0x20000867 = 0; *(uint8_t*)0x20000868 = 0; *(uint8_t*)0x20000869 = 5; *(uint8_t*)0x2000086a = 0x24; *(uint8_t*)0x2000086b = 0; *(uint16_t*)0x2000086c = 0x5e2; *(uint8_t*)0x2000086e = 0xd; *(uint8_t*)0x2000086f = 0x24; *(uint8_t*)0x20000870 = 0xf; *(uint8_t*)0x20000871 = 1; *(uint32_t*)0x20000872 = 9; *(uint16_t*)0x20000876 = 1; *(uint16_t*)0x20000878 = 1; *(uint8_t*)0x2000087a = 9; *(uint8_t*)0x2000087b = 0xc; *(uint8_t*)0x2000087c = 0x24; *(uint8_t*)0x2000087d = 0x1b; *(uint16_t*)0x2000087e = 1; *(uint16_t*)0x20000880 = 0x1f; *(uint8_t*)0x20000882 = 0x81; *(uint8_t*)0x20000883 = 0xd; *(uint16_t*)0x20000884 = 1; *(uint8_t*)0x20000886 = 2; *(uint8_t*)0x20000887 = 7; *(uint8_t*)0x20000888 = 0x24; *(uint8_t*)0x20000889 = 0x14; *(uint16_t*)0x2000088a = 0xa4ca; *(uint16_t*)0x2000088c = 0xac28; *(uint8_t*)0x2000088e = 9; *(uint8_t*)0x2000088f = 5; *(uint8_t*)0x20000890 = 0x82; *(uint8_t*)0x20000891 = 2; *(uint16_t*)0x20000892 = 0x10; *(uint8_t*)0x20000894 = 1; *(uint8_t*)0x20000895 = 2; *(uint8_t*)0x20000896 = 5; *(uint8_t*)0x20000897 = 9; *(uint8_t*)0x20000898 = 5; *(uint8_t*)0x20000899 = 3; *(uint8_t*)0x2000089a = 2; *(uint16_t*)0x2000089b = 0x10; *(uint8_t*)0x2000089d = 1; *(uint8_t*)0x2000089e = 4; *(uint8_t*)0x2000089f = 0; *(uint32_t*)0x20000dc0 = 0xa; *(uint64_t*)0x20000dc4 = 0x200008c0; *(uint8_t*)0x200008c0 = 0xa; *(uint8_t*)0x200008c1 = 6; *(uint16_t*)0x200008c2 = 0x200; *(uint8_t*)0x200008c4 = 0x6d; *(uint8_t*)0x200008c5 = 9; *(uint8_t*)0x200008c6 = 0; *(uint8_t*)0x200008c7 = -1; *(uint8_t*)0x200008c8 = 6; *(uint8_t*)0x200008c9 = 0; *(uint32_t*)0x20000dcc = 0x4f; *(uint64_t*)0x20000dd0 = 0x20000900; *(uint8_t*)0x20000900 = 5; *(uint8_t*)0x20000901 = 0xf; *(uint16_t*)0x20000902 = 0x4f; *(uint8_t*)0x20000904 = 4; *(uint8_t*)0x20000905 = 0x24; *(uint8_t*)0x20000906 = 0x10; *(uint8_t*)0x20000907 = 0xa; *(uint8_t*)0x20000908 = 2; STORE_BY_BITMASK(uint32_t, , 0x20000909, 6, 0, 5); STORE_BY_BITMASK(uint32_t, , 0x20000909, 0x7ff, 5, 27); *(uint16_t*)0x2000090d = 0xf00; *(uint16_t*)0x2000090f = 0x1f; *(uint32_t*)0x20000911 = 0x3f00; *(uint32_t*)0x20000915 = 0xff0000; *(uint32_t*)0x20000919 = 0x60cf; *(uint32_t*)0x2000091d = 0x3f00; *(uint32_t*)0x20000921 = 0xc000; *(uint32_t*)0x20000925 = 0xff0000; *(uint8_t*)0x20000929 = 0x14; *(uint8_t*)0x2000092a = 0x10; *(uint8_t*)0x2000092b = 4; *(uint8_t*)0x2000092c = 0; memcpy((void*)0x2000092d, "\xe1\x8e\x49\xb2\xd3\xa0\x9b\x3b\x31\xad\xb2\x59\xb4\xc5\xf7\xed", 16); *(uint8_t*)0x2000093d = 7; *(uint8_t*)0x2000093e = 0x10; *(uint8_t*)0x2000093f = 2; STORE_BY_BITMASK(uint32_t, , 0x20000940, 8, 0, 8); STORE_BY_BITMASK(uint32_t, , 0x20000941, 0xf, 0, 4); STORE_BY_BITMASK(uint32_t, , 0x20000941, 5, 4, 4); STORE_BY_BITMASK(uint32_t, , 0x20000942, 0x8000, 0, 16); *(uint8_t*)0x20000944 = 0xb; *(uint8_t*)0x20000945 = 0x10; *(uint8_t*)0x20000946 = 1; *(uint8_t*)0x20000947 = 4; *(uint16_t*)0x20000948 = 0x28; *(uint8_t*)0x2000094a = 8; *(uint8_t*)0x2000094b = 1; *(uint16_t*)0x2000094c = 5; *(uint8_t*)0x2000094e = 4; *(uint32_t*)0x20000dd8 = 7; *(uint32_t*)0x20000ddc = 0xfc; *(uint64_t*)0x20000de0 = 0x20000980; *(uint8_t*)0x20000980 = 0xfc; *(uint8_t*)0x20000981 = 3; memcpy( (void*)0x20000982, "\x57\xac\xe2\xdf\x83\xb6\xca\xa5\x31\xa3\xcb\x1d\xb4\x74\x73\x29\xfe" "\x45\x8c\x31\x64\x10\x2f\xe4\xfa\x06\xa3\xd3\x8c\x72\x4c\x55\xb3\x60" "\x66\xec\xeb\x8b\x0f\x93\x28\x16\x84\xab\x84\x06\x40\x34\xf6\x7f\xc8" "\x09\x33\xb6\xdb\x32\x83\x9e\xca\x81\xa4\x62\xdf\xf9\x5e\x27\x8b\x30" "\xc9\xc2\x78\x14\x53\xb8\x3f\xc2\x73\x82\x7d\x1e\x2b\xde\x57\x5c\xe0" "\x87\x1b\x46\xb0\xa1\xcd\xe8\x7e\x80\xc1\x2d\x80\x8b\x3a\x84\xa6\xe0" "\xb5\x12\x59\xa8\x9f\xd5\xed\x5f\xe6\xef\xdd\xe6\x48\x35\x54\x80\xc6" "\x20\x04\x0c\x4c\x49\x51\x5b\xa0\x65\x0f\xdf\x58\x78\xd2\xf0\x5e\x9d" "\xef\xaf\xf3\x86\x35\xd9\x59\x73\x21\xa2\x2e\xdb\x15\x6e\xdd\x00\x40" "\x66\x7d\xeb\x0f\x70\xad\xb8\x41\xb0\x42\x30\xa8\xef\xcc\x0e\xc8\x8f" "\x77\x06\xef\xc5\xf4\xb4\x65\x1a\xb4\x40\x26\x27\xca\x21\x99\x02\xea" "\x19\xff\x83\x35\x01\xc9\x72\x52\x64\x19\x87\x0f\x95\x43\x7d\xa1\xf3" "\x81\x77\xe1\x88\xf5\x36\x7c\x7c\x3f\x16\xef\x40\xdb\xea\x5d\x8d\xe2" "\x28\x25\x47\x24\x4d\x2e\x5d\x96\x70\x71\xbf\xf9\x33\x6e\xd6\x04\x3a" "\xf2\x94\x21\x46\xde\x12\xf4\x36\x4a\xf4\xb9\x4d", 250); *(uint32_t*)0x20000de8 = 0x5a; *(uint64_t*)0x20000dec = 0x20000a80; *(uint8_t*)0x20000a80 = 0x5a; *(uint8_t*)0x20000a81 = 3; memcpy((void*)0x20000a82, "\x6b\x81\xa9\x69\xe4\xa4\xc4\x43\x48\x2e\xad\x1e\xd1\xfa\x00\x2d" "\x2d\x5a\x06\xb2\x79\xb3\x12\xbc\x18\x51\xf6\x71\xfd\xd3\x6e\xad" "\x7d\xf0\x06\x1f\x8a\xd9\x9c\x18\xcd\xb5\xed\xa6\x6d\xce\x2b\x87" "\x46\x50\x01\x38\x31\x13\xb4\x56\x1b\xf5\xa4\x99\xce\x25\x7b\xa6" "\x7b\x8f\x10\xed\x17\xcb\xd9\xaf\x96\x6c\x79\xed\x71\x36\xf6\x3f" "\x57\xee\x23\xb3\x5a\x58\xc0\x4e", 88); *(uint32_t*)0x20000df4 = 4; *(uint64_t*)0x20000df8 = 0x20000b00; *(uint8_t*)0x20000b00 = 4; *(uint8_t*)0x20000b01 = 3; *(uint16_t*)0x20000b02 = 0xc01; *(uint32_t*)0x20000e00 = 0; *(uint64_t*)0x20000e04 = 0; *(uint32_t*)0x20000e0c = 0x46; *(uint64_t*)0x20000e10 = 0x20000c00; *(uint8_t*)0x20000c00 = 0x46; *(uint8_t*)0x20000c01 = 3; memcpy( (void*)0x20000c02, "\xe8\xca\xe8\x50\x7f\xac\x5a\xe2\xf3\x51\xf3\xf3\x0a\x32\x2d\x3e\xf4" "\x52\x24\x84\x64\xdd\x0b\x43\x5f\xcf\x5d\xbe\xd4\x08\x0d\x5d\xaf\xc2" "\xf9\x09\xd9\xb6\x13\x24\x45\xcb\xd7\x6b\x46\x0f\x2a\xbf\xd1\xa2\x19" "\xa6\xf8\xd5\x15\x44\x61\xa9\x86\xdb\x43\x05\xae\x9b\x1b\x14\x38\x41", 68); *(uint32_t*)0x20000e18 = 0xa4; *(uint64_t*)0x20000e1c = 0x20000c80; *(uint8_t*)0x20000c80 = 0xa4; *(uint8_t*)0x20000c81 = 3; memcpy( (void*)0x20000c82, "\xd1\x03\x37\x11\x22\x66\x80\xcd\xe7\xca\x5c\x94\xe1\x51\xf8\x99\x45" "\xe5\x1d\x34\x69\x09\xa1\xe7\x25\xe4\x81\x6f\x57\x3e\xc4\xe7\xc8\xf3" "\x0c\x95\x0b\xaf\x48\x57\xc3\xdc\xe1\x07\xdf\x20\x47\x5d\x2e\xfe\x89" "\x91\x7f\x9b\x3d\x43\x89\xdc\xad\x9a\xca\x62\x6d\xfe\x91\x83\x8e\x08" "\xde\x84\xbe\x03\x9c\xda\x5d\x36\x4a\x68\xa9\x5e\xac\x96\x46\x36\xa7" "\xe1\xb8\xe5\x8d\xec\xf8\x03\x1e\x16\x14\xd3\xfe\x96\x5e\x25\xcf\xf7" "\xcb\x74\x31\x8c\xcd\x69\xaa\x10\x23\x34\x66\x3e\xf6\xdf\x74\xcd\xeb" "\x22\x15\x7c\xf0\xba\x79\xbc\xc5\xe2\xfa\x45\x3d\x78\x0a\xb1\xa9\x9e" "\x64\xa1\x8a\x06\xdc\x4d\x75\x3e\xab\xbd\x2e\x7c\xfe\xe2\x7d\xb2\xd5" "\x8d\x4e\xce\xd9\x00\xce\x15\x5f\xe7", 162); *(uint32_t*)0x20000e24 = 0x7f; *(uint64_t*)0x20000e28 = 0x20000d40; *(uint8_t*)0x20000d40 = 0x7f; *(uint8_t*)0x20000d41 = 3; memcpy((void*)0x20000d42, "\x28\x26\xd8\xd1\xee\xa1\xc9\x85\xe7\xfb\xa8\x98\x59\xee\x0d\x63" "\x05\x0b\x13\x51\x96\x0f\xb6\x5b\x90\x7d\xb7\xeb\xd1\x83\x83\xba" "\x94\x8a\xbd\x6a\xc7\x60\x35\x4f\x18\x70\xce\x33\x09\xfa\x73\x08" "\x29\x51\xdf\x07\xad\x8a\x25\x2f\x91\x8e\x2d\xf3\x2e\x46\xc7\x06" "\x91\x1d\x99\xfd\x43\xcc\x4b\x35\x6a\x23\xde\xcb\xa2\x91\x03\xe3" "\x0c\x79\xb8\xab\x13\xa3\x41\x96\xee\xca\x8e\x2b\x9f\x87\x4d\xdd" "\x48\x3a\xe6\x32\x42\x00\x67\xab\x9c\xb6\x4a\xb7\x49\xcd\x3a\xb7" "\x76\x3e\xe4\x9e\xca\x42\x5f\x42\xfe\xb8\xcf\xbf\xb9", 125); syz_usb_connect(2, 0x60, 0x20000840, 0x20000dc0); break; } } int main(void) { syscall(SYS_mmap, 0x20000000ul, 0x1000000ul, 3ul, 0x1012ul, -1, 0ul, 0ul); for (procid = 0; procid < 6; procid++) { if (fork() == 0) { use_temporary_dir(); do_sandbox_none(); } } sleep(1000000); return 0; }