[Toybox] Question about ping.

Рысь lynx at sibserver.ru
Mon Oct 13 17:35:12 PDT 2014



14 октября 2014 г. 2:50:47 KRAT, Rob Landley <rob at landley.net> пишет:
>On 10/13/14 01:04, Рысь wrote:
>>>> Will ping work when invoked by root or not in that case?
>>>
>>> The new way does not require ping to run as root.
>...
>>>
>>> The thing is, Linux added an API that lets you do the same thing
>>> without
>>> requiring root access to do so. Seems like an improvement,
>especially
>>> since toybox isn't always installed with the suid bit set. (So you
>have
>>> to run things _as_ root to use the stuff requiring root.)
>> 
>> So toybox ping will work regardless of kernel version, even 2.6.1x?
>
>If I include the old codepath that _does_ require root, which wouldn't
>be used on newer systems (which would use the newer codepath either
>way), then it would support old 2.6 kernels from 4 years ago, yes.
>
>Whether or not I should bother doing that is the question I'm asking.
>It
>would make the code bigger in order to support old kernels.
>
>There are two APIs. The question is, should I include _both_ APIs, or
>just the newer one (which was introduced in linux 3.0).

Then I think it worth implementing, at least as a configurable choice. I still have systems with 2.6.1x/2.6.2x kernels which I have no way to update. Ping is a type of tool which should not require special kernel to work IMO.

>
>Rob
>_______________________________________________
>Toybox mailing list
>Toybox at lists.landley.net
>http://lists.landley.net/listinfo.cgi/toybox-landley.net


 1413246912.0


More information about the Toybox mailing list