BUG in SNMPv1 Traps

Graeme McKerrell (graemem@pdd.3com.com)
Mon, 01 Jul 1996 07:39:19 +0100

Hi
I noticed earlier today that scotty2.1.0 is incorrect in the way that
it sends generic SNMPv1 traps. I checked the same thing with scotty2.0.1 and
found that it too was wrong but in a different way.

SCOTTY-2.0.1
********************************************************************************
Trap sent from scotty using 'snmp1 trap coldStart ""'
--------------------------------------------------------------------------------
snmp1 configuration:
====================
-community public -address 127.0.0.1 -port 162 -timeout 5 -retries 3
--------------------------------------------------------------------------------
send 43 bytes [127.0.0.1:162]:
30 28 SEQUENCE OF (40 bytes)
02 01 00 INTEGER (0)
04 06 70 75 62 6c 69 63 community "public" OCTET_STRING
a4 1b Application[4]
06 07 2b 06 01 04 01 8d 25 enterprise RUBBISH OID iso.6.1.4.1.141.37
40 04 a1 47 46 7a SRC_IP 161.71.70.122 Application[0]
02 01 00 generic 0 INTEGER (6)
02 01 00 specific 0 INTEGER (0)
43 02 10 04 timeTicks 0d 0:00:16.04 Application[3]
30 00 (no-varBinds) SEQUENCE OF (0 bytes)
********************************************************************************
The enterprise OID is rubbish!! but the generic and specific values are
correct.

SCOTTY-2.1.0
********************************************************************************
Trap sent from scotty using 'snmp1 trap coldStart ""'
--------------------------------------------------------------------------------
snmp1 configuration:
====================
-community generic -address 127.0.0.1 -port 162 -version SNMPv1
-timeout 5 -retries 3 -window 10 -delay 0
--------------------------------------------------------------------------------
send 43 bytes [127.0.0.1:162]:
30 29 SEQUENCE OF (41 bytes)
02 01 00 INTEGER (0)
04 07 67 65 6e 65 72 69 63 community "generic" OCTET_STRING
a4 1b Application[4]
06 06 2b 06 01 02 01 0b enterprise snmp OID iso.6.1.2.1.11
40 04 a1 47 46 7a SRC_IP 161.71.70.122 Application[0]
02 01 06 generic 6 INTEGER (6)
02 01 00 specific 0 INTEGER (0)
43 03 07 c5 d8 timeTicks 0d 1:24:54.00 Application[3]
30 00 (no-varBinds) SEQUENCE OF (0 bytes)
********************************************************************************
The error is in specifying generic=6 and specific=0
for a generic SNMPv1 trap the generic integer should be set to the required
trap number.
generic
=======
0 coldStart
1 warmStart
2 linkDown
3 linkUp
4 authenticationFailure
5 egpNeighborLoss
6 enterprise - use the value of 'specific'

The trap which is being generated translates as
"An enterprise specific trap of ID 0, where the enterprise is 'snmp'"
instead of
"Generic trap 0"

Yours
Graeme
_______________________________________________________
/ ___ | \
| ,' ` | """ |
| | ;--, .~~~, .~~~, .~~,~~. .~~~, | O O |
| | ``; | | | |---' | ! | |---' | ` ^ ' |
| `.__,' .!. `._.'. `._.' `. .' `._.' | (\_/) |
| | \_/ |
| graemem@pdd.3com.com | |
| | |
\_______________________________________________|________/