~ubuntu-branches/ubuntu/trusty/net-snmp/trusty

« back to all changes in this revision

Viewing changes to acconfig.h

  • Committer: Bazaar Package Importer
  • Author(s): Steve Kowalik
  • Date: 2007-12-08 14:59:50 UTC
  • mfrom: (1.1.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20071208145950-u1tykhpw56nyzqik
Tags: 5.4.1~dfsg-4ubuntu1
* Merge from debian unstable.
* Remaining Ubuntu changes:
  - Remove stop links from rc0 and rc6
  - Munge Maintainer field as per spec.
* Ubuntu changes dropped:
  - Symlink common files between the packages, CDBS ought to handle that
    for us automatically.
* The latest Debian changes has dropped history from the changelog. Slot in
  the Ubuntu changes as best I can. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* 
 
2
 * net-snmp configuration header file
 
3
 */
1
4
/* Portions of this file are subject to the following copyright(s).  See
2
5
 * the Net-SNMP's COPYING file for more details and other copyrights
3
6
 * that may apply:
12
15
#ifndef NET_SNMP_CONFIG_H
13
16
#define NET_SNMP_CONFIG_H
14
17
 
15
 
/* config.h:  a general config file */
16
 
 
17
 
/* Default (SNMP) version number for the tools to use */
18
 
#define DEFAULT_SNMP_VERSION 3
19
 
 
20
 
/* don't change these values! */
21
 
#define SNMPV1      0xAAAA       /* readable by anyone */
22
 
#define SNMPV2ANY   0xA000       /* V2 Any type (includes NoAuth) */
23
 
#define SNMPV2AUTH  0x8000       /* V2 Authenticated requests only */
24
 
 
25
 
/* default list of mibs to load */
26
 
 
27
 
#define DEFAULT_MIBS "IP-MIB:IF-MIB:TCP-MIB:UDP-MIB:SNMPv2-MIB:RFC1213-MIB"
28
 
 
29
 
/* default location to look for mibs to load using the above tokens
30
 
   and/or those in the MIBS envrionment variable*/
31
 
#undef DEFAULT_MIBDIRS
32
 
 
33
 
/* default mib files to load, specified by path. */
34
 
#undef DEFAULT_MIBFILES
35
 
 
36
 
/* should we compile to use special opaque types: float, double,
37
 
   counter64, i64, ui64, union? */
38
 
#undef OPAQUE_SPECIAL_TYPES
39
 
 
40
 
/* comment the next line if you are compiling with libsnmp.h 
41
 
   and are not using the UC-Davis SNMP library. */
42
 
#define UCD_SNMP_LIBRARY 1
43
 
 
44
 
/* define if you want to compile support for both authentication and
45
 
   privacy support. */
46
 
#undef SCAPI_AUTHPRIV
47
 
 
48
 
/* define if you are using the MD5 code ...*/
49
 
#undef USE_INTERNAL_MD5
50
 
 
51
 
/* define if you are using the codeS11 library ...*/
52
 
#undef USE_PKCS
53
 
 
54
 
/* add in recent CMU library extensions (not complete) */
55
 
#undef CMU_COMPATIBLE
56
 
 
57
 
/* add in recent resource lock functions (not complete) */
58
 
#undef _REENTRANT
59
 
 
60
 
/* debugging stuff */
61
 
/* if defined, we optimize the code to exclude all debugging calls. */
62
 
#undef SNMP_NO_DEBUGGING
63
 
/* ignore the -D flag and always print debugging information */
64
 
#define SNMP_ALWAYS_DEBUG 0
65
 
 
66
 
/* reverse encoding BER packets is both faster and more efficient in space. */
67
 
#define USE_REVERSE_ASNENCODING       1
68
 
#define DEFAULT_ASNENCODING_DIRECTION 1 /* 1 = reverse, 0 = forwards */
69
 
 
70
 
/* PERSISTENT_DIRECTORY: If defined, the library is capabile of saving
71
 
   persisant information to this directory in the form of configuration
72
 
   lines: PERSISTENT_DIRECTORY/NAME.persistent.conf */
73
 
#define PERSISTENT_DIRECTORY "/var/snmp"
74
 
 
75
 
/* PERSISTENT_MASK: the umask permissions to set up persistent files with */
76
 
#define PERSISTENT_MASK 077
77
 
 
78
 
/* AGENT_DIRECTORY_MODE: the mode the agents should use to create
79
 
   directories with. Since the data stored here is probably sensitive, it
80
 
   probably should be read-only by root/administrator. */
81
 
#define AGENT_DIRECTORY_MODE 0700
82
 
 
83
 
/* MAX_PERSISTENT_BACKUPS:
84
 
 *   The maximum number of persistent backups the library will try to
85
 
 *   read from the persistent cache directory.  If an application fails to
86
 
 *   close down successfully more than this number of times, data will be lost.
 
18
 
 
19
/* ********* NETSNMP_MARK_BEGIN_AUTOCONF_DEFINITIONS ********* */
 
20
/*
 
21
 * put all autoconf-specific definitions below here
 
22
 *
87
23
 */
88
 
#define MAX_PERSISTENT_BACKUPS 10
89
 
 
90
 
@TOP@
91
 
 
92
 
/* define if you are embedding perl in the main agent */
93
 
#undef NETSNMP_EMBEDDED_PERL
94
 
 
95
 
/* define the system type include file here */
96
 
#define SYSTEM_INCLUDE_FILE <net-snmp/system/generic.h>
97
 
 
98
 
/* define the machine (cpu) type include file here */
99
 
#define MACHINE_INCLUDE_FILE <net-snmp/machine/generic.h>
100
 
 
101
 
/* define the UDP buffer defaults undefined means use the OS buffers
102
 
 * by default */
103
 
#undef DEFAULT_SERVER_SEND_BUF
104
 
#undef DEFAULT_SERVER_RECV_BUF
105
 
#undef DEFAULT_CLIENT_SEND_BUF
106
 
#undef DEFAULT_CLIENT_RECV_BUF
107
 
 
108
 
/* SNMPLIBDIR contains important files */
109
 
#undef SNMPLIBPATH
110
 
#undef SNMPSHAREPATH
111
 
#undef SNMPCONFPATH
112
 
#undef SNMPDLMODPATH
113
 
 
114
 
/* LOGFILE:  If defined it closes stdout/err/in and opens this in out/err's
115
 
   place.  (stdin is closed so that sh scripts won't wait for it) */
116
 
#undef LOGFILE
117
 
 
118
 
/* default system contact */
119
 
#undef SYS_CONTACT
120
 
 
121
 
/* system location */
122
 
#undef SYS_LOC
123
 
 
124
 
/* Use libwrap to handle allow/deny hosts? */
125
 
#undef USE_LIBWRAP
126
 
 
127
 
/* Use dmalloc to do malloc debugging? */
128
 
#undef HAVE_DMALLOC_H
129
 
 
130
 
/* location of UNIX kernel */
131
 
#define KERNEL_LOC "/vmunix"
132
 
 
133
 
/* location of mount table list */
134
 
#define ETC_MNTTAB "/etc/mnttab"
135
 
 
136
 
/* location of swap device (ok if not found) */
137
 
#undef DMEM_LOC
138
 
 
139
 
/* Command to generate ps output, the final column must be the process
140
 
   name withOUT arguments */
141
 
#define PSCMD "/bin/ps"
142
 
 
143
 
/* Where is the uname command */
144
 
#define UNAMEPROG "/bin/uname"
145
 
 
146
 
/* pattern for temporary file names */
147
 
#define NETSNMP_TEMP_FILE_PATTERN "/tmp/snmpdXXXXXX"
148
 
 
149
 
/* testing code sections. */
150
 
#undef SNMP_TESTING_CODE 
151
 
 
152
 
/* If you don't have root access don't exit upon kmem errors */
153
 
#undef NO_ROOT_ACCESS
154
 
 
155
 
/* If we don't want to use kmem. */
156
 
#undef NO_KMEM_USAGE
157
 
 
158
 
/* If you don't want the agent to report on variables it doesn't have data for */
159
 
#undef NO_DUMMY_VALUES
160
 
 
161
 
/* Define if statfs takes 2 args and the second argument has
162
 
   type struct fs_data. [Ultrix] */
163
 
#undef STAT_STATFS_FS_DATA
164
 
 
165
 
/* Define if the TCP timer constants in <netinet/tcp_timer.h>
166
 
   depend on the integer variable `hz'.  [FreeBSD 4.x] */
167
 
#undef TCPTV_NEEDS_HZ
168
 
 
169
 
@BOTTOM@
 
24
#ifndef NETSNMP_NO_AUTOCONF_DEFINITIONS
170
25
 
171
26
/* define if you have type int32_t */
172
27
#undef HAVE_INT32_T
192
47
/* define if you have type uintptr_t */
193
48
#undef HAVE_UINTPTR_T
194
49
 
 
50
/* got socklen_t? */
 
51
#undef HAVE_SOCKLEN_T
 
52
 
 
53
/* got in_addr_t? */
 
54
#undef HAVE_IN_ADDR_T
 
55
 
195
56
/* define if you have getdevs() */
196
57
#undef HAVE_GETDEVS
197
58
 
204
65
/* define if you have <sys/disklabel.h> */
205
66
#undef HAVE_SYS_DISKLABEL_H
206
67
 
 
68
/* define if your compiler (processor) defines __FUNCTION__ for you */
 
69
#undef HAVE_CPP_UNDERBAR_FUNCTION_DEFINED
 
70
 
 
71
/* on aix, if you have perfstat */
 
72
#undef HAVE_PERFSTAT
 
73
 
 
74
/* define if you have libdb, libnm or librpm, respectively */
 
75
#undef HAVE_LIBDB
 
76
#undef HAVE_LIBNM
 
77
#undef HAVE_LIBRPM
 
78
 
 
79
/* define if you have pkginfo */
 
80
#undef HAVE_PKGINFO
 
81
 
 
82
/* define if you have gethostbyname */
 
83
#undef HAVE_GETHOSTBYNAME
 
84
 
 
85
/* define if you have the perl_eval_pv() function */
 
86
#undef HAVE_PERL_EVAL_PV_LC
 
87
 
 
88
/* define if you have the Perl_eval_pv() function */
 
89
#undef HAVE_PERL_EVAL_PV_UC
 
90
 
 
91
/* printing system */
 
92
#undef HAVE_LPSTAT
 
93
#undef LPSTAT_PATH
 
94
#undef HAVE_PRINTCAP
 
95
/* Use dmalloc to do malloc debugging? */
 
96
#undef HAVE_DMALLOC_H
 
97
 
 
98
/* location of UNIX kernel */
 
99
#define KERNEL_LOC "/vmunix"
 
100
 
 
101
/* location of mount table list */
 
102
#define ETC_MNTTAB "/etc/mnttab"
 
103
 
 
104
/* location of swap device (ok if not found) */
 
105
#undef DMEM_LOC
 
106
 
 
107
/* Command to generate ps output, the final column must be the process
 
108
   name withOUT arguments */
 
109
#define PSCMD "/bin/ps"
 
110
 
 
111
/* Where is the uname command */
 
112
#define UNAMEPROG "/bin/uname"
 
113
 
207
114
/* define if you are using linux and /proc/net/dev has the compressed
208
115
   field, which exists in linux kernels 2.2 and greater. */
209
116
#undef PROC_NET_DEV_HAS_COMPRESSED
226
133
/* Does struct sockaddr have a sa_family2 field? */
227
134
#undef STRUCT_SOCKADDR_HAS_SA_UNION_SA_GENERIC_SA_FAMILY2
228
135
 
 
136
/* Does struct sockaddr_storage have a ss_family field? */
 
137
#undef STRUCT_SOCKADDR_STORAGE_HAS_SS_FAMILY
 
138
 
 
139
/* Does struct sockaddr_storage have a __ss_family field? */
 
140
#undef STRUCT_SOCKADDR_STORAGE_HAS___SS_FAMILY
 
141
 
229
142
/* Does struct in6_addr have a s6_un.sa6_ladd field? */
230
143
#undef STRUCT_IN6_ADDR_HAS_S6_UN_SA6_LADDR
231
144
 
282
195
/* nlist.n_value */
283
196
#undef STRUCT_NLIST_HAS_N_VALUE
284
197
 
 
198
/* nlist64.n_value */
 
199
#undef STRUCT_NLIST64_HAS_N_VALUE
 
200
 
285
201
/* ipstat structure tests */
286
202
#undef STRUCT_IPSTAT_HAS_IPS_CANTFORWARD
287
203
#undef STRUCT_IPSTAT_HAS_IPS_CANTFRAG
313
229
#undef IFNET_NEEDS_KERNEL
314
230
 
315
231
/* sysctl works to get boottime, etc... */
316
 
#undef CAN_USE_SYSCTL
317
 
 
318
 
/* type check for in_addr_t */
319
 
#undef in_addr_t
 
232
#undef NETSNMP_CAN_USE_SYSCTL
320
233
 
321
234
/* define if SIOCGIFADDR exists in sys/ioctl.h */
322
235
#undef SYS_IOCTL_H_HAS_SIOCGIFADDR
323
236
 
324
 
/* define if your compiler (processor) defines __FUNCTION__ for you */
325
 
#undef HAVE_CPP_UNDERBAR_FUNCTION_DEFINED
 
237
/* Define if statfs takes 2 args and the second argument has
 
238
   type struct fs_data. [Ultrix] */
 
239
#undef STAT_STATFS_FS_DATA
 
240
 
 
241
/* Define if the TCP timer constants in <netinet/tcp_timer.h>
 
242
   depend on the integer variable `hz'.  [FreeBSD 4.x] */
 
243
#undef TCPTV_NEEDS_HZ
 
244
 
 
245
/* Not-to-be-compiled macros for use by configure only */
 
246
#define config_require(x)
 
247
#define config_exclude(x)
 
248
#define config_arch_require(x,y)
 
249
#define config_parse_dot_conf(w,x,y,z)
 
250
#define config_add_mib(x)
 
251
#define config_belongs_in(x)
 
252
#define config_error(x)
 
253
#define config_warning(x)
 
254
  
 
255
#if defined (WIN32) || defined (mingw32) || defined (cygwin)
 
256
#define ENV_SEPARATOR ";"
 
257
#define ENV_SEPARATOR_CHAR ';'
 
258
#else
 
259
#define ENV_SEPARATOR ":"
 
260
#define ENV_SEPARATOR_CHAR ':'
 
261
#endif
 
262
 
 
263
/* definitions added by configure on-the-fly */
 
264
@TOP@
 
265
@BOTTOM@
 
266
 
 
267
/* end of definitions added by configure on-the-fly */
 
268
 
 
269
#ifndef HAVE_STRCHR
 
270
#ifdef HAVE_INDEX
 
271
# define strchr index
 
272
# define strrchr rindex
 
273
#endif
 
274
#endif
 
275
 
 
276
#ifndef HAVE_INDEX
 
277
#ifdef HAVE_STRCHR
 
278
#ifdef mingw32
 
279
# define index(a,b) strchr(a,b)
 
280
# define rindex(a,b) strrchr(a,b)
 
281
#else
 
282
# define index strchr
 
283
# define rindex strrchr
 
284
#endif
 
285
#endif
 
286
#endif
 
287
 
 
288
#ifndef HAVE_MEMCPY
 
289
#ifdef HAVE_BCOPY
 
290
# define memcpy(d, s, n) bcopy ((s), (d), (n))
 
291
# define memmove(d, s, n) bcopy ((s), (d), (n))
 
292
# define memcmp bcmp
 
293
#endif
 
294
#endif
 
295
 
 
296
#ifndef HAVE_MEMMOVE
 
297
#ifdef HAVE_MEMCPY
 
298
# define memmove memcpy
 
299
#endif
 
300
#endif
 
301
 
 
302
#ifndef HAVE_BCOPY
 
303
#ifdef HAVE_MEMCPY
 
304
# define bcopy(s, d, n) memcpy ((d), (s), (n))
 
305
# define bzero(p,n) memset((p),(0),(n))
 
306
# define bcmp memcmp
 
307
#endif
 
308
#endif
 
309
 
 
310
/* If you have openssl 0.9.7 or above, you likely have AES support. */
 
311
#undef NETSNMP_USE_OPENSSL
 
312
#if defined(NETSNMP_USE_OPENSSL) && defined(HAVE_OPENSSL_AES_H) && defined(HAVE_AES_CFB128_ENCRYPT)
 
313
#define HAVE_AES 1
 
314
#endif
 
315
 
 
316
/* define random functions */
 
317
 
 
318
#ifndef HAVE_RANDOM
 
319
#ifdef HAVE_LRAND48
 
320
#define random lrand48
 
321
#define srandom(s) srand48(s)
 
322
#else
 
323
#ifdef HAVE_RAND
 
324
#define random rand
 
325
#define srandom(s) srand(s)
 
326
#endif
 
327
#endif
 
328
#endif
 
329
 
 
330
/* define signal if DNE */
 
331
 
 
332
#ifndef HAVE_SIGNAL
 
333
#ifdef HAVE_SIGSET
 
334
#define signal(a,b) sigset(a,b)
 
335
#endif
 
336
#endif
 
337
 
 
338
#if HAVE_DMALLOC_H
 
339
#define DMALLOC_FUNC_CHECK
 
340
#endif
 
341
 
 
342
#endif /* NETSNMP_NO_AUTOCONF_DEFINITIONS */
 
343
 
 
344
 
 
345
 
 
346
 
 
347
/* ********* NETSNMP_MARK_BEGIN_CLEAN_NAMESPACE ********* */
 
348
/* 
 
349
 * put all new net-snmp-specific definitions here
 
350
 *
 
351
 * all definitions MUST have a NETSNMP_ prefix
 
352
 *
 
353
 */
 
354
 
 
355
/* Default (SNMP) version number for the tools to use */
 
356
#define NETSNMP_DEFAULT_SNMP_VERSION 3
 
357
 
 
358
/* don't change these values! */
 
359
#define NETSNMP_SNMPV1      0xAAAA       /* readable by anyone */
 
360
#define NETSNMP_SNMPV2ANY   0xA000       /* V2 Any type (includes NoAuth) */
 
361
#define NETSNMP_SNMPV2AUTH  0x8000       /* V2 Authenticated requests only */
 
362
 
 
363
/* default list of mibs to load */
 
364
#define NETSNMP_DEFAULT_MIBS "IP-MIB:IF-MIB:TCP-MIB:UDP-MIB:SNMPv2-MIB:RFC1213-MIB"
 
365
 
 
366
/* default location to look for mibs to load using the above tokens
 
367
   and/or those in the MIBS envrionment variable*/
 
368
#undef NETSNMP_DEFAULT_MIBDIRS
 
369
 
 
370
/* default mib files to load, specified by path. */
 
371
#undef NETSNMP_DEFAULT_MIBFILES
 
372
 
 
373
/* should we compile to use special opaque types: float, double,
 
374
   counter64, i64, ui64, union? */
 
375
#undef NETSNMP_WITH_OPAQUE_SPECIAL_TYPES
 
376
 
 
377
/* define if you want to compile support for both authentication and
 
378
   privacy support. */
 
379
#undef NETSNMP_ENABLE_SCAPI_AUTHPRIV
 
380
 
 
381
/* define if you are using the MD5 code ...*/
 
382
#undef NETSNMP_USE_INTERNAL_MD5
 
383
 
 
384
/* define if you are using the codeS11 library ...*/
 
385
#undef NETSNMP_USE_PKCS11
 
386
 
 
387
/* debugging stuff */
 
388
/* if defined, we optimize the code to exclude all debugging calls. */
 
389
#undef NETSNMP_NO_DEBUGGING
 
390
/* ignore the -D flag and always print debugging information */
 
391
#define NETSNMP_ALWAYS_DEBUG 0
 
392
 
 
393
/* reverse encoding BER packets is both faster and more efficient in space. */
 
394
#define NETSNMP_USE_REVERSE_ASNENCODING       1
 
395
#define NETSNMP_DEFAULT_ASNENCODING_DIRECTION 1 /* 1 = reverse, 0 = forwards */
 
396
 
 
397
/* PERSISTENT_DIRECTORY: If defined, the library is capabile of saving
 
398
   persisant information to this directory in the form of configuration
 
399
   lines: PERSISTENT_DIRECTORY/NAME.persistent.conf */
 
400
#define NETSNMP_PERSISTENT_DIRECTORY "/var/snmp"
 
401
 
 
402
/* PERSISTENT_MASK: the umask permissions to set up persistent files with */
 
403
#define NETSNMP_PERSISTENT_MASK 077
 
404
 
 
405
/* AGENT_DIRECTORY_MODE: the mode the agents should use to create
 
406
   directories with. Since the data stored here is probably sensitive, it
 
407
   probably should be read-only by root/administrator. */
 
408
#define NETSNMP_AGENT_DIRECTORY_MODE 0700
 
409
 
 
410
/* MAX_PERSISTENT_BACKUPS:
 
411
 *   The maximum number of persistent backups the library will try to
 
412
 *   read from the persistent cache directory.  If an application fails to
 
413
 *   close down successfully more than this number of times, data will be lost.
 
414
 */
 
415
#define NETSNMP_MAX_PERSISTENT_BACKUPS 10
 
416
 
 
417
/* define the system type include file here */
 
418
#define NETSNMP_SYSTEM_INCLUDE_FILE <net-snmp/system/generic.h>
 
419
 
 
420
/* define the machine (cpu) type include file here */
 
421
#define NETSNMP_MACHINE_INCLUDE_FILE <net-snmp/machine/generic.h>
 
422
 
 
423
/* define the UDP buffer defaults undefined means use the OS buffers
 
424
 * by default */
 
425
#undef NETSNMP_DEFAULT_SERVER_SEND_BUF
 
426
#undef NETSNMP_DEFAULT_SERVER_RECV_BUF
 
427
#undef NETSNMP_DEFAULT_CLIENT_SEND_BUF
 
428
#undef NETSNMP_DEFAULT_CLIENT_RECV_BUF
 
429
 
 
430
/* net-snmp's major path names */
 
431
#undef SNMPLIBPATH
 
432
#undef SNMPSHAREPATH
 
433
#undef SNMPCONFPATH
 
434
#undef SNMPDLMODPATH
 
435
 
 
436
/* NETSNMP_LOGFILE:  If defined it closes stdout/err/in and opens this in 
 
437
   out/err's place.  (stdin is closed so that sh scripts won't wait for it) */
 
438
#undef NETSNMP_LOGFILE
 
439
 
 
440
/* default system contact */
 
441
#undef NETSNMP_SYS_CONTACT
 
442
 
 
443
/* system location */
 
444
#undef NETSNMP_SYS_LOC
 
445
 
 
446
/* Use libwrap to handle allow/deny hosts? */
 
447
#undef NETSNMP_USE_LIBWRAP
 
448
 
 
449
/* testing code sections. */
 
450
#undef NETSNMP_ENABLE_TESTING_CODE 
 
451
 
 
452
/* If you don't have root access don't exit upon kmem errors */
 
453
#undef NETSNMP_NO_ROOT_ACCESS
 
454
 
 
455
/* If we don't want to use kmem. */
 
456
#undef NETSNMP_NO_KMEM_USAGE
 
457
 
 
458
/* If you don't want the agent to report on variables it doesn't have data for */
 
459
#undef NETSNMP_NO_DUMMY_VALUES
 
460
 
326
461
 
327
462
/* Mib-2 tree Info */
328
463
/* These are the system information variables. */
329
464
 
330
 
#define VERS_DESC   "unknown"             /* overridden at run time */
331
 
#define SYS_NAME    "unknown"             /* overridden at run time */
 
465
#define NETSNMP_VERS_DESC   "unknown"             /* overridden at run time */
 
466
#define NETSNMP_SYS_NAME    "unknown"             /* overridden at run time */
332
467
 
333
468
/* comment out the second define to turn off functionality for any of
334
469
   these: (See README for details) */
335
470
 
336
471
/*   proc PROCESSNAME [MAX] [MIN] */
337
 
#define PROCMIBNUM 2
 
472
#define NETSNMP_PROCMIBNUM 2
338
473
 
339
474
/*   exec/shell NAME COMMAND      */
340
 
#define SHELLMIBNUM 8
 
475
#define NETSNMP_SHELLMIBNUM 8
341
476
 
342
477
/*   swap MIN                     */
343
 
#define MEMMIBNUM 4
 
478
#define NETSNMP_MEMMIBNUM 4
344
479
 
345
480
/*   disk DISK MINSIZE            */
346
 
#define DISKMIBNUM 9
 
481
#define NETSNMP_DISKMIBNUM 9
347
482
 
348
483
/*   load 1 5 15                  */
349
 
#define LOADAVEMIBNUM 10
 
484
#define NETSNMP_LOADAVEMIBNUM 10
350
485
 
351
486
/* which version are you using? This mibloc will tell you */
352
 
#define VERSIONMIBNUM 100
 
487
#define NETSNMP_VERSIONMIBNUM 100
353
488
 
354
489
/* Reports errors the agent runs into */
355
490
/* (typically its "can't fork, no mem" problems) */
356
 
#define ERRORMIBNUM 101
 
491
#define NETSNMP_ERRORMIBNUM 101
357
492
 
358
493
/* The sub id of EXTENSIBLEMIB returned to queries of
359
494
   .iso.org.dod.internet.mgmt.mib-2.system.sysObjectID.0 */
360
 
#define AGENTID 250
 
495
#define NETSNMP_AGENTID 250
361
496
 
362
497
/* This ID is returned after the AGENTID above.  IE, the resulting
363
498
   value returned by a query to sysObjectID is
364
499
   EXTENSIBLEMIB.AGENTID.???, where ??? is defined below by OSTYPE */
365
500
 
366
 
#define HPUX9ID 1
367
 
#define SUNOS4ID 2 
368
 
#define SOLARISID 3
369
 
#define OSFID 4
370
 
#define ULTRIXID 5
371
 
#define HPUX10ID 6
372
 
#define NETBSD1ID 7
373
 
#define FREEBSDID 8
374
 
#define IRIXID 9
375
 
#define LINUXID 10
376
 
#define BSDIID 11
377
 
#define OPENBSDID 12
378
 
#define WIN32ID 13
379
 
#define HPUX11ID 14
380
 
#define AIXID 15
381
 
#define MACOSXID 16
382
 
#define UNKNOWNID 255
 
501
#define NETSNMP_HPUX9ID 1
 
502
#define NETSNMP_SUNOS4ID 2 
 
503
#define NETSNMP_SOLARISID 3
 
504
#define NETSNMP_OSFID 4
 
505
#define NETSNMP_ULTRIXID 5
 
506
#define NETSNMP_HPUX10ID 6
 
507
#define NETSNMP_NETBSD1ID 7
 
508
#define NETSNMP_FREEBSDID 8
 
509
#define NETSNMP_IRIXID 9
 
510
#define NETSNMP_LINUXID 10
 
511
#define NETSNMP_BSDIID 11
 
512
#define NETSNMP_OPENBSDID 12
 
513
#define NETSNMP_WIN32ID 13
 
514
#define NETSNMP_HPUX11ID 14
 
515
#define NETSNMP_AIXID 15
 
516
#define NETSNMP_MACOSXID 16
 
517
#define NETSNMP_UNKNOWNID 255
383
518
 
384
519
#ifdef hpux9
385
 
#define OSTYPE HPUX9ID
 
520
#define NETSNMP_OSTYPE NETSNMP_HPUX9ID
386
521
#endif
387
522
#ifdef hpux10
388
 
#define OSTYPE HPUX10ID
 
523
#define NETSNMP_OSTYPE NETSNMP_HPUX10ID
389
524
#endif
390
525
#ifdef hpux11
391
 
#define OSTYPE HPUX11ID
 
526
#define NETSNMP_OSTYPE NETSNMP_HPUX11ID
392
527
#endif
393
528
#ifdef sunos4
394
 
#define OSTYPE SUNOS4ID
 
529
#define NETSNMP_OSTYPE NETSNMP_SUNOS4ID
395
530
#endif
396
531
#ifdef solaris2
397
 
#define OSTYPE SOLARISID
 
532
#define NETSNMP_OSTYPE NETSNMP_SOLARISID
398
533
#endif
399
534
#if defined(osf3) || defined(osf4) || defined(osf5)
400
 
#define OSTYPE OSFID
 
535
#define NETSNMP_OSTYPE NETSNMP_OSFID
401
536
#endif
402
537
#ifdef ultrix4
403
 
#define OSTYPE ULTRIXID
 
538
#define NETSNMP_OSTYPE NETSNMP_ULTRIXID
404
539
#endif
405
540
#if defined(netbsd1) || defined(netbsd2)
406
 
#define OSTYPE NETBSD1ID
 
541
#define NETSNMP_OSTYPE NETSNMP_NETBSD1ID
407
542
#endif
408
543
#if defined(__FreeBSD__)
409
 
#define OSTYPE FREEBSDID
 
544
#define NETSNMP_OSTYPE NETSNMP_FREEBSDID
410
545
#endif
411
546
#if defined(irix6) || defined(irix5)
412
 
#define OSTYPE IRIXID
 
547
#define NETSNMP_OSTYPE NETSNMP_IRIXID
413
548
#endif
414
549
#ifdef linux
415
 
#define OSTYPE LINUXID
 
550
#define NETSNMP_OSTYPE NETSNMP_LINUXID
416
551
#endif
417
552
#if defined(bsdi2) || defined(bsdi3) || defined(bsdi4)
418
 
#define OSTYPE BSDIID
 
553
#define NETSNMP_OSTYPE NETSNMP_BSDIID
419
554
#endif
420
 
#if defined(openbsd2) || defined(openbsd3)
421
 
#define OSTYPE OPENBSDID
 
555
#if defined(openbsd2) || defined(openbsd3) || defined(openbsd4)
 
556
#define NETSNMP_OSTYPE NETSNMP_OPENBSDID
422
557
#endif
423
558
#ifdef WIN32
424
 
#define OSTYPE WIN32ID
 
559
#define NETSNMP_OSTYPE NETSNMP_WIN32ID
425
560
#endif
426
561
#if defined(aix3) || defined(aix4) || defined(aix5)
427
 
#define OSTYPE AIXID
 
562
#define NETSNMP_OSTYPE NETSNMP_AIXID
428
563
#endif
429
 
#ifdef darwin8
430
 
#define OSTYPE MACOSXID
 
564
#if defined(darwin) && (darwin >= 8)
 
565
#define NETSNMP_OSTYPE NETSNMP_MACOSXID
431
566
#endif
432
567
/* unknown */
433
 
#ifndef OSTYPE
434
 
#define OSTYPE UNKNOWNID
 
568
#ifndef NETSNMP_OSTYPE
 
569
#define NETSNMP_OSTYPE NETSNMP_UNKNOWNID
435
570
#endif
436
571
 
437
572
/* The enterprise number has been assigned by the IANA group.   */
438
573
/* Optionally, this may point to the location in the tree your  */
439
574
/* company/organization has been allocated.                     */
440
575
/* The assigned enterprise number for the NET_SNMP MIB modules. */
441
 
#define ENTERPRISE_OID                  8072
442
 
#define ENTERPRISE_MIB                  1,3,6,1,4,1,8072
443
 
#define ENTERPRISE_DOT_MIB              1.3.6.1.4.1.8072
444
 
#define ENTERPRISE_DOT_MIB_LENGTH       7
 
576
#define NETSNMP_ENTERPRISE_OID                  8072
 
577
#define NETSNMP_ENTERPRISE_MIB                  1,3,6,1,4,1,8072
 
578
#define NETSNMP_ENTERPRISE_DOT_MIB              1.3.6.1.4.1.8072
 
579
#define NETSNMP_ENTERPRISE_DOT_MIB_LENGTH       7
445
580
 
446
581
/* The assigned enterprise number for sysObjectID. */
447
 
#define SYSTEM_MIB              1,3,6,1,4,1,8072,3,2,OSTYPE
448
 
#define SYSTEM_DOT_MIB          1.3.6.1.4.1.8072.3.2.OSTYPE
449
 
#define SYSTEM_DOT_MIB_LENGTH   10
 
582
#define NETSNMP_SYSTEM_MIB              1,3,6,1,4,1,8072,3,2,NETSNMP_OSTYPE
 
583
#define NETSNMP_SYSTEM_DOT_MIB          1.3.6.1.4.1.8072.3.2.NETSNMP_OSTYPE
 
584
#define NETSNMP_SYSTEM_DOT_MIB_LENGTH   10
450
585
 
451
586
/* The assigned enterprise number for notifications. */
452
 
#define NOTIFICATION_MIB                1,3,6,1,4,1,8072,4
453
 
#define NOTIFICATION_DOT_MIB            1.3.6.1.4.1.8072.4
454
 
#define NOTIFICATION_DOT_MIB_LENGTH     8
 
587
#define NETSNMP_NOTIFICATION_MIB                1,3,6,1,4,1,8072,4
 
588
#define NETSNMP_NOTIFICATION_DOT_MIB            1.3.6.1.4.1.8072.4
 
589
#define NETSNMP_NOTIFICATION_DOT_MIB_LENGTH     8
455
590
 
456
591
/* this is the location of the ucdavis mib tree.  It shouldn't be
457
592
   changed, as the places it is used are expected to be constant
458
593
   values or are directly tied to the UCD-SNMP-MIB. */
459
 
#define UCDAVIS_OID             2021
460
 
#define UCDAVIS_MIB             1,3,6,1,4,1,2021
461
 
#define UCDAVIS_DOT_MIB         1.3.6.1.4.1.2021
462
 
#define UCDAVIS_DOT_MIB_LENGTH  7
463
 
 
464
 
/* this is the location of the net-snmp mib tree.  It shouldn't be
465
 
   changed, as the places it is used are expected to be constant
466
 
   values or are directly tied to the UCD-SNMP-MIB. */
467
 
#define NETSNMP_OID             8072
468
 
#define NETSNMP_MIB             1,3,6,1,4,1,8072
469
 
#define NETSNMP_DOT_MIB         1.3.6.1.4.1.8072
470
 
#define NETSNMP_DOT_MIB_LENGTH  7
 
594
#define NETSNMP_UCDAVIS_OID             2021
 
595
#define NETSNMP_UCDAVIS_MIB             1,3,6,1,4,1,2021
 
596
#define NETSNMP_UCDAVIS_DOT_MIB         1.3.6.1.4.1.2021
 
597
#define NETSNMP_UCDAVIS_DOT_MIB_LENGTH  7
471
598
 
472
599
/* how long to wait (seconds) for error querys before reseting the error trap.*/
473
 
#define ERRORTIMELENGTH 600 
 
600
#define NETSNMP_ERRORTIMELENGTH 600 
474
601
 
475
602
/* Exec command to fix PROC problems */
476
603
/* %s will be replaced by the process name in error */
477
604
 
478
 
/* #define PROCFIXCMD "/usr/bin/perl /local/scripts/fixproc %s" */
 
605
/* #define NETSNMP_PROCFIXCMD "/usr/bin/perl /local/scripts/fixproc %s" */
479
606
 
480
607
/* Exec command to fix EXEC problems */
481
608
/* %s will be replaced by the exec/script name in error */
482
609
 
483
 
/* #define EXECFIXCMD "/usr/bin/perl /local/scripts/fixproc %s" */
 
610
/* #define NETSNMP_EXECFIXCMD "/usr/bin/perl /local/scripts/fixproc %s" */
484
611
 
485
612
/* Should exec output Cashing be used (speeds up things greatly), and
486
613
   if so, After how many seconds should the cache re-newed?  Note:
487
614
   Don't define CASHETIME to disable cashing completely */
488
615
 
489
 
#define EXCACHETIME 30
490
 
#define CACHEFILE ".snmp-exec-cache"
491
 
#define MAXCACHESIZE (200*80)   /* roughly 200 lines max */
 
616
#define NETSNMP_EXCACHETIME 30
 
617
#define NETSNMP_CACHEFILE ".snmp-exec-cache"
 
618
#define NETSNMP_MAXCACHESIZE (200*80)   /* roughly 200 lines max */
492
619
 
493
620
/* misc defaults */
494
621
 
495
622
/* default of 100 meg minimum if the minimum size is not specified in
496
623
   the config file */
497
 
#define DEFDISKMINIMUMSPACE 100000
498
 
 
499
 
#define DEFMAXLOADAVE 12.0      /* default maximum load average before error */
500
 
 
 
624
#define NETSNMP_DEFDISKMINIMUMSPACE 100000
 
625
 
 
626
/* default maximum load average before error */
 
627
#define NETSNMP_DEFMAXLOADAVE 12.0
 
628
 
 
629
/* max times to loop reading output from execs. */
501
630
/* Because of sleep(1)s, this will also be time to wait (in seconds) for exec
502
631
   to finish */
503
 
#define MAXREADCOUNT 100   /* max times to loop reading output from execs. */
 
632
#define NETSNMP_MAXREADCOUNT 100
504
633
 
 
634
/* Set if snmpgets should block and never timeout */
505
635
/* The original CMU code had this hardcoded as = 1 */
506
 
#define SNMPBLOCK 1       /* Set if snmpgets should block and never timeout */
 
636
#define NETSNMP_SNMPBLOCK 1
507
637
 
508
638
/* How long to wait before restarting the agent after a snmpset to
509
639
   EXTENSIBLEMIB.VERSIONMIBNUM.VERRESTARTAGENT.  This is
510
640
   necessary to finish the snmpset reply before restarting. */
511
 
#define RESTARTSLEEP 5
512
 
 
513
 
/* Number of community strings to store */
514
 
#define NUM_COMMUNITIES 5
 
641
#define NETSNMP_RESTARTSLEEP 5
515
642
 
516
643
/* UNdefine to allow specifying zero-length community string */
517
 
/* #define NO_ZEROLENGTH_COMMUNITY 1 */
 
644
/* #define NETSNMP_NO_ZEROLENGTH_COMMUNITY 1 */
518
645
 
519
 
/* #define EXIT_ON_BAD_KLREAD  */
520
646
/* define to exit the agent on a bad kernel read */
521
 
 
522
 
#define LASTFIELD -1      /* internal define */
 
647
/* #define NETSNMP_EXIT_ON_BAD_KLREAD  */
 
648
 
 
649
/* Number of community strings to store */
 
650
#define NETSNMP_NUM_COMMUNITIES 5
 
651
 
 
652
/* internal define */
 
653
#define NETSNMP_LASTFIELD -1
523
654
 
524
655
/* configure options specified */
525
 
#define CONFIGURE_OPTIONS ""
526
 
 
527
 
/* got socklen_t? */
528
 
#undef HAVE_SOCKLEN_T
529
 
 
530
 
/* got in_addr_t? */
531
 
#undef HAVE_IN_ADDR_T
532
 
 
533
 
/* got ssize_t? */
534
 
#undef HAVE_SSIZE_T
535
 
 
536
 
#ifndef HAVE_STRCHR
537
 
#ifdef HAVE_INDEX
538
 
# define strchr index
539
 
# define strrchr rindex
540
 
#endif
541
 
#endif
542
 
 
543
 
#ifndef HAVE_INDEX
544
 
#ifdef HAVE_STRCHR
545
 
#ifdef mingw32
546
 
# define index(a,b) strchr(a,b)
547
 
# define rindex(a,b) strrchr(a,b)
548
 
#else
549
 
# define index strchr
550
 
# define rindex strrchr
551
 
#endif
552
 
#endif
553
 
#endif
554
 
 
555
 
#ifndef HAVE_MEMCPY
556
 
#ifdef HAVE_BCOPY
557
 
# define memcpy(d, s, n) bcopy ((s), (d), (n))
558
 
# define memmove(d, s, n) bcopy ((s), (d), (n))
559
 
# define memcmp bcmp
560
 
#endif
561
 
#endif
562
 
 
563
 
#ifndef HAVE_MEMMOVE
564
 
#ifdef HAVE_MEMCPY
565
 
# define memmove memcpy
566
 
#endif
567
 
#endif
568
 
 
569
 
#ifndef HAVE_BCOPY
570
 
#ifdef HAVE_MEMCPY
571
 
# define bcopy(s, d, n) memcpy ((d), (s), (n))
572
 
# define bzero(p,n) memset((p),(0),(n))
573
 
# define bcmp memcmp
574
 
#endif
575
 
#endif
576
 
 
577
 
/* If you have openssl 0.9.7 or above, you likely have AES support. */
578
 
#undef USE_OPENSSL
579
 
#if defined(USE_OPENSSL) && defined(HAVE_OPENSSL_AES_H) && defined(HAVE_AES_CFB128_ENCRYPT)
580
 
#define HAVE_AES 1
581
 
#endif
582
 
 
583
 
/* define random functions */
584
 
 
585
 
#ifndef HAVE_RANDOM
586
 
#ifdef HAVE_LRAND48
587
 
#define random lrand48
588
 
#define srandom(s) srand48(s)
589
 
#else
590
 
#ifdef HAVE_RAND
591
 
#define random rand
592
 
#define srandom(s) srand(s)
593
 
#endif
594
 
#endif
595
 
#endif
596
 
 
597
 
/* define signal if DNE */
598
 
 
599
 
#ifndef HAVE_SIGNAL
600
 
#ifdef HAVE_SIGSET
601
 
#define signal(a,b) sigset(a,b)
602
 
#endif
603
 
#endif
604
 
 
605
 
/* define if you have librpm and libdb */
606
 
#undef HAVE_LIBDB
607
 
#undef HAVE_LIBRPM
608
 
 
609
 
/* define if you have pkginfo */
610
 
#undef HAVE_PKGINFO
611
 
 
612
 
/* define if you have gethostbyname */
613
 
#undef HAVE_GETHOSTBYNAME
614
 
 
615
 
/* define if you have getservbyname */
616
 
#undef HAVE_GETSERVBYNAME
617
 
 
618
 
/* printing system */
619
 
#undef HAVE_LPSTAT
620
 
#undef LPSTAT_PATH
621
 
#undef HAVE_PRINTCAP
 
656
#define NETSNMP_CONFIGURE_OPTIONS ""
622
657
 
623
658
/*  Pluggable transports.  */
624
659
 
625
660
/*  This is defined if support for the UDP/IP transport domain is
626
661
    available.   */
627
 
#undef SNMP_TRANSPORT_UDP_DOMAIN
 
662
#undef NETSNMP_TRANSPORT_UDP_DOMAIN
628
663
 
629
664
/*  This is defined if support for the "callback" transport domain is
630
665
    available.   */
631
 
#undef SNMP_TRANSPORT_CALLBACK_DOMAIN
 
666
#undef NETSNMP_TRANSPORT_CALLBACK_DOMAIN
632
667
 
633
668
/*  This is defined if support for the TCP/IP transport domain is
634
669
    available.  */
635
 
#undef SNMP_TRANSPORT_TCP_DOMAIN
 
670
#undef NETSNMP_TRANSPORT_TCP_DOMAIN
636
671
 
637
672
/*  This is defined if support for the Unix transport domain
638
673
    (a.k.a. "local IPC") is available.  */
639
 
#undef SNMP_TRANSPORT_UNIX_DOMAIN
 
674
#undef NETSNMP_TRANSPORT_UNIX_DOMAIN
640
675
 
641
676
/*  This is defined if support for the AAL5 PVC transport domain is
642
677
    available.  */
643
 
#undef SNMP_TRANSPORT_AAL5PVC_DOMAIN
 
678
#undef NETSNMP_TRANSPORT_AAL5PVC_DOMAIN
644
679
 
645
680
/*  This is defined if support for the IPX transport domain is
646
681
    available.  */
647
 
#undef SNMP_TRANSPORT_IPX_DOMAIN
 
682
#undef NETSNMP_TRANSPORT_IPX_DOMAIN
648
683
 
649
684
/*  This is defined if support for the UDP/IPv6 transport domain is
650
685
    available.  */
651
 
#undef SNMP_TRANSPORT_UDPIPV6_DOMAIN
 
686
#undef NETSNMP_TRANSPORT_UDPIPV6_DOMAIN
652
687
 
653
688
/*  This is defined if support for the TCP/IPv6 transport domain is
654
689
    available.  */
655
 
#undef SNMP_TRANSPORT_TCPIPV6_DOMAIN
 
690
#undef NETSNMP_TRANSPORT_TCPIPV6_DOMAIN
656
691
 
657
692
/*  This is defined if support for the UDP/IP transport domain is
658
693
    available.   */
659
 
#undef SNMP_TRANSPORT_TLS_DOMAIN
 
694
#undef NETSNMP_TRANSPORT_TLS_DOMAIN
660
695
 
661
696
/*  This is defined if support for stdin/out transport domain is available.   */
662
 
#undef SNMP_TRANSPORT_STD_DOMAIN
 
697
#undef NETSNMP_TRANSPORT_STD_DOMAIN
663
698
 
664
699
/* define this if the USM security module is available */
665
 
#undef SNMP_SECMOD_USM
 
700
#undef NETSNMP_SECMOD_USM
666
701
 
667
702
/* define this if the KSM (kerberos based snmp) security module is available */
668
 
#undef SNMP_SECMOD_KSM
 
703
#undef NETSNMP_SECMOD_KSM
669
704
 
670
705
/* define this if the local security module is available */
671
 
#undef SNMP_SECMOD_LOCALSM
672
 
 
673
 
/* define this if we're using the new MIT crypto API */
674
 
#undef MIT_NEW_CRYPTO
 
706
#undef NETSNMP_SECMOD_LOCALSM
675
707
 
676
708
/* define if you want to build with reentrant/threaded code (incomplete)*/
677
 
#undef NS_REENTRANT
 
709
#undef NETSNMP_REENTRANT
 
710
 
 
711
/* define if configured as a "mini-agent" */
 
712
#undef NETSNMP_MINI_AGENT
 
713
 
 
714
/* define if you are embedding perl in the main agent */
 
715
#undef NETSNMP_EMBEDDED_PERL
678
716
 
679
717
/* define if you want to build MFD module rewrites*/
680
718
#undef NETSNMP_ENABLE_MFD_REWRITES
681
719
 
682
 
/* on aix, if you have perfstat */
683
 
#undef HAVE_PERFSTAT
 
720
/* this is the location of the net-snmp mib tree.  It shouldn't be
 
721
   changed, as the places it is used are expected to be constant
 
722
   values or are directly tied to the UCD-SNMP-MIB. */
 
723
#define NETSNMP_OID             8072
 
724
#define NETSNMP_MIB             1,3,6,1,4,1,8072
 
725
#define NETSNMP_DOT_MIB         1.3.6.1.4.1.8072
 
726
#define NETSNMP_DOT_MIB_LENGTH  7
684
727
 
685
 
/* Not-to-be-compiled macros for use by configure only */
686
 
#define config_require(x)
687
 
#define config_exclude(x)
688
 
#define config_arch_require(x,y)
689
 
#define config_parse_dot_conf(w,x,y,z)
690
 
#define config_add_mib(x)
691
 
#define config_belongs_in(x)
692
 
  
693
 
#if defined (WIN32) || defined (mingw32) || defined (cygwin)
694
 
#define ENV_SEPARATOR ";"
695
 
#define ENV_SEPARATOR_CHAR ';'
696
 
#else
697
 
#define ENV_SEPARATOR ":"
698
 
#define ENV_SEPARATOR_CHAR ':'
699
 
#endif
 
728
/* pattern for temporary file names */
 
729
#define NETSNMP_TEMP_FILE_PATTERN "/tmp/snmpdXXXXXX"
700
730
 
701
731
/*
702
732
 * this must be before the system/machine includes, to allow them to
728
758
 *    static NETSNMP_INLINE function(int parm) { return parm -1; }
729
759
 *
730
760
 */
731
 
#undef NETSNMP_BROKEN_INLINE
732
761
#ifdef NETSNMP_BROKEN_INLINE
733
762
#   define NETSNMP_ENABLE_INLINE 0
734
763
#else
735
764
#   define NETSNMP_ENABLE_INLINE 1
736
765
#endif
737
766
 
738
 
#include SYSTEM_INCLUDE_FILE
739
 
#include MACHINE_INCLUDE_FILE
 
767
#include NETSNMP_SYSTEM_INCLUDE_FILE
 
768
#include NETSNMP_MACHINE_INCLUDE_FILE
740
769
 
741
770
#if NETSNMP_ENABLE_INLINE && !defined(NETSNMP_NO_INLINE)
742
771
#   define NETSNMP_USE_INLINE 1
755
784
#  define NETSNMP_IMPORT extern
756
785
#endif
757
786
 
758
 
#if defined(HAVE_NLIST) && defined(STRUCT_NLIST_HAS_N_VALUE) && !defined(DONT_USE_NLIST) && !defined(NO_KMEM_USAGE)
759
 
#define CAN_USE_NLIST
760
 
#endif
761
 
 
762
 
#if HAVE_DMALLOC_H
763
 
#define DMALLOC_FUNC_CHECK
764
 
#endif
765
 
 
766
 
#undef INET6
767
 
#undef LOCAL_SMUX
 
787
/* define if you want to enable IPv6 support */
 
788
#undef NETSNMP_ENABLE_IPV6
 
789
 
 
790
/* define if you want to restrict SMUX connections to localhost by default */
 
791
#undef NETSNMP_ENABLE_LOCAL_SMUX
768
792
 
769
793
/* define if agentx transport is to use domain sockets only */
770
 
#undef AGENTX_DOM_SOCK_ONLY
 
794
#undef NETSNMP_AGENTX_DOM_SOCK_ONLY
771
795
 
772
796
/* define if you do not want snmptrapd to register as an AgentX subagent */
773
 
#undef SNMPTRAPD_DISABLE_AGENTX
774
 
 
775
 
#undef HEIMDAL
 
797
#undef NETSNMP_SNMPTRAPD_DISABLE_AGENTX
 
798
 
 
799
/* define this if we're using the new MIT crypto API */
 
800
#undef NETSNMP_USE_KERBEROS_MIT
 
801
 
 
802
/* define this if you're using Heimdal Kerberos */
 
803
#undef NETSNMP_USE_KERBEROS_HEIMDAL
 
804
 
 
805
/* comment the next line if you are compiling with libsnmp.h 
 
806
   and are not using the UC-Davis SNMP library. */
 
807
#define UCD_SNMP_LIBRARY 1
 
808
 
 
809
/* add in recent CMU library extensions (not complete) */
 
810
#undef CMU_COMPATIBLE
 
811
 
 
812
/* final conclusion on nlist usage */
 
813
#if defined(HAVE_NLIST) && defined(STRUCT_NLIST_HAS_N_VALUE) && !defined(NETSNMP_DONT_USE_NLIST) && !defined(NETSNMP_NO_KMEM_USAGE)
 
814
#define NETSNMP_CAN_USE_NLIST
 
815
#endif
 
816
 
 
817
 
 
818
/* ********* NETSNMP_MARK_BEGIN_LEGACY_DEFINITIONS *********/
 
819
/* 
 
820
 * existing definitions prior to Net-SNMP 5.4
 
821
 *
 
822
 * do not add anything new here
 
823
 *
 
824
 */
 
825
 
 
826
#ifndef NETSNMP_NO_LEGACY_DEFINITIONS
 
827
 
 
828
#ifdef NETSNMP_DEFAULT_SNMP_VERSION
 
829
# define DEFAULT_SNMP_VERSION NETSNMP_DEFAULT_SNMP_VERSION
 
830
#endif
 
831
 
 
832
#ifdef NETSNMP_SNMPV1
 
833
# define SNMPV1 NETSNMP_SNMPV1
 
834
#endif
 
835
 
 
836
#ifdef NETSNMP_SNMPV2ANY
 
837
# define SNMPV2ANY NETSNMP_SNMPV2ANY
 
838
#endif
 
839
 
 
840
#ifdef NETSNMP_SNMPV2AUTH
 
841
# define SNMPV2AUTH NETSNMP_SNMPV2AUTH
 
842
#endif
 
843
 
 
844
#ifdef NETSNMP_DEFAULT_MIBS
 
845
# define DEFAULT_MIBS NETSNMP_DEFAULT_MIBS
 
846
#endif
 
847
 
 
848
#ifdef NETSNMP_DEFAULT_MIBDIRS
 
849
# define DEFAULT_MIBDIRS NETSNMP_DEFAULT_MIBDIRS
 
850
#endif
 
851
 
 
852
#ifdef NETSNMP_DEFAULT_MIBFILES
 
853
# define DEFAULT_MIBFILES NETSNMP_DEFAULT_MIBFILES
 
854
#endif
 
855
 
 
856
#ifdef NETSNMP_WITH_OPAQUE_SPECIAL_TYPES
 
857
# define OPAQUE_SPECIAL_TYPES NETSNMP_WITH_OPAQUE_SPECIAL_TYPES
 
858
#endif
 
859
 
 
860
#ifdef NETSNMP_ENABLE_SCAPI_AUTHPRIV
 
861
# define SCAPI_AUTHPRIV NETSNMP_ENABLE_SCAPI_AUTHPRIV
 
862
#endif
 
863
 
 
864
#ifdef NETSNMP_USE_INTERNAL_MD5
 
865
# define USE_INTERNAL_MD5 NETSNMP_USE_INTERNAL_MD5
 
866
#endif
 
867
 
 
868
#ifdef NETSNMP_USE_PKCS11
 
869
# define USE_PKCS NETSNMP_USE_PKCS11
 
870
#endif
 
871
 
 
872
#ifdef NETSNMP_USE_OPENSSL
 
873
# define USE_OPENSSL NETSNMP_USE_OPENSSL
 
874
#endif
 
875
 
 
876
#ifdef NETSNMP_NO_DEBUGGING
 
877
# define SNMP_NO_DEBUGGING NETSNMP_NO_DEBUGGING
 
878
#endif
 
879
 
 
880
#ifdef NETSNMP_ALWAYS_DEBUG
 
881
# define SNMP_ALWAYS_DEBUG NETSNMP_ALWAYS_DEBUG
 
882
#endif
 
883
 
 
884
#ifdef NETSNMP_USE_REVERSE_ASNENCODING
 
885
# define USE_REVERSE_ASNENCODING NETSNMP_USE_REVERSE_ASNENCODING
 
886
#endif
 
887
#ifdef NETSNMP_DEFAULT_ASNENCODING_DIRECTION
 
888
# define DEFAULT_ASNENCODING_DIRECTION NETSNMP_DEFAULT_ASNENCODING_DIRECTION
 
889
#endif
 
890
 
 
891
#define PERSISTENT_DIRECTORY NETSNMP_PERSISTENT_DIRECTORY
 
892
#define PERSISTENT_MASK NETSNMP_PERSISTENT_MASK
 
893
#define AGENT_DIRECTORY_MODE NETSNMP_AGENT_DIRECTORY_MODE
 
894
#define MAX_PERSISTENT_BACKUPS NETSNMP_MAX_PERSISTENT_BACKUPS
 
895
#define SYSTEM_INCLUDE_FILE NETSNMP_SYSTEM_INCLUDE_FILE
 
896
#define MACHINE_INCLUDE_FILE NETSNMP_MACHINE_INCLUDE_FILE
 
897
 
 
898
#ifdef NETSNMP_DEFAULT_SERVER_SEND_BUF
 
899
# define DEFAULT_SERVER_SEND_BUF NETSNMP_DEFAULT_SERVER_SEND_BUF
 
900
#endif
 
901
#ifdef NETSNMP_DEFAULT_SERVER_RECV_BUF
 
902
# define DEFAULT_SERVER_RECV_BUF NETSNMP_DEFAULT_SERVER_RECV_BUF
 
903
#endif
 
904
#ifdef NETSNMP_DEFAULT_CLIENT_SEND_BUF
 
905
# define DEFAULT_CLIENT_SEND_BUF NETSNMP_DEFAULT_CLIENT_SEND_BUF
 
906
#endif
 
907
#ifdef NETSNMP_DEFAULT_CLIENT_RECV_BUF
 
908
# define DEFAULT_CLIENT_RECV_BUF NETSNMP_DEFAULT_CLIENT_RECV_BUF
 
909
#endif
 
910
 
 
911
#ifdef NETSNMP_LOGFILE
 
912
# define LOGFILE NETSNMP_LOGFILE
 
913
#endif
 
914
 
 
915
#ifdef NETSNMP_SYS_CONTACT
 
916
# define SYS_CONTACT NETSNMP_SYS_CONTACT
 
917
#endif
 
918
 
 
919
#ifdef NETSNMP_SYS_LOC
 
920
# define SYS_LOC NETSNMP_SYS_LOC
 
921
#endif
 
922
 
 
923
#ifdef NETSNMP_USE_LIBWRAP
 
924
# define USE_LIBWRAP NETSNMP_USE_LIBWRAP
 
925
#endif
 
926
 
 
927
#ifdef NETSNMP_ENABLE_TESTING_CODE 
 
928
# define SNMP_TESTING_CODE NETSNMP_ENABLE_TESTING_CODE
 
929
#endif
 
930
 
 
931
#ifdef NETSNMP_NO_ROOT_ACCESS
 
932
# define NO_ROOT_ACCESS NETSNMP_NO_ROOT_ACCESS
 
933
#endif
 
934
 
 
935
#ifdef NETSNMP_NO_KMEM_USAGE
 
936
# define NO_KMEM_USAGE NETSNMP_NO_KMEM_USAGE
 
937
#endif
 
938
 
 
939
#ifdef NETSNMP_NO_DUMMY_VALUES
 
940
# define NO_DUMMY_VALUES NETSNMP_NO_DUMMY_VALUES
 
941
#endif
 
942
 
 
943
#define VERS_DESC     NETSNMP_VERS_DESC
 
944
#define SYS_NAME      NETSNMP_SYS_NAME
 
945
 
 
946
#define PROCMIBNUM    NETSNMP_PROCMIBNUM
 
947
#define SHELLMIBNUM   NETSNMP_SHELLMIBNUM
 
948
#define MEMMIBNUM     NETSNMP_MEMMIBNUM
 
949
#define DISKMIBNUM    NETSNMP_DISKMIBNUM
 
950
 
 
951
#define LOADAVEMIBNUM NETSNMP_LOADAVEMIBNUM
 
952
#define VERSIONMIBNUM NETSNMP_VERSIONMIBNUM
 
953
#define ERRORMIBNUM   NETSNMP_ERRORMIBNUM
 
954
#define AGENTID       NETSNMP_AGENTID
 
955
 
 
956
#define HPUX9ID       NETSNMP_HPUX9ID
 
957
#define SUNOS4ID      NETSNMP_SUNOS4ID
 
958
#define SOLARISID     NETSNMP_SOLARISID
 
959
#define OSFID         NETSNMP_OSFID
 
960
#define ULTRIXID      NETSNMP_ULTRIXID
 
961
#define HPUX10ID      NETSNMP_HPUX10ID
 
962
#define NETBSD1ID     NETSNMP_NETBSD1ID
 
963
#define FREEBSDID     NETSNMP_FREEBSDID
 
964
#define IRIXID        NETSNMP_IRIXID
 
965
#define LINUXID       NETSNMP_LINUXID
 
966
#define BSDIID        NETSNMP_BSDIID
 
967
#define OPENBSDID     NETSNMP_OPENBSDID
 
968
#define WIN32ID       NETSNMP_WIN32ID
 
969
#define HPUX11ID      NETSNMP_HPUX11ID
 
970
#define AIXID         NETSNMP_AIXID
 
971
#define MACOSXID      NETSNMP_MACOSXID
 
972
#define UNKNOWNID     NETSNMP_UNKNOWNID
 
973
 
 
974
#define ENTERPRISE_OID            NETSNMP_ENTERPRISE_OID
 
975
#define ENTERPRISE_MIB            NETSNMP_ENTERPRISE_MIB
 
976
#define ENTERPRISE_DOT_MIB        NETSNMP_ENTERPRISE_DOT_MIB
 
977
#define ENTERPRISE_DOT_MIB_LENGTH NETSNMP_ENTERPRISE_DOT_MIB_LENGTH
 
978
 
 
979
#define SYSTEM_MIB                NETSNMP_SYSTEM_MIB
 
980
#define SYSTEM_DOT_MIB            NETSNMP_SYSTEM_DOT_MIB
 
981
#define SYSTEM_DOT_MIB_LENGTH     NETSNMP_SYSTEM_DOT_MIB_LENGTH
 
982
 
 
983
#define NOTIFICATION_MIB            NETSNMP_NOTIFICATION_MIB    
 
984
#define NOTIFICATION_DOT_MIB        NETSNMP_NOTIFICATION_DOT_MIB
 
985
#define NOTIFICATION_DOT_MIB_LENGTH NETSNMP_NOTIFICATION_DOT_MIB_LENGTH
 
986
 
 
987
#define UCDAVIS_OID               NETSNMP_UCDAVIS_OID
 
988
#define UCDAVIS_MIB               NETSNMP_UCDAVIS_MIB
 
989
#define UCDAVIS_DOT_MIB           NETSNMP_UCDAVIS_DOT_MIB
 
990
#define UCDAVIS_DOT_MIB_LENGTH    NETSNMP_UCDAVIS_DOT_MIB_LENGTH
 
991
 
 
992
#define ERRORTIMELENGTH NETSNMP_ERRORTIMELENGTH
 
993
 
 
994
#ifdef NETSNMP_PROCFIXCMD
 
995
# define PROCFIXCMD NETSNMP_PROCFIXCMD
 
996
#endif
 
997
 
 
998
#ifdef NETSNMP_EXECFIXCMD
 
999
# define EXECFIXCMD NETSNMP_EXECFIXCMD
 
1000
#endif
 
1001
 
 
1002
#define EXCACHETIME  NETSNMP_EXCACHETIME
 
1003
#define CACHEFILE    NETSNMP_CACHEFILE
 
1004
#define MAXCACHESIZE NETSNMP_MAXCACHESIZE
 
1005
 
 
1006
#define DEFDISKMINIMUMSPACE NETSNMP_DEFDISKMINIMUMSPACE
 
1007
#define DEFMAXLOADAVE NETSNMP_DEFMAXLOADAVE
 
1008
#define MAXREADCOUNT NETSNMP_MAXREADCOUNT
 
1009
 
 
1010
#define SNMPBLOCK NETSNMP_SNMPBLOCK
 
1011
#define RESTARTSLEEP NETSNMP_RESTARTSLEEP
 
1012
 
 
1013
#define NUM_COMMUNITIES NETSNMP_NUM_COMMUNITIES
 
1014
 
 
1015
#ifdef NETSNMP_NO_ZEROLENGTH_COMMUNITY
 
1016
# define NO_ZEROLENGTH_COMMUNITY NETSNMP_NO_ZEROLENGTH_COMMUNITY
 
1017
#endif
 
1018
 
 
1019
#ifdef NETSNMP_EXIT_ON_BAD_KLREAD
 
1020
# define EXIT_ON_BAD_KLREAD NETSNMP_EXIT_ON_BAD_KLREAD
 
1021
#endif
 
1022
 
 
1023
#define LASTFIELD NETSNMP_LASTFIELD
 
1024
 
 
1025
#define CONFIGURE_OPTIONS NETSNMP_CONFIGURE_OPTIONS
 
1026
 
 
1027
#ifdef NETSNMP_TRANSPORT_UDP_DOMAIN
 
1028
# define SNMP_TRANSPORT_UDP_DOMAIN NETSNMP_TRANSPORT_UDP_DOMAIN
 
1029
#endif
 
1030
 
 
1031
#ifdef NETSNMP_TRANSPORT_CALLBACK_DOMAIN
 
1032
# define SNMP_TRANSPORT_CALLBACK_DOMAIN NETSNMP_TRANSPORT_CALLBACK_DOMAIN
 
1033
#endif
 
1034
 
 
1035
#ifdef NETSNMP_TRANSPORT_TCP_DOMAIN
 
1036
# define SNMP_TRANSPORT_TCP_DOMAIN NETSNMP_TRANSPORT_TCP_DOMAIN
 
1037
#endif
 
1038
 
 
1039
#ifdef NETSNMP_TRANSPORT_UNIX_DOMAIN
 
1040
# define SNMP_TRANSPORT_UNIX_DOMAIN NETSNMP_TRANSPORT_UNIX_DOMAIN
 
1041
#endif
 
1042
 
 
1043
#ifdef NETSNMP_TRANSPORT_AAL5PVC_DOMAIN
 
1044
# define SNMP_TRANSPORT_AAL5PVC_DOMAIN NETSNMP_TRANSPORT_AAL5PVC_DOMAIN
 
1045
#endif
 
1046
 
 
1047
#ifdef NETSNMP_TRANSPORT_IPX_DOMAIN
 
1048
# define SNMP_TRANSPORT_IPX_DOMAIN NETSNMP_TRANSPORT_IPX_DOMAIN
 
1049
#endif
 
1050
 
 
1051
#ifdef NETSNMP_TRANSPORT_UDPIPV6_DOMAIN
 
1052
# define SNMP_TRANSPORT_UDPIPV6_DOMAIN NETSNMP_TRANSPORT_UDPIPV6_DOMAIN
 
1053
#endif
 
1054
 
 
1055
#ifdef NETSNMP_TRANSPORT_TCPIPV6_DOMAIN
 
1056
# define SNMP_TRANSPORT_TCPIPV6_DOMAIN NETSNMP_TRANSPORT_TCPIPV6_DOMAIN
 
1057
#endif
 
1058
 
 
1059
#ifdef NETSNMP_TRANSPORT_TLS_DOMAIN
 
1060
# define SNMP_TRANSPORT_TLS_DOMAIN NETSNMP_TRANSPORT_TLS_DOMAIN
 
1061
#endif
 
1062
 
 
1063
#ifdef NETSNMP_TRANSPORT_STD_DOMAIN
 
1064
# define SNMP_TRANSPORT_STD_DOMAIN NETSNMP_TRANSPORT_STD_DOMAIN
 
1065
#endif
 
1066
 
 
1067
#ifdef NETSNMP_SECMOD_USM
 
1068
# define SNMP_SECMOD_USM NETSNMP_SECMOD_USM
 
1069
#endif
 
1070
 
 
1071
#ifdef NETSNMP_SECMOD_KSM
 
1072
# define SNMP_SECMOD_KSM NETSNMP_SECMOD_KSM
 
1073
#endif
 
1074
 
 
1075
#ifdef NETSNMP_SECMOD_LOCALSM 
 
1076
# define SNMP_SECMOD_LOCALSM NETSNMP_SECMOD_LOCALSM
 
1077
#endif
 
1078
 
 
1079
#ifdef NETSNMP_REENTRANT
 
1080
# define NS_REENTRANT NETSNMP_REENTRANT
 
1081
#endif
 
1082
 
 
1083
#ifdef NETSNMP_ENABLE_IPV6
 
1084
# define INET6 NETSNMP_ENABLE_IPV6
 
1085
#endif
 
1086
 
 
1087
#ifdef NETSNMP_ENABLE_LOCAL_SMUX
 
1088
# define LOCAL_SMUX NETSNMP_ENABLE_LOCAL_SMUX
 
1089
#endif
 
1090
 
 
1091
#ifdef NETSNMP_AGENTX_DOM_SOCK_ONLY
 
1092
# define AGENTX_DOM_SOCK_ONLY NETSNMP_AGENTX_DOM_SOCK_ONLY
 
1093
#endif
 
1094
 
 
1095
#ifdef NETSNMP_SNMPTRAPD_DISABLE_AGENTX
 
1096
# define SNMPTRAPD_DISABLE_AGENTX
 
1097
#endif
 
1098
 
 
1099
#ifdef NETSNMP_USE_KERBEROS_MIT
 
1100
# define MIT_NEW_CRYPTO NETSNMP_USE_KERBEROS_MIT
 
1101
#endif
 
1102
 
 
1103
#ifdef NETSNMP_USE_KERBEROS_HEIMDAL
 
1104
# define HEIMDAL NETSNMP_USE_KERBEROS_HEIMDAL
 
1105
#endif
 
1106
 
 
1107
#ifdef NETSNMP_AGENTX_SOCKET
 
1108
# define AGENTX_SOCKET NETSNMP_AGENTX_SOCKET
 
1109
#endif
 
1110
 
 
1111
#ifdef NETSNMP_DISABLE_MIB_LOADING
 
1112
# define DISABLE_MIB_LOADING NETSNMP_DISABLE_MIB_LOADING
 
1113
#endif
 
1114
 
 
1115
#ifdef NETSNMP_DISABLE_SNMPV1
 
1116
# define DISABLE_SNMPV1 NETSNMP_DISABLE_SNMPV1
 
1117
#endif
 
1118
 
 
1119
#ifdef NETSNMP_DISABLE_SNMPV2C
 
1120
# define DISABLE_SNMPV2C NETSNMP_DISABLE_SNMPV2C
 
1121
#endif
 
1122
 
 
1123
#ifdef NETSNMP_DISABLE_SET_SUPPORT
 
1124
# define DISABLE_SET_SUPPORT NETSNMP_DISABLE_SET_SUPPORT
 
1125
#endif
 
1126
 
 
1127
#ifdef NETSNMP_DISABLE_DES
 
1128
# define DISABLE_DES NETSNMP_DISABLE_DES
 
1129
#endif
 
1130
 
 
1131
#ifdef NETSNMP_DISABLE_MD5
 
1132
# define DISABLE_MD5 NETSNMP_DISABLE_MD5
 
1133
#endif
 
1134
 
 
1135
#ifdef NETSNMP_DONT_USE_NLIST
 
1136
# define DONT_USE_NLIST NETSNMP_DONT_USE_NLIST
 
1137
#endif
 
1138
 
 
1139
#ifdef NETSNMP_CAN_USE_NLIST
 
1140
# define CAN_USE_NLIST NETSNMP_CAN_USE_NLIST
 
1141
#endif
 
1142
 
 
1143
#ifdef NETSNMP_CAN_USE_SYSCTL
 
1144
# define CAN_USE_SYSCTL NETSNMP_CAN_USE_SYSCTL
 
1145
#endif
 
1146
 
 
1147
#endif /* NETSNMP_NO_LEGACY_DEFINITIONS */
 
1148
 
776
1149
 
777
1150
#endif /* NET_SNMP_CONFIG_H */