Go to the source code of this file.
Functions | |
| void | init_agent_read_config (const char *) |
| void | update_config (void) |
| void | snmpd_register_config_handler (const char *, void(*parser)(const char *, char *), void(*releaser)(void), const char *) |
| void | snmpd_unregister_config_handler (const char *) |
| void | snmpd_store_config (const char *) |
|
|
Definition at line 169 of file agent_read_config.c. Referenced by init_agent().
00170 {
00171 if ( app != NULL )
00172 ds_set_string(DS_LIBRARY_ID, DS_LIB_APPTYPE, app);
00173
00174 register_app_config_handler("authtrapenable",
00175 snmpd_parse_config_authtrap, NULL,
00176 "1 | 2\t\t(1 = enable, 2 = disable)");
00177
00178 if ( ds_get_boolean(DS_APPLICATION_ID, DS_AGENT_ROLE) == MASTER_AGENT ) {
00179 register_app_config_handler("trapsink",
00180 snmpd_parse_config_trapsink, snmpd_free_trapsinks,
00181 "host [community] [port]");
00182 register_app_config_handler("trap2sink",
00183 snmpd_parse_config_trap2sink, NULL,
00184 "host [community] [port]");
00185 register_app_config_handler("informsink",
00186 snmpd_parse_config_informsink, NULL,
00187 "host [community] [port]");
00188 register_app_config_handler("trapsess",
00189 snmpd_parse_config_trapsess, NULL,
00190 "[snmpcmdargs] host");
00191 }
00192 register_app_config_handler("trapcommunity",
00193 snmpd_parse_config_trapcommunity,
00194 snmpd_free_trapcommunity,
00195 "community-string");
00196 #ifdef HAVE_UNISTD_H
00197 register_app_config_handler("agentuser",
00198 snmpd_set_agent_user, NULL,
00199 "userid");
00200 register_app_config_handler("agentgroup",
00201 snmpd_set_agent_group, NULL,
00202 "groupid");
00203 #endif
00204 register_app_config_handler("agentaddress",
00205 snmpd_set_agent_address, NULL,
00206 "SNMP bind address");
00207 register_app_config_handler("table",
00208 config_parse_table_set, NULL, "tableoid");
00209 register_app_config_handler("add_row",
00210 config_parse_add_row, NULL, "indexes... values...");
00211
00212 #include "mib_module_dot_conf.h"
00213 #ifdef TESTING
00214 print_config_handlers();
00215 #endif
00216 }
|
|
||||||||||||||||||||
|
Definition at line 226 of file agent_read_config.c. 00230 {
00231 DEBUGMSGTL(("snmpd_register_app_config_handler",
00232 "registering .conf token for \"%s\"\n", token));
00233 register_app_config_handler(token, parser, releaser, help);
00234 }
|
|
|
Definition at line 245 of file agent_read_config.c. 00246 {
00247 read_app_config_store(line);
00248 }
|
|
|
Definition at line 237 of file agent_read_config.c. 00238 {
00239 unregister_app_config_handler(token);
00240 }
|
|
|
Definition at line 218 of file agent_read_config.c. 00219 {
00220 free_config();
00221 read_configs();
00222 }
|
1.2.11 written by Dimitri van Heesch,
© 1997-2001
[an error occurred while processing this directive]
[an error occurred while processing this directive]
Last modified: Tuesday, 23-Dec-2025 17:22:04 UTC
For questions regarding web content and site functionality, please write to the net-snmp-users mail list.