lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sat, 16 Nov 2019 01:18:34 +0000
From:   Alexei Starovoitov <ast@...com>
To:     Daniel Borkmann <daniel@...earbox.net>,
        Andrii Nakryiko <andriin@...com>,
        "bpf@...r.kernel.org" <bpf@...r.kernel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
CC:     "andrii.nakryiko@...il.com" <andrii.nakryiko@...il.com>,
        Kernel Team <Kernel-team@...com>,
        Johannes Weiner <hannes@...xchg.org>,
        Rik van Riel <riel@...riel.com>
Subject: Re: [PATCH v4 bpf-next 2/4] bpf: add mmap() support for
 BPF_MAP_TYPE_ARRAY

On 11/15/19 4:13 PM, Daniel Borkmann wrote:
>>> Yeah, only for fd array currently. Question is, if we ever reuse that
>>> map_release_uref
>>> callback in future for something else, will we remember that we earlier
>>> missed to add
>>> it here? :/
>>
>> What do you mean 'missed to add' ?
> 
> Was saying missed to add the inc/put for the uref counter.
> 
>> This is mmap path. Anything that needs releasing (like FDs for
>> prog_array or progs for sockmap) cannot be mmap-able.
> 
> Right, I meant if in future we ever have another use case outside of it
> for some reason (unrelated to those maps you mention above). Can we
> guarantee this is never going to happen? Seemed less fragile at least to
> maintain proper count here.

I'm struggling to understand the concern.
map-in-map, xskmap, socket local storage are doing bpf_map_inc(, false)
when they need to hold the map. Why this case is any different?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ