CVE-2023-4130 (GCVE-0-2023-4130)
Vulnerability from cvelistv5
Published
2025-08-16 13:27
Modified
2026-08-15 12:23
Summary
In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix wrong next length validation of ea buffer in smb2_set_ea() There are multiple smb2_ea_info buffers in FILE_FULL_EA_INFORMATION request from client. ksmbd find next smb2_ea_info using ->NextEntryOffset of current smb2_ea_info. ksmbd need to validate buffer length Before accessing the next ea. ksmbd should check buffer length using buf_len, not next variable. next is the start offset of current ea that got from previous ea.
Impacted products
Vendor Product Version
Linux Linux Version: e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9
Version: e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9
Version: e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9
Version: e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "fs/smb/server/smb2pdu.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "aeb974907642be095e38ecb1a400ca583958b2b0",
              "status": "affected",
              "version": "e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9",
              "versionType": "git"
            },
            {
              "lessThan": "f339d76a3a972601d0738b881b099d49ebbdc3a2",
              "status": "affected",
              "version": "e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9",
              "versionType": "git"
            },
            {
              "lessThan": "4bf629262f9118ee91b1c3a518ebf2b3bcb22180",
              "status": "affected",
              "version": "e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9",
              "versionType": "git"
            },
            {
              "lessThan": "79ed288cef201f1f212dfb934bcaac75572fb8f6",
              "status": "affected",
              "version": "e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "fs/smb/server/smb2pdu.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.15"
            },
            {
              "lessThan": "5.15",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.127",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.1.*",
              "status": "unaffected",
              "version": "6.1.46",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.4.*",
              "status": "unaffected",
              "version": "6.4.11",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.5",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.127",
                  "versionStartIncluding": "5.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1.46",
                  "versionStartIncluding": "5.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.4.11",
                  "versionStartIncluding": "5.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.5",
                  "versionStartIncluding": "5.15",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: fix wrong next length validation of ea buffer in smb2_set_ea()\n\nThere are multiple smb2_ea_info buffers in FILE_FULL_EA_INFORMATION request\nfrom client. ksmbd find next smb2_ea_info using -\u003eNextEntryOffset of\ncurrent smb2_ea_info. ksmbd need to validate buffer length Before\naccessing the next ea. ksmbd should check buffer length using buf_len,\nnot next variable. next is the start offset of current ea that got from\nprevious ea."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 8.1,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:N - The bug is in ksmbd\u0027s in-kernel SMB server (fs/smb/server/smb2pdu.c) and is reached over TCP/445 via SMB2_SET_INFO FILE_FULL_EA_INFORMATION or SMB2_CREATE with an EA create context; a remote client triggers it with crafted EA buffers.\nAC:L - The attacker fully controls NextEntryOffset, EaNameLength, and EaValueLength in the EA list and can deterministically advance past the validated region so subsequent entries are parsed with an incorrect remaining-length check; no race or attacker-uncontrollable precondition is required.\nPR:L - smb2_set_ea() is reached only after SMB2 session setup and tree connect: SET_INFO needs a writable handle with FILE_WRITE_EA, and CREATE-with-EA needs share write access, so an ordinary authenticated SMB account (or guest on guest-enabled shares) suffices, but this is not a pre-authentication path.\nUI:N - The attacker completes negotiate, session setup, tree connect, and the crafted SET_INFO/CREATE sequence entirely from its own connection; no local user or administrator action is required.\nS:U - The out-of-bounds read, optional xattr exfiltration, and any oops occur within the host kernel/ksmbd security authority; this is not a VM escape, IOMMU bypass, or sandbox boundary cross.\nC:H - After advancing via NextEntryOffset, the wrong check validates against next instead of remaining buf_len, so EaNameLength/EaValueLength can drive unbounded out-of-bounds reads of adjacent kernel heap; setxattr can persist that memory into an EA the attacker later queries, so the over-read is not limited to a few bytes.\nI:N - The defect is a read past the request buffer into name/value parsing and setxattr source data; there is no out-of-bounds write, type confusion, or control-flow hijack primitive from this bug alone (ZDI classifies it as information disclosure).\nA:H - Reading past the kmalloc\u0027d request buffer can fault into unmapped memory and oops/panic the kernel, and the attacker can retrigger the malformed EA list on each SET_INFO or CREATE."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-15T12:23:44.304Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/aeb974907642be095e38ecb1a400ca583958b2b0"
        },
        {
          "url": "https://git.kernel.org/stable/c/f339d76a3a972601d0738b881b099d49ebbdc3a2"
        },
        {
          "url": "https://git.kernel.org/stable/c/4bf629262f9118ee91b1c3a518ebf2b3bcb22180"
        },
        {
          "url": "https://git.kernel.org/stable/c/79ed288cef201f1f212dfb934bcaac75572fb8f6"
        }
      ],
      "title": "ksmbd: fix wrong next length validation of ea buffer in smb2_set_ea()",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2023-4130",
    "datePublished": "2025-08-16T13:27:58.227Z",
    "dateReserved": "2023-08-03T08:12:08.227Z",
    "dateUpdated": "2026-08-15T12:23:44.304Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2"
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…