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: <fe42b22b-c3d6-136e-a659-8bd189302afd@fb.com>
Date:   Thu, 2 Jul 2020 14:01:20 -0700
From:   Yonghong Song <yhs@...com>
To:     John Fastabend <john.fastabend@...il.com>, <andriin@...com>,
        <ast@...nel.org>, <daniel@...earbox.net>
CC:     <netdev@...r.kernel.org>, <bpf@...r.kernel.org>
Subject: Re: [bpf-next PATCH] bpf: fix bpftool without skeleton code enabled



On 7/2/20 10:25 AM, John Fastabend wrote:
> Fix segfault from bpftool by adding emit_obj_refs_plain when skeleton
> code is disabled.
> 
> Tested by deleting BUILD_BPF_SKELS in Makefile.

You probably hit this issue with a different way, right?
Old clang, or anything? I would be good to clarify in
the commit message. People in general do not tweak Makefile
to find bugs, I guess.

> 
> # ./bpftool prog show
> Error: bpftool built without PID iterator support
> 3: cgroup_skb  tag 7be49e3934a125ba  gpl
>          loaded_at 2020-07-01T08:01:29-0700  uid 0
> Segmentation fault
> 
> Signed-off-by: John Fastabend <john.fastabend@...il.com>

Ack with request for better description in the commit message.

Acked-by: Yonghong Song <yhs@...com>

> ---
>   tools/bpf/bpftool/pids.c |    1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/tools/bpf/bpftool/pids.c b/tools/bpf/bpftool/pids.c
> index 2709be4de2b1..7d5416667c85 100644
> --- a/tools/bpf/bpftool/pids.c
> +++ b/tools/bpf/bpftool/pids.c
> @@ -19,6 +19,7 @@ int build_obj_refs_table(struct obj_refs_table *table, enum bpf_obj_type type)
>   	return -ENOTSUP;
>   }
>   void delete_obj_refs_table(struct obj_refs_table *table) {}
> +void emit_obj_refs_plain(struct obj_refs_table *table, __u32 id, const char *prefix) {}
>   
>   #else /* BPFTOOL_WITHOUT_SKELETONS */
>   
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ