diff options
author | Aliaksei Urbanski <aliaksei.urbanski@gmail.com> | 2023-11-08 04:58:52 +0300 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2023-11-23 13:31:19 +0000 |
commit | 124f3e448e7a0c4680fbff2306a3e2c9354bde77 (patch) | |
tree | f512817f4047356bf4d9d80a1faa79901621a313 | |
parent | README: fix typo: s/peforming/performing. (diff) | |
download | pax-utils-124f3e448e7a0c4680fbff2306a3e2c9354bde77.tar.gz pax-utils-124f3e448e7a0c4680fbff2306a3e2c9354bde77.tar.bz2 pax-utils-124f3e448e7a0c4680fbff2306a3e2c9354bde77.zip |
Fix fuzz-dumpelf test
Not sure why, but the dumpelf.fuzz fuzzer fails when it's calling
prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, ...) at security_init.
So I suggest disabling seccomp for fuzzy testing.
Also, in order to not run indefinitely,
the fuzzer must be executed with some reasonable options.
https://releases.llvm.org/14.0.0/docs/LibFuzzer.html#options
Signed-off-by: Aliaksei Urbanski <aliaksei.urbanski@gmail.com>
Closes: https://github.com/gentoo/pax-utils/pull/13
Signed-off-by: Sam James <sam@gentoo.org>
-rw-r--r-- | meson.build | 8 | ||||
-rw-r--r-- | security.c | 4 |
2 files changed, 11 insertions, 1 deletions
diff --git a/meson.build b/meson.build index 0cb9a0e..255107b 100644 --- a/meson.build +++ b/meson.build @@ -166,6 +166,12 @@ if do_tests and get_option('use_fuzzing') link_args : fuzz_flags, install : false ) - test('fuzz-dumpelf', dumpelf_fuzzer) + test('fuzz-dumpelf', dumpelf_fuzzer, + args : [ + '-close_fd_mask=3', + '-max_total_time=10', + '-print_final_stats', + ] + ) endif endif @@ -46,6 +46,10 @@ # undef WANT_SECCOMP #endif +#if PAX_UTILS_LIBFUZZ +# undef WANT_SECCOMP +#endif + static int ns_unshare(int flags) { int flag, ret = 0; |