| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Acked-by: Paul Moore <paul@paul-moore.com>
Signed-off-by: Tom Hromatka <tom.hromatka@oracle.com>
|
|
|
|
|
|
|
|
|
|
|
| |
[xen0n: LoongArch (and a few upcoming architectures / ABIs) does not
have fstat, so the fstat in 06-sim-actions is also being changed to
fstatfs for uniformity across the board.]
Signed-off-by: Xiaotian Wu <wuxiaotian@loongson.cn>
Signed-off-by: WANG Xuerui <git@xen0n.name>
Acked-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
| |
Signed-off-by: Manabu Sugimoto <Manabu.Sugimoto@sony.com>
Reviewed-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
| |
This allows us to specify the test batches via environment variables
like we do other parts of the test configuration.
Acked-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
| |
You can now run multiple test types using the '-T' argument and
the LIBSECCOMP_TSTCFG_TYPE environment variable, for example:
% cd tests
% ./regression -T bpf-valgrind,live
Acked-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
| |
Initial support for seccomp for SuperH in Linux was added in 2.6.27-rc2,
support for SECCOMP_FILTER was added for Linux 5.9. This adds support
for SuperH in libseccomp, both for little-endian and big-endian mode.
Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Acked-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The LIBSECCOMP_TSTCFG_JOBS environment variable allows the caller to
specify the number of test jobs through the environment as opposed
to the command line. This is primarily useful for running the tests
through scripts or via the 'make check' command.
The LIBSECCOMP_TSTCFG_JOBS environment variable value behaves the
same as the '-j <JOBS>' command line argument.
Reviewed-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the beginning it didn't matter that we were running the regression
tests serially, but as we are now running +16k tests the run time is
getting rather long.
As there is no good reason why we can't run these tests in parallel,
let's add some basic support to do so. This patch adds support for
running multiple tests jobs at once using the '-j <NUM>' flag,
similar to the "make" command. If the number of jobs specified is
invalid/zero then it is set to the number of CPUs present on the
system. If the '-j <NUM>' flag is not specified then the tests are
executed in serial fashion as they are done now.
If the '-l <LOG>' option is specified the test run reverts to serial
execution regardless of the command line in order to preserve the log
output. While the normal console output is preserved regardless of
the number of jobs, the logfile output is handled differently and
this restriction was the easiest solution. We should consider
removing the '-l <LOG>' option at some point since output capture and
redirection is likely best handled by the shell anyway.
As far as the performance improvements are concerned, the results
speak for themselves. On my eight core laptop the runtime drops from
~14 minutes to ~4 minutes (!).
* Existing code, single threaded (14 minutes, 14 seconds)
% time -- ./regression -m c -m python
=============== Tue Jan 5 06:11:52 PM EST 2021 ===============
Regression Test Report ("regression -m c -m python")
batch name: 01-sim-allow
test mode: c
test type: bpf-sim
Test 01-sim-allow%%001-00001 result: SUCCESS
...
Test 58-live-tsync_notify%%001-00001 result: SKIPPED (must specify live tests)
Regression Test Summary
tests run: 16412
tests skipped: 130
tests passed: 16412
tests failed: 0
tests errored: 0
============================================================
real 854.37
user 693.87
sys 269.25
* Patched code, 8 jobs (4 minutes, 7 seconds)
% time -- ./regression -j 8 -m c -m python
=============== Tue Jan 5 06:27:56 PM EST 2021 ===============
Regression Test Report ("regression -j 8 -m c -m python")
batch name: 01-sim-allow
test mode: c
test type: bpf-sim
Test 01-sim-allow%%001-00001 result: SUCCESS
...
Test 58-live-tsync_notify%%001-00001 result: SKIPPED (must specify live tests)
Regression Test Summary
tests run: 16412
tests skipped: 130
tests passed: 16412
tests failed: 0
tests errored: 0
============================================================
real 246.96
user 966.08
sys 251.27
Reviewed-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
| |
This appears to cause problems in the Travis CI with the aarch64
architecture.
Acked-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
| |
Signed-off-by: Andreas Schwab <schwab@suse.de>
[PM: minor macro shuffling in seccomp.h.in]
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
| |
Signed-off-by: Chris Waldon <chris.waldon@ibm.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
| |
Add "[+]all_32" and "[+]all_64" which work the same as the
little and big endian test filters.
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
| |
This addresses GitHub Issue #96 - RFE: add support for
SECCOMP_RET_KILL_PROCESS
Signed-off-by: Tom Hromatka <tom.hromatka@oracle.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
| |
I'm not particularly proud of the seccomp.pyx hack, but it works, and
enabling the python bindings during the distcheck is definitely the
"Greater Good".
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
| |
The basics needed to handle tests that use the new SCMP_ACT_LOG
action.
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
| |
A conditional added in ec6f45ab was incorrectly comparing the (empty)
stdout of grep -q against 0, which always evaluated to be true and
skipped the basic python tests.
Fix it by using bash's pattern matching.
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
| |
This commit also renames some of the variables in the tests directory
to better reflect their meaning.
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
| |
This commit also adds special shell-script handling for the "basic"
tests.
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
| |
Allow the fuzz tests to be configured via the
LIBSECCOMP_TSTCFG_STRESSCNT environment variable.
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
| |
Allow the test type to be specified by the LIBSECCOMP_TSTCFG_TYPE
environment variable.
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch (v4) adds support for the parisc and parisc64 architectures
to libseccomp.
I didn't split up the patch, because it's pretty trivial.
Those parisc-specific files gets added:
src/arch-parisc-syscalls.c
src/arch-parisc.c
src/arch-parisc.h
src/arch-parisc64.c
All other changes are trivial because they simply add parisc-specific
case statements in variouse switch statements.
I did ran a "make check" on x86-64 and parisc and all testcases succeeded.
All live testcases succeed as well when running "./regression -T live".
The patch applies cleanly to current libseccomp git head.
Changes between v4 and v3 of this patch:
- Added parisc arch to arch-syscall-check.c and fixup syscall table as
needed
- Fixed copyright notices in parisc files as suggested by Mike Frysinger
Changes between v3 and v2 of this patch:
- Stripped out patch which reports if a check was skipped because
valgrind isn't installed.
- Added tuxcall pseudo syscall for 19-sim-missing_syscalls testcase
- Added sysmips pseudo syscall for 29-sim-pseudo_syscall testcase
Changes between v2 and v1 of this patch:
- Enabled seccomp mode 2 regression tests on parisc. Kernel support for
hppa was added in kernel 4.6-rc1 and backported into the kernel v4.5.2
stable series.
Signed-off-by: Helge Deller <deller@gmx.de>
[PM: corrected a number or errors from 'make check-syntax']
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Print a message if a regression test was skipped just because valgrind isn't
installed.
This additional info is useful for architectures (e.g. parisc) which aren't
as fast as x86_64. On parisc it seemed that the whole testcase was hanging,
now people know what's actually happening.
Signed-off-by: Helge Deller <deller@gmx.de>
Signed-off-by: Paul Moore <paul@paul-moore.com>
|
|\
| |
| |
| | |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This patch adds support for S390 (32-bit) architecture.
Signed-off-by: Jan Willeke <willeke@linux.vnet.ibm.com>
[PM: rewrote the subject line, style fixes, s390x/s390 typo bugfixes]
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This patch adds support for S390x (64-bit) architecture.
Signed-off-by: Jan Willeke <willeke@linux.vnet.ibm.com>
[PM: rewrote the subject line, style fixes]
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
| |
| |
| |
| |
| |
| | |
This is a bit of a hack, but it works; fix it later.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|\ \
| | |
| | |
| | |
| | |
| | | |
Mike Strosaker <strosake@linux.vnet.ibm.com> reports that the
working-ppc64 branch is working for both 'make check' and './regression
-T live'.
|
| | |
| | |
| | |
| | |
| | | |
Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com>
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Otherwise The live tests will fail with
"ERROR arch ppc64 not supported"
Send against the working-ppc64 branch.
Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com>
[PM: added ppc64le]
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
| |/
| |
| |
| | |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
| |
Because of incorrect number sequence generation by seq(1) on at least 32
bit ARM systems using coreutils v8.23/v8.24 we provide a minimal seq(1)
implementation that fits our needs.
This fixes the bug mentioned in the following mailing thread:
https://groups.google.com/forum/#!topic/libseccomp/VtrClkXxLGA
Signed-off-by: Mathias Krause <minipli@googlemail.com>
[PM: subject line, build locations, and vertical whitespace tweaks]
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
|
| |
This patch adds support for AArch64 (64-bit ARM) architecture.
Signed-off-by: Marcin Juszkiewicz <mjuszkiewicz@redhat.com>
(Additional fixes/corrections/etc.)
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds support for a number of new enhancements to the
automated test suite, all of which are focused on the architecture
selection of the bpf-sim test type.
With this patch, the architecture field can now contain a comma
delimited list of architecture names with the following values:
* all
Add the current native arch to the list.
* all_le
Add the current native arch to the list only if it is little
endian.
* +all_le
Add all of the supported little endian architectures to the list.
* all_be
Add the current native arch to the list only if it is big endian.
* +all_be
Add all of the supported big endian architectures to the list.
* <arch>
Add the architecture specified by "<arch>" if it is the native
architecture.
* +<arch>
Add the architecture specified by "<arch>" to the list.
* -<arch>
Remove the architecture specified by "<arch>" to the list if
present.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
| |
Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
| |
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
| |
Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
|
| |
Replace the "+all" architecture tokens in the test files with the
"+all_le" and "+all_be" tokens to represent all the little endian and
big endian architectures respectively.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
| |
Add support for MIPS 32-bit (O32 ABI) Little Endian
Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
| |
Add support for valgrind suppressions files to the test tools. As part
of this patch include a fix for valgrind 3.9.0 and glibc 2.19.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
| |
Evidently the return value for a killed process can differ between
architectures/ABIs due to differences in the SIGSYS value.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
| |
Reported-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
| |
We don't really need to run valgrind multiple times for each test case,
just once should be enough.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
| |
With this patch the test harness returns 0 if there were no errors or
failures detected, positive values if a error or failure was detected.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|
|
|
|
|
|
|
|
| |
Some of the tools are quite handy and would likely be useful for
developers incorporating libseccomp into their applications so let's
go ahead and namespace the tools in preparation for installing them.
Signed-off-by: Paul Moore <pmoore@redhat.com>
|