Subject: | Problems with Octet string values |
Hi,
i've got that problem with D-Link switch'es. OID - SNMPv2-SMI::mib-
2.17.7.1.3.1.1.3.1 (.iso.org.dod.internet.mgmt.mib-
2.dot1dBridge.qBridgeMIB.qBridgeMIBObjects.dot1qStatic.dot1qStaticUnica
stTable)
Labb
uname -a
FreeBSD unix.server 4.11-STABLE FreeBSD 4.11-STABLE #3: Thu Nov 3
12:05:50 EET 2005 /usr/obj/usr/src/sys/GENERIC i386
------------------------------------------------------------------
## Version of the Net::SNMP module
our $VERSION = v5.2.0;
------------------------------------------------------------------
perl -V
Summary of my perl5 (revision 5 version 8 subversion 6) configuration:
Platform:
osname=freebsd, osvers=4.11-stable, archname=i386-freebsd-thread-
multi-64int
uname='freebsd aps.elekta.lt 4.11-stable freebsd 4.11-stable #1:
fri mar 4 11:53:35 eet 2005 root@aps.elekta.lt:usrobjusrsrcsysgeneric
i386 '
config_args='-sde -Dprefix=/usr/local -
Darchlib=/usr/local/lib/perl5/5.8.6/mach -
Dprivlib=/usr/local/lib/perl5/5.8.6 -
Dman3dir=/usr/local/lib/perl5/5.8.6/perl/man/man3 -
Dman1dir=/usr/local/man/man1 -
Dsitearch=/usr/local/lib/perl5/site_perl/5.8.6/mach -
Dsitelib=/usr/local/lib/perl5/site_perl/5.8.6 -
Dscriptdir=/usr/local/bin -
Dsiteman3dir=/usr/local/lib/perl5/5.8.6/man/man3 -
Dsiteman1dir=/usr/local/man/man1 -Ui_malloc -Ui_iconv -
Uinstallusrbinperl -Dcc=cc -Doptimize=-O -pipe -Duseshrplib -
Dccflags=-DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.6/BSDPAN" -Ud_dosuid -
Di_gdbm -Dusethreads=y -Dusemymalloc=n -Duse64bitint'
hint=recommended, useposix=true, d_sigaction=define
usethreads=define use5005threads=undef useithreads=define
usemultiplicity=define
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=define use64bitall=undef uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='cc', ccflags ='-
DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.6/BSDPAN" -D_THREAD_SAFE -
DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe -
I/usr/local/include',
optimize='-O -pipe ',
cppflags='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.8.6/BSDPAN" -
D_THREAD_SAFE -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-
aliasing -pipe -I/usr/local/include'
ccversion='', gccversion='2.95.4 20020320 [FreeBSD]',
gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype='long long', ivsize=8, nvtype='double', nvsize=8,
Off_t='off_t', lseeksize=8
alignbytes=4, prototype=define
Linker and Libraries:
ld='cc', ldflags ='-pthread -Wl,-E -L/usr/local/lib'
libpth=/usr/lib /usr/local/lib
libs=-lgdbm -lm -lcrypt -lutil
perllibs=-lm -lcrypt -lutil
libc=, so=so, useshrplib=true, libperl=libperl.so
gnulibc_version=''
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' -Wl,-
R/usr/local/lib/perl5/5.8.6/mach/CORE'
cccdlflags='-DPIC -fPIC', lddlflags='-shared -L/usr/local/lib'
Characteristics of this binary (from libperl):
Compile-time options: MULTIPLICITY USE_ITHREADS USE_64_BIT_INT
USE_LARGE_FILES PERL_IMPLICIT_CONTEXT
Locally applied patches:
SUIDPERLIO0 - fix PERLIO_DEBUG local root exploit (CAN-2005-
0155)
SUIDPERLIO1 - fix PERLIO_DEBUG buffer overflow (CAN-2005-0156)
Built under freebsd
Compiled at Mar 7 2005 13:39:05
@INC:
/usr/local/lib/perl5/site_perl/5.8.6/mach
/usr/local/lib/perl5/site_perl/5.8.6
/usr/local/lib/perl5/site_perl
/usr/local/lib/perl5/5.8.6/BSDPAN
/usr/local/lib/perl5/5.8.6/mach
/usr/local/lib/perl5/5.8.6
------------------------------------------------------------------
from tcpdump:
tcpdump: listening on em0
15:49:33.375488 unix.server.2694 > dlink.switch.snmp: C=Private
GetRequest(26) system.sysUpTime.0
15:49:33.376877 dlink.switch.snmp > unix.server.2694: C=Private
GetResponse(31) system.sysUpTime.0=1283974
15:49:33.386173 unix.server.2694 > dlink.switch.snmp: C=Private
GetRequest(38) 17.7.1.3.1.1.3.1.0.13.97.30.126.13.0
15:49:33.389128 dlink.switch.snmp > unix.server.2694: C=Private
GetResponse(44) 17.7.1.3.1.1.3.1.0.13.97.30.126.13.0=00_20_00_00
------------------------------------------------------------------
from Net::SNMP debugger:
perl upgrade.pl
debug: [448] Net::SNMP::Dispatcher::_event_insert(): created new head
and tail [ARRAY(0x8084eac)]
debug: [593] Net::SNMP::Dispatcher::_event_handle(): event [ARRAY
(0x8084eac)], poll delay = 0.000000
debug: [646] Net::SNMP::Message::send(): transport address
dlink.switch:161
debug: [1896] Net::SNMP::Message::_buffer_dump(): 55 bytes
[0000] 30 35 02 01 01 04 08 65 6C 65 6B 74 61 43 46 A0
05.....Private.
[0016] 26 02 02 16 3E 02 01 00 02 01 00 30 1A 30 18 06
&...>......0.0..
[0032] 14 2B 06 01 02 01 11 07 01 03 01 01 03 01 00
0D .+..............
[0048] 61 1E 7E 0D 00 05 00 a.~....
debug: [202] Net::SNMP::Dispatcher::register(): adding descriptor [5]
debug: [471] Net::SNMP::Dispatcher::_event_insert(): modified tail
[ARRAY(0x8084c9c)]
debug: [542] Net::SNMP::Dispatcher::_event_delete(): deleted [ARRAY
(0x8084eac)], defined new head [ARRAY(0x8084c9c)]
debug: [593] Net::SNMP::Dispatcher::_event_handle(): event [ARRAY
(0x8084c9c)], poll delay = 1.999861
debug: [645] Net::SNMP::Dispatcher::_event_select(): descriptor [5]
ready for read
debug: [670] Net::SNMP::Message::recv(): transport address
dlink.switch:161
debug: [1896] Net::SNMP::Message::_buffer_dump(): 65 bytes
[0000] 30 82 00 3D 02 01 01 04 08 65 6C 65 6B 74 61 43
0..=.....elektaC
[0016] 46 A2 82 00 2C 02 02 16 3E 02 01 00 02 01 00 30
F...,...>......0
[0032] 82 00 1E 30 1C 06 14 2B 06 01 02 01 11 07 01
03 ...0...+........
[0048] 01 01 03 01 00 0D 61 1E 7E 0D 00 04 04 00 20
00 ......a.~..... .
[0064] 00 .
debug: [953] Net::SNMP::PDU::_process_var_bind_list(): {
1.3.6.1.2.1.17.7.1.3.1.1.3.1.0.13.97.30.126.13.0 => OCTET STRING: }
debug: [524] Net::SNMP::Dispatcher::_event_delete(): deleted [ARRAY
(0x8084c9c)], list is now empty
debug: [241] Net::SNMP::Dispatcher::deregister(): removing descriptor
[5]
1.3.6.1.2.1.17.7.1.3.1.1.3.1.0.13.97.30.126.13.0 =>