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] [day] [month] [year] [list]
Message-ID: <20200710185241.07d53eb2@toad>
Date:   Fri, 10 Jul 2020 18:52:41 +0200
From:   Jakub Sitnicki <jakub@...udflare.com>
To:     Jakub Sitnicki <jakub@...udflare.com>, bpf@...r.kernel.org
Cc:     netdev@...r.kernel.org, kernel-team@...udflare.com,
        Alexei Starovoitov <ast@...nel.org>,
        Daniel Borkmann <daniel@...earbox.net>,
        Stanislav Fomichev <sdf@...gle.com>
Subject: Re: [PATCH bpf] selftests/bpf: Set attach type for CGROUP_SOCKOPT
 verifier test

On Fri, 10 Jul 2020 16:49:17 +0000
Jakub Sitnicki <jakub@...udflare.com> wrote:

> BPF_PROG_TYPE_CGROUP_SOCKOPT requires expected_attach_type to be set on
> prog load. Set it in the verifier test that checks if calling
> bpf_perf_event_output() from CGROUP_SOCKOPT is allowed so that the runner
> does skip it.
> 
> Cc: Stanislav Fomichev <sdf@...gle.com>
> Fixes: 0456ea170cd6 ("bpf: Enable more helpers for BPF_PROG_TYPE_CGROUP_{DEVICE,SYSCTL,SOCKOPT}")
> Signed-off-by: Jakub Sitnicki <jakub@...udflare.com>
> ---
>  tools/testing/selftests/bpf/verifier/event_output.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/testing/selftests/bpf/verifier/event_output.c b/tools/testing/selftests/bpf/verifier/event_output.c
> index 99f8f582c02b..c5e805980409 100644
> --- a/tools/testing/selftests/bpf/verifier/event_output.c
> +++ b/tools/testing/selftests/bpf/verifier/event_output.c
> @@ -112,6 +112,7 @@
>  	"perfevent for cgroup sockopt",
>  	.insns =  { __PERF_EVENT_INSNS__ },
>  	.prog_type = BPF_PROG_TYPE_CGROUP_SOCKOPT,
> +	.expected_attach_type = BPF_CGROUP_SETSOCKOPT,
>  	.fixup_map_event_output = { 4 },
>  	.result = ACCEPT,
>  	.retval = 1,

Just noticed same fix has been already posted a couple hours earlier:

  https://lore.kernel.org/bpf/20200710150439.126627-1-jean-philippe@linaro.org/

Please ignore.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ