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:   Tue, 28 Apr 2020 09:44:26 -0700
From:   Alexei Starovoitov <alexei.starovoitov@...il.com>
To:     Andrii Nakryiko <andriin@...com>
Cc:     bpf@...r.kernel.org, netdev@...r.kernel.org, ast@...com,
        daniel@...earbox.net, andrii.nakryiko@...il.com,
        kernel-team@...com, Julia Kartseva <hex@...com>
Subject: Re: [PATCH bpf-next 2/6] selftests/bpf: add test_progs-asan flavor
 with AddressSantizer

On Mon, Apr 27, 2020 at 09:46:24PM -0700, Andrii Nakryiko wrote:
> Add another flavor of test_progs that is compiled and run with
> AddressSanitizer and LeakSanitizer. This allows to find potential memory
> correction bugs and memory leaks. Due to sometimes not trivial requirements on
> the environment, this is (for now) done as a separate flavor, not by default.
> Eventually I hope to enable it by default.
> 
> To run ./test_progs-asan successfully, you need to have libasan installed in
> the system, where version of the package depends on GCC version you have.
> E.g., GCC8 needs libasan5, while GCC7 uses libasan4.
> 
> For CentOS 7, to build everything successfully one would need to:
>   $ sudo yum install devtoolset-8-gcc devtoolset-libasan-devel
> 
> For Arch Linux to run selftests, one would need to install gcc-libs package to
> get libasan.so.5:
>   $ sudo pacman -S gcc-libs
> 
> Cc: Julia Kartseva <hex@...com>
> Signed-off-by: Andrii Nakryiko <andriin@...com>

It needs a feature check.
selftest shouldn't be forcing asan on everyone.
Even after I did:
sudo yum install devtoolset-8-libasan-devel
it still failed to build:
  BINARY   test_progs-asan
/opt/rh/devtoolset-9/root/usr/libexec/gcc/x86_64-redhat-linux/9/ld: cannot find libasan_preinit.o: No such file or directory
/opt/rh/devtoolset-9/root/usr/libexec/gcc/x86_64-redhat-linux/9/ld: cannot find -lasan

Also I really don't like that skeletons are now built three times for now good reason
  GEN-SKEL [test_progs-asan] test_stack_map.skel.h
  GEN-SKEL [test_progs-asan] test_core_reloc_nesting.skel.h
default vs no_alu32 makes sense. They are different bpf.o files and different skeletons,
but for asan there is no such need.

Please resubmit the rest of the patches, since asan isn't a prerequisite.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ