Package: iputils-arping
Version: 3:20100418-1
Severity: important
Tags: patch


There's a logic error in the function that parses the interface's 
broadcast address, causing it not to fill the broadcast address array 
correctly.

ie.

sendto(3, 
"\0\1\10\0\6\4\0\1\0\24\244\4\337\t\300\250\nv\377\24\377\4\377\t\300\250\n\1", 
28, 0, {sa_family=AF_PACKET, proto=0x806, if4, pkttype=PACKET_LOOPBACK, 
addr(6)={1, ff14ff04ff09}, 20) = 28

instead of

sendto(3, 
"\0\1\10\0\6\4\0\1\0\24\244\4\337\t\300\250\nv\377\377\377\377\377\377\300\250\n\1",
 28, 0, {sa_family=AF_PACKET, proto=0x806, if4, pkttype=0x65 /* ? */, 
addr(6)={1, ffffffffffff}, 20) = 28



-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (99, 
'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.34 (PREEMPT)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages iputils-arping depends on:
ii  libc6                         2.11.1-3   Embedded GNU C Library: Shared lib
ii  libsysfs2                     2.1.0-6    interface library to sysfs

iputils-arping recommends no packages.

iputils-arping suggests no packages.

-- no debconf information
diff -ur iputils-20100418//arping.c iputils-fixed//arping.c
--- iputils-20100418//arping.c	2010-06-12 02:40:40.000000000 +0100
+++ iputils-fixed//arping.c	2010-06-12 02:39:39.004009428 +0100
@@ -340,8 +340,8 @@
 		exit(2);
 	}
 
-	for (p = ba, ch = 0; p < ba + balen; p++, ch += 3)
-		*p++ = strtoul(brdcast->value + ch * 3, NULL, 16);
+	for (p = ba, ch = 0; p < ba + balen; p++, ch += 3) 
+		*p = strtoul(brdcast->value + ch, NULL, 16);
 
 	return;
 }

Reply via email to