It is documented in snmp.conf(5) that setting clientaddr is supposed
to be used as trap source address, but it doesn't work. The issue is
that the configuration handler for this value is in snmplib which is not
used in snmpd.

This patch against 5.5 adds the necessary configuration setup.
---
 agent/agent_read_config.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

--- a/agent/agent_read_config.c 2009-12-22 17:23:24.025946449 -0800
+++ b/agent/agent_read_config.c 2010-01-13 19:34:08.970312839 -0800
@@ -270,6 +270,8 @@ init_agent_read_config(const char *app)
     netsnmp_ds_register_config(ASN_INTEGER, app, "maxGetbulkResponses",
                                NETSNMP_DS_APPLICATION_ID,
                                NETSNMP_DS_AGENT_MAX_GETBULKRESPONSES);
+    netsnmp_ds_register_config(ASN_OCTET_STR, app, "clientaddr",
+                              NETSNMP_DS_LIBRARY_ID, 
NETSNMP_DS_LIB_CLIENT_ADDR);
     netsnmp_init_handler_conf();
 
 #include "agent_module_dot_conf.h"

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to