Bug 2420415 (CVE-2025-40328) - CVE-2025-40328 kernel: smb: client: fix potential UAF in smb2_close_cached_fid()
Summary: CVE-2025-40328 kernel: smb: client: fix potential UAF in smb2_close_cached_fid()
Keywords:
Status: NEW
Alias: CVE-2025-40328
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-12-09 05:01 UTC by OSIDB Bzimport
Modified: 2025-12-09 23:08 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2025-12-09 05:01:52 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.