filelock: fix potential use-after-free in posix_lock_inode
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 74f6f5912693ce454384eaeec48705646a21c74f · < 116599f6a26906cf33f67975c59f0692ecf7e9b2| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
filelock: fix potential use-after-free in posix_lock_inode
Light Hsieh reported a KASAN UAF warning in trace_posix_lock_inode(). The request pointer had been changed earlier to point to a lock entry that was added to the inode's list. However, before the tracepoint could fire, another task raced in and freed that lock.
Fix this by moving the tracepoint inside the spinlock, which should ensure that this doesn't happen.
From the CVE record · Linux
A race in the Linux kernel’s posix_lock_inode can let another task free a lock before trace_posix_lock_inode uses it, causing a use-after-free. The input does not specify how an attacker could trigger the race or whether access or user interaction is required.
Anyone running the Linux kernel should check their version; affected versions are not specified.