Re: [PATCH bpf] bpf: Fix offset calculation error in __copy_map_value and zero_map_value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Nov 11, 2022 at 06:26:20PM IST, Xu Kuohai wrote:
> From: Xu Kuohai <xukuohai@xxxxxxxxxx>
>
> Function __copy_map_value and zero_map_value miscalculated copy offset,
> resulting in possible copy of unwanted data to user or kernel.
>
> Fix it.
>
> Fixes: cc48755808c6 ("bpf: Add zero_map_value to zero map value with special fields")
> Fixes: 4d7d7f69f4b1 ("bpf: Adapt copy_map_value for multiple offset case")
> Signed-off-by: Xu Kuohai <xukuohai@xxxxxxxxxx>
> ---

Acked-by: Kumar Kartikeya Dwivedi <memxor@xxxxxxxxx>

I also have a fix here for bpf-next, since this won't apply to it:
https://lore.kernel.org/bpf/20221111193224.876706-4-memxor@xxxxxxxxx

I think it'd be best if this one gets applied to bpf and mine to bpf-next, and
any conflicts are resolved when merging both trees (the conflict is trivial),
but I'll leave it up to the maintainers to decide.



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux