On Sat, 2005-06-11 at 16:12, Emmanuel Doguet wrote:
> Robert Story wrote:
> > You can try using the snmpd.conf proxy token to do this. Otherwise, try
> > registering the existing handler with your custom OID.
> >
> How it's possible to register existing handler?
>
> In the 'netsnmp_create_handler_registration' function, I can only put my
> OID... not another? :/
You can only have one OID in a 'netsnmp_create_handler_registration'
call, yes. But it's perfectly possible to have two or more such
registrations, that all reference the same handler routine:
reginfo = netsnmp_create_handler_registration("originalVersion",
some_handler, oid1, OID_LENGTH(oid1),
HANDLER_CAN_RONLY),
netsnmp_register_handler( reginfo );
reginfo = netsnmp_create_handler_registration("customVersion",
some_handler, oid2, OID_LENGTH(oid2),
HANDLER_CAN_RONLY),
netsnmp_register_handler( reginfo );
The same handler routine ("some_handler") will then process requests
for oid1 (the original version) and oid2 (the custom version).
Dave
-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games. How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders