Den 02-07-2012 20:22, Bill Fenner skrev:

> A related question: isn't it safer to pretend to the compatibility
> functions that a given interface with ifIndex > 16 bits (or 15 bits)
> doesn't exist, rather than returning a potentially-aliased value
> (e.g., pretend I have two interfaces on my system: lo with ifIndex 1,
> and foo1 with ifIndex 65537.  The compatibility functions will see two
> interfaces, both with ifIndex = 1.)

That is actually how Wes originally described it:

> Patch #2 is a bit more complex and creates new integer based index API
> for retrieving indexes and then ensure that they're < 2^SHIFT.  If
> they're greater than that, they're dropped as invalid indexes and the
> data isn't reported (which is better than a crash).

I would also prefer that behaviour

> (On one of my test systems, I have 66 interfaces, with ifIndex values
> from 1 to 2162175.  Yes, lots of interfaces are getting deleted and
> recreated.)

Luckily the ifTable seems not to be affected, it is only the 
hrDeviceTable :-)

/Niels

-- 
Niels Baggesen -- @home -- Ã…rhus -- Denmark -- ni...@baggesen.net
The purpose of computing is insight, not numbers  --  R W Hamming

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to