[prev in list] [next in list] [prev in thread] [next in thread]
List: net-snmp-bugs
Subject: [ net-snmp-Bugs-1534378 ] representation of IPv4 and IPv6 addresses
From: "SourceForge.net" <noreply () sourceforge ! net>
Date: 2007-03-19 2:20:05
Message-ID: 200703190220.l2J2K5br029728 () sc8-sf-db2-new-b ! sourceforge ! net
[Download RAW message or body]
Bugs item #1534378, was opened at 2006-08-04 01:51
Message generated for change (Comment added) made by sf-robot
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112694&aid=1534378&group_id=12694
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: agent
Group: linux
>Status: Closed
Resolution: Fixed
Priority: 5
Private: No
Submitted By: Radek (radekrat)
Assigned to: Robert Story (rstory)
Summary: representation of IPv4 and IPv6 addresses and port numbers
Initial Comment:
This is clone of Red Hat bug
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=200255
IPv6 representation is buggy, basically byteorder problems
# LC_ALL=C netstat -nltp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign
Address
State PID/Program name
tcp 0 0 127.0.0.1:20389
0.0.0.0:*
LISTEN 3854/ssh
tcp 0 0 0.0.0.0:902
0.0.0.0:*
LISTEN 1557/xinetd
tcp 0 0 0.0.0.0:199
0.0.0.0:*
LISTEN 24982/snmpd
tcp 0 0 0.0.0.0:43340
0.0.0.0:*
LISTEN -
tcp 0 0 0.0.0.0:111
0.0.0.0:*
LISTEN 1388/portmap
tcp 0 0 0.0.0.0:6000
0.0.0.0:*
LISTEN 1936/X
tcp 0 0 0.0.0.0:53106
0.0.0.0:*
LISTEN 1406/rpc.statd
tcp 0 0 127.0.0.1:631
0.0.0.0:*
LISTEN 1826/cupsd
tcp 0 0 0.0.0.0:25
0.0.0.0:*
LISTEN 1708/master
tcp 0 0 127.0.0.1:20636
0.0.0.0:*
LISTEN 3854/ssh
tcp 0 0 ::1:20389 :::*
LISTEN 3854/ssh
tcp 0 0 :::6000 :::*
LISTEN 1936/X
tcp 0 0 :::22 :::*
LISTEN 1548/sshd
tcp 0 0 ::1:20636 :::*
LISTEN 3854/ssh
Related entries in SNMP:
$ snmpwalk -v 2c -c public localhost|grep
^TCP-MIB::tcpListenerProcess
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".6400 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".19625 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".28416 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".28695 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".29391 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".34307 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."0.0.0.0".50944 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."1.0.0.127".30466 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."1.0.0.127".40016 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv4."1.0.0.127".42319 =
Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv6."00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00".5632
= Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv6."00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00".28695
= Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv6."00:00:00:00:00:00:00:00:00:00:00:00:01:00:00:00".40016
= Gauge32: 0
TCP-MIB::tcpListenerProcess.ipv6."00:00:00:00:00:00:00:00:00:00:00:00:01:00:00:00".42319
= Gauge32: 0
There are at least 3 problems:
1) byte order problem in port representation:
5632 = 0x1600 -> 0x0016 = 22
2) address representation problem IPv6
Is:
"00:00:00:00:00:00:00:00:00:00:00:00:01:00:00:00"
should:
"00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:01"
3) address representation problem IPv4
Is: "1.0.0.127"
Should: "127.0.0.1"
BTW: for UDP, the port is ok, but the address is broken in
udpEndpointProcess.ipv4 while correct in
udpLocalAddress. Can't currently check
udpEndpointProcess.ipv6
$ snmpwalk -v 2c -c public localhost|grep ^UDP-MIB
UDP-MIB::udpLocalAddress.0.0.0.0.111 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.123 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.161 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.631 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.734 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.1194 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.32768 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.32769 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.32770 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.0.0.0.0.32771 = IpAddress: 0.0.0.0
UDP-MIB::udpLocalAddress.127.0.0.1.123 = IpAddress:
127.0.0.1
UDP-MIB::udpLocalPort.0.0.0.0.111 = INTEGER: 111
UDP-MIB::udpLocalPort.0.0.0.0.123 = INTEGER: 123
UDP-MIB::udpLocalPort.0.0.0.0.161 = INTEGER: 161
UDP-MIB::udpLocalPort.0.0.0.0.631 = INTEGER: 631
UDP-MIB::udpLocalPort.0.0.0.0.734 = INTEGER: 734
UDP-MIB::udpLocalPort.0.0.0.0.1194 = INTEGER: 1194
UDP-MIB::udpLocalPort.0.0.0.0.32768 = INTEGER: 32768
UDP-MIB::udpLocalPort.0.0.0.0.32769 = INTEGER: 32769
UDP-MIB::udpLocalPort.0.0.0.0.32770 = INTEGER: 32770
UDP-MIB::udpLocalPort.0.0.0.0.32771 = INTEGER: 32771
UDP-MIB::udpLocalPort.127.0.0.1.123 = INTEGER: 123
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".111.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".123.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".161.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".631.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".734.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".1194.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".32768.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".32769.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".32770.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."0.0.0.0".32771.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv4."1.0.0.127".123.ipv4."".0.0
= Gauge32: 0
UDP-MIB::udpEndpointProcess.ipv6."00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00".123.ipv6."".0.0
= Gauge32: 0
----------------------------------------------------------------------
>Comment By: SourceForge Robot (sf-robot)
Date: 2007-03-18 19:20
Message:
Logged In: YES
user_id=1312539
Originator: NO
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 180 days (the time period specified by
the administrator of this Tracker).
----------------------------------------------------------------------
Comment By: Thomas Anders (tanders)
Date: 2006-09-19 05:27
Message:
Logged In: YES
user_id=848638
I think Robert has applied fixes to all affected branches.
----------------------------------------------------------------------
Comment By: Robert Story (rstory)
Date: 2006-09-01 10:22
Message:
Logged In: YES
user_id=76148
proposed patch was pretty close for tcp, but had some
broken-ness for udp. It also didn't take endianness into
account, and would have broken ppc systems.
Please test my alternative patch, heavily based on the
original, and let me know if it works. Tested on 32 bit x86
and ppc, so 64bit testing on both would be helpful.
----------------------------------------------------------------------
Comment By: Radek (radekrat)
Date: 2006-08-29 06:23
Message:
Logged In: YES
user_id=1122867
proposed patch
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112694&aid=1534378&group_id=12694
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Net-snmp-bugs mailing list
Net-snmp-bugs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-bugs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic