-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fails when run as suid root #34
Comments
(Debian maintainer here.) Thanks, a patch would be very welcome! |
tfheen
added a commit
to tfheen/liboping
that referenced
this issue
Mar 20, 2018
This allows this to run as non-root again, without this, oping will have dropped privileges before trying to ping, which then fails to open the necessary raw sockets. Fixes: octo#34
|
bob-beck
pushed a commit
to openbsd/ports
that referenced
this issue
Apr 28, 2018
Backport a fix for octo/liboping#34 ok danj@
Oliviers-OSS
pushed a commit
to Oliviers-OSS/liboping
that referenced
this issue
Mar 3, 2019
This allows this to run as non-root again, without this, oping will have dropped privileges before trying to ping, which then fails to open the necessary raw sockets. Fixes: octo#34 Patch from tfheen@a88c51f?diff=split
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a variant over https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=864184.
In Debian, oping is installed suid root. In older versions, in
liboping.c
, doingping_host_add
would also grab a raw socket. In the current version, that is only added whenping_send
is called, which is after when oping and noping have dropped their privileges, leading toping_send failed: Operation not permitted
errors.I'm happy to provide a patch if that's useful, but as there are a few ways of solving this, some guidance would be useful. (Just creating the socket in the
add_host
function is probably the easiest, from a quick glance.)The text was updated successfully, but these errors were encountered: