I: strace --seccomp-bpf is not compatible with -b execve

Dmitry V. Levin ldv at altlinux.org
Sat Oct 5 16:04:41 UTC 2019


Hi,

There is one case I missed during seccomp-bpf review: for the same reason
why --seccomp-bpf implies -f there is no way to implement -b execve when
--seccomp-bpf is enabled.  This combination of options is silently broken
now:

$ /bin/pwd |wc -l
1
$ strace -o /dev/null -f -b execve -e '!fchdir' sh -c '/bin/pwd' |wc -l
1
$ strace -o /dev/null -f --seccomp-bpf -b execve -e '!fchdir' sh -c
'/bin/pwd' |wc -l
0

We have to either disallow this combination of options with an error
message saying that -b and --seccomp-bpf are mutually exclusive,
or disable seccomp-bpf when -b option is enabled, with a warning
saying that --seccomp-bpf is not enabled because of -b execve.


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20191005/0b8957eb/attachment.bin>


More information about the Strace-devel mailing list