getcap prints `cap_dac_override=eip` instead of `cap_dac_override+eip` on CentOS8.6

77 Views Asked by At

On CentOS Linux release 8.2.2004 (Core), after

setcap 'cap_dac_override=eip' foo.sh

the output for getcap foo.sh is:

foo.sh = cap_dac_override+eip

However on Red Hat Enterprise Linux release 8.6 (Ootpa) the output is:

/root/foo.sh cap_dac_override=eip

On CentOS8.2 the libcap.x86_64 version is 2.26-5.el8, while on CentOS8.6 the libcap.x86_64 version is 2.48-2.el8.

I couldn't find an answer on setcap/getcap's man page, this strange behavior has troubled me for days, does anyone have a clue?

0

There are 0 best solutions below