diff options
author | Subhendu Ghosh <sghosh@users.sourceforge.net> | 2005-05-25 03:23:19 +0000 |
---|---|---|
committer | Subhendu Ghosh <sghosh@users.sourceforge.net> | 2005-05-25 03:23:19 +0000 |
commit | 1c13d632b4a3b4cc0f11ba4cad6de0c3f799a26c (patch) | |
tree | d4c21eb1e14c49732948be49932993afc01c9dfc /plugins | |
parent | 4e19425ce697ce17257b0db904a656e3c8557911 (diff) | |
download | monitoring-plugins-1c13d632b4a3b4cc0f11ba4cad6de0c3f799a26c.tar.gz |
v2c support - 1155754
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1178 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/check_snmp.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/check_snmp.c b/plugins/check_snmp.c index d66d834e..5d65113f 100644 --- a/plugins/check_snmp.c +++ b/plugins/check_snmp.c | |||
@@ -659,6 +659,9 @@ validate_arguments () | |||
659 | asprintf(&proto, DEFAULT_PROTOCOL); | 659 | asprintf(&proto, DEFAULT_PROTOCOL); |
660 | asprintf(&authpriv, "%s%s", "-c ", community); | 660 | asprintf(&authpriv, "%s%s", "-c ", community); |
661 | } | 661 | } |
662 | else if ( strcmp (proto, "2c") == 0 ) { /* snmpv2c args */ | ||
663 | asprintf(&authpriv, "%s%s", "-c ", community); | ||
664 | } | ||
662 | else if ( strcmp (proto, "3") == 0 ) { /* snmpv3 args */ | 665 | else if ( strcmp (proto, "3") == 0 ) { /* snmpv3 args */ |
663 | asprintf(&proto, "%s", "3"); | 666 | asprintf(&proto, "%s", "3"); |
664 | 667 | ||
@@ -872,7 +875,7 @@ Check status of remote machines and obtain sustem information via SNMP\n\n")); | |||
872 | 875 | ||
873 | /* SNMP and Authentication Protocol */ | 876 | /* SNMP and Authentication Protocol */ |
874 | printf (_("\ | 877 | printf (_("\ |
875 | -P, --protocol=[1|3]\n\ | 878 | -P, --protocol=[1|2c|3]\n\ |
876 | SNMP protocol version\n\ | 879 | SNMP protocol version\n\ |
877 | -L, --seclevel=[noAuthNoPriv|authNoPriv|authPriv]\n\ | 880 | -L, --seclevel=[noAuthNoPriv|authNoPriv|authPriv]\n\ |
878 | SNMPv3 securityLevel\n\ | 881 | SNMPv3 securityLevel\n\ |