6

After running,

$ ls -l /bin/ping
-rwsr-xr-x 1 root root 34740 Nov  5  2012 /bin/ping

I wonder, why doesn't Ubuntu use capabilities (i.e. raw sockets) rather than setuid?

  • ¡Attention! In Ubuntu 20.04 there's no cap_net_raw capability yet but bit suid neither!!?? I don't know how ping can be run flawessly if it has rwxr-xr-x permissions and no capabiliy (getcap shows nothing). I can't understand!! – Osqui Oct 23 at 20:14
  • Well, I've found the answer myself. It's here: unix.stackexchange.com/questions/592911/… – Osqui Oct 23 at 20:22
1

It is considered a bug if a package has overly permissive capabilities, so these cases should be reported. However, they might have already fixed it according to https://bugs.launchpad.net/ubuntu/+source/iputils/+bug/534341

| improve this answer | |
  • Since Ubuntu 16.04 uses setuid, how could I use the C# Ping class constructor to avoid the TypeInitializer for 'System.Net.NetworkInformaton.Ping threw an exception error? Thank you. – Frank Jul 24 '16 at 6:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.