Messages in this thread |  | | From | cel@kernel ... | | Subject | Re: [PATCH] nfsd: free nfsd_file by gc after adding it to lru list | | Date | Tue, 14 Jan 2025 14:40:07 -0500 |
| |
From: Chuck Lever <chuck.lever@oracle.com>
On Mon, 13 Jan 2025 10:59:57 +0800, Li Lingfeng wrote: > In nfsd_file_put, after inserting the nfsd_file into the nfsd_file_lru > list, gc may be triggered in another thread and immediately release this > nfsd_file, which will lead to a UAF when accessing this nfsd_file again. > > All the places where unhash is done will also perform lru_remove, so there > is no need to do lru_remove separately here. After inserting the nfsd_file > into the nfsd_file_lru list, it can be released by relying on gc. > > [...]
Applied to nfsd-testing, thanks!
Cc-stable tag added.
[1/1] nfsd: free nfsd_file by gc after adding it to lru list commit: e57420be100ab3ff6d42992a37ce34f3e03d8d91
-- Chuck Lever
|  |