Skip to content
Heist/ feed
Unrated

smb: client: fix request buffer leak in smb2_new_read_req()

Type: advisorySource: Official CVE List1 source record

In the Linux kernel, the following vulnerability has been resolved: smb: client: fix request buffer leak in smb2_new_read_req() smb2_new_read_req() allocates the request buffer with smb2_plain_req_init() but only publishes it to the caller with *buf = req at the very end of the function. Two error returns sit in between: rc = smb2_plain_req_init(SMB2_READ, io_parms->tcon, server, (void **) &req, total_len); if (rc) return rc; if (server == NULL) return -ECONNABORTED; [...] rdata->mr = smbd_register_mr(server->smbd_conn, &rdata->subreq.io_iter, true, need_invalidate); if (!rdata->mr) return -EAGAIN; On either of them the buffer is neither released nor handed back, so it is leaked. The caller cannot clean up after it: smb2_async_readv() does 'goto out' on a non-zero return, which skips the cifs_small_buf_release(buf) at async_readv_out, and buf has not been assigned at that point in any case. The write path has never had this problem. smb2_async_writev() registers the memory region inline and jumps to its release label instead of returning: wdata->mr = smbd_register_mr(...); if (!wdata->mr) { rc = -EAGAIN; goto async_writev_out; } Commit b7972092199f ("cifs: smbd: Retry on memory registration failure") changed both sides from -ENOBUFS to -EAGAIN in a single patch, which puts the two shapes next to each other. Only the -EAGAIN return is reachable in practice, because smb2_plain_req_init() calls smb2_reconnect() first and that already fails with -EIO when server is NULL, before a

Announced Source revision 1
Original source ↗

CVE-2026-90125

Primary source · Revision 1

Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.

Security context

Source reference: cve:CVE-2026-90125

Linux

Source reference: /containers/cna/affected/0/product

Affected versions
Not stated in this record
Fixed versions
Not stated in this record
Prerequisites
Not stated in this record

Linux

Source reference: /containers/cna/affected/1/product

Affected versions
Not stated in this record
Fixed versions
Not stated in this record
Prerequisites
Not stated in this record

Structured affected-version data

Original package identities and version rules from this source.

[
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "bd3dcc6a22a9186ed78da51ce09e889803552189",
        "lessThan": "58066940076b90c16e821fd6f9767cd979cbdb5e",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "bd3dcc6a22a9186ed78da51ce09e889803552189",
        "lessThan": "12092ed28434bf41e08d41e3c5269eb6b337fc02",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "bd3dcc6a22a9186ed78da51ce09e889803552189",
        "lessThan": "442c5f1358ced0d4e716778ac06f1e323a7e4f21",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "bd3dcc6a22a9186ed78da51ce09e889803552189",
        "lessThan": "73f6bdb0380486ab37fe12cd74de20abfaf5d3ae",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "bd3dcc6a22a9186ed78da51ce09e889803552189",
        "lessThan": "deb6468f4164640e4dc875f008aa449cf55987a5",
        "versionType": "git"
      }
    ],
    "programFiles": [
      "fs/smb/client/smb2pdu.c"
    ],
    "defaultStatus": "unaffected"
  },
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "4.16"
      },
      {
        "status": "unaffected",
        "version": "0",
        "lessThan": "4.16",
        "versionType": "semver"
      },
      {
        "status": "unaffected",
        "version": "6.6.157",
        "versionType": "semver",
        "lessThanOrEqual": "6.6.*"
      },
      {
        "status": "unaffected",
        "version": "6.12.110",
        "versionType": "semver",
        "lessThanOrEqual": "6.12.*"
      },
      {
        "status": "unaffected",
        "version": "6.18.52",
        "versionType": "semver",
        "lessThanOrEqual": "6.18.*"
      },
      {
        "status": "unaffected",
        "version": "7.2.6",
        "versionType": "semver",
        "lessThanOrEqual": "7.2.*"
      },
      {
        "status": "unaffected",
        "version": "7.3",
        "versionType": "original_commit_for_fix",
        "lessThanOrEqual": "*"
      }
    ],
    "programFiles": [
      "fs/smb/client/smb2pdu.c"
    ],
    "defaultStatus": "affected"
  }
]
Related CVEs
CVE-2026-90125

Source reference: /cveMetadata/cveId

Publisher severity

No explicit severity was provided.

Event
#36527 · Revision 1
Added to Heist Feed
Publisher date
Read the original announcement