This reverts commit
badb2474ca8bd6427255cf0a9886cdca49a5c3b7.
The new iptables 1.8.12 release is broken on docker, pinpointed to the
getauxval() change that apparently can be nonzero in presence of LSMs.
That makes getauxval() useless for the purpose of detecting a setcap
binary. As nftables contains a change just like iptables, it is safe to
assume nftables is broken as well.
So revert this.
Bugzilla: https://bugzilla.netfilter.org/show_bug.cgi?id=1830
Signed-off-by: Florian Westphal <fw@strlen.de>
#include <getopt.h>
#include <fcntl.h>
#include <sys/types.h>
-#include <sys/auxv.h>
#include <nftables/libnftables.h>
#include <utils.h>
char *filename = NULL;
unsigned int len;
- /* nftables cannot be used with setuid/setcap in a safe way. */
- if (getuid() != geteuid() || getauxval(AT_SECURE))
+ /* nftables cannot be used with setuid in a safe way. */
+ if (getuid() != geteuid())
_exit(111);
if (!nft_options_check(argc, argv))