summaryrefslogtreecommitdiff
path: root/kernel/kexec.c
diff options
context:
space:
mode:
authorBaokun Li <libaokun1@huawei.com>2024-05-22 19:43:02 +0800
committerChristian Brauner <brauner@kernel.org>2024-05-29 13:03:30 +0200
commita26dc49df37e996876f50a0210039b2d211fdd6f (patch)
tree3694199b7034232b83d56cb649a82e55759576f4 /kernel/kexec.c
parent3e6d704f02aa4c50c7bc5fe91a4401df249a137b (diff)
downloadlwn-a26dc49df37e996876f50a0210039b2d211fdd6f.tar.gz
lwn-a26dc49df37e996876f50a0210039b2d211fdd6f.zip
cachefiles: add consistency check for copen/cread
This prevents malicious processes from completing random copen/cread requests and crashing the system. Added checks are listed below: * Generic, copen can only complete open requests, and cread can only complete read requests. * For copen, ondemand_id must not be 0, because this indicates that the request has not been read by the daemon. * For cread, the object corresponding to fd and req should be the same. Signed-off-by: Baokun Li <libaokun1@huawei.com> Link: https://lore.kernel.org/r/20240522114308.2402121-7-libaokun@huaweicloud.com Acked-by: Jeff Layton <jlayton@kernel.org> Reviewed-by: Jingbo Xu <jefflexu@linux.alibaba.com> Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'kernel/kexec.c')
0 files changed, 0 insertions, 0 deletions