{"id":"CVE-2026-90162","published":"2026-09-17T16:06:53Z","modified":"2026-10-30T12:34:31Z","title":"ksmbd: defer publishing granted locks to prevent UAF/double-free race","vendor":"Linux","product":"Linux","tier":"tail","description":{"text":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: defer publishing granted locks to prevent UAF/double-free race\n\nIn smb2_lock(), mid-batch granted locks are published to connection-wide\n(conn->lock_list) and file-wide (fp->lock_list) lists immediately upon\nvfs_lock_file() success, while also remaining tracked on the stack-local\nrollback_list.\n\nIf a subsequent element in the same SMB2_LOCK request array fails\nvalidation or execution, the thread jumps to out: and walks\nrollback_list to undo previously granted locks. However, because the\ngranted lock was already published to conn->lock_list, a concurrent\nUNLOCK request on the same connection can find the lock object and\nkfree() it before the rollback loop executes.\n\nWhen the granting thread subsequently walks rollback_list, it\ndereferences and frees the already-freed ksmbd_lock structure, resulting\nin a Use-After-Free and Double-Free (on both ksmbd_lock and struct\nfile_lock).\n\nFix this by deferring the publication of granted locks to\nconn->lock_list and fp->lock_list until after the entire array of lock\nelements has been processed without error. Mid-batch grants remain\ntracked exclusively on the request-local rollback_list until the whole\nbatch succeeds, eliminating the race window.","provenance":"source","from":"CVE.org"},"cvss":{"score":8.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00702,"percentile":0.53252,"provenance":"source"},"cwes":[],"references":[{"url":"https://git.kernel.org/stable/c/f1371a140722c1d6868f9acf69d601de7d4142bf","tags":[]},{"url":"https://git.kernel.org/stable/c/b68d4bb6b03a667c305626bd2c242fd162bac17e","tags":[]},{"url":"https://git.kernel.org/stable/c/65f54ed0289e9a57e6c60b14347ccea4c318f1fc","tags":[]},{"url":"https://git.kernel.org/stable/c/ff6870cf3b7eccc69d03cbb6f23e3995d96e9a8d","tags":[]},{"url":"https://git.kernel.org/stable/c/a1d26dfb32919088e3638dca01068df3c4507433","tags":[]},{"url":"https://git.kernel.org/stable/c/29f74f0f2e6df3b393b7b66e810136d0c64e3c59","tags":[]}],"priority":{"score":16.8,"factors":[{"name":"EPSS percentile","points":10.65},{"name":"CVSS severity","points":6.16}]},"vendorSlug":"linux","affectedVersions":[{"vendor":"Linux","product":"Linux","versions":[">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < f1371a140722c1d6868f9acf69d601de7d4142bf",">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < b68d4bb6b03a667c305626bd2c242fd162bac17e",">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < 65f54ed0289e9a57e6c60b14347ccea4c318f1fc",">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < ff6870cf3b7eccc69d03cbb6f23e3995d96e9a8d",">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < a1d26dfb32919088e3638dca01068df3c4507433",">= e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9, < 29f74f0f2e6df3b393b7b66e810136d0c64e3c59"]},{"vendor":"Linux","product":"Linux","versions":["5.15"]}],"euvd":{"id":"EUVD-2026-81755","exploited":false,"provenance":"source"}}