VDB

CVE-2025-40328

CVE-2025-40328 PUBLISHED CVSS 8.8 HIGH

smb: client: fix potential UAF in smb2_close_cached_fid()

Reported by linux · Published December 9, 2025

In the Linux kernel, the following vulnerability has been resolved: smb: client: fix potential UAF in smb2_close_cached_fid() find_or_create_cached_dir() could grab a new reference after kref_put() had seen the refcount drop to zero but before cfid_list_lock is acquired in smb2_close_cached_fid(), leading to use-after-free. Switch to kref_put_lock() so cfid_release() is called with cfid_list_lock held, closing that gap.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
kernel-livepatch-6.12.58-82.121Amazon Linux1:1.0-0.amzn2023
kernel-headersAmazon Linux1:6.1.163-186.299.amzn2023
kernel6.12-headersAmazon Linux1:6.12.58-82.121.amzn2023
kernel-modules-extra-commonAmazon Linux1:6.1.163-186.299.amzn2023
kernel6.12-libbpf-staticAmazon Linux1:6.12.58-82.121.amzn2023
kernel6.12Amazon Linux1:6.12.58-82.121.amzn2023
python3-perf6.12Amazon Linux1:6.12.58-82.121.amzn2023
kernel6.12-modules-extraAmazon Linux1:6.12.58-82.121.amzn2023
perfAmazon Linux1:6.1.163-186.299.amzn2023
kernel6.12-libbpfAmazon Linux1:6.12.58-82.121.amzn2023
kernel-libbpf-develAmazon Linux1:6.1.163-186.299.amzn2023

Risk scores

CVSS 3.1
8.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Affected products

VendorProductVersions
LinuxLinuxebe98f1447bbccf8228335c62d86af02a0ed23f7, ebe98f1447bbccf8228335c62d86af02a0ed23f7, ebe98f1447bbccf8228335c62d86af02a0ed23f7
LinuxLinux6.1, 0, 6.1.191
amazon:2023kernel-livepatch-6.12.58-82.1210
amazon:2023kernel-headers0
amazon:2023kernel6.12-headers0
amazon:2023kernel-modules-extra-common0
amazon:2023kernel6.12-libbpf-static0
amazon:2023kernel6.120
amazon:2023python3-perf6.120
amazon:2023kernel6.12-modules-extra0
amazon:2023perf0
amazon:2023kernel6.12-libbpf0
amazon:2023kernel-libbpf-devel0
linuxlinux_kernel6.1, 6.1, 6.1
amazon:2023kernel-libbpf-static0
amazon:2023kernel0
amazon:2023python3-perf0
amazon:2023kernel6.12-libbpf-devel0
amazon:2023kernel-tools0
amazon:2023kernel-devel0

…and 12 more

Timeline

  • Dec 8, 2025 CVE Published
  • Dec 9, 2025 EPSS Score (30 in total, the first dated here)
  • Mar 29, 2026 Distribution Patch (114 in total, the first dated here)
  • Mar 29, 2026 Security Advisory (117 in total, the first dated here)
  • Jun 8, 2026 Coalition ESS Score
  • Jul 30, 2026 CVE Updated

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2025-40328
vulnetix vdb fixes CVE-2025-40328

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2025-40328/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

References

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›