{"api_version":"1","generated_at":"2026-12-01T14:13:23+00:00","cve":"CVE-2026-139165","urls":{"html":"https://cve.report/CVE-2026-139165","api":"https://cve.report/api/cve/CVE-2026-139165.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-139165","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-139165"},"summary":{"title":"ksmbd: avoid races between named-pipe operations","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: avoid races between named-pipe operations\n\nRPC IPC replies are matched by pipe handle. READ, WRITE, TRANSCEIVE and\nCLOSE on the same pipe all use that handle. The session RPC lock protects\nthe handle table, but is dropped before a pipe I/O request waits for its\nreply. Another operation, including CLOSE, can issue a request with the\nsame handle while that wait is still in progress.\n\nThese requests have no separate IPC correlation ID, so overlapping waits\ncan interfere with reply delivery. CLOSE can also release the handle\nbefore an earlier operation finishes. Protecting table access alone does\nnot provide the serialization or lifetime needed by an active pipe.\n\nSerialize operations per pipe and keep its state and handle alive until\nall users finish. Avoid holding the session table lock across IPC waits,\nso a blocked pipe does not hold up unrelated pipes. This also provides\nthe lifetime needed to retain unread replies in the following patch.\n\nRecheck cancellation, connection release and session teardown after taking\nthe pipe lock, and mark a removed pipe closed before waiting for its active\noperation. Close all session RPC pipes on logoff after the other requests\nhave drained; keeping the TCP connection open must not retain old handles.\nUse standard SMB2 error replies for failed pipe operations while preserving\nthe selected status.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-11-30 14:18:35","updated_at":"2026-11-30 14:18:35"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/a43e0718a4abed7f859a67bd7b154acf213589fa","name":"https://git.kernel.org/stable/c/a43e0718a4abed7f859a67bd7b154acf213589fa","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/dbb4b1d59549a3000d4ba4aca0d0abd05066bd79","name":"https://git.kernel.org/stable/c/dbb4b1d59549a3000d4ba4aca0d0abd05066bd79","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-139165","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-139165","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 dbb4b1d59549a3000d4ba4aca0d0abd05066bd79 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 a43e0718a4abed7f859a67bd7b154acf213589fa git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7.3.6 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3.6 7.3.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.4-rc1 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["fs/smb/server/mgmt/user_session.c","fs/smb/server/mgmt/user_session.h","fs/smb/server/smb2pdu.c","fs/smb/server/transport_ipc.c","fs/smb/server/transport_ipc.h"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"dbb4b1d59549a3000d4ba4aca0d0abd05066bd79","status":"affected","version":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","versionType":"git"},{"lessThan":"a43e0718a4abed7f859a67bd7b154acf213589fa","status":"affected","version":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","versionType":"git"},{"lessThan":"7.3.6","status":"affected","version":"0","versionType":"semver"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["fs/smb/server/mgmt/user_session.c","fs/smb/server/mgmt/user_session.h","fs/smb/server/smb2pdu.c","fs/smb/server/transport_ipc.c","fs/smb/server/transport_ipc.h"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThanOrEqual":"7.3.*","status":"unaffected","version":"7.3.6","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.4-rc1","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3.6","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.4-rc1","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: avoid races between named-pipe operations\n\nRPC IPC replies are matched by pipe handle. READ, WRITE, TRANSCEIVE and\nCLOSE on the same pipe all use that handle. The session RPC lock protects\nthe handle table, but is dropped before a pipe I/O request waits for its\nreply. Another operation, including CLOSE, can issue a request with the\nsame handle while that wait is still in progress.\n\nThese requests have no separate IPC correlation ID, so overlapping waits\ncan interfere with reply delivery. CLOSE can also release the handle\nbefore an earlier operation finishes. Protecting table access alone does\nnot provide the serialization or lifetime needed by an active pipe.\n\nSerialize operations per pipe and keep its state and handle alive until\nall users finish. Avoid holding the session table lock across IPC waits,\nso a blocked pipe does not hold up unrelated pipes. This also provides\nthe lifetime needed to retain unread replies in the following patch.\n\nRecheck cancellation, connection release and session teardown after taking\nthe pipe lock, and mark a removed pipe closed before waiting for its active\noperation. Close all session RPC pipes on logoff after the other requests\nhave drained; keeping the TCP connection open must not retain old handles.\nUse standard SMB2 error replies for failed pipe operations while preserving\nthe selected status."}],"providerMetadata":{"dateUpdated":"2026-11-30T13:32:11.026Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/dbb4b1d59549a3000d4ba4aca0d0abd05066bd79"},{"url":"https://git.kernel.org/stable/c/a43e0718a4abed7f859a67bd7b154acf213589fa"}],"title":"ksmbd: avoid races between named-pipe operations","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-139165","datePublished":"2026-11-30T13:32:11.026Z","dateReserved":"2026-11-30T13:22:15.918Z","dateUpdated":"2026-11-30T13:32:11.026Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-11-30 14:18:35","lastModifiedDate":"2026-11-30 14:18:35","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"139165","Ordinal":"1","Title":"ksmbd: avoid races between named-pipe operations","CVE":"CVE-2026-139165","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"139165","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: avoid races between named-pipe operations\n\nRPC IPC replies are matched by pipe handle. READ, WRITE, TRANSCEIVE and\nCLOSE on the same pipe all use that handle. The session RPC lock protects\nthe handle table, but is dropped before a pipe I/O request waits for its\nreply. Another operation, including CLOSE, can issue a request with the\nsame handle while that wait is still in progress.\n\nThese requests have no separate IPC correlation ID, so overlapping waits\ncan interfere with reply delivery. CLOSE can also release the handle\nbefore an earlier operation finishes. Protecting table access alone does\nnot provide the serialization or lifetime needed by an active pipe.\n\nSerialize operations per pipe and keep its state and handle alive until\nall users finish. Avoid holding the session table lock across IPC waits,\nso a blocked pipe does not hold up unrelated pipes. This also provides\nthe lifetime needed to retain unread replies in the following patch.\n\nRecheck cancellation, connection release and session teardown after taking\nthe pipe lock, and mark a removed pipe closed before waiting for its active\noperation. Close all session RPC pipes on logoff after the other requests\nhave drained; keeping the TCP connection open must not retain old handles.\nUse standard SMB2 error replies for failed pipe operations while preserving\nthe selected status.","Type":"Description","Title":"ksmbd: avoid races between named-pipe operations"}]}}}