Package: bandwidthd / 2.0.1+cvs20090917-7

Metadata

Package Version Patches format
bandwidthd 2.0.1+cvs20090917-7 3.0 (quilt)

Patch series

view the series file
Patch File delta Description
0001 Disable installation of bandwidthd.conf from orig so.patch | (download)

Makefile.in | 2 1 + 1 - 0 !
1 file changed, 1 insertion(+), 1 deletion(-)

 disable installation of bandwidthd.conf from orig source


0002 fix version in configure script.patch | (download)

configure.in | 4 2 + 2 - 0 !
1 file changed, 2 insertions(+), 2 deletions(-)

 fix version in configure script


0003 Add configure option for pgsql support.patch | (download)

configure.in | 36 32 + 4 - 0 !
1 file changed, 32 insertions(+), 4 deletions(-)

 add configure option for pgsql support

Add configure option --enable-pgsql to manually be able to select
instead of automagically choosing at build-time, to be able to build
both the static- and postgresql-version of bandwidthd

0004 Include filename in syntax error logging.patch | (download)

conf.y | 4 2 + 2 - 0 !
1 file changed, 2 insertions(+), 2 deletions(-)

 include filename in syntax error logging

Say which file the syntax error is in, to make logged error message clear.

0005 Add missing MAIL table header to generated static ht.patch | (download)

graph.c | 4 2 + 2 - 0 !
1 file changed, 2 insertions(+), 2 deletions(-)

 add missing "mail" table header to generated static html.


0006 Add missing comma to fix syntax in created CDF files.patch | (download)

bandwidthd.c | 2 1 + 1 - 0 !
1 file changed, 1 insertion(+), 1 deletion(-)

 add missing comma to fix syntax in created cdf files.

I've been using bandwidthd for a while, but since upgrading to lucid I          noticed my parsing started acting up, so I investigated. Eventually
discovered that bandwidthd's CDF writing has been broken since a
certain commit last year:

http://bandwidthd.cvs.sourceforge.net/viewvc/bandwidthd/bandwidthd/bandwidthd.c?r1=1.52&r2=1.53

You can see there's two fprintf statements there, but after that
commit there is no comma between the last value of the first fprintf,
and the first value of the second fprintf. It's even easier to spot if
you look at an actual line in a CDF file since this, where you get a
field like "01329001" which is a concatenation of "0" and "1329001".
The fix for this is of course trivial, you just need to add a comma to
the end of the first fprintf on line 827:

0007 Fix recover CDF option.patch | (download)

bandwidthd.c | 4 2 + 2 - 0 !
1 file changed, 2 insertions(+), 2 deletions(-)

 fix recover cdf option

Upstream (sourceforge) Tracker id 2018613 (See Bug link)
New upstream bug id 39.

Bug: http://sourceforge.net/p/bandwidthd/bugs/39/
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=660810
0008 Fix subnet reporting in syslog message.patch | (download)

bandwidthd.c | 5 4 + 1 - 0 !
1 file changed, 4 insertions(+), 1 deletion(-)

 fix subnet reporting in syslog message

With the following entries in etc/bandwidthd.conf, syslog shows:

Feb 24 10:35:13 debian netmon: Monitoring subnet 255.0.0.0 with netmask 255.0.0.0
Feb 24 10:35:13 debian netmon: Monitoring subnet 255.255.0.0 with netmask 255.255.0.0
Feb 24 10:35:13 debian netmon: Monitoring subnet 255.240.0.0 with netmask 255.240.0.0

It should show:

Feb 24 10:46:53 debian netmon: Monitoring subnet 10.0.0.0 with netmask 255.0.0.0
Feb 24 10:46:53 debian netmon: Monitoring subnet 192.168.0.0 with netmask 255.255.0.0
Feb 24 10:46:53 debian netmon: Monitoring subnet 172.16.0.0 with netmask 255.240.0.0

Cause:
Bandwidthd.c calls inet_ntoa twice in a parameter list. inet_ntoa has static character buffer: second call overwrites first.

0009 Make HTML output valid and prevent sql injection in .patch | (download)

phphtdocs/details.php | 72 45 + 27 - 0 !
phphtdocs/failures.php | 17 7 + 10 - 0 !
phphtdocs/footer.php | 9 6 + 3 - 0 !
phphtdocs/graph.php | 32 21 + 11 - 0 !
phphtdocs/header.php | 11 10 + 1 - 0 !
phphtdocs/include.php | 4 2 + 2 - 0 !
phphtdocs/location_statistics.php | 17 8 + 9 - 0 !
phphtdocs/sensors.php | 180 108 + 72 - 0 !
phphtdocs/signal_level.php | 12 4 + 8 - 0 !
phphtdocs/uptime.php | 10 3 + 7 - 0 !
10 files changed, 214 insertions(+), 150 deletions(-)

 make html output valid and prevent sql injection in php code.


0010 Add proper script header and use for loop since echo.patch | (download)

phphtdocs/bd_pgsql_purge.sh | 6 4 + 2 - 0 !
1 file changed, 4 insertions(+), 2 deletions(-)

 add proper script header and use for loop, since echo -e is bashism.


0011 Fetch database credentials from external file.patch | (download)

phphtdocs/config.conf | 7 4 + 3 - 0 !
1 file changed, 4 insertions(+), 3 deletions(-)

 fetch database credentials from external file

Modify php configuration to fetch postgresql auth params from
dbconfig-common generated file.