Re: enum registration
"Nikos Balkanas" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <000301c96b75$5c727380$02b2a8c0@tardis> |
Hi, net-snmp automatically does type checking according to the MIB. I.e. it will reject strings if the mib says integer. Is it for certain that it doesn't constraint enums (through some strange MIB setting or other configuration)? Thanx, Nikos ----- Original Message ----- From: "Wes Hardaker" <[email protected]> To: "Nikos Balkanas" <[email protected]> Cc: <[email protected]> Sent: Wednesday, December 31, 2008 7:11 PM Subject: Re: enum registration >>>>>> On Sun, 28 Dec 2008 13:47:47 +0200, "Nikos Balkanas" >>>>>> <[email protected]> said: > > NB> I am registering an enum scalar, but I don't know how to restrict > NB> snmpset just to the enum values: > > You'll need to implement a subhandler and pass that into your > registration function instead of the NULL. And then in that, check if > you're processing a SET and force an error if it's out of bounds. > -- > Wes Hardaker > Sparta, Inc. ------------------------------------------------------------------------------ _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users