[Nagiosplug-checkins] nagiosplug/plugins check_snmp.c,1.54,1.55
Subhendu Ghosh
sghosh at users.sourceforge.net
Tue May 24 20:25:17 CEST 2005
Update of /cvsroot/nagiosplug/nagiosplug/plugins
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25554
Modified Files:
check_snmp.c
Log Message:
v2c support - 1155754
Index: check_snmp.c
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_snmp.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- check_snmp.c 5 Apr 2005 21:26:56 -0000 1.54
+++ check_snmp.c 25 May 2005 03:23:19 -0000 1.55
@@ -659,6 +659,9 @@
asprintf(&proto, DEFAULT_PROTOCOL);
asprintf(&authpriv, "%s%s", "-c ", community);
}
+ else if ( strcmp (proto, "2c") == 0 ) { /* snmpv2c args */
+ asprintf(&authpriv, "%s%s", "-c ", community);
+ }
else if ( strcmp (proto, "3") == 0 ) { /* snmpv3 args */
asprintf(&proto, "%s", "3");
@@ -872,7 +875,7 @@
/* SNMP and Authentication Protocol */
printf (_("\
- -P, --protocol=[1|3]\n\
+ -P, --protocol=[1|2c|3]\n\
SNMP protocol version\n\
-L, --seclevel=[noAuthNoPriv|authNoPriv|authPriv]\n\
SNMPv3 securityLevel\n\
More information about the Commits
mailing list