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]
Message-ID: <CAADnVQLbxWPM1njsE141dQjw2+USd8Ggv80QgY+PgsGRd6FoVA@mail.gmail.com>
Date: Wed, 6 Dec 2023 10:19:27 -0800
From: Alexei Starovoitov <alexei.starovoitov@...il.com>
To: Andrii Nakryiko <andrii@...nel.org>
Cc: bpf <bpf@...r.kernel.org>, Network Development <netdev@...r.kernel.org>, 
	Paul Moore <paul@...l-moore.com>, Christian Brauner <brauner@...nel.org>, 
	Linux-Fsdevel <linux-fsdevel@...r.kernel.org>, 
	LSM List <linux-security-module@...r.kernel.org>, Kees Cook <keescook@...omium.org>, 
	Kernel Team <kernel-team@...a.com>, Sargun Dhillon <sargun@...gun.me>
Subject: Re: [PATCH v12 bpf-next 03/17] bpf: introduce BPF token object

On Thu, Nov 30, 2023 at 10:57 AM Andrii Nakryiko <andrii@...nel.org> wrote:
>   *
> @@ -901,6 +931,8 @@ enum bpf_cmd {
>         BPF_ITER_CREATE,
>         BPF_LINK_DETACH,
>         BPF_PROG_BIND_MAP,
> +       BPF_TOKEN_CREATE,
> +       __MAX_BPF_CMD,
>  };

Not an issue with this commit. I just noticed that
commit f2e10bff16a0 ("bpf: Add support for BPF_OBJ_GET_INFO_BY_FD for bpf_link")
added MAX_BPF_LINK_TYPE to enum bpf_link_type.
While this commit is correctly adding __MAX_BPF_CMD that
is consistent with old __MAX_BPF_ATTACH_TYPE (added in 2016)
and __MAX_BPF_REG (added in 2014).
I think it would be good to follow up with adding two underscores
to MAX_BPF_LINK_TYPE just to keep things consistent in bpf.h.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ