Re: Need help to "drop the response" for a request

Magnus Fromreide <[email protected]>
Newsgroups gmane.network.net-snmp.devel
Message-ID <[email protected]>
On Fri, Sep 18, 2020 at 04:39:21PM +0530, Sanjay Kumar wrote:
> Hi Net-SNMP team,
>                              Need help on below scenario:
> We are handling the Error condition for the SNMP request(get/set) packet
> with the below options in the *"subagent"*
> 
> netsnmp_request_set_error(request, SNMP_ERR_NOSUCHNAME);
> 
> netsnmp_request_set_error(request, SNMP_ERR_GENERR);
> 
> With this error handling *"snmpd"-the agent*, is responding to the
> client(SNMP get/set request command) with these errors in error-status (in
> response packet) with null values for the OID(OID-value pair).
> 
> We think this is expected and valid.
> 
> 
> But for some scenario, we want* "snmpd" -the agent* to drop the packet
> without responding.
> 
> Is there any options in the net-SNMP code we can use or
> 
> any error handling scenario which can be set to drop the response packet
> for a get/set request?

Do you want the get/set to be processed or do you want to drop the incoming
packet?

If the former then there is no support.

When it comes to the latter there is no way to do it from an agentx subagent.

It might be possible from the agent but you have to be a bit more specific
about the conditions than 'some scenario'.

/MF

> 
> Thanks a lot in Advance.
> 
> Sanjay


> _______________________________________________
> Net-snmp-coders mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.