{"id":9256,"date":"2026-09-04T18:50:17","date_gmt":"2026-09-04T10:50:17","guid":{"rendered":"https:\/\/www.54iter.cn\/?vuln=cve-2026-9771-2"},"modified":"2026-09-04T18:50:17","modified_gmt":"2026-09-04T10:50:17","slug":"cve-2026-9771-2","status":"publish","type":"vuln","link":"https:\/\/www.54iter.cn\/?vuln=cve-2026-9771-2","title":{"rendered":"CVE-2026-9771 [HIGH] &#8211; The flash_copy() system call is verified by z_vrfy_flash_copy() in drivers\/flash\/flash_uti"},"content":{"rendered":"<p>The flash_copy() system call is verified by z_vrfy_flash_copy() in drivers\/flash\/flash_util.c. On builds with CONFIG_USERSPACE enabled, this handler is the kernel-side trust boundary for a user-mode caller. Prior to the fix it validated only the output buffer (K_SYSCALL_MEMORY_WRITE) and passed the two struct device * arguments, src_dev and dst_dev, directly into the implementation without any object validation \u2014 unlike every sibling flash syscall, which guards its device pointer with K_SYSCALL_DRIVER_FLASH.<\/p>\n<p>A user-mode thread fully controls the values of src_dev\/dst_dev and the contents of its own address space. The implementation z_impl_flash_copy() dereferences these pointers and calls through their driver-API function tables (e.g. api-&gt;get_parameters(dst_dev), flash_read(src_dev, &#8230;), flash_write(dst_dev, &#8230;)). By supplying a pointer to a forged struct device whose api table contains attacker-chosen function pointers, an unprivileged thread can cause the kernel to call arbitrary code in supervisor mode; passing any arbitrary or invalid address otherwise yields a kernel crash or out-of-bounds read.<\/p>\n<p>The result is a local privilege escalation out of the userspace sandbox (with kernel denial-of-service and information disclosure as lesser outcomes). The fix adds K_SYSCALL_DRIVER_FLASH(src_dev, read) and K_SYSCALL_DRIVER_FLASH(dst_dev, write) to z_vrfy_flash_copy(), which verify each device is a registered flash-driver kernel object the calling thread is permitted to use before any dereference, closing the path completely.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The flash_copy() system call is verified by z_vrfy_flash_copy() in drivers\/flash\/flash_util.c. On builds with CONFIG_USERSPACE enabled, this handler is the kernel-side trust boundary for a user-mode c<\/p>\n","protected":false},"template":"","meta":[],"categories":[],"tags":[],"class_list":["post-9256","vuln","type-vuln","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.54iter.cn\/index.php?rest_route=\/wp\/v2\/vuln\/9256","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.54iter.cn\/index.php?rest_route=\/wp\/v2\/vuln"}],"about":[{"href":"https:\/\/www.54iter.cn\/index.php?rest_route=\/wp\/v2\/types\/vuln"}],"wp:attachment":[{"href":"https:\/\/www.54iter.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9256"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.54iter.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9256"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.54iter.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9256"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}