Hi, Yes, we don't need to process request with OID (sub-id count more than 128).
RFC 3416 says: SNMP limits OBJECT IDENTIFIER values to a maximum of 128 sub-identifiers, where each sub-identifier has a maximum value of 2**32-1. Any PDU with an OID having More than 128 sub-identifiers is an illegal PDU, and causes an ASN.1 Parse error which is counted by RFC 3418's snmpInASNParseErrs. In each of the cases in RFC 1157 (on page 18) where an ASN.1 parse error is detected, the message is discarded. In each of the places in RFC 3412 where snmpInASNParseErrs is incremented, the message is discarded. Can I add this check to "asn_parse_objid()" of asnl.c of snmplib/ directory? Regards, Saif --- Robert Story <[EMAIL PROTECTED]> wrote: > On Tue, 9 Aug 2005 06:44:24 +0100 (BST) saifulla > wrote: > SMA> As per the SNMP standard, the MAX OID length > should > SMA> not be > 128 bytes. > SMA> > SMA> We have found that SNMP agents(Commercial, open > SMA> software) take care of this differently. > SMA> > SMA> Question is : What is the correct behaviour: > SMA> > SMA> 1. Does agent must Return Error(ASN Parse > Error) for > SMA> any GET/SET/NEXT request with OID > 128? > > My reading of the specs is that an ObjectName with > more than 128 > subidentifiers is not valid. Thus a parse error is > the correct, and the packet > should be dropped. > > Any tool/library that sends such a packet is broken. > > -- > NOTE: messages sent directly to me, instead of the > lists, will be deleted > unless they are requests for paid consulting > services. > > Robert Story; NET-SNMP Junkie > Support: <http://www.net-snmp.org/> > <irc://irc.freenode.net/#net-snmp> > Archive: > <http://sourceforge.net/mailarchive/forum.php?forum=net-snmp-coders> > > You are lost in a twisty maze of little standards, > all different. > ___________________________________________________________ How much free photo storage do you get? Store your holiday snaps for FREE with Yahoo! Photos http://uk.photos.yahoo.com ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf _______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
