Debian Bug report logs - #186208
the calculated broadcast address is wrong when subnetting

version graph

Package: net-tools; Maintainer for net-tools is net-tools Team <team+net-tools@tracker.debian.org>; Source for net-tools is src:net-tools (PTS, buildd, popcon).

Reported by: Arndt Schoenewald <arndt@lin02384n012.mc.schoenewald.de>

Date: Tue, 25 Mar 2003 09:48:03 UTC

Severity: normal

Merged with 87784, 90410, 122792, 145004

Found in versions 1.59-1, 1.60-4

Fixed in version net-tools/1.60-17

Done: Martín Ferrari <tincho@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Anthony Towns <ajt@debian.org>, ifupdown@packages.qa.debian.org:
Bug#186208; Package ifupdown. (full text, mbox, link).


Acknowledgement sent to Arndt Schoenewald <arndt@lin02384n012.mc.schoenewald.de>:
New Bug report received and forwarded. Copy sent to Anthony Towns <ajt@debian.org>, ifupdown@packages.qa.debian.org. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Arndt Schoenewald <arndt@lin02384n012.mc.schoenewald.de>
To: submit@bugs.debian.org
Subject: the calculated broadcast address is wrong when subnetting
Date: Tue, 25 Mar 2003 10:44:31 +0100
Package: ifupdown
Version: 0.6.4-4.4

The interfaces(5) man page indicates that the "broadcast" parameter is
optional for static interface configurations, but if it is not given,
a wrong value is calculated when subnetting is used.

Example:
    iface eth2 inet static
	address 10.0.0.42
	netmask 255.255.255.240

When eth2 is brought up (kernel 2.4.21pre5, net-tools 1.60-4), its
configuration looks like this:

    eth2  Link encap:Ethernet  HWaddr 00:E0:03:08:46:6D  
          inet addr:10.0.0.42  Bcast:10.255.255.255  Mask:255.255.255.240
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100 
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

i.e. the broadcast address is 10.255.255.255 but should be 10.0.0.47.

As you know, the formula for calculating the broadcast address is

    (address & netmask) | !netmask

You could argue that the problem is with ifconfig (ifconfig sets the
wrong broadcast address if none is specified), but then again why doesn't
ifup call it with a valid broadcast address? (And if you argue that way,
why do you require that the netmask be given? ifconfig does not require
this parameter.) I don't think that, on Debian, people should have to
know about the peculiarities of ifconfig since the published mechanism
for defining network interfaces is the ifupdown system. And giving an
address together with a netmask is nowadays the common way.

If you still think this should stay as it is, at least add a note to
interfaces(5) that the broadcast parameter is needed, too.

Thank you very much,
Arndt

-- 
Arndt Schönewald <arndt@lin02384n012.mc.schoenewald.de>, Software Developer
Quelltext AG (http://www.quelltext-ag.de), Dortmund, Germany



Bug reassigned from package `ifupdown' to `net-tools'. Request was from Anthony Towns <aj@azure.humbug.org.au> to control@bugs.debian.org. (full text, mbox, link).


Bug reassigned from package `net-tools' to `net-tools'. Request was from Anthony Towns <aj@azure.humbug.org.au> to control@bugs.debian.org. (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, net-tools Team <pkg-net-tools-maintainers@lists.alioth.debian.org>:
Bug#186208; Package net-tools. (Mon, 16 Mar 2009 04:51:02 GMT) (full text, mbox, link).


Acknowledgement sent to Martín Ferrari <tincho@debian.org>:
Extra info received and forwarded to list. Copy sent to net-tools Team <pkg-net-tools-maintainers@lists.alioth.debian.org>. (Mon, 16 Mar 2009 04:51:03 GMT) (full text, mbox, link).


Message #14 received at 186208@bugs.debian.org (full text, mbox, reply):

From: Martín Ferrari <tincho@debian.org>
To: 186208@bugs.debian.org
Subject: Closing old bug
Date: Mon, 16 Mar 2009 01:49:26 -0300
Package: net-tools
Version: 1.60-17

Following #87784, #122792 and #145004 (boy, this one had many
duplicates), I'm closing this bug because it's not reproducible even on
etch systems, I can reproduce it on sarge, though.

On Sarge:

# ifconfig dummy0 128.42.162.116 netmask 255.255.255.0
# ifconfig dummy0 | head -n2
dummy0    Link encap:Ethernet  HWaddr C2:C5:EF:F4:92:1A  
          inet addr:128.42.162.116  Bcast:128.42.255.255
Mask:255.255.255.0
# dpkg -s net-tools | grep ^Version:
Version: 1.60-10

On Etch and newer systems:

# ifconfig dummy0 128.42.162.116 netmask 255.255.255.0
# ifconfig dummy0 | head -n2
dummy0    Link encap:Ethernet  HWaddr 3A:B1:38:29:F1:FE  
          inet addr:128.42.162.116  Bcast:128.42.162.255
Mask:255.255.255.0
# dpkg -s net-tools | grep ^Version:
Version: 1.60-17






Reply sent to Martín Ferrari <tincho@debian.org>:
You have taken responsibility. (Mon, 16 Mar 2009 05:00:02 GMT) (full text, mbox, link).


Notification sent to Arndt Schoenewald <arndt@lin02384n012.mc.schoenewald.de>:
Bug acknowledged by developer. (Mon, 16 Mar 2009 05:00:02 GMT) (full text, mbox, link).


Message #19 received at 186208-done@bugs.debian.org (full text, mbox, reply):

From: Martín Ferrari <tincho@debian.org>
To: 186208-done@bugs.debian.org
Subject: Fwd: Bug#186208: Closing old bug
Date: Mon, 16 Mar 2009 01:57:37 -0300
Package: net-tools
Version: 1.60-17

Following #87784, #122792 and #145004 (boy, this one had many
duplicates), I'm closing this bug because it's not reproducible even on
etch systems, I can reproduce it on sarge, though.

On Sarge:

# ifconfig dummy0 128.42.162.116 netmask 255.255.255.0
# ifconfig dummy0 | head -n2
dummy0    Link encap:Ethernet  HWaddr C2:C5:EF:F4:92:1A
         inet addr:128.42.162.116  Bcast:128.42.255.255
Mask:255.255.255.0
# dpkg -s net-tools | grep ^Version:
Version: 1.60-10

On Etch and newer systems:

# ifconfig dummy0 128.42.162.116 netmask 255.255.255.0
# ifconfig dummy0 | head -n2
dummy0    Link encap:Ethernet  HWaddr 3A:B1:38:29:F1:FE
         inet addr:128.42.162.116  Bcast:128.42.162.255
Mask:255.255.255.0
# dpkg -s net-tools | grep ^Version:
Version: 1.60-17








-- 
Martín Ferrari




Merged 87784 90410 122792 145004 186208. Request was from Martín Ferrari <tincho@debian.org> to control@bugs.debian.org. (Mon, 16 Mar 2009 05:03:03 GMT) (full text, mbox, link).


Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Mon, 13 Apr 2009 07:27:01 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Jul 3 01:56:04 2024; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.