{"id":25580,"date":"2026-09-18T04:31:35","date_gmt":"2026-09-17T20:31:35","guid":{"rendered":"https:\/\/www.54iter.cn\/?vuln=cve-2026-90171"},"modified":"2026-09-18T04:31:35","modified_gmt":"2026-09-17T20:31:35","slug":"cve-2026-90171","status":"publish","type":"vuln","link":"https:\/\/www.54iter.cn\/?vuln=cve-2026-90171","title":{"rendered":"CVE-2026-90171 &#8211; In the Linux kernel, the following vulnerability has been resolved:\n\nsmb: smbdirect: relea"},"content":{"rendered":"<p>In the Linux kernel, the following vulnerability has been resolved:<\/p>\n<p>smb: smbdirect: release pending child sockets outside the handler lock<\/p>\n<p>smbdirect_socket_destroy() releases the listener&#8217;s pending\/ready child<br \/>\nsockets while still holding the listener&#8217;s handler lock, the<br \/>\n&amp;id_priv-&gt;handler_mutex taken via rdma_lock_handler(), not<br \/>\nsc-&gt;listen.lock, and before the listener&#8217;s own rdma_destroy_id().<br \/>\nThat ordering has one real consequence and one cosmetic one.<\/p>\n<p>The real one: smbdirect_socket_release() drops the child&#8217;s last<br \/>\nreference, which destroys the child&#8217;s cm_id.  Doing that before the<br \/>\nlistener&#8217;s rdma_destroy_id() lets _cma_cancel_listens(), running from<br \/>\nthe listener&#8217;s _destroy_id(), walk an already freed child id_priv,<br \/>\nwhich KASAN catches as a slab-use-after-free during listener shutdown:<\/p>\n<p>[ 4758.909130] BUG: KASAN: slab-use-after-free in __mutex_lock+0x1469\/0x1560<br \/>\n[ 4758.911450] Read of size 1 at addr ffff88821c381db4 by task ksmbd.control\/1652<br \/>\n[ 4758.913262] Call Trace:<br \/>\n[ 4758.913267]<br \/>\n[ 4758.913299]  __mutex_lock+0x1469\/0x1560<br \/>\n[ 4758.913408]  _cma_cancel_listens+0x312\/0x3b0<br \/>\n[ 4758.913413]  _destroy_id+0x363\/0xee0<br \/>\n[ 4758.913417]  smbdirect_socket_destroy_sync+0x17d5\/0x2440<br \/>\n[ 4758.913443]  smbdirect_socket_release+0x124\/0x230<br \/>\n[ 4758.913451]  ksmbd_rdma_stop_listening+0x9f\/0x190<br \/>\n[ 4758.913457]  ksmbd_conn_transport_destroy+0x65\/0x3c0<br \/>\n[ 4758.913463]  kill_server_store+0x1fb\/0x2b0<br \/>\n[ 4758.913501]  kernfs_fop_write_iter+0x349\/0x4d0<br \/>\n[ 4758.913507]  vfs_write+0x5e7\/0xc70<br \/>\n[ 4758.913528]  ksys_write+0x12a\/0x210<br \/>\n[ 4758.913541]  do_syscall_64+0x135\/0x460<br \/>\n[ 4758.913555]  entry_SYSCALL_64_after_hwframe+0x77\/0x7f<\/p>\n<p>The cosmetic one: releasing a child recurses into<br \/>\nsmbdirect_socket_destroy(), which takes the child&#8217;s own<br \/>\nrdma_lock_handler() lock nested under the listener&#8217;s.  The listener&#8217;s<br \/>\nand the child&#8217;s cm_id are always different instances, so this cannot<br \/>\ndeadlock for real; the CM core itself nests a new connection id&#8217;s<br \/>\nhandler_mutex under the listening id&#8217;s in cma_ib_req_handler().  But<br \/>\nlockdep only sees one lock class, reports possible recursive locking,<br \/>\nand then disables itself, hiding real locking bugs for the rest of the<br \/>\nrun:<\/p>\n<p>[ 2424.579653] WARNING: possible recursive locking detected<br \/>\n[ 2424.581180] 7.1.0-next-20260623+ #89 Not tainted<br \/>\n[ 2424.582548] &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\n[ 2424.584500] ksmbd.control\/8854 is trying to acquire lock:<br \/>\n[ 2424.586817] ffff888102303c20 (&amp;id_priv-&gt;handler_mutex){+.+.}-{4:4}, at: smbdirect_socket_destroy_sync+0xc39\/0x2440<br \/>\n[ 2424.590590]<br \/>\n[ 2424.590590] but task is already holding lock:<br \/>\n[ 2424.591601] ffff888102046c20 (&amp;id_priv-&gt;handler_mutex){+.+.}-{4:4}, at: smbdirect_socket_destroy_sync+0xc39\/0x2440<br \/>\n[ 2424.594178]<br \/>\n[ 2424.594178] other info that might help us debug this:<br \/>\n[ 2424.596634]  Possible unsafe locking scenario:<br \/>\n[ 2424.596634]<br \/>\n[ 2424.598841]        CPU0<br \/>\n[ 2424.599765]        &#8212;-<br \/>\n[ 2424.600695]   lock(&amp;id_priv-&gt;handler_mutex);<br \/>\n[ 2424.601836]   lock(&amp;id_priv-&gt;handler_mutex);<br \/>\n[ 2424.602590]<br \/>\n[ 2424.602590]  *** DEADLOCK ***<br \/>\n[ 2424.602590]<br \/>\n[ 2424.604512]  May be due to missing lock nesting notation<\/p>\n<p>Splice the pending\/ready children onto a local list under the<br \/>\nlistener&#8217;s listen.lock, while the handler lock is held so a concurrent<br \/>\nCM CONNECT_REQUEST cannot add more, but defer the actual<br \/>\nsmbdirect_socket_release() calls until after the listener&#8217;s cm_id has<br \/>\nbeen destroyed and its handler lock dropped.  The children are<br \/>\nindependent sockets whose teardown needs neither the listener&#8217;s<br \/>\nhandler lock nor its cm_id.<\/p>\n<p>Found with ksmbdzzer [2], a KSMBD fuzzer that drives libFuzzer with a<br \/>\nkcov-dataflow [1] coverage vector: it folds each instrumented<br \/>\ncomparison\/argument&#8217;s runtime operand value together with its PC (the<br \/>\ndefault arm mixes them as pc\u2295val) so that a new operand value at a known<br \/>\nsite counts as new coverage.<\/p>\n<p>[1] https:\/\/lwn.net\/Articles\/1077606\/<br \/>\n[2] https:\/\/github.com\/yskzalloc\/kcov-dataflow<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the Linux kernel, the following vulnerability has been resolved:<\/p>\n<p>smb: smbdirect: release pending child sockets outside the handler lock<\/p>\n<p>smbdirect_socket_destroy() releases the listener&#8217;s pending\/<\/p>\n","protected":false},"template":"","meta":[],"categories":[],"tags":[],"class_list":["post-25580","vuln","type-vuln","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.54iter.cn\/index.php?rest_route=\/wp\/v2\/vuln\/25580","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=25580"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.54iter.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=25580"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.54iter.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=25580"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}