Eric Andersen f96675bc50 James Petterson writes:
I've found a possible bug in libbb/interface.c, in function
if_readlist_proc(). This function calls get_name(), and passes
as an argument 'name', a buffer of 16 bytes (IFNAMSIZ).  The
function get_name(), however, may use more than 16 bytes,
when it is searching for aliases. Even if you don't have an
alias interface, you can run into trouble if the interface
has received more than 99999999 bytes, in which case the
space between the interface name and the rx stats
disappears, as in the /proc/net/dev example below:
 wan0.200:264573315  462080    ...
In this case get_name() correctly identifies the interface name
as "wan0.200", but to do that it uses 18 bytes of the 'name'
buffer, which could lead to an unpredictable error.

A simple solution would be to increase the size of the buffer:
2003-07-28 06:37:04 +00:00
..
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-05-26 14:07:50 +00:00
2003-05-26 14:07:50 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-04-21 10:26:39 +00:00
2003-03-19 09:13:01 +00:00
2003-06-20 09:01:58 +00:00
2003-07-28 06:37:04 +00:00
2003-05-26 14:07:50 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-04-16 23:02:35 +00:00
2003-07-03 10:07:04 +00:00
2002-12-14 01:58:59 +00:00
2003-05-26 14:07:50 +00:00
2003-07-03 10:07:04 +00:00
2003-05-26 14:07:50 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-07-22 08:56:55 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-05-26 14:07:50 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00
2003-03-19 09:13:01 +00:00

Please see the LICENSE file for copyright information (GPLv2)
    
libbb is BusyBox's utility library.  All of this stuff used to be stuffed into
a single file named utility.c.  When I split utility.c to create libbb, some of
the very oldest stuff ended up without their original copyright and licensing
information (which is now lost in the mists of time).  If you see something
that you wrote that is mis-attributed, do let me know so we can fix that up.

	Erik Andersen 
	<andersen@codepoet.org>