{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2024-26594",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2024-02-19T14:20:24.127Z",
        "datePublished": "2024-02-23T13:26:46.577Z",
        "dateUpdated": "2026-08-05T11:26:08.636Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-08-05T11:26:08.636Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: validate mech token in session setup\n\nIf client send invalid mech token in session setup request, ksmbd\nvalidate and make the error if it is invalid."
                }
            ],
            "metrics": [
                {
                    "cvssV3_1": {
                        "version": "3.1",
                        "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H",
                        "baseScore": 9.1,
                        "baseSeverity": "CRITICAL"
                    },
                    "scenarios": [
                        {
                            "lang": "en",
                            "value": "AV:N - ksmbd is the in-kernel SMB server listening on TCP/445, and the flaw is triggered entirely by fields in a remotely supplied SMB2 SESSION_SETUP PDU (SecurityBufferLength plus the SPNEGO mechToken). Any host that can reach the SMB port can drive the vulnerable path.\nAC:L - The attacker directly and independently controls both sides of the length mismatch — the ASN.1 mechToken size (which sizes the kmemdup_nul allocation) and SecurityBufferLength (which is used as the bound) — so a single crafted packet deterministically produces the overread with no race, no timing dependency, and no reliance on uncontrolled state.\nPR:N - smb2_check_user_session() explicitly skips session validation for SMB2_SESSION_SETUP, and this code runs during the NTLMSSP/SPNEGO handshake before any credential is verified, so a completely unauthenticated remote peer reaches it after NEGOTIATE.\nUI:N - The server processes SESSION_SETUP requests autonomously in its kernel worker thread; no local user or administrator action is needed beyond ksmbd already serving a share.\nS:U - The out-of-bounds access occurs in kernel memory and its effects stay within the kernel's own security authority; no VM, IOMMU, or sandbox boundary is crossed.\nC:H - With a mechToken sized to hold an authenticate_message header and SecurityBufferLength set to 65535, the attacker fully controls name_off/name_len and nt_off/nt_len, giving an arbitrary-offset heap read of up to ~64KB past a small slab object — far beyond a \"few bytes\" bound. The disclosed bytes are converted into the username and domain strings that reach ksmbd.mountd and the kernel log, and the domain string feeds the NTLMv2 HMAC comparison, forming a remote oracle for recovering adjacent heap contents.\nI:N - Every consumer of the mis-sized buffer was traced and all are reads; the only writes (conn->ntlmssp.client_flags, sess->sess_key via cifs_arc4_crypt bounded by CIFS_KEY_SIZE, and the kzalloc'd construct buffer) target correctly sized in-bounds destinations, so no out-of-bounds write or control-flow primitive exists.\nA:H - The attacker-chosen read offset of up to 65535 bytes past a kmalloc-8/kmalloc-96 object will readily walk off the end of the slab page into unmapped or poisoned memory, oopsing the ksmbd worker thread (and panicking immediately under KASAN/DEBUG_PAGEALLOC), and it can be retriggered on a fresh unauthenticated connection at will."
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "fs/smb/server/asn1.c",
                        "fs/smb/server/connection.h",
                        "fs/smb/server/smb2pdu.c"
                    ],
                    "versions": [
                        {
                            "version": "0626e6641f6b467447c81dd7678a69c66f7746cf",
                            "lessThan": "dd1de9268745f0eac83a430db7afc32cbd62e84b",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "0626e6641f6b467447c81dd7678a69c66f7746cf",
                            "lessThan": "6eb8015492bcc84e40646390e50a862b2c0529c9",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "0626e6641f6b467447c81dd7678a69c66f7746cf",
                            "lessThan": "a2b21ef1ea4cf632d19b3a7cc4d4245b8e63202a",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "0626e6641f6b467447c81dd7678a69c66f7746cf",
                            "lessThan": "5e6dfec95833edc54c48605a98365a7325e5541e",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "0626e6641f6b467447c81dd7678a69c66f7746cf",
                            "lessThan": "92e470163d96df8db6c4fa0f484e4a229edb903d",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "fs/smb/server/asn1.c",
                        "fs/smb/server/connection.h",
                        "fs/smb/server/smb2pdu.c"
                    ],
                    "versions": [
                        {
                            "version": "5.15",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "5.15",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.15.149",
                            "lessThanOrEqual": "5.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.1.75",
                            "lessThanOrEqual": "6.1.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.6.14",
                            "lessThanOrEqual": "6.6.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.7.2",
                            "lessThanOrEqual": "6.7.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.8",
                            "lessThanOrEqual": "*",
                            "status": "unaffected",
                            "versionType": "original_commit_for_fix"
                        }
                    ]
                }
            ],
            "cpeApplicability": [
                {
                    "nodes": [
                        {
                            "operator": "OR",
                            "negate": false,
                            "cpeMatch": [
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15",
                                    "versionEndExcluding": "5.15.149"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15",
                                    "versionEndExcluding": "6.1.75"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15",
                                    "versionEndExcluding": "6.6.14"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15",
                                    "versionEndExcluding": "6.7.2"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15",
                                    "versionEndExcluding": "6.8"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/dd1de9268745f0eac83a430db7afc32cbd62e84b"
                },
                {
                    "url": "https://git.kernel.org/stable/c/6eb8015492bcc84e40646390e50a862b2c0529c9"
                },
                {
                    "url": "https://git.kernel.org/stable/c/a2b21ef1ea4cf632d19b3a7cc4d4245b8e63202a"
                },
                {
                    "url": "https://git.kernel.org/stable/c/5e6dfec95833edc54c48605a98365a7325e5541e"
                },
                {
                    "url": "https://git.kernel.org/stable/c/92e470163d96df8db6c4fa0f484e4a229edb903d"
                }
            ],
            "title": "ksmbd: validate mech token in session setup",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        },
        "adp": [
            {
                "metrics": [
                    {
                        "other": {
                            "type": "ssvc",
                            "content": {
                                "id": "CVE-2024-26594",
                                "role": "CISA Coordinator",
                                "options": [
                                    {
                                        "Exploitation": "none"
                                    },
                                    {
                                        "Automatable": "no"
                                    },
                                    {
                                        "Technical Impact": "partial"
                                    }
                                ],
                                "version": "2.0.3",
                                "timestamp": "2024-02-23T22:33:33.242942Z"
                            }
                        }
                    }
                ],
                "title": "CISA ADP Vulnrichment",
                "providerMetadata": {
                    "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
                    "shortName": "CISA-ADP",
                    "dateUpdated": "2024-07-05T17:21:02.695Z"
                }
            },
            {
                "providerMetadata": {
                    "orgId": "af854a3a-2127-422b-91ae-364da2661108",
                    "shortName": "CVE",
                    "dateUpdated": "2024-08-02T00:07:19.636Z"
                },
                "title": "CVE Program Container",
                "references": [
                    {
                        "url": "https://git.kernel.org/stable/c/dd1de9268745f0eac83a430db7afc32cbd62e84b",
                        "tags": [
                            "x_transferred"
                        ]
                    },
                    {
                        "url": "https://git.kernel.org/stable/c/6eb8015492bcc84e40646390e50a862b2c0529c9",
                        "tags": [
                            "x_transferred"
                        ]
                    },
                    {
                        "url": "https://git.kernel.org/stable/c/a2b21ef1ea4cf632d19b3a7cc4d4245b8e63202a",
                        "tags": [
                            "x_transferred"
                        ]
                    },
                    {
                        "url": "https://git.kernel.org/stable/c/5e6dfec95833edc54c48605a98365a7325e5541e",
                        "tags": [
                            "x_transferred"
                        ]
                    },
                    {
                        "url": "https://git.kernel.org/stable/c/92e470163d96df8db6c4fa0f484e4a229edb903d",
                        "tags": [
                            "x_transferred"
                        ]
                    }
                ]
            }
        ]
    }
}