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:   Fri, 21 May 2021 07:38:38 -0700
From:   Alexei Starovoitov <alexei.starovoitov@...il.com>
To:     "David S. Miller" <davem@...emloft.net>
Cc:     Daniel Borkmann <daniel@...earbox.net>,
        Andrii Nakryiko <andrii@...nel.org>,
        John Fastabend <john.fastabend@...il.com>,
        Lorenz Bauer <lmb@...udflare.com>,
        Network Development <netdev@...r.kernel.org>,
        bpf <bpf@...r.kernel.org>, Kernel Team <kernel-team@...com>
Subject: Re: [RFC PATCH bpf-next] bpf: Introduce bpf_timer

On Thu, May 20, 2021 at 11:55 AM Alexei Starovoitov
<alexei.starovoitov@...il.com> wrote:
>
> From: Alexei Starovoitov <ast@...nel.org>
>
> Introduce 'struct bpf_timer' that can be embedded in most BPF map types
> and helpers to operate on it:
> long bpf_timer_init(struct bpf_timer *timer, void *callback, int flags)
> long bpf_timer_mod(struct bpf_timer *timer, u64 msecs)
> long bpf_timer_del(struct bpf_timer *timer)
>
> Signed-off-by: Alexei Starovoitov <ast@...nel.org>
> ---
> This is work in progress, but gives an idea on how API will look.

Forgot to mention the todo list:
- restrict to cap_bpf
- kfree bpf_timer_list
- verifier btf checks
- restrict to array, hash, lru, lpm. per-cpu maps cannot be supported.
- safe interaction with lookup/update/delete operations and iterator
- relax the 'first field only' requirement to allow bpf_timerr in global data.
  kinda without a map.
- check prog_rdonly, frozen, mmaped flags
- decide on a return value from the timer callback
- more tests

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ