CVE-2023-54076 (GCVE-0-2023-54076)
Vulnerability from cvelistv5
Published
2025-12-24 12:23
Modified
2026-08-05 09:16
Severity ?
Summary
In the Linux kernel, the following vulnerability has been resolved: smb: client: fix missed ses refcounting Use new cifs_smb_ses_inc_refcount() helper to get an active reference of @ses and @ses->dfs_root_ses (if set). This will prevent @ses->dfs_root_ses of being put in the next call to cifs_put_smb_ses() and thus potentially causing an use-after-free bug.
Impacted products
Vendor Product Version
Linux Linux Version: 8e3554150d6c80a84b3cb046615d1a0e943811dc
Version: 8e3554150d6c80a84b3cb046615d1a0e943811dc
Version: f30d226bcc9f0e2d97b4a6e94c43a28148fbeab6
Version: c082c3be0f96e759ff2e361d929832fda0b93851
Version: 6.2.15   
Version: 6.3.2   
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "fs/smb/client/dfs.c",
            "fs/smb/client/smb2transport.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "eb382196e6f6e05cfafdab797840e5a96c6e7bf0",
              "status": "affected",
              "version": "8e3554150d6c80a84b3cb046615d1a0e943811dc",
              "versionType": "git"
            },
            {
              "lessThan": "bf99f6be2d20146942bce6f9e90a0ceef12cbc1e",
              "status": "affected",
              "version": "8e3554150d6c80a84b3cb046615d1a0e943811dc",
              "versionType": "git"
            },
            {
              "status": "affected",
              "version": "f30d226bcc9f0e2d97b4a6e94c43a28148fbeab6",
              "versionType": "git"
            },
            {
              "status": "affected",
              "version": "c082c3be0f96e759ff2e361d929832fda0b93851",
              "versionType": "git"
            },
            {
              "lessThan": "6.3",
              "status": "affected",
              "version": "6.2.15",
              "versionType": "semver"
            },
            {
              "lessThan": "6.4",
              "status": "affected",
              "version": "6.3.2",
              "versionType": "semver"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "fs/smb/client/dfs.c",
            "fs/smb/client/smb2transport.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.4"
            },
            {
              "lessThan": "6.4",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.4.*",
              "status": "unaffected",
              "version": "6.4.7",
              "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": "6.4.7",
                  "versionStartIncluding": "6.4",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.5",
                  "versionStartIncluding": "6.4",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionStartIncluding": "6.2.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionStartIncluding": "6.3.2",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nsmb: client: fix missed ses refcounting\n\nUse new cifs_smb_ses_inc_refcount() helper to get an active reference\nof @ses and @ses-\u003edfs_root_ses (if set).  This will prevent\n@ses-\u003edfs_root_ses of being put in the next call to cifs_put_smb_ses()\nand thus potentially causing an use-after-free bug."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 9.8,
            "baseSeverity": "CRITICAL",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:N - The flaw is in the in-kernel SMB/CIFS network filesystem client, and the unbalanced puts are driven by data from the remote peer \u2014 the server picks the SMB2.0/2.1 dialect that routes signing through the buggy `smb2_calc_signature()`, returns the DFS referrals (`DFSREF_REFERRAL_SERVER`) that populate `ses-\u003edfs_root_ses`, and controls the delayed CREATE replies that reach `smb2_handle_cancelled_mid()`. A malicious, compromised, or MITM\u0027d SMB/DFS server drives the refcount underflow purely over the network.\nAC:L - The imbalance is deterministic, not a race: every `smb2_find_smb_ses_unlocked()` acquisition drops one extra reference on `ses-\u003edfs_root_ses` at release, so the attacker simply drives enough signed exchanges to force the count to zero. No memory-layout or timing condition outside the attacker\u0027s control is needed.\nPR:N - The attacker is the remote SMB/DFS server (or a network MITM) and holds no privileges or account on the victim client; referral responses and dialect negotiation happen without any credential on the target system.\nUI:N - The `smb2transport.c` half of the bug is a steady-state runtime path \u2014 on an already-mounted DFS share, signature calculation, cancelled-MID handling, echo keepalives and the DFS cache refresh worker accumulate the extra puts with no user action at attack time.\nS:U - The premature free and subsequent corruption are confined to kernel memory within the same security authority; no VM, IOMMU, or sandbox boundary is crossed.\nC:H - Use-after-free on a `cifs_ses` object whose slot can be reoccupied by attacker-groomed heap data yields a read primitive, and the freed session still holds authentication material (`auth_key.response`, signing keys) and kernel pointers used by subsequent code.\nI:H - After the free, `cifs_put_smb_ses()` reads `ses-\u003eserver` from freed memory and performs an indirect call via `server-\u003eops-\u003elogoff()`, giving a control-flow hijack primitive; heap spraying over the freed `cifs_ses` converts this into arbitrary write/code execution.\nA:H - The refcount underflow frees a session still referenced by child sessions, tcons, and the DFS cache worker, reliably producing an oops/panic (and a `WARN_ON(ses-\u003eses_count \u003c 0)`) that takes down the machine."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T09:16:59.986Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/eb382196e6f6e05cfafdab797840e5a96c6e7bf0"
        },
        {
          "url": "https://git.kernel.org/stable/c/bf99f6be2d20146942bce6f9e90a0ceef12cbc1e"
        }
      ],
      "title": "smb: client: fix missed ses refcounting",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2023-54076",
    "datePublished": "2025-12-24T12:23:18.330Z",
    "dateReserved": "2025-12-24T12:21:05.093Z",
    "dateUpdated": "2026-08-05T09:16:59.986Z",
    "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…