# 1 "mibII/tcp.c" # 1 "" # 1 "" # 1 "mibII/tcp.c" # 1 "../../include/net-snmp/net-snmp-config.h" 1 # 1567 "../../include/net-snmp/net-snmp-config.h" # 1 "../../include/net-snmp/system/openbsd.h" 1 # 1 "../../include/net-snmp/system/netbsd.h" 1 # 1 "../../include/net-snmp/system/bsd.h" 1 # 1 "../../include/net-snmp/system/generic.h" 1 # 2 "../../include/net-snmp/system/bsd.h" 2 # 2 "../../include/net-snmp/system/netbsd.h" 2 # 1 "/usr/include/sys/param.h" 1 3 4 # 56 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/sys/types.h" 1 3 4 # 44 "/usr/include/sys/types.h" 3 4 # 1 "/usr/include/machine/types.h" 1 3 4 # 38 "/usr/include/machine/types.h" 3 4 # 1 "/usr/include/sys/cdefs.h" 1 3 4 # 41 "/usr/include/sys/cdefs.h" 3 4 # 1 "/usr/include/machine/cdefs.h" 1 3 4 # 42 "/usr/include/sys/cdefs.h" 2 3 4 # 39 "/usr/include/machine/types.h" 2 3 4 typedef struct label_t { int val[6]; } label_t; typedef unsigned long vaddr_t; typedef unsigned long paddr_t; typedef unsigned long vsize_t; typedef unsigned long psize_t; typedef signed char int8_t; typedef unsigned char u_int8_t; typedef unsigned char uint8_t; typedef short int16_t; typedef unsigned short u_int16_t; typedef unsigned short uint16_t; typedef int int32_t; typedef unsigned int u_int32_t; typedef unsigned int uint32_t; typedef long long int64_t; typedef unsigned long long u_int64_t; typedef unsigned long long uint64_t; typedef int32_t register_t; # 45 "/usr/include/sys/types.h" 2 3 4 # 1 "/usr/include/machine/ansi.h" 1 3 4 # 47 "/usr/include/sys/types.h" 2 3 4 # 1 "/usr/include/machine/endian.h" 1 3 4 # 68 "/usr/include/machine/endian.h" 3 4 # 1 "/usr/include/sys/endian.h" 1 3 4 # 152 "/usr/include/sys/endian.h" 3 4 u_int64_t htobe64(u_int64_t); u_int32_t htobe32(u_int32_t); u_int16_t htobe16(u_int16_t); u_int64_t betoh64(u_int64_t); u_int32_t betoh32(u_int32_t); u_int16_t betoh16(u_int16_t); u_int64_t htole64(u_int64_t); u_int32_t htole32(u_int32_t); u_int16_t htole16(u_int16_t); u_int64_t letoh64(u_int64_t); u_int32_t letoh32(u_int32_t); u_int16_t letoh16(u_int16_t); # 69 "/usr/include/machine/endian.h" 2 3 4 # 48 "/usr/include/sys/types.h" 2 3 4 typedef unsigned char u_char; typedef unsigned short u_short; typedef unsigned int u_int; typedef unsigned long u_long; typedef unsigned char unchar; typedef unsigned short ushort; typedef unsigned int uint; typedef unsigned long ulong; typedef unsigned long cpuid_t; typedef u_int64_t u_quad_t; typedef int64_t quad_t; typedef quad_t * qaddr_t; typedef char * caddr_t; typedef int32_t daddr_t; typedef int32_t dev_t; typedef u_int32_t fixpt_t; typedef u_int32_t gid_t; typedef u_int32_t id_t; typedef u_int32_t ino_t; typedef long key_t; typedef u_int32_t mode_t; typedef u_int32_t nlink_t; typedef int32_t pid_t; typedef u_quad_t rlim_t; typedef int32_t segsz_t; typedef int32_t swblk_t; typedef u_int32_t uid_t; typedef u_int32_t useconds_t; typedef int32_t suseconds_t; # 92 "/usr/include/sys/types.h" 3 4 typedef u_int32_t in_addr_t; typedef u_int16_t in_port_t; typedef u_int8_t sa_family_t; typedef u_int32_t socklen_t; typedef unsigned long clock_t; typedef unsigned int size_t; typedef int ssize_t; typedef int time_t; typedef int clockid_t; typedef int timer_t; typedef long long off_t; # 140 "/usr/include/sys/types.h" 3 4 off_t lseek(int, off_t, int); int ftruncate(int, off_t); int truncate(const char *, off_t); # 168 "/usr/include/sys/types.h" 3 4 typedef int32_t fd_mask; typedef struct fd_set { fd_mask fds_bits[(((1024) + (((sizeof(fd_mask) * 8)) - 1)) / ((sizeof(fd_mask) * 8)))]; } fd_set; # 57 "/usr/include/sys/param.h" 2 3 4 # 1 "/usr/include/sys/simplelock.h" 1 3 4 # 19 "/usr/include/sys/simplelock.h" 3 4 struct simplelock { int lock_data; }; # 58 "/usr/include/sys/param.h" 2 3 4 # 67 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/sys/syslimits.h" 1 3 4 # 68 "/usr/include/sys/param.h" 2 3 4 # 91 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/sys/signal.h" 1 3 4 # 44 "/usr/include/sys/signal.h" 3 4 # 1 "/usr/include/machine/signal.h" 1 3 4 # 38 "/usr/include/machine/signal.h" 3 4 typedef int sig_atomic_t; # 1 "/usr/include/machine/trap.h" 1 3 4 # 45 "/usr/include/machine/signal.h" 2 3 4 # 53 "/usr/include/machine/signal.h" 3 4 struct sigcontext { int sc_gs; int sc_fs; int sc_es; int sc_ds; int sc_edi; int sc_esi; int sc_ebp; int sc_ebx; int sc_edx; int sc_ecx; int sc_eax; int sc_eip; int sc_cs; int sc_eflags; int sc_esp; int sc_ss; int sc_onstack; int sc_mask; int sc_trapno; int sc_err; }; # 45 "/usr/include/sys/signal.h" 2 3 4 # 106 "/usr/include/sys/signal.h" 3 4 typedef unsigned int sigset_t; # 1 "/usr/include/sys/siginfo.h" 1 3 4 # 31 "/usr/include/sys/siginfo.h" 3 4 union sigval { int sival_int; void *sival_ptr; }; # 128 "/usr/include/sys/siginfo.h" 3 4 # 1 "/usr/include/sys/time.h" 1 3 4 # 44 "/usr/include/sys/time.h" 3 4 struct timeval { long tv_sec; long tv_usec; }; struct timespec { time_t tv_sec; long tv_nsec; }; # 66 "/usr/include/sys/time.h" 3 4 struct timezone { int tz_minuteswest; int tz_dsttime; }; # 131 "/usr/include/sys/time.h" 3 4 struct bintime { time_t sec; uint64_t frac; }; static __inline void bintime_addx(struct bintime *bt, uint64_t x) { uint64_t u; u = bt->frac; bt->frac += x; if (u > bt->frac) bt->sec++; } static __inline void bintime_add(struct bintime *bt, struct bintime *bt2) { uint64_t u; u = bt->frac; bt->frac += bt2->frac; if (u > bt->frac) bt->sec++; bt->sec += bt2->sec; } static __inline void bintime_sub(struct bintime *bt, struct bintime *bt2) { uint64_t u; u = bt->frac; bt->frac -= bt2->frac; if (u < bt->frac) bt->sec--; bt->sec -= bt2->sec; } # 185 "/usr/include/sys/time.h" 3 4 static __inline void bintime2timespec(struct bintime *bt, struct timespec *ts) { ts->tv_sec = bt->sec; ts->tv_nsec = ((uint64_t)1000000000 * (uint32_t)(bt->frac >> 32)) >> 32; } static __inline void timespec2bintime(struct timespec *ts, struct bintime *bt) { bt->sec = ts->tv_sec; bt->frac = ts->tv_nsec * (uint64_t)18446744073LL; } static __inline void bintime2timeval(struct bintime *bt, struct timeval *tv) { tv->tv_sec = bt->sec; tv->tv_usec = ((uint64_t)1000000 * (uint32_t)(bt->frac >> 32)) >> 32; } static __inline void timeval2bintime(struct timeval *tv, struct bintime *bt) { bt->sec = tv->tv_sec; bt->frac = tv->tv_usec * (uint64_t)18446744073709LL; } # 227 "/usr/include/sys/time.h" 3 4 struct itimerval { struct timeval it_interval; struct timeval it_value; }; struct itimerspec { struct timespec it_interval; struct timespec it_value; }; struct clockinfo { int hz; int tick; int tickadj; int stathz; int profhz; }; # 307 "/usr/include/sys/time.h" 3 4 # 1 "/usr/include/time.h" 1 3 4 # 71 "/usr/include/time.h" 3 4 struct tm { int tm_sec; int tm_min; int tm_hour; int tm_mday; int tm_mon; int tm_year; int tm_wday; int tm_yday; int tm_isdst; long tm_gmtoff; char *tm_zone; }; struct timespec; char *asctime(const struct tm *); clock_t clock(void); char *ctime(const time_t *); double difftime(time_t, time_t); struct tm *gmtime(const time_t *); struct tm *localtime(const time_t *); time_t mktime(struct tm *); size_t strftime(char *, size_t, const char *, const struct tm *) __attribute__ ((__bounded__(__string__,1,2))); char *strptime(const char *, const char *, struct tm *); time_t time(time_t *); char *asctime_r(const struct tm *, char *) __attribute__ ((__bounded__(__minbytes__,2,26))); char *ctime_r(const time_t *, char *) __attribute__ ((__bounded__(__minbytes__,2,26))); struct tm *gmtime_r(const time_t *, struct tm *); struct tm *localtime_r(const time_t *, struct tm *); int nanosleep(const struct timespec *, struct timespec *); extern char *tzname[2]; void tzset(void); char *timezone(int, int); void tzsetwall(void); time_t timelocal(struct tm *); time_t timegm(struct tm *); time_t timeoff(struct tm *, const long); # 308 "/usr/include/sys/time.h" 2 3 4 int adjtime(const struct timeval *, struct timeval *); int clock_getres(clockid_t, struct timespec *); int clock_gettime(clockid_t, struct timespec *); int clock_settime(clockid_t, const struct timespec *); int futimes(int, const struct timeval *); int getitimer(int, struct itimerval *); int gettimeofday(struct timeval *, struct timezone *); int setitimer(int, const struct itimerval *, struct itimerval *); int settimeofday(const struct timeval *, const struct timezone *); int utimes(const char *, const struct timeval *); # 129 "/usr/include/sys/siginfo.h" 2 3 4 typedef struct { int si_signo; int si_code; int si_errno; union { int _pad[((128 / sizeof (int)) - 3)]; struct { pid_t _pid; union { struct { uid_t _uid; union sigval _value; } _kill; struct { clock_t _utime; int _status; clock_t _stime; } _cld; } _pdata; } _proc; struct { caddr_t _addr; int _trapno; } _fault; # 170 "/usr/include/sys/siginfo.h" 3 4 } _data; } siginfo_t; # 109 "/usr/include/sys/signal.h" 2 3 4 struct sigaction { union { void (*__sa_handler)(int); void (*__sa_sigaction)(int, siginfo_t *, void *); } __sigaction_u; sigset_t sa_mask; int sa_flags; }; # 147 "/usr/include/sys/signal.h" 3 4 typedef void (*sig_t)(int); typedef struct sigaltstack { void *ss_sp; size_t ss_size; int ss_flags; } stack_t; # 174 "/usr/include/sys/signal.h" 3 4 struct sigvec { void (*sv_handler)(int); int sv_mask; int sv_flags; }; # 187 "/usr/include/sys/signal.h" 3 4 struct sigstack { void *ss_sp; int ss_onstack; }; typedef struct sigcontext ucontext_t; # 209 "/usr/include/sys/signal.h" 3 4 void (*signal(int, void (*)(int)))(int); # 92 "/usr/include/sys/param.h" 2 3 4 # 1 "/usr/include/sys/limits.h" 1 3 4 # 41 "/usr/include/sys/limits.h" 3 4 # 1 "/usr/include/machine/internal_types.h" 1 3 4 # 42 "/usr/include/sys/limits.h" 2 3 4 # 1 "/usr/include/machine/limits.h" 1 3 4 # 45 "/usr/include/sys/limits.h" 2 3 4 # 95 "/usr/include/sys/param.h" 2 3 4 # 1 "/usr/include/machine/param.h" 1 3 4 # 96 "/usr/include/sys/param.h" 2 3 4 # 4 "../../include/net-snmp/system/netbsd.h" 2 # 2 "../../include/net-snmp/system/openbsd.h" 2 # 1568 "../../include/net-snmp/net-snmp-config.h" 2 # 1 "../../include/net-snmp/machine/generic.h" 1 # 1569 "../../include/net-snmp/net-snmp-config.h" 2 # 8 "mibII/tcp.c" 2 # 1 "mibII/mibII_common.h" 1 # 1 "/usr/include/stdlib.h" 1 3 4 # 51 "/usr/include/stdlib.h" 3 4 typedef int wchar_t; typedef struct { int quot; int rem; } div_t; typedef struct { long quot; long rem; } ldiv_t; typedef struct { quad_t quot; quad_t rem; } qdiv_t; # 100 "/usr/include/stdlib.h" 3 4 __attribute__((__noreturn__)) void abort(void); int abs(int); int atexit(void (*)(void)); double atof(const char *); int atoi(const char *); long atol(const char *); long long atoll(const char *); void *bsearch(const void *, const void *, size_t, size_t, int (*)(const void *, const void *)); void *calloc(size_t, size_t); div_t div(int, int); char *ecvt(double, int, int *, int *); __attribute__((__noreturn__)) void exit(int); __attribute__((__noreturn__)) void _Exit(int); char *fcvt(double, int, int *, int *); void free(void *); char *gcvt(double, int, char *); char *getenv(const char *); long labs(long); ldiv_t ldiv(long, long); long long llabs(long long); void *malloc(size_t); void qsort(void *, size_t, size_t, int (*)(const void *, const void *)); int rand(void); int rand_r(unsigned int *); void *realloc(void *, size_t); void srand(unsigned); double strtod(const char *, char **); long strtol(const char *, char **, int); long long strtoll(const char *, char **, int); long long strtonum(const char *, long long, long long, const char **); unsigned long strtoul(const char *, char **, int); unsigned long long strtoull(const char *, char **, int); int system(const char *); int mblen(const char *, size_t); size_t mbstowcs(wchar_t *, const char *, size_t); int wctomb(char *, wchar_t); int mbtowc(wchar_t *, const char *, size_t); size_t wcstombs(char *, const wchar_t *, size_t); void *alloca(size_t); char *getbsize(int *, long *); char *cgetcap(char *, const char *, int); int cgetclose(void); int cgetent(char **, char **, const char *); int cgetfirst(char **, char **); int cgetmatch(char *, const char *); int cgetnext(char **, char **); int cgetnum(char *, const char *, long *); int cgetset(const char *); int cgetusedb(int); int cgetstr(char *, const char *, char **); int cgetustr(char *, const char *, char **); int daemon(int, int); char *devname(int, int); int getloadavg(double [], int); long a64l(const char *); char *l64a(long); void cfree(void *); int getopt(int, char * const *, const char *); extern char *optarg; extern int opterr; extern int optind; extern int optopt; extern int optreset; int getsubopt(char **, char * const *, char **); extern char *suboptarg; int heapsort(void *, size_t, size_t, int (*)(const void *, const void *)); int mergesort(void *, size_t, size_t, int (*)(const void *, const void *)); int radixsort(const unsigned char **, int, const unsigned char *, unsigned); int sradixsort(const unsigned char **, int, const unsigned char *, unsigned); char *initstate(unsigned int, char *, size_t) __attribute__((__bounded__ (__string__,2,3))); long random(void); char *realpath(const char *, char *); char *setstate(const char *); void srandom(unsigned int); void srandomdev(void); int putenv(const char *); int setenv(const char *, const char *, int); void unsetenv(const char *); void setproctitle(const char *, ...) __attribute__((__format__ (__printf__, 1, 2))); quad_t qabs(quad_t); qdiv_t qdiv(quad_t, quad_t); quad_t strtoq(const char *, char **, int); u_quad_t strtouq(const char *, char **, int); double drand48(void); double erand48(unsigned short[3]); long jrand48(unsigned short[3]); void lcong48(unsigned short[7]); long lrand48(void); long mrand48(void); long nrand48(unsigned short[3]); unsigned short *seed48(unsigned short[3]); void srand48(long); u_int32_t arc4random(void); void arc4random_stir(void); void arc4random_addrandom(unsigned char *, int) __attribute__((__bounded__ (__string__,1,2))); # 3 "mibII/mibII_common.h" 2 # 1 "/usr/include/unistd.h" 1 3 4 # 40 "/usr/include/unistd.h" 3 4 # 1 "/usr/include/sys/unistd.h" 1 3 4 # 41 "/usr/include/unistd.h" 2 3 4 # 54 "/usr/include/unistd.h" 3 4 __attribute__((__noreturn__)) void _exit(int); int access(const char *, int); unsigned int alarm(unsigned int); int chdir(const char *); int chown(const char *, uid_t, gid_t); int close(int); size_t confstr(int, char *, size_t) __attribute__((__bounded__(__string__,2,3))); char *cuserid(char *); int dup(int); int dup2(int, int); int execl(const char *, const char *, ...) __attribute__((sentinel)); int execle(const char *, const char *, ...) __attribute__((sentinel)); int execlp(const char *, const char *, ...) __attribute__((sentinel)); int execv(const char *, char * const *); int execve(const char *, char * const *, char * const *); int execvp(const char *, char * const *); pid_t fork(void); long fpathconf(int, int); char *getcwd(char *, size_t) __attribute__((__bounded__(__string__,1,2))) __attribute__((__bounded__(__minbytes__,1,1024))); gid_t getegid(void); uid_t geteuid(void); gid_t getgid(void); int getgroups(int, gid_t *); char *getlogin(void); int getlogin_r(char *, size_t) __attribute__((__bounded__(__string__,1,2))) __attribute__((__bounded__(__minbytes__,1,32))); pid_t getpgrp(void); pid_t getpid(void); pid_t getpgid(pid_t); pid_t getppid(void); pid_t getsid(pid_t); uid_t getuid(void); int isatty(int); int link(const char *, const char *); off_t lseek(int, off_t, int); long pathconf(const char *, int); int pause(void); int pipe(int *); ssize_t read(int, void *, size_t) __attribute__((__bounded__(__buffer__,2,3))); int rmdir(const char *); int setgid(gid_t); int setpgid(pid_t, pid_t); pid_t setsid(void); int setuid(uid_t); unsigned int sleep(unsigned int); long sysconf(int); pid_t tcgetpgrp(int); int tcsetpgrp(int, pid_t); char *ttyname(int); int ttyname_r(int, char *, size_t) __attribute__((__bounded__(__string__,2,3))); int unlink(const char *); ssize_t write(int, const void *, size_t) __attribute__((__bounded__(__buffer__,2,3))); # 128 "/usr/include/unistd.h" 3 4 ssize_t pread(int, void *, size_t, off_t); ssize_t pwrite(int, const void *, size_t, off_t); int acct(const char *); char *brk(const char *); int chroot(const char *); int closefrom(int); char *crypt(const char *, const char *); int des_cipher(const char *, char *, int32_t, int); int des_setkey(const char *key); int encrypt(char *, int); void endusershell(void); int exect(const char *, char * const *, char * const *); int fchdir(int); int fchown(int, uid_t, gid_t); char *fflagstostr(u_int32_t); int fsync(int); int ftruncate(int, off_t); int getdomainname(char *, size_t) __attribute__ ((__bounded__(__string__,1,2))); int getdtablesize(void); int getgrouplist(const char *, gid_t, gid_t *, int *); long gethostid(void); int gethostname(char *, size_t) __attribute__ ((__bounded__(__string__,1,2))); mode_t getmode(const void *, mode_t); int getpagesize(void); int getresgid(gid_t *, gid_t *, gid_t *); int getresuid(uid_t *, uid_t *, uid_t *); char *getpass(const char *); char *getusershell(void); char *getwd(char *) __attribute__ ((__bounded__(__minbytes__,1,1024))); int initgroups(const char *, gid_t); int iruserok(u_int32_t, int, const char *, const char *); int iruserok_sa(const void *, int, int, const char *, const char *); int lchown(const char *, uid_t, gid_t); char *mkdtemp(char *); int mkstemp(char *); int mkstemps(char *, int); char *mktemp(char *); int nfssvc(int, void *); int nice(int); void psignal(unsigned int, const char *); extern const char *const sys_siglist[]; int profil(char *, size_t, unsigned long, unsigned int) __attribute__ ((__bounded__(__string__,1,2))); int rcmd(char **, int, const char *, const char *, const char *, int *); int rcmd_af(char **, int, const char *, const char *, const char *, int *, int); int rcmdsh(char **, int, const char *, const char *, const char *, char *); char *re_comp(const char *); int re_exec(const char *); int readlink(const char *, char *, size_t) __attribute__ ((__bounded__(__string__,2,3))); int reboot(int); int revoke(const char *); int rfork(int opts); int rresvport(int *); int rresvport_af(int *, int); int ruserok(const char *, int, const char *, const char *); int quotactl(const char *, int, int, char *); char *sbrk(int); int select(int, fd_set *, fd_set *, fd_set *, struct timeval *); int setdomainname(const char *, size_t); int setegid(gid_t); int seteuid(uid_t); int setgroups(int, const gid_t *); int sethostid(long); int sethostname(const char *, size_t); int setkey(const char *); int setlogin(const char *); void *setmode(const char *); int setpgrp(pid_t pid, pid_t pgrp); int setregid(gid_t, gid_t); int setresgid(gid_t, gid_t, gid_t); int setresuid(uid_t, uid_t, uid_t); int setreuid(uid_t, uid_t); int setrgid(gid_t); int setruid(uid_t); void setusershell(void); int strtofflags(char **, u_int32_t *, u_int32_t *); void swab(const void *, void *, size_t); int swapctl(int cmd, const void *arg, int misc); int symlink(const char *, const char *); void sync(void); int syscall(int, ...); int truncate(const char *, off_t); int ttyslot(void); unsigned int ualarm(unsigned int, unsigned int); int undelete(const char *); int usleep(useconds_t); void *valloc(size_t); pid_t vfork(void); int issetugid(void); # 253 "/usr/include/unistd.h" 3 4 int lockf(int, int, off_t); # 6 "mibII/mibII_common.h" 2 # 1 "/usr/include/string.h" 1 3 4 # 54 "/usr/include/string.h" 3 4 void *memchr(const void *, int, size_t); int memcmp(const void *, const void *, size_t); void *memcpy(void *, const void *, size_t) __attribute__ ((__bounded__(__buffer__,1,3))) __attribute__ ((__bounded__(__buffer__,2,3))); void *memmove(void *, const void *, size_t) __attribute__ ((__bounded__(__buffer__,1,3))) __attribute__ ((__bounded__(__buffer__,2,3))); void *memset(void *, int, size_t) __attribute__ ((__bounded__(__buffer__,1,3))); char *strcat(char *, const char *); char *strchr(const char *, int); int strcmp(const char *, const char *); int strcoll(const char *, const char *); char *strcpy(char *, const char *); size_t strcspn(const char *, const char *); char *strerror(int); int strerror_r(int, char *, size_t) __attribute__ ((__bounded__(__string__,2,3))); size_t strlen(const char *); char *strncat(char *, const char *, size_t) __attribute__ ((__bounded__(__string__,1,3))); int strncmp(const char *, const char *, size_t); char *strncpy(char *, const char *, size_t) __attribute__ ((__bounded__(__string__,1,3))); char *strpbrk(const char *, const char *); char *strrchr(const char *, int); size_t strspn(const char *, const char *); char *strstr(const char *, const char *); char *strtok(char *, const char *); char *strtok_r(char *, const char *, char **); size_t strxfrm(char *, const char *, size_t) __attribute__ ((__bounded__(__string__,1,3))); int bcmp(const void *, const void *, size_t); void bcopy(const void *, void *, size_t) __attribute__ ((__bounded__(__buffer__,1,3))) __attribute__ ((__bounded__(__buffer__,2,3))); void bzero(void *, size_t) __attribute__ ((__bounded__(__buffer__,1,2))); int ffs(int); char *index(const char *, int); void *memccpy(void *, const void *, int, size_t) __attribute__ ((__bounded__(__buffer__,1,4))); char *rindex(const char *, int); int strcasecmp(const char *, const char *); char *strdup(const char *); size_t strlcat(char *, const char *, size_t) __attribute__ ((__bounded__(__string__,1,3))); size_t strlcpy(char *, const char *, size_t) __attribute__ ((__bounded__(__string__,1,3))); void strmode(int, char *); int strncasecmp(const char *, const char *, size_t); char *strsep(char **, const char *); char *strsignal(int); # 10 "mibII/mibII_common.h" 2 # 19 "mibII/mibII_common.h" # 1 "/usr/include/sys/param.h" 1 3 4 # 67 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/sys/syslimits.h" 1 3 4 # 68 "/usr/include/sys/param.h" 2 3 4 # 95 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/machine/param.h" 1 3 4 # 96 "/usr/include/sys/param.h" 2 3 4 # 20 "mibII/mibII_common.h" 2 # 1 "/usr/include/netinet/in.h" 1 3 4 # 135 "/usr/include/netinet/in.h" 3 4 struct in_addr { in_addr_t s_addr; }; # 212 "/usr/include/netinet/in.h" 3 4 struct sockaddr_in { u_int8_t sin_len; sa_family_t sin_family; in_port_t sin_port; struct in_addr sin_addr; int8_t sin_zero[8]; }; struct sockaddr_rtin { u_int8_t rtin_len; sa_family_t rtin_family; in_port_t rtin_port; struct in_addr rtin_dst; struct in_addr rtin_src; int8_t rtin_zero[4]; }; # 236 "/usr/include/netinet/in.h" 3 4 struct ip_opts { struct in_addr ip_dst; int8_t ip_opts[40]; }; # 304 "/usr/include/netinet/in.h" 3 4 struct ip_mreq { struct in_addr imr_multiaddr; struct in_addr imr_interface; }; # 551 "/usr/include/netinet/in.h" 3 4 # 1 "/usr/include/netinet6/in6.h" 1 3 4 # 116 "/usr/include/netinet6/in6.h" 3 4 struct in6_addr { union { u_int8_t __u6_addr8[16]; u_int16_t __u6_addr16[8]; u_int32_t __u6_addr32[4]; } __u6_addr; }; # 139 "/usr/include/netinet6/in6.h" 3 4 struct sockaddr_in6 { u_int8_t sin6_len; sa_family_t sin6_family; in_port_t sin6_port; u_int32_t sin6_flowinfo; struct in6_addr sin6_addr; u_int32_t sin6_scope_id; }; # 217 "/usr/include/netinet6/in6.h" 3 4 extern const struct in6_addr in6addr_any; extern const struct in6_addr in6addr_loopback; extern const struct in6_addr in6addr_nodelocal_allnodes; extern const struct in6_addr in6addr_linklocal_allnodes; extern const struct in6_addr in6addr_linklocal_allrouters; # 370 "/usr/include/netinet6/in6.h" 3 4 struct route_in6 { struct rtentry *ro_rt; struct sockaddr_in6 ro_dst; }; # 435 "/usr/include/netinet6/in6.h" 3 4 struct ipv6_mreq { struct in6_addr ipv6mr_multiaddr; unsigned int ipv6mr_interface; }; struct in6_pktinfo { struct in6_addr ipi6_addr; unsigned int ipi6_ifindex; }; # 656 "/usr/include/netinet6/in6.h" 3 4 struct cmsghdr; extern int inet6_option_space(int); extern int inet6_option_init(void *, struct cmsghdr **, int); extern int inet6_option_append(struct cmsghdr *, const u_int8_t *, int, int); extern u_int8_t *inet6_option_alloc(struct cmsghdr *, int, int, int); extern int inet6_option_next(const struct cmsghdr *, u_int8_t **); extern int inet6_option_find(const struct cmsghdr *, u_int8_t **, int); extern size_t inet6_rthdr_space(int, int); extern struct cmsghdr *inet6_rthdr_init(void *, int); extern int inet6_rthdr_add(struct cmsghdr *, const struct in6_addr *, unsigned int); extern int inet6_rthdr_lasthop(struct cmsghdr *, unsigned int); extern int inet6_rthdr_segments(const struct cmsghdr *); extern struct in6_addr *inet6_rthdr_getaddr(struct cmsghdr *, int); extern int inet6_rthdr_getflags(const struct cmsghdr *, int); # 552 "/usr/include/netinet/in.h" 2 3 4 int bindresvport(int, struct sockaddr_in *); struct sockaddr; int bindresvport_sa(int, struct sockaddr *); # 24 "mibII/mibII_common.h" 2 # 36 "mibII/mibII_common.h" # 1 "/usr/include/sys/socket.h" 1 3 4 # 41 "/usr/include/sys/socket.h" 3 4 # 1 "/usr/include/machine/param.h" 1 3 4 # 42 "/usr/include/sys/socket.h" 2 3 4 # 86 "/usr/include/sys/socket.h" 3 4 struct linger { int l_onoff; int l_linger; }; # 143 "/usr/include/sys/socket.h" 3 4 struct sockaddr { u_int8_t sa_len; sa_family_t sa_family; char sa_data[14]; }; # 161 "/usr/include/sys/socket.h" 3 4 struct sockaddr_storage { u_int8_t ss_len; sa_family_t ss_family; unsigned char __ss_pad1[6]; u_int64_t __ss_pad2; unsigned char __ss_pad3[240]; }; struct sockproto { unsigned short sp_family; unsigned short sp_protocol; }; # 228 "/usr/include/sys/socket.h" 3 4 struct sockcred { uid_t sc_uid; uid_t sc_euid; gid_t sc_gid; gid_t sc_egid; int sc_ngroups; gid_t sc_groups[1]; }; # 341 "/usr/include/sys/socket.h" 3 4 struct msghdr { void *msg_name; socklen_t msg_namelen; struct iovec *msg_iov; unsigned int msg_iovlen; void *msg_control; socklen_t msg_controllen; int msg_flags; }; # 368 "/usr/include/sys/socket.h" 3 4 struct cmsghdr { socklen_t cmsg_len; int cmsg_level; int cmsg_type; }; # 415 "/usr/include/sys/socket.h" 3 4 struct osockaddr { unsigned short sa_family; char sa_data[14]; }; struct omsghdr { caddr_t msg_name; int msg_namelen; struct iovec *msg_iov; int msg_iovlen; caddr_t msg_accrights; int msg_accrightslen; }; int accept(int, struct sockaddr *, socklen_t *); int bind(int, const struct sockaddr *, socklen_t); int connect(int, const struct sockaddr *, socklen_t); int getpeereid(int, uid_t *, gid_t *); int getpeername(int, struct sockaddr *, socklen_t *); int getsockname(int, struct sockaddr *, socklen_t *); int getsockopt(int, int, int, void *, socklen_t *); int listen(int, int); ssize_t recv(int, void *, size_t, int); ssize_t recvfrom(int, void *, size_t, int, struct sockaddr *, socklen_t *); ssize_t recvmsg(int, struct msghdr *, int); ssize_t send(int, const void *, size_t, int); ssize_t sendto(int, const void *, size_t, int, const struct sockaddr *, socklen_t); ssize_t sendmsg(int, const struct msghdr *, int); int setsockopt(int, int, int, const void *, socklen_t); int shutdown(int, int); int socket(int, int, int); int socketpair(int, int, int, int *); # 37 "mibII/mibII_common.h" 2 # 1 "/usr/include/net/if.h" 1 3 4 # 38 "/usr/include/net/if.h" 3 4 # 1 "/usr/include/sys/queue.h" 1 3 4 # 39 "/usr/include/net/if.h" 2 3 4 # 1 "/usr/include/altq/if_altq.h" 1 3 4 # 38 "/usr/include/altq/if_altq.h" 3 4 struct altq_pktattr; struct tb_regulator; struct top_cdnr; struct ifaltq { struct mbuf *ifq_head; struct mbuf *ifq_tail; int ifq_len; int ifq_maxlen; int ifq_drops; int ifq_congestion; int altq_type; int altq_flags; void *altq_disc; struct ifnet *altq_ifp; int (*altq_enqueue)(struct ifaltq *, struct mbuf *, struct altq_pktattr *); struct mbuf *(*altq_dequeue)(struct ifaltq *, int); int (*altq_request)(struct ifaltq *, int, void *); void *altq_clfier; void *(*altq_classify)(void *, struct mbuf *, int); struct tb_regulator *altq_tbr; struct top_cdnr *altq_cdnr; }; # 47 "/usr/include/net/if.h" 2 3 4 # 75 "/usr/include/net/if.h" 3 4 struct mbuf; struct proc; struct rtentry; struct socket; struct ether_header; struct arpcom; struct rt_addrinfo; struct if_clone { struct { struct if_clone *le_next; struct if_clone **le_prev; } ifc_list; const char *ifc_name; size_t ifc_namelen; int (*ifc_create)(struct if_clone *, int); int (*ifc_destroy)(struct ifnet *); }; struct if_clonereq { int ifcr_total; int ifcr_count; char *ifcr_buffer; }; struct if_data { u_char ifi_type; u_char ifi_addrlen; u_char ifi_hdrlen; u_char ifi_link_state; u_long ifi_mtu; u_long ifi_metric; u_long ifi_baudrate; u_long ifi_ipackets; u_long ifi_ierrors; u_long ifi_opackets; u_long ifi_oerrors; u_long ifi_collisions; u_long ifi_ibytes; u_long ifi_obytes; u_long ifi_imcasts; u_long ifi_omcasts; u_long ifi_iqdrops; u_long ifi_noproto; struct timeval ifi_lastchange; }; struct ifqueue { struct mbuf *ifq_head; struct mbuf *ifq_tail; int ifq_len; int ifq_maxlen; int ifq_drops; struct timeout *ifq_congestion; }; # 159 "/usr/include/net/if.h" 3 4 struct ifnet_head { struct ifnet *tqh_first; struct ifnet **tqh_last; }; # 173 "/usr/include/net/if.h" 3 4 struct ifnet { void *if_softc; struct { struct ifnet *tqe_next; struct ifnet **tqe_prev; } if_list; struct { struct ifaddr *tqh_first; struct ifaddr **tqh_last; } if_addrlist; struct { struct ifg_list *tqh_first; struct ifg_list **tqh_last; } if_groups; struct hook_desc_head *if_addrhooks; char if_xname[16]; int if_pcount; caddr_t if_bpf; caddr_t if_bridge; union { caddr_t carp_s; struct ifnet *carp_d; } if_carp_ptr; u_short if_index; short if_timer; short if_flags; struct if_data if_data; int if_capabilities; char if_description[64]; int (*if_output)(struct ifnet *, struct mbuf *, struct sockaddr *, struct rtentry *); void (*if_start)(struct ifnet *); int (*if_ioctl)(struct ifnet *, u_long, caddr_t); int (*if_init)(struct ifnet *); int (*if_reset)(struct ifnet *); void (*if_watchdog)(struct ifnet *); struct ifaltq if_snd; struct sockaddr_dl *if_sadl; void *if_afdata[33]; }; # 346 "/usr/include/net/if.h" 3 4 struct ifaddr { struct sockaddr *ifa_addr; struct sockaddr *ifa_dstaddr; struct sockaddr *ifa_netmask; struct ifnet *ifa_ifp; struct { struct ifaddr *tqe_next; struct ifaddr **tqe_prev; } ifa_list; void (*ifa_rtrequest)(int, struct rtentry *, struct rt_addrinfo *); u_int ifa_flags; u_int ifa_refcnt; int ifa_metric; }; struct if_msghdr { u_short ifm_msglen; u_char ifm_version; u_char ifm_type; int ifm_addrs; int ifm_flags; u_short ifm_index; struct if_data ifm_data; }; struct ifa_msghdr { u_short ifam_msglen; u_char ifam_version; u_char ifam_type; int ifam_addrs; int ifam_flags; u_short ifam_index; int ifam_metric; }; struct if_announcemsghdr { u_short ifan_msglen; u_char ifan_version; u_char ifan_type; u_short ifan_index; char ifan_name[16]; u_short ifan_what; }; struct ifg_group { char ifg_group[16]; u_int ifg_refcnt; struct { struct ifg_group *tqe_next; struct ifg_group **tqe_prev; } ifg_next; }; struct ifg_list { struct ifg_group *ifgl_group; struct { struct ifg_list *tqe_next; struct ifg_list **tqe_prev; } ifgl_next; }; struct ifg_req { char ifgrq_group[16]; }; struct ifgroupreq { char ifgr_name[16]; u_int ifgr_len; union { char ifgru_group[16]; struct ifg_req *ifgru_groups; } ifgr_ifgru; }; struct ifreq { char ifr_name[16]; union { struct sockaddr ifru_addr; struct sockaddr ifru_dstaddr; struct sockaddr ifru_broadaddr; short ifru_flags; int ifru_metric; caddr_t ifru_data; } ifr_ifru; # 461 "/usr/include/net/if.h" 3 4 }; struct ifaliasreq { char ifra_name[16]; struct sockaddr ifra_addr; struct sockaddr ifra_dstaddr; struct sockaddr ifra_mask; }; struct ifmediareq { char ifm_name[16]; int ifm_current; int ifm_mask; int ifm_status; int ifm_active; int ifm_count; int *ifm_ulist; }; struct ifconf { int ifc_len; union { caddr_t ifcu_buf; struct ifreq *ifcu_req; } ifc_ifcu; }; struct if_laddrreq { char iflr_name[16]; unsigned int flags; unsigned int prefixlen; struct sockaddr_storage addr; struct sockaddr_storage dstaddr; }; struct if_nameindex { unsigned int if_index; char *if_name; }; unsigned int if_nametoindex(const char *); char *if_indextoname(unsigned int, char *); struct if_nameindex *if_nameindex(void); # 1 "/usr/include/net/if_arp.h" 1 3 4 # 47 "/usr/include/net/if_arp.h" 3 4 struct arphdr { u_int16_t ar_hrd; u_int16_t ar_pro; u_int8_t ar_hln; u_int8_t ar_pln; u_int16_t ar_op; # 73 "/usr/include/net/if_arp.h" 3 4 }; struct arpreq { struct sockaddr arp_pa; struct sockaddr arp_ha; int arp_flags; }; # 525 "/usr/include/net/if.h" 2 3 4 # 40 "mibII/mibII_common.h" 2 # 49 "mibII/mibII_common.h" # 1 "/usr/include/sys/sysctl.h" 1 3 4 # 46 "/usr/include/sys/sysctl.h" 3 4 # 1 "/usr/include/sys/ucred.h" 1 3 4 # 41 "/usr/include/sys/ucred.h" 3 4 struct ucred { u_int cr_ref; uid_t cr_uid; gid_t cr_gid; short cr_ngroups; gid_t cr_groups[16]; }; # 47 "/usr/include/sys/sysctl.h" 2 3 4 # 1 "/usr/include/sys/proc.h" 1 3 4 # 43 "/usr/include/sys/proc.h" 3 4 # 1 "/usr/include/machine/proc.h" 1 3 4 # 38 "/usr/include/machine/proc.h" 3 4 struct mdproc { struct trapframe *md_regs; int md_flags; int md_tss_sel; }; # 44 "/usr/include/sys/proc.h" 2 3 4 # 1 "/usr/include/sys/select.h" 1 3 4 # 38 "/usr/include/sys/select.h" 3 4 # 1 "/usr/include/sys/event.h" 1 3 4 # 52 "/usr/include/sys/event.h" 3 4 struct kevent { u_int ident; short filter; u_short flags; u_int fflags; int data; void *udata; }; # 115 "/usr/include/sys/event.h" 3 4 struct knote; struct klist { struct knote *slh_first; }; # 176 "/usr/include/sys/event.h" 3 4 struct timespec; int kqueue(void); int kevent(int kq, const struct kevent *changelist, int nchanges, struct kevent *eventlist, int nevents, const struct timespec *timeout); # 39 "/usr/include/sys/select.h" 2 3 4 struct selinfo { pid_t si_selpid; struct klist si_note; short si_flags; }; # 45 "/usr/include/sys/proc.h" 2 3 4 # 1 "/usr/include/sys/timeout.h" 1 3 4 # 54 "/usr/include/sys/timeout.h" 3 4 struct circq { struct circq *next; struct circq *prev; }; struct timeout { struct circq to_list; void (*to_func)(void *); void *to_arg; int to_time; int to_flags; }; # 47 "/usr/include/sys/proc.h" 2 3 4 # 56 "/usr/include/sys/proc.h" 3 4 struct session { int s_count; struct proc *s_leader; struct vnode *s_ttyvp; struct tty *s_ttyp; char s_login[32]; }; struct pgrp { struct { struct pgrp *le_next; struct pgrp **le_prev; } pg_hash; struct { struct proc *lh_first; } pg_members; struct session *pg_session; pid_t pg_id; int pg_jobc; }; struct exec_package; struct ps_strings; struct uvm_object; union sigval; struct emul { char e_name[8]; int *e_errno; void (*e_sendsig)(sig_t, int, int, u_long, int, union sigval); int e_nosys; int e_nsysent; struct sysent *e_sysent; char **e_syscallnames; int e_arglen; void *(*e_copyargs)(struct exec_package *, struct ps_strings *, void *, void *); void (*e_setregs)(struct proc *, struct exec_package *, u_long, register_t *); int (*e_fixup)(struct proc *, struct exec_package *); char *e_sigcode; char *e_esigcode; int e_flags; struct uvm_object *e_sigobject; void (*e_proc_exec)(struct proc *, struct exec_package *); void (*e_proc_fork)(struct proc *p, struct proc *parent); void (*e_proc_exit)(struct proc *); }; extern struct emul *emulsw[]; extern int nemuls; # 127 "/usr/include/sys/proc.h" 3 4 struct proc { struct proc *p_forw; struct proc *p_back; struct { struct proc *le_next; struct proc **le_prev; } p_list; struct pcred *p_cred; struct filedesc *p_fd; struct pstats *p_stats; struct plimit *p_limit; struct vmspace *p_vmspace; struct sigacts *p_sigacts; int p_exitsig; int p_flag; u_char p_os; char p_stat; char p_pad1[2]; pid_t p_pid; struct { struct proc *le_next; struct proc **le_prev; } p_hash; struct { struct proc *le_next; struct proc **le_prev; } p_pglist; struct proc *p_pptr; struct { struct proc *le_next; struct proc **le_prev; } p_sibling; struct { struct proc *lh_first; } p_children; pid_t p_oppid; int p_dupfd; u_int p_estcpu; int p_cpticks; fixpt_t p_pctcpu; void *p_wchan; struct timeout p_sleep_to; const char *p_wmesg; u_int p_swtime; u_int p_slptime; struct cpu_info * volatile p_cpu; struct itimerval p_realtimer; struct timeout p_realit_to; struct timeval p_rtime; u_quad_t p_uticks; u_quad_t p_sticks; u_quad_t p_iticks; int p_traceflag; struct vnode *p_tracep; void *p_systrace; int p_siglist; struct vnode *p_textvp; int p_holdcnt; struct emul *p_emul; void *p_emuldata; struct klist p_klist; # 207 "/usr/include/sys/proc.h" 3 4 sigset_t p_sigmask; sigset_t p_sigignore; sigset_t p_sigcatch; u_char p_priority; u_char p_usrpri; char p_nice; char p_comm[16 +1]; struct pgrp *p_pgrp; vaddr_t p_sigcode; struct user *p_addr; struct mdproc p_md; u_short p_xstat; u_short p_acflag; struct rusage *p_ru; int p_locks; }; # 307 "/usr/include/sys/proc.h" 3 4 struct pcred { struct ucred *pc_ucred; uid_t p_ruid; uid_t p_svuid; gid_t p_rgid; gid_t p_svgid; int p_refcnt; }; # 48 "/usr/include/sys/sysctl.h" 2 3 4 # 1 "/usr/include/sys/resource.h" 1 3 4 # 55 "/usr/include/sys/resource.h" 3 4 struct rusage { struct timeval ru_utime; struct timeval ru_stime; long ru_maxrss; long ru_ixrss; long ru_idrss; long ru_isrss; long ru_minflt; long ru_majflt; long ru_nswap; long ru_inblock; long ru_oublock; long ru_msgsnd; long ru_msgrcv; long ru_nsignals; long ru_nvcsw; long ru_nivcsw; }; # 95 "/usr/include/sys/resource.h" 3 4 struct orlimit { int32_t rlim_cur; int32_t rlim_max; }; struct rlimit { rlim_t rlim_cur; rlim_t rlim_max; }; struct loadavg { fixpt_t ldavg[3]; long fscale; }; # 119 "/usr/include/sys/resource.h" 3 4 int getpriority(int, id_t); int getrlimit(int, struct rlimit *); int getrusage(int, struct rusage *); int setpriority(int, id_t, int); int setrlimit(int, const struct rlimit *); # 49 "/usr/include/sys/sysctl.h" 2 3 4 # 1 "/usr/include/sys/resourcevar.h" 1 3 4 # 44 "/usr/include/sys/resourcevar.h" 3 4 struct pstats { struct rusage p_ru; struct rusage p_cru; struct itimerval p_timer[3]; struct uprof { caddr_t pr_base; size_t pr_size; u_long pr_off; u_int pr_scale; u_long pr_addr; } p_prof; struct timeval p_start; struct timeout p_virt_to; struct timeout p_prof_to; }; # 74 "/usr/include/sys/resourcevar.h" 3 4 struct plimit { struct rlimit pl_rlimit[9]; int p_lflags; int p_refcnt; }; # 52 "/usr/include/sys/sysctl.h" 2 3 4 # 1 "/usr/include/uvm/uvm_extern.h" 1 3 4 # 87 "/usr/include/uvm/uvm_extern.h" 3 4 typedef unsigned int uvm_flag_t; typedef int vm_fault_t; typedef int vm_inherit_t; typedef off_t voff_t; union vm_map_object; typedef union vm_map_object vm_map_object_t; struct vm_map_entry; typedef struct vm_map_entry *vm_map_entry_t; struct vm_map; typedef struct vm_map *vm_map_t; struct vm_page; typedef struct vm_page *vm_page_t; # 145 "/usr/include/uvm/uvm_extern.h" 3 4 typedef int vm_prot_t; # 232 "/usr/include/uvm/uvm_extern.h" 3 4 struct buf; struct core; struct mount; struct pglist; struct proc; struct ucred; struct uio; struct uvm_object; struct vm_anon; struct vm_aref; struct vm_map; struct vmspace; struct pmap; struct vnode; struct pool; struct simplelock; extern struct pool *uvm_aiobuf_pool; struct uvmexp { int pagesize; int pagemask; int pageshift; int npages; int free; int active; int inactive; int paging; int wired; int zeropages; int reserve_pagedaemon; int reserve_kernel; int anonpages; int vnodepages; int vtextpages; int freemin; int freetarg; int inactarg; int wiredmax; int anonmin; int vtextmin; int vnodemin; int anonminpct; int vtextminpct; int vnodeminpct; int nswapdev; int swpages; int swpginuse; int swpgonly; int nswget; int nanon; int nanonneeded; int nfreeanon; int faults; int traps; int intrs; int swtch; int softs; int syscalls; int pageins; int swapins; int swapouts; int pgswapin; int pgswapout; int forks; int forks_ppwait; int forks_sharevm; int pga_zerohit; int pga_zeromiss; int zeroaborts; int fltnoram; int fltnoanon; int fltpgwait; int fltpgrele; int fltrelck; int fltrelckok; int fltanget; int fltanretry; int fltamcopy; int fltnamap; int fltnomap; int fltlget; int fltget; int flt_anon; int flt_acow; int flt_obj; int flt_prcopy; int flt_przero; int pdwoke; int pdrevs; int pdswout; int pdfreed; int pdscans; int pdanscan; int pdobscan; int pdreact; int pdbusy; int pdpageouts; int pdpending; int pddeact; int pdreanon; int pdrevnode; int pdrevtext; struct uvm_object *kmem_object; }; # 370 "/usr/include/uvm/uvm_extern.h" 3 4 # 1 "/usr/include/sys/vmmeter.h" 1 3 4 # 44 "/usr/include/sys/vmmeter.h" 3 4 struct vmtotal { u_int16_t t_rq; u_int16_t t_dw; u_int16_t t_pw; u_int16_t t_sl; u_int16_t t_sw; u_int32_t t_vm; u_int32_t t_avm; u_int32_t t_rm; u_int32_t t_arm; u_int32_t t_vmshr; u_int32_t t_avmshr; u_int32_t t_rmshr; u_int32_t t_armshr; u_int32_t t_free; }; struct forkstat { int cntfork; int cntvfork; int cntrfork; int cntkthread; int sizfork; int sizvfork; int sizrfork; int sizkthread; }; # 371 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/sys/tree.h" 1 3 4 # 373 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_param.h" 1 3 4 # 71 "/usr/include/uvm/uvm_param.h" 3 4 # 1 "/usr/include/machine/vmparam.h" 1 3 4 # 116 "/usr/include/machine/vmparam.h" 3 4 struct pmap_physseg { struct pv_head *pvhead; char *attrs; }; # 72 "/usr/include/uvm/uvm_param.h" 2 3 4 typedef int boolean_t; # 132 "/usr/include/uvm/uvm_param.h" 3 4 struct _ps_strings { void *val; }; # 374 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/sys/lock.h" 1 3 4 # 43 "/usr/include/sys/lock.h" 3 4 typedef struct simplelock simple_lock_data_t; typedef struct simplelock *simple_lock_t; typedef struct lock lock_data_t; typedef struct lock *lock_t; struct lock { struct simplelock lk_interlock; u_int lk_flags; int lk_sharecount; int lk_waitcount; short lk_exclusivecount; short lk_recurselevel; char *lk_wmesg; union { struct { pid_t lk_sleep_lockholder; int lk_sleep_prio; int lk_sleep_timo; } lk_un_sleep; struct { cpuid_t lk_spin_cpu; } lk_un_spin; } lk_un; # 102 "/usr/include/sys/lock.h" 3 4 }; # 204 "/usr/include/sys/lock.h" 3 4 struct proc; void lockinit(struct lock *, int prio, char *wmesg, int timo, int flags); int lockmgr(volatile struct lock *, u_int flags, struct simplelock *, struct proc *p); void lockmgr_printinfo(volatile struct lock *); int lockstatus(struct lock *); # 232 "/usr/include/sys/lock.h" 3 4 int spinlock_release_all(volatile struct lock *); void spinlock_acquire_count(volatile struct lock *, int); # 375 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_page.h" 1 3 4 # 118 "/usr/include/uvm/uvm_page.h" 3 4 # 1 "/usr/include/uvm/uvm_extern.h" 1 3 4 # 119 "/usr/include/uvm/uvm_page.h" 2 3 4 # 1 "/usr/include/uvm/uvm_pglist.h" 1 3 4 # 47 "/usr/include/uvm/uvm_pglist.h" 3 4 struct pglist { struct vm_page *tqh_first; struct vm_page **tqh_last; }; # 57 "/usr/include/uvm/uvm_pglist.h" 3 4 struct pgfreelist { struct pglist pgfl_queues[2]; }; # 120 "/usr/include/uvm/uvm_page.h" 2 3 4 struct vm_page { struct { struct vm_page *tqe_next; struct vm_page **tqe_prev; } pageq; struct { struct vm_page *tqe_next; struct vm_page **tqe_prev; } hashq; struct { struct vm_page *tqe_next; struct vm_page **tqe_prev; } listq; struct vm_anon *uanon; struct uvm_object *uobject; voff_t offset; u_short flags; u_short version; u_short wire_count; u_short pqflags; u_int loan_count; paddr_t phys_addr; # 148 "/usr/include/uvm/uvm_page.h" 3 4 }; # 209 "/usr/include/uvm/uvm_page.h" 3 4 struct vm_physseg { paddr_t start; paddr_t end; paddr_t avail_start; paddr_t avail_end; int free_list; struct vm_page *pgs; struct vm_page *lastpg; struct pmap_physseg pmseg; }; # 376 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_pmap.h" 1 3 4 # 72 "/usr/include/uvm/uvm_pmap.h" 3 4 struct proc; struct pmap_statistics { long resident_count; long wired_count; }; typedef struct pmap_statistics *pmap_statistics_t; # 1 "/usr/include/machine/pmap.h" 1 3 4 # 43 "/usr/include/machine/pmap.h" 3 4 # 1 "/usr/include/machine/cpufunc.h" 1 3 4 # 44 "/usr/include/machine/pmap.h" 2 3 4 # 1 "/usr/include/machine/pte.h" 1 3 4 # 137 "/usr/include/machine/pte.h" 3 4 typedef u_int32_t pd_entry_t; typedef u_int32_t pt_entry_t; # 45 "/usr/include/machine/pmap.h" 2 3 4 # 1 "/usr/include/machine/segments.h" 1 3 4 # 79 "/usr/include/machine/segments.h" 3 4 struct segment_descriptor { unsigned sd_lolimit:16; unsigned sd_lobase:24; unsigned sd_type:5; unsigned sd_dpl:2; unsigned sd_p:1; unsigned sd_hilimit:4; unsigned sd_xx:2; unsigned sd_def32:1; unsigned sd_gran:1; unsigned sd_hibase:8; } __attribute__((__packed__)); struct gate_descriptor { unsigned gd_looffset:16; unsigned gd_selector:16; unsigned gd_stkcpy:5; unsigned gd_xx:3; unsigned gd_type:5; unsigned gd_dpl:2; unsigned gd_p:1; unsigned gd_hioffset:16; } __attribute__((__packed__)); union descriptor { struct segment_descriptor sd; struct gate_descriptor gd; } __attribute__((__packed__)); struct region_descriptor { unsigned rd_limit:16; unsigned rd_base:32; } __attribute__((__packed__)); # 46 "/usr/include/machine/pmap.h" 2 3 4 # 1 "/usr/include/uvm/uvm_object.h" 1 3 4 # 49 "/usr/include/uvm/uvm_object.h" 3 4 struct uvm_object { simple_lock_data_t vmobjlock; struct uvm_pagerops *pgops; struct pglist memq; int uo_npages; int uo_refs; }; # 48 "/usr/include/machine/pmap.h" 2 3 4 # 87 "/usr/include/uvm/uvm_pmap.h" 2 3 4 # 377 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_map.h" 1 3 4 # 113 "/usr/include/uvm/uvm_map.h" 3 4 # 1 "/usr/include/uvm/uvm_anon.h" 1 3 4 # 51 "/usr/include/uvm/uvm_anon.h" 3 4 struct vm_anon { int an_ref; simple_lock_data_t an_lock; union { struct vm_anon *an_nxt; struct vm_page *an_page; } u; int an_swslot; }; # 86 "/usr/include/uvm/uvm_anon.h" 3 4 struct vm_aref { int ar_pageoff; struct vm_amap *ar_amap; }; # 114 "/usr/include/uvm/uvm_map.h" 2 3 4 # 130 "/usr/include/uvm/uvm_map.h" 3 4 union vm_map_object { struct uvm_object *uvm_obj; struct vm_map *sub_map; }; struct vm_map_entry { struct { struct vm_map_entry *rbe_left; struct vm_map_entry *rbe_right; struct vm_map_entry *rbe_parent; int rbe_color; } rb_entry; vaddr_t ownspace; vaddr_t space; struct vm_map_entry *prev; struct vm_map_entry *next; vaddr_t start; vaddr_t end; union vm_map_object object; voff_t offset; int etype; vm_prot_t protection; vm_prot_t max_protection; vm_inherit_t inheritance; int wired_count; struct vm_aref aref; int advice; u_int8_t flags; }; # 220 "/usr/include/uvm/uvm_map.h" 3 4 struct vm_map { struct pmap * pmap; lock_data_t lock; struct uvm_tree { struct vm_map_entry *rbh_root; } rbhead; struct vm_map_entry header; int nentries; vsize_t size; int ref_count; simple_lock_data_t ref_lock; vm_map_entry_t hint; simple_lock_data_t hint_lock; vm_map_entry_t first_free; int flags; simple_lock_data_t flags_lock; unsigned int timestamp; }; # 275 "/usr/include/uvm/uvm_map.h" 3 4 struct vm_map_intrsafe { struct vm_map vmi_map; struct { struct vm_map_intrsafe *le_next; struct vm_map_intrsafe **le_prev; } vmi_list; }; struct vmi_list { struct vm_map_intrsafe *lh_first; }; # 378 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_fault.h" 1 3 4 # 59 "/usr/include/uvm/uvm_fault.h" 3 4 struct uvm_faultinfo { vm_map_t orig_map; vaddr_t orig_rvaddr; vsize_t orig_size; vm_map_t map; unsigned int mapv; vm_map_entry_t entry; vsize_t size; }; # 379 "/usr/include/uvm/uvm_extern.h" 2 3 4 # 1 "/usr/include/uvm/uvm_pager.h" 1 3 4 # 85 "/usr/include/uvm/uvm_pager.h" 3 4 struct uvm_pagerops { void (*pgo_init)(void); void (*pgo_reference)(struct uvm_object *); void (*pgo_detach)(struct uvm_object *); int (*pgo_fault)(struct uvm_faultinfo *, vaddr_t, vm_page_t *, int, int, vm_fault_t, vm_prot_t, int); boolean_t (*pgo_flush)(struct uvm_object *, voff_t, voff_t, int); int (*pgo_get)(struct uvm_object *, voff_t, vm_page_t *, int *, int, vm_prot_t, int, int); int (*pgo_put)(struct uvm_object *, vm_page_t *, int, boolean_t); void (*pgo_cluster)(struct uvm_object *, voff_t, voff_t *, voff_t *); struct vm_page ** (*pgo_mk_pcluster)(struct uvm_object *, struct vm_page **, int *, struct vm_page *, int, voff_t, voff_t); boolean_t (*pgo_releasepg)(struct vm_page *, struct vm_page **); }; # 380 "/usr/include/uvm/uvm_extern.h" 2 3 4 struct vmspace { struct vm_map vm_map; int vm_refcnt; caddr_t vm_shm; segsz_t vm_rssize; segsz_t vm_swrss; segsz_t vm_tsize; segsz_t vm_dsize; segsz_t vm_ssize; caddr_t vm_taddr; caddr_t vm_daddr; caddr_t vm_maxsaddr; caddr_t vm_minsaddr; }; # 432 "/usr/include/uvm/uvm_extern.h" 3 4 struct buf; struct loadavg; struct proc; struct pmap; struct vmspace; struct vmtotal; struct mount; struct vnode; struct core; # 54 "/usr/include/sys/sysctl.h" 2 3 4 # 73 "/usr/include/sys/sysctl.h" 3 4 struct ctlname { char *ctl_name; int ctl_type; }; # 301 "/usr/include/sys/sysctl.h" 3 4 struct kinfo_proc { struct proc kp_proc; struct eproc { struct proc *e_paddr; struct session *e_sess; struct pcred e_pcred; struct ucred e_ucred; struct vmspace e_vm; struct pstats e_pstats; int e_pstats_valid; pid_t e_ppid; pid_t e_pgid; short e_jobc; dev_t e_tdev; pid_t e_tpgid; struct session *e_tsess; char e_wmesg[7 +1]; segsz_t e_xsize; short e_xrssize; short e_xccount; short e_xswrss; long e_flag; char e_login[32]; char e_emul[7 +1]; rlim_t e_maxrss; } kp_eproc; }; # 347 "/usr/include/sys/sysctl.h" 3 4 struct kinfo_proc2 { u_int64_t p_forw; u_int64_t p_back; u_int64_t p_paddr; u_int64_t p_addr; u_int64_t p_fd; u_int64_t p_stats; u_int64_t p_limit; u_int64_t p_vmspace; u_int64_t p_sigacts; u_int64_t p_sess; u_int64_t p_tsess; u_int64_t p_ru; int32_t p_eflag; int32_t p_exitsig; int32_t p_flag; int32_t p_pid; int32_t p_ppid; int32_t p_sid; int32_t p__pgid; int32_t p_tpgid; u_int32_t p_uid; u_int32_t p_ruid; u_int32_t p_gid; u_int32_t p_rgid; u_int32_t p_groups[16]; int16_t p_ngroups; int16_t p_jobc; u_int32_t p_tdev; u_int32_t p_estcpu; u_int32_t p_rtime_sec; u_int32_t p_rtime_usec; int32_t p_cpticks; u_int32_t p_pctcpu; u_int32_t p_swtime; u_int32_t p_slptime; int32_t p_schedflags; u_int64_t p_uticks; u_int64_t p_sticks; u_int64_t p_iticks; u_int64_t p_tracep; int32_t p_traceflag; int32_t p_holdcnt; int32_t p_siglist; u_int32_t p_sigmask; u_int32_t p_sigignore; u_int32_t p_sigcatch; int8_t p_stat; u_int8_t p_priority; u_int8_t p_usrpri; u_int8_t p_nice; u_int16_t p_xstat; u_int16_t p_acflag; char p_comm[24]; char p_wmesg[8]; u_int64_t p_wchan; char p_login[32]; int32_t p_vm_rssize; int32_t p_vm_tsize; int32_t p_vm_dsize; int32_t p_vm_ssize; int64_t p_uvalid; u_int32_t p_ustart_sec; u_int32_t p_ustart_usec; u_int32_t p_uutime_sec; u_int32_t p_uutime_usec; u_int32_t p_ustime_sec; u_int32_t p_ustime_usec; u_int64_t p_uru_maxrss; u_int64_t p_uru_ixrss; u_int64_t p_uru_idrss; u_int64_t p_uru_isrss; u_int64_t p_uru_minflt; u_int64_t p_uru_majflt; u_int64_t p_uru_nswap; u_int64_t p_uru_inblock; u_int64_t p_uru_oublock; u_int64_t p_uru_msgsnd; u_int64_t p_uru_msgrcv; u_int64_t p_uru_nsignals; u_int64_t p_uru_nvcsw; u_int64_t p_uru_nivcsw; u_int32_t p_uctime_sec; u_int32_t p_uctime_usec; u_int64_t p_realflag; u_int32_t p_svuid; u_int32_t p_svgid; char p_emul[8]; u_int64_t p_rlim_rss_cur; u_int64_t p_cpuid; }; # 720 "/usr/include/sys/sysctl.h" 3 4 int sysctl(int *, u_int, void *, size_t *, void *, size_t); # 50 "mibII/mibII_common.h" 2 # 1 "/usr/include/net/route.h" 1 3 4 # 52 "/usr/include/net/route.h" 3 4 struct route { struct rtentry *ro_rt; struct sockaddr ro_dst; }; struct rt_kmetrics { u_long rmx_locks; u_long rmx_mtu; u_long rmx_expire; u_long rmx_pksent; }; struct rt_metrics { u_long rmx_locks; u_long rmx_mtu; u_long rmx_hopcount; u_long rmx_expire; u_long rmx_recvpipe; u_long rmx_sendpipe; u_long rmx_ssthresh; u_long rmx_rtt; u_long rmx_rttvar; u_long rmx_pksent; }; # 101 "/usr/include/net/route.h" 3 4 # 1 "/usr/include/net/radix.h" 1 3 4 # 42 "/usr/include/net/radix.h" 3 4 struct radix_node { struct radix_mask *rn_mklist; struct radix_node *rn_p; short rn_b; char rn_bmask; u_char rn_flags; union { struct { caddr_t rn_Key; caddr_t rn_Mask; struct radix_node *rn_Dupedkey; } rn_leaf; struct { int rn_Off; struct radix_node *rn_L; struct radix_node *rn_R; } rn_node; } rn_u; }; # 81 "/usr/include/net/radix.h" 3 4 extern struct radix_mask { short rm_b; char rm_unused; u_char rm_flags; struct radix_mask *rm_mklist; union { caddr_t rmu_mask; struct radix_node *rmu_leaf; } rm_rmu; int rm_refs; } *rn_mkfreelist; # 105 "/usr/include/net/radix.h" 3 4 struct radix_node_head { struct radix_node *rnh_treetop; int rnh_addrsize; int rnh_pktsize; struct radix_node *(*rnh_addaddr)(void *v, void *mask, struct radix_node_head *head, struct radix_node nodes[]); struct radix_node *(*rnh_addpkt)(void *v, void *mask, struct radix_node_head *head, struct radix_node nodes[]); struct radix_node *(*rnh_deladdr)(void *v, void *mask, struct radix_node_head *head, struct radix_node *rn); struct radix_node *(*rnh_delpkt)(void *v, void *mask, struct radix_node_head *head); struct radix_node *(*rnh_matchaddr)(void *v, struct radix_node_head *head); struct radix_node *(*rnh_lookup)(void *v, void *mask, struct radix_node_head *head); struct radix_node *(*rnh_matchpkt)(void *v, struct radix_node_head *head); int (*rnh_walktree)(struct radix_node_head *, int (*)(struct radix_node *, void *), void *); struct radix_node rnh_nodes[3]; int rnh_multipath; }; # 102 "/usr/include/net/route.h" 2 3 4 # 1 "/usr/include/net/radix_mpath.h" 1 3 4 # 103 "/usr/include/net/route.h" 2 3 4 struct rtentry { struct radix_node rt_nodes[2]; struct sockaddr *rt_gateway; u_int rt_flags; int rt_refcnt; struct ifnet *rt_ifp; struct ifaddr *rt_ifa; struct sockaddr *rt_genmask; caddr_t rt_llinfo; struct rt_kmetrics rt_rmx; struct rtentry *rt_gwroute; struct rtentry *rt_parent; struct { struct rttimer *lh_first; } rt_timer; u_int16_t rt_labelid; }; struct ortentry { u_int32_t rt_hash; struct sockaddr rt_dst; struct sockaddr rt_gateway; int16_t rt_flags; int16_t rt_refcnt; u_int32_t rt_ouse; struct ifnet *rt_ifp; }; # 165 "/usr/include/net/route.h" 3 4 struct rtstat { u_int32_t rts_badredirect; u_int32_t rts_dynamic; u_int32_t rts_newgateway; u_int32_t rts_unreach; u_int32_t rts_wildcard; }; struct rt_msghdr { u_short rtm_msglen; u_char rtm_version; u_char rtm_type; u_short rtm_index; int rtm_flags; int rtm_addrs; pid_t rtm_pid; int rtm_seq; int rtm_errno; int rtm_use; u_long rtm_inits; struct rt_metrics rtm_rmx; }; # 249 "/usr/include/net/route.h" 3 4 struct rt_addrinfo { int rti_addrs; struct sockaddr *rti_info[11]; int rti_flags; struct ifaddr *rti_ifa; struct ifnet *rti_ifp; struct rt_msghdr *rti_rtm; }; struct route_cb { int ip_count; int ip6_count; int ns_count; int iso_count; int any_count; }; struct rttimer { struct { struct rttimer *tqe_next; struct rttimer **tqe_prev; } rtt_next; struct { struct rttimer *le_next; struct rttimer **le_prev; } rtt_link; struct rttimer_queue *rtt_queue; struct rtentry *rtt_rt; void (*rtt_func)(struct rtentry *, struct rttimer *); time_t rtt_time; }; struct rttimer_queue { long rtq_timeout; unsigned long rtq_count; struct { struct rttimer *tqh_first; struct rttimer **tqh_last; } rtq_head; struct { struct rttimer_queue *le_next; struct rttimer_queue **le_prev; } rtq_link; }; struct sockaddr_rtlabel { u_int8_t sr_len; sa_family_t sr_family; char sr_label[32]; }; const char *rtlabel_id2name(u_int16_t); u_int16_t rtlabel_name2id(char *); void rtlabel_unref(u_int16_t); # 56 "mibII/mibII_common.h" 2 # 1 "/usr/include/netinet/in_systm.h" 1 3 4 # 51 "/usr/include/netinet/in_systm.h" 3 4 typedef u_int16_t n_short; typedef u_int32_t n_long; typedef u_int32_t n_time; # 59 "mibII/mibII_common.h" 2 # 1 "/usr/include/netinet/ip.h" 1 3 4 # 47 "/usr/include/netinet/ip.h" 3 4 struct ip { u_int8_t ip_hl:4, ip_v:4; u_int8_t ip_tos; u_int16_t ip_len; u_int16_t ip_id; u_int16_t ip_off; u_int8_t ip_ttl; u_int8_t ip_p; u_int16_t ip_sum; struct in_addr ip_src, ip_dst; }; # 140 "/usr/include/netinet/ip.h" 3 4 struct ip_timestamp { u_int8_t ipt_code; u_int8_t ipt_len; u_int8_t ipt_ptr; u_int8_t ipt_flg:4, ipt_oflw:4; union ipt_timestamp { n_time ipt_time[1]; struct ipt_ta { struct in_addr ipt_addr; n_time ipt_time; } ipt_ta[1]; } ipt_timestamp; }; # 190 "/usr/include/netinet/ip.h" 3 4 struct ippseudo { struct in_addr ippseudo_src; struct in_addr ippseudo_dst; u_int8_t ippseudo_pad; u_int8_t ippseudo_p; u_int16_t ippseudo_len; }; # 62 "mibII/mibII_common.h" 2 # 1 "/usr/include/sys/socketvar.h" 1 3 4 # 38 "/usr/include/sys/socketvar.h" 3 4 struct soqhead { struct socket *tqh_first; struct socket **tqh_last; }; struct socket { short so_type; short so_options; short so_linger; short so_state; void *so_pcb; struct protosw *so_proto; # 64 "/usr/include/sys/socketvar.h" 3 4 struct socket *so_head; struct soqhead *so_onq; struct soqhead so_q0; struct soqhead so_q; struct { struct socket *tqe_next; struct socket **tqe_prev; } so_qe; short so_q0len; short so_qlen; short so_qlimit; short so_timeo; u_short so_error; pid_t so_pgid; uid_t so_siguid; uid_t so_sigeuid; u_long so_oobmark; struct sockbuf { u_long sb_cc; u_long sb_hiwat; u_long sb_mbcnt; u_long sb_mbmax; long sb_lowat; struct mbuf *sb_mb; struct mbuf *sb_mbtail; struct mbuf *sb_lastrecord; struct selinfo sb_sel; short sb_flags; short sb_timeo; } so_rcv, so_snd; # 104 "/usr/include/sys/socketvar.h" 3 4 void *so_internal; void (*so_upcall)(struct socket *so, caddr_t arg, int waitf); caddr_t so_upcallarg; uid_t so_euid, so_ruid; gid_t so_egid, so_rgid; }; # 68 "mibII/mibII_common.h" 2 # 1 "/usr/include/netinet/ip_var.h" 1 3 4 # 43 "/usr/include/netinet/ip_var.h" 3 4 struct ipovly { u_int8_t ih_x1[9]; u_int8_t ih_pr; u_int16_t ih_len; struct in_addr ih_src; struct in_addr ih_dst; }; # 62 "/usr/include/netinet/ip_var.h" 3 4 struct ipqehead { struct ipqent *lh_first; }; struct ipqent { struct { struct ipqent *le_next; struct ipqent **le_prev; } ipqe_q; union { struct ip *_ip; struct tcphdr *_tcp; } _ipqe_u1; struct mbuf *ipqe_m; u_int8_t ipqe_mff; }; # 81 "/usr/include/netinet/ip_var.h" 3 4 struct ipq { struct { struct ipq *le_next; struct ipq **le_prev; } ipq_q; u_int8_t ipq_ttl; u_int8_t ipq_p; u_int16_t ipq_id; struct ipqehead ipq_fragq; struct in_addr ipq_src, ipq_dst; }; # 98 "/usr/include/netinet/ip_var.h" 3 4 struct ipoption { struct in_addr ipopt_dst; int8_t ipopt_list[40]; }; struct ip_moptions { struct ifnet *imo_multicast_ifp; u_int8_t imo_multicast_ttl; u_int8_t imo_multicast_loop; u_int16_t imo_num_memberships; struct in_multi *imo_membership[20]; }; struct ipstat { u_long ips_total; u_long ips_badsum; u_long ips_tooshort; u_long ips_toosmall; u_long ips_badhlen; u_long ips_badlen; u_long ips_fragments; u_long ips_fragdropped; u_long ips_fragtimeout; u_long ips_forward; u_long ips_cantforward; u_long ips_redirectsent; u_long ips_noproto; u_long ips_delivered; u_long ips_localout; u_long ips_odropped; u_long ips_reassembled; u_long ips_fragmented; u_long ips_ofragments; u_long ips_cantfrag; u_long ips_badoptions; u_long ips_noroute; u_long ips_badvers; u_long ips_rawout; u_long ips_badfrags; u_long ips_rcvmemdrop; u_long ips_toolong; u_long ips_nogif; u_long ips_badaddr; u_long ips_inhwcsum; u_long ips_outhwcsum; }; # 71 "mibII/mibII_common.h" 2 # 1 "/usr/include/netinet/in_pcb.h" 1 3 4 # 68 "/usr/include/netinet/in_pcb.h" 3 4 # 1 "/usr/include/netinet/ip6.h" 1 3 4 # 72 "/usr/include/netinet/ip6.h" 3 4 struct ip6_hdr { union { struct ip6_hdrctl { u_int32_t ip6_un1_flow; u_int16_t ip6_un1_plen; u_int8_t ip6_un1_nxt; u_int8_t ip6_un1_hlim; } ip6_un1; u_int8_t ip6_un2_vfc; } ip6_ctlun; struct in6_addr ip6_src; struct in6_addr ip6_dst; } __attribute__((__packed__)); # 128 "/usr/include/netinet/ip6.h" 3 4 struct ip6_ext { u_int8_t ip6e_nxt; u_int8_t ip6e_len; } __attribute__((__packed__)); struct ip6_hbh { u_int8_t ip6h_nxt; u_int8_t ip6h_len; } __attribute__((__packed__)); struct ip6_dest { u_int8_t ip6d_nxt; u_int8_t ip6d_len; } __attribute__((__packed__)); # 173 "/usr/include/netinet/ip6.h" 3 4 struct ip6_opt { u_int8_t ip6o_type; u_int8_t ip6o_len; } __attribute__((__packed__)); struct ip6_opt_jumbo { u_int8_t ip6oj_type; u_int8_t ip6oj_len; u_int8_t ip6oj_jumbo_len[4]; } __attribute__((__packed__)); struct ip6_opt_nsap { u_int8_t ip6on_type; u_int8_t ip6on_len; u_int8_t ip6on_src_nsap_len; u_int8_t ip6on_dst_nsap_len; } __attribute__((__packed__)); struct ip6_opt_tunnel { u_int8_t ip6ot_type; u_int8_t ip6ot_len; u_int8_t ip6ot_encap_limit; } __attribute__((__packed__)); struct ip6_opt_router { u_int8_t ip6or_type; u_int8_t ip6or_len; u_int8_t ip6or_value[2]; } __attribute__((__packed__)); # 223 "/usr/include/netinet/ip6.h" 3 4 struct ip6_rthdr { u_int8_t ip6r_nxt; u_int8_t ip6r_len; u_int8_t ip6r_type; u_int8_t ip6r_segleft; } __attribute__((__packed__)); struct ip6_rthdr0 { u_int8_t ip6r0_nxt; u_int8_t ip6r0_len; u_int8_t ip6r0_type; u_int8_t ip6r0_segleft; u_int32_t ip6r0_reserved; } __attribute__((__packed__)); struct ip6_frag { u_int8_t ip6f_nxt; u_int8_t ip6f_reserved; u_int16_t ip6f_offlg; u_int32_t ip6f_ident; } __attribute__((__packed__)); # 69 "/usr/include/netinet/in_pcb.h" 2 3 4 # 1 "/usr/include/netinet6/ip6_var.h" 1 3 4 # 71 "/usr/include/netinet6/ip6_var.h" 3 4 struct ip6q { u_int32_t ip6q_head; u_int16_t ip6q_len; u_int8_t ip6q_nxt; u_int8_t ip6q_hlim; struct ip6asfrag *ip6q_down; struct ip6asfrag *ip6q_up; u_int32_t ip6q_ident; u_int8_t ip6q_arrive; u_int8_t ip6q_ttl; struct in6_addr ip6q_src, ip6q_dst; struct ip6q *ip6q_next; struct ip6q *ip6q_prev; int ip6q_unfrglen; int ip6q_nfrag; }; struct ip6asfrag { u_int32_t ip6af_head; u_int16_t ip6af_len; u_int8_t ip6af_nxt; u_int8_t ip6af_hlim; struct ip6asfrag *ip6af_down; struct ip6asfrag *ip6af_up; struct mbuf *ip6af_m; int ip6af_offset; int ip6af_frglen; int ip6af_off; u_int16_t ip6af_mff; }; struct ip6_moptions { struct ifnet *im6o_multicast_ifp; u_char im6o_multicast_hlim; u_char im6o_multicast_loop; struct { struct in6_multi_mship *lh_first; } im6o_memberships; }; struct ip6po_rhinfo { struct ip6_rthdr *ip6po_rhi_rthdr; struct route_in6 ip6po_rhi_route; }; struct ip6_pktopts { struct mbuf *ip6po_m; int ip6po_hlim; struct in6_pktinfo *ip6po_pktinfo; struct sockaddr *ip6po_nexthop; struct ip6_hbh *ip6po_hbh; struct ip6_dest *ip6po_dest1; struct ip6po_rhinfo ip6po_rhinfo; struct ip6_dest *ip6po_dest2; }; struct ip6stat { u_quad_t ip6s_total; u_quad_t ip6s_tooshort; u_quad_t ip6s_toosmall; u_quad_t ip6s_fragments; u_quad_t ip6s_fragdropped; u_quad_t ip6s_fragtimeout; u_quad_t ip6s_fragoverflow; u_quad_t ip6s_forward; u_quad_t ip6s_cantforward; u_quad_t ip6s_redirectsent; u_quad_t ip6s_delivered; u_quad_t ip6s_localout; u_quad_t ip6s_odropped; u_quad_t ip6s_reassembled; u_quad_t ip6s_fragmented; u_quad_t ip6s_ofragments; u_quad_t ip6s_cantfrag; u_quad_t ip6s_badoptions; u_quad_t ip6s_noroute; u_quad_t ip6s_badvers; u_quad_t ip6s_rawout; u_quad_t ip6s_badscope; u_quad_t ip6s_notmember; u_quad_t ip6s_nxthist[256]; u_quad_t ip6s_m1; u_quad_t ip6s_m2m[32]; u_quad_t ip6s_mext1; u_quad_t ip6s_mext2m; u_quad_t ip6s_exthdrtoolong; u_quad_t ip6s_nogif; u_quad_t ip6s_toomanyhdr; u_quad_t ip6s_sources_none; u_quad_t ip6s_sources_sameif[16]; u_quad_t ip6s_sources_otherif[16]; u_quad_t ip6s_sources_samescope[16]; u_quad_t ip6s_sources_otherscope[16]; u_quad_t ip6s_sources_deprecated[16]; u_quad_t ip6s_forward_cachehit; u_quad_t ip6s_forward_cachemiss; }; # 70 "/usr/include/netinet/in_pcb.h" 2 3 4 # 1 "/usr/include/netinet/icmp6.h" 1 3 4 # 70 "/usr/include/netinet/icmp6.h" 3 4 struct icmp6_hdr { u_int8_t icmp6_type; u_int8_t icmp6_code; u_int16_t icmp6_cksum; union { u_int32_t icmp6_un_data32[1]; u_int16_t icmp6_un_data16[2]; u_int8_t icmp6_un_data8[4]; } icmp6_dataun; } __attribute__((__packed__)); # 175 "/usr/include/netinet/icmp6.h" 3 4 struct mld_hdr { struct icmp6_hdr mld_icmp6_hdr; struct in6_addr mld_addr; } __attribute__((__packed__)); # 202 "/usr/include/netinet/icmp6.h" 3 4 struct nd_router_solicit { struct icmp6_hdr nd_rs_hdr; } __attribute__((__packed__)); struct nd_router_advert { struct icmp6_hdr nd_ra_hdr; u_int32_t nd_ra_reachable; u_int32_t nd_ra_retransmit; } __attribute__((__packed__)); # 228 "/usr/include/netinet/icmp6.h" 3 4 struct nd_neighbor_solicit { struct icmp6_hdr nd_ns_hdr; struct in6_addr nd_ns_target; } __attribute__((__packed__)); struct nd_neighbor_advert { struct icmp6_hdr nd_na_hdr; struct in6_addr nd_na_target; } __attribute__((__packed__)); # 261 "/usr/include/netinet/icmp6.h" 3 4 struct nd_redirect { struct icmp6_hdr nd_rd_hdr; struct in6_addr nd_rd_target; struct in6_addr nd_rd_dst; } __attribute__((__packed__)); struct nd_opt_hdr { u_int8_t nd_opt_type; u_int8_t nd_opt_len; } __attribute__((__packed__)); struct nd_opt_prefix_info { u_int8_t nd_opt_pi_type; u_int8_t nd_opt_pi_len; u_int8_t nd_opt_pi_prefix_len; u_int8_t nd_opt_pi_flags_reserved; u_int32_t nd_opt_pi_valid_time; u_int32_t nd_opt_pi_preferred_time; u_int32_t nd_opt_pi_reserved2; struct in6_addr nd_opt_pi_prefix; } __attribute__((__packed__)); struct nd_opt_rd_hdr { u_int8_t nd_opt_rh_type; u_int8_t nd_opt_rh_len; u_int16_t nd_opt_rh_reserved1; u_int32_t nd_opt_rh_reserved2; } __attribute__((__packed__)); struct nd_opt_mtu { u_int8_t nd_opt_mtu_type; u_int8_t nd_opt_mtu_len; u_int16_t nd_opt_mtu_reserved; u_int32_t nd_opt_mtu_mtu; } __attribute__((__packed__)); struct icmp6_namelookup { struct icmp6_hdr icmp6_nl_hdr; u_int8_t icmp6_nl_nonce[8]; int32_t icmp6_nl_ttl; } __attribute__((__packed__)); struct icmp6_nodeinfo { struct icmp6_hdr icmp6_ni_hdr; u_int8_t icmp6_ni_nonce[8]; } __attribute__((__packed__)); # 395 "/usr/include/netinet/icmp6.h" 3 4 struct ni_reply_fqdn { u_int32_t ni_fqdn_ttl; u_int8_t ni_fqdn_namelen; u_int8_t ni_fqdn_name[3]; } __attribute__((__packed__)); struct icmp6_router_renum { struct icmp6_hdr rr_hdr; u_int8_t rr_segnum; u_int8_t rr_flags; u_int16_t rr_maxdelay; u_int32_t rr_reserved; } __attribute__((__packed__)); # 423 "/usr/include/netinet/icmp6.h" 3 4 struct rr_pco_match { u_int8_t rpm_code; u_int8_t rpm_len; u_int8_t rpm_ordinal; u_int8_t rpm_matchlen; u_int8_t rpm_minlen; u_int8_t rpm_maxlen; u_int16_t rpm_reserved; struct in6_addr rpm_prefix; } __attribute__((__packed__)); struct rr_pco_use { u_int8_t rpu_uselen; u_int8_t rpu_keeplen; u_int8_t rpu_ramask; u_int8_t rpu_raflags; u_int32_t rpu_vltime; u_int32_t rpu_pltime; u_int32_t rpu_flags; struct in6_addr rpu_prefix; } __attribute__((__packed__)); # 460 "/usr/include/netinet/icmp6.h" 3 4 struct rr_result { u_int16_t rrr_flags; u_int8_t rrr_ordinal; u_int8_t rrr_matchedlen; u_int32_t rrr_ifid; struct in6_addr rrr_prefix; } __attribute__((__packed__)); # 479 "/usr/include/netinet/icmp6.h" 3 4 struct icmp6_filter { u_int32_t icmp6_filt[8]; }; # 513 "/usr/include/netinet/icmp6.h" 3 4 struct icmp6errstat { u_quad_t icp6errs_dst_unreach_noroute; u_quad_t icp6errs_dst_unreach_admin; u_quad_t icp6errs_dst_unreach_beyondscope; u_quad_t icp6errs_dst_unreach_addr; u_quad_t icp6errs_dst_unreach_noport; u_quad_t icp6errs_packet_too_big; u_quad_t icp6errs_time_exceed_transit; u_quad_t icp6errs_time_exceed_reassembly; u_quad_t icp6errs_paramprob_header; u_quad_t icp6errs_paramprob_nextheader; u_quad_t icp6errs_paramprob_option; u_quad_t icp6errs_redirect; u_quad_t icp6errs_unknown; }; struct icmp6stat { u_quad_t icp6s_error; u_quad_t icp6s_canterror; u_quad_t icp6s_toofreq; u_quad_t icp6s_outhist[256]; u_quad_t icp6s_badcode; u_quad_t icp6s_tooshort; u_quad_t icp6s_checksum; u_quad_t icp6s_badlen; u_quad_t icp6s_reflect; u_quad_t icp6s_inhist[256]; u_quad_t icp6s_nd_toomanyopt; struct icmp6errstat icp6s_outerrhist; # 566 "/usr/include/netinet/icmp6.h" 3 4 u_quad_t icp6s_pmtuchg; u_quad_t icp6s_nd_badopt; u_quad_t icp6s_badns; u_quad_t icp6s_badna; u_quad_t icp6s_badrs; u_quad_t icp6s_badra; u_quad_t icp6s_badredirect; }; # 71 "/usr/include/netinet/in_pcb.h" 2 3 4 # 1 "/usr/include/netinet/ip_ipsp.h" 1 3 4 # 50 "/usr/include/netinet/ip_ipsp.h" 3 4 union sockaddr_union { struct sockaddr sa; struct sockaddr_in sin; struct sockaddr_in6 sin6; }; # 104 "/usr/include/netinet/ip_ipsp.h" 3 4 struct sockaddr_encap { u_int8_t sen_len; u_int8_t sen_family; u_int16_t sen_type; union { struct { u_int8_t Direction; struct in_addr Src; struct in_addr Dst; u_int8_t Proto; u_int16_t Sport; u_int16_t Dport; } Sip4; struct { u_int8_t Direction; struct in6_addr Src; struct in6_addr Dst; u_int8_t Proto; u_int16_t Sport; u_int16_t Dport; } Sip6; struct ipsec_policy *PolicyHead; } Sen; }; # 163 "/usr/include/netinet/ip_ipsp.h" 3 4 struct ipsec_ref { u_int16_t ref_type; int16_t ref_len; int ref_count; int ref_malloctype; }; struct ipsec_acquire { union sockaddr_union ipa_addr; u_int32_t ipa_seq; struct sockaddr_encap ipa_info; struct sockaddr_encap ipa_mask; struct timeout ipa_timeout; struct ipsec_policy *ipa_policy; struct inpcb *ipa_pcb; struct { struct ipsec_acquire *tqe_next; struct ipsec_acquire **tqe_prev; } ipa_ipo_next; struct { struct ipsec_acquire *tqe_next; struct ipsec_acquire **tqe_prev; } ipa_next; struct { struct ipsec_acquire *tqe_next; struct ipsec_acquire **tqe_prev; } ipa_inp_next; }; struct ipsec_policy { struct sockaddr_encap ipo_addr; struct sockaddr_encap ipo_mask; union sockaddr_union ipo_src; union sockaddr_union ipo_dst; # 197 "/usr/include/netinet/ip_ipsp.h" 3 4 u_int64_t ipo_last_searched; u_int8_t ipo_flags; u_int8_t ipo_type; u_int8_t ipo_sproto; int ipo_ref_count; struct tdb *ipo_tdb; struct ipsec_ref *ipo_srcid; struct ipsec_ref *ipo_dstid; struct ipsec_ref *ipo_local_cred; struct ipsec_ref *ipo_local_auth; struct ipo_acquires_head { struct ipsec_acquire *tqh_first; struct ipsec_acquire **tqh_last; } ipo_acquires; struct { struct ipsec_policy *tqe_next; struct ipsec_policy **tqe_prev; } ipo_tdb_next; struct { struct ipsec_policy *tqe_next; struct ipsec_policy **tqe_prev; } ipo_list; }; # 261 "/usr/include/netinet/ip_ipsp.h" 3 4 struct route_enc { struct rtentry *re_rt; struct sockaddr_encap re_dst; }; struct tdb { # 275 "/usr/include/netinet/ip_ipsp.h" 3 4 struct tdb *tdb_hnext; struct tdb *tdb_anext; struct tdb *tdb_snext; struct tdb *tdb_inext; struct tdb *tdb_onext; struct xformsw *tdb_xform; struct enc_xform *tdb_encalgxform; struct auth_hash *tdb_authalgxform; struct comp_algo *tdb_compalgxform; # 305 "/usr/include/netinet/ip_ipsp.h" 3 4 u_int32_t tdb_flags; struct timeout tdb_timer_tmo; struct timeout tdb_first_tmo; struct timeout tdb_stimer_tmo; struct timeout tdb_sfirst_tmo; u_int32_t tdb_seq; u_int32_t tdb_exp_allocations; u_int32_t tdb_soft_allocations; u_int32_t tdb_cur_allocations; u_int64_t tdb_exp_bytes; u_int64_t tdb_soft_bytes; u_int64_t tdb_cur_bytes; u_int64_t tdb_exp_timeout; u_int64_t tdb_soft_timeout; u_int64_t tdb_established; u_int64_t tdb_first_use; u_int64_t tdb_soft_first_use; u_int64_t tdb_exp_first_use; u_int64_t tdb_last_used; u_int64_t tdb_last_marked; u_int64_t tdb_cryptoid; u_int32_t tdb_spi; u_int16_t tdb_amxkeylen; u_int16_t tdb_emxkeylen; u_int16_t tdb_ivlen; u_int8_t tdb_sproto; u_int8_t tdb_wnd; u_int8_t tdb_satype; union sockaddr_union tdb_dst; union sockaddr_union tdb_src; union sockaddr_union tdb_proxy; u_int8_t *tdb_amxkey; u_int8_t *tdb_emxkey; u_int32_t tdb_rpl; u_int32_t tdb_bitmap; u_int32_t tdb_epoch; u_int8_t tdb_iv[4]; struct ipsec_ref *tdb_local_cred; struct ipsec_ref *tdb_remote_cred; struct ipsec_ref *tdb_srcid; struct ipsec_ref *tdb_dstid; struct ipsec_ref *tdb_local_auth; struct ipsec_ref *tdb_remote_auth; u_int32_t tdb_mtu; u_int64_t tdb_mtutimeout; u_int16_t tdb_udpencap_port; struct sockaddr_encap tdb_filter; struct sockaddr_encap tdb_filtermask; struct tdb_inp_head_in { struct inpcb *tqh_first; struct inpcb **tqh_last; } tdb_inp_in; struct tdb_inp_head_out { struct inpcb *tqh_first; struct inpcb **tqh_last; } tdb_inp_out; struct tdb_policy_head { struct ipsec_policy *tqh_first; struct ipsec_policy **tqh_last; } tdb_policy_head; }; struct tdb_ident { u_int32_t spi; union sockaddr_union dst; u_int8_t proto; }; struct tdb_crypto { u_int32_t tc_spi; union sockaddr_union tc_dst; u_int8_t tc_proto; int tc_protoff; int tc_skip; caddr_t tc_ptr; }; struct ipsecinit { u_int8_t *ii_enckey; u_int8_t *ii_authkey; u_int16_t ii_enckeylen; u_int16_t ii_authkeylen; u_int8_t ii_encalg; u_int8_t ii_authalg; u_int8_t ii_compalg; }; # 418 "/usr/include/netinet/ip_ipsp.h" 3 4 static __inline u_int64_t htonq(u_int64_t q) { u_int32_t u, l; u = q >> 32; l = (u_int32_t) q; return __extension__({ u_int32_t __swap32_x = (u); __builtin_constant_p(u) ? __extension__({ u_int32_t __swap32gen_x = (__swap32_x); (u_int32_t)((__swap32gen_x & 0xff) << 24 | (__swap32gen_x & 0xff00) << 8 | (__swap32gen_x & 0xff0000) >> 8 | (__swap32gen_x & 0xff000000) >> 24); }) : ({ u_int32_t __swap32md_x = (__swap32_x); __asm ("rorw $8, %w1; rorl $16, %1; rorw $8, %w1" : "+r" (__swap32md_x)); __swap32md_x; }); }) | ((u_int64_t)__extension__({ u_int32_t __swap32_x = (l); __builtin_constant_p(l) ? __extension__({ u_int32_t __swap32gen_x = (__swap32_x); (u_int32_t)((__swap32gen_x & 0xff) << 24 | (__swap32gen_x & 0xff00) << 8 | (__swap32gen_x & 0xff0000) >> 8 | (__swap32gen_x & 0xff000000) >> 24); }) : ({ u_int32_t __swap32md_x = (__swap32_x); __asm ("rorw $8, %w1; rorl $16, %1; rorw $8, %w1" : "+r" (__swap32md_x)); __swap32md_x; }); }) << 32); } # 72 "/usr/include/netinet/in_pcb.h" 2 3 4 union inpaddru { struct in6_addr iau_addr6; struct { uint8_t pad[12]; struct in_addr inaddr; } iau_a4u; }; # 88 "/usr/include/netinet/in_pcb.h" 3 4 struct inpcb { struct { struct inpcb *le_next; struct inpcb **le_prev; } inp_hash; struct { struct inpcb *le_next; struct inpcb **le_prev; } inp_lhash; struct { struct inpcb *cqe_next; struct inpcb *cqe_prev; } inp_queue; struct inpcbtable *inp_table; union inpaddru inp_faddru; union inpaddru inp_laddru; u_int16_t inp_fport; u_int16_t inp_lport; struct socket *inp_socket; caddr_t inp_ppcb; union { struct route ru_route; struct route_in6 ru_route6; } inp_ru; int inp_flags; union { struct ip hu_ip; struct ip6_hdr hu_ipv6; } inp_hu; struct mbuf *inp_options; struct ip6_pktopts *inp_outputopts6; int inp_hops; union { struct ip_moptions *mou_mo; struct ip6_moptions *mou_mo6; } inp_mou; u_char inp_seclevel[4]; u_int8_t inp_secrequire:4, inp_secresult:4; struct { struct inpcb *tqe_next; struct inpcb **tqe_prev; } inp_tdb_in_next, inp_tdb_out_next; struct tdb *inp_tdb_in, *inp_tdb_out; struct ipsec_policy *inp_ipo; struct ipsec_ref *inp_ipsec_remotecred; struct ipsec_ref *inp_ipsec_remoteauth; int in6p_cksum; struct icmp6_filter *inp_icmp6filt; }; struct inpcbtable { struct { struct inpcb *cqh_first; struct inpcb *cqh_last; } inpt_queue; struct inpcbhead { struct inpcb *lh_first; } *inpt_hashtbl, *inpt_lhashtbl; u_long inpt_hash, inpt_lhash; u_int16_t inpt_lastport; }; # 226 "/usr/include/netinet/in_pcb.h" 3 4 struct baddynamicports { u_int32_t tcp[((((1024/2) + (((sizeof(u_int32_t) * 8)) - 1)) / ((sizeof(u_int32_t) * 8))))]; u_int32_t udp[((((1024/2) + (((sizeof(u_int32_t) * 8)) - 1)) / ((sizeof(u_int32_t) * 8))))]; }; # 79 "mibII/mibII_common.h" 2 # 94 "mibII/mibII_common.h" # 1 "../../agent/kernel.h" 1 extern void init_kmem(const char *); extern int klookup(unsigned long, char *, int); # 1 "/usr/include/kvm.h" 1 3 4 # 48 "/usr/include/kvm.h" 3 4 # 1 "/usr/include/nlist.h" 1 3 4 # 47 "/usr/include/nlist.h" 3 4 struct nlist { char *n_name; # 70 "/usr/include/nlist.h" 3 4 unsigned char n_type; char n_other; short n_desc; unsigned long n_value; }; int nlist(const char *, struct nlist *); # 49 "/usr/include/kvm.h" 2 3 4 # 1 "/usr/include/stdio.h" 1 3 4 # 68 "/usr/include/stdio.h" 3 4 typedef off_t fpos_t; # 77 "/usr/include/stdio.h" 3 4 struct __sbuf { unsigned char *_base; int _size; }; # 106 "/usr/include/stdio.h" 3 4 typedef struct __sFILE { unsigned char *_p; int _r; int _w; short _flags; short _file; struct __sbuf _bf; int _lbfsize; void *_cookie; int (*_close)(void *); int (*_read)(void *, char *, int); fpos_t (*_seek)(void *, fpos_t, int); int (*_write)(void *, const char *, int); struct __sbuf _ub; unsigned char *_up; int _ur; unsigned char _ubuf[3]; unsigned char _nbuf[1]; struct __sbuf _lb; int _blksize; fpos_t _offset; } FILE; extern FILE __sF[]; # 209 "/usr/include/stdio.h" 3 4 void clearerr(FILE *); int fclose(FILE *); int feof(FILE *); int ferror(FILE *); int fflush(FILE *); int fgetc(FILE *); int fgetpos(FILE *, fpos_t *); char *fgets(char *, int, FILE *) __attribute__((__bounded__ (__string__,1,2))); FILE *fopen(const char *, const char *); int fprintf(FILE *, const char *, ...); int fputc(int, FILE *); int fputs(const char *, FILE *); size_t fread(void *, size_t, size_t, FILE *) __attribute__((__bounded__ (__size__,1,3,2))); FILE *freopen(const char *, const char *, FILE *); int fscanf(FILE *, const char *, ...); int fseek(FILE *, long, int); int fseeko(FILE *, off_t, int); int fsetpos(FILE *, const fpos_t *); long ftell(FILE *); off_t ftello(FILE *); size_t fwrite(const void *, size_t, size_t, FILE *) __attribute__((__bounded__ (__size__,1,3,2))); int getc(FILE *); int getchar(void); char *gets(char *); extern int sys_nerr; extern char *sys_errlist[]; void perror(const char *); int printf(const char *, ...); int putc(int, FILE *); int putchar(int); int puts(const char *); int remove(const char *); int rename(const char *, const char *); void rewind(FILE *); int scanf(const char *, ...); void setbuf(FILE *, char *); int setvbuf(FILE *, char *, int, size_t); int sprintf(char *, const char *, ...); int sscanf(const char *, const char *, ...); FILE *tmpfile(void); char *tmpnam(char *); int ungetc(int, FILE *); int vfprintf(FILE *, const char *, __builtin_va_list); int vprintf(const char *, __builtin_va_list); int vsprintf(char *, const char *, __builtin_va_list); # 271 "/usr/include/stdio.h" 3 4 char *ctermid(char *); char *ctermid_r(char *); char *cuserid(char *); FILE *fdopen(int, const char *); int fileno(FILE *); void flockfile(FILE *); int ftrylockfile(FILE *); void funlockfile(FILE *); int getc_unlocked(FILE *); int putc_unlocked(int, FILE *); int getchar_unlocked(void); int putchar_unlocked(int); # 299 "/usr/include/stdio.h" 3 4 int asprintf(char **, const char *, ...) __attribute__((__format__ (printf, 2, 3))) __attribute__((__nonnull__ (2))); char *fgetln(FILE *, size_t *); int fpurge(FILE *); int getw(FILE *); int pclose(FILE *); FILE *popen(const char *, const char *); int putw(int, FILE *); void setbuffer(FILE *, char *, int); int setlinebuf(FILE *); char *tempnam(const char *, const char *); int snprintf(char *, size_t, const char *, ...) __attribute__((__format__ (printf, 3, 4))) __attribute__((__nonnull__ (3))) __attribute__((__bounded__ (__string__,1,2))); int vasprintf(char **, const char *, __builtin_va_list) __attribute__((__format__ (printf, 2, 0))) __attribute__((__nonnull__ (2))); int vsnprintf(char *, size_t, const char *, __builtin_va_list) __attribute__((__format__ (printf, 3, 0))) __attribute__((__nonnull__ (3))) __attribute__((__bounded__(__string__,1,2))); int vscanf(const char *, __builtin_va_list) __attribute__((__format__ (scanf, 1, 0))) __attribute__((__nonnull__ (1))); int vsscanf(const char *, const char *, __builtin_va_list) __attribute__((__format__ (scanf, 2, 0))) __attribute__((__nonnull__ (2))); # 341 "/usr/include/stdio.h" 3 4 FILE *funopen(const void *, int (*)(void *, char *, int), int (*)(void *, const char *, int), fpos_t (*)(void *, fpos_t, int), int (*)(void *)); int __srget(FILE *); int __svfscanf(FILE *, const char *, __builtin_va_list); int __swbuf(int, FILE *); static __inline int __sputc(int _c, FILE *_p) { if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n')) return (*_p->_p++ = _c); else return (__swbuf(_c, _p)); } # 51 "/usr/include/kvm.h" 2 3 4 typedef struct __kvm kvm_t; struct kinfo_proc; struct kinfo_proc2; int kvm_close(kvm_t *); int kvm_dump_inval(kvm_t *); int kvm_dump_mkheader(kvm_t *, off_t); int kvm_dump_wrtheader(kvm_t *, FILE *, int); char **kvm_getargv(kvm_t *, const struct kinfo_proc *, int); char **kvm_getargv2(kvm_t *, const struct kinfo_proc2 *, int); char **kvm_getenvv(kvm_t *, const struct kinfo_proc *, int); char **kvm_getenvv2(kvm_t *, const struct kinfo_proc2 *, int); char *kvm_geterr(kvm_t *); int kvm_getloadavg(kvm_t *, double [], int); char *kvm_getfiles(kvm_t *, int, int, int *); struct kinfo_proc * kvm_getprocs(kvm_t *, int, int, int *); struct kinfo_proc2 * kvm_getproc2(kvm_t *, int, int, size_t, int *); int kvm_nlist(kvm_t *, struct nlist *); kvm_t *kvm_open(const char *, const char *, const char *, int, const char *); kvm_t *kvm_openfiles(const char *, const char *, const char *, unsigned int, char *); ssize_t kvm_read(kvm_t *, unsigned long, void *, size_t) __attribute__((__bounded__(__buffer__,3,4))); ssize_t kvm_write(kvm_t *, unsigned long, const void *, size_t) __attribute__((__bounded__(__buffer__,3,4))); # 9 "../../agent/kernel.h" 2 extern kvm_t *kd; # 95 "mibII/mibII_common.h" 2 # 9 "mibII/tcp.c" 2 # 18 "mibII/tcp.c" # 1 "/usr/include/sys/protosw.h" 1 3 4 # 58 "/usr/include/sys/protosw.h" 3 4 struct mbuf; struct sockaddr; struct socket; struct domain; struct protosw { short pr_type; struct domain *pr_domain; short pr_protocol; short pr_flags; void (*pr_input)(struct mbuf *, ...); int (*pr_output)(struct mbuf *, ...); void *(*pr_ctlinput)(int, struct sockaddr *, void *); int (*pr_ctloutput)(int, struct socket *, int, int, struct mbuf **); int (*pr_usrreq)(struct socket *, int, struct mbuf *, struct mbuf *, struct mbuf *); void (*pr_init)(void); void (*pr_fasttimo)(void); void (*pr_slowtimo)(void); void (*pr_drain)(void); int (*pr_sysctl)(int *, u_int, void *, size_t *, void *, size_t); }; # 19 "mibII/tcp.c" 2 # 1 "/usr/include/arpa/inet.h" 1 3 4 # 64 "/usr/include/arpa/inet.h" 3 4 # 1 "/usr/include/sys/param.h" 1 3 4 # 67 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/sys/syslimits.h" 1 3 4 # 68 "/usr/include/sys/param.h" 2 3 4 # 95 "/usr/include/sys/param.h" 3 4 # 1 "/usr/include/machine/param.h" 1 3 4 # 96 "/usr/include/sys/param.h" 2 3 4 # 65 "/usr/include/arpa/inet.h" 2 3 4 in_addr_t inet_addr(const char *); int inet_aton(const char *, struct in_addr *); in_addr_t inet_lnaof(struct in_addr); struct in_addr inet_makeaddr(in_addr_t , in_addr_t); char * inet_neta(in_addr_t, char *, size_t) __attribute__((__bounded__(__string__,2,3))); in_addr_t inet_netof(struct in_addr); in_addr_t inet_network(const char *); char *inet_net_ntop(int, const void *, int, char *, size_t) __attribute__((__bounded__(__string__,4,5))); int inet_net_pton(int, const char *, void *, size_t) __attribute__((__bounded__(__string__,3,4))); char *inet_ntoa(struct in_addr); int inet_pton(int, const char *, void *); const char *inet_ntop(int, const void *, char *, size_t) __attribute__ ((__bounded__(__string__,3,4))); unsigned int inet_nsap_addr(const char *, unsigned char *, int); char *inet_nsap_ntoa(int, const unsigned char *, char *); # 22 "mibII/tcp.c" 2 # 34 "mibII/tcp.c" # 1 "/usr/include/netinet/tcp.h" 1 3 4 # 38 "/usr/include/netinet/tcp.h" 3 4 typedef u_int32_t tcp_seq; struct tcphdr { u_int16_t th_sport; u_int16_t th_dport; tcp_seq th_seq; tcp_seq th_ack; u_int8_t th_x2:4, th_off:4; u_int8_t th_flags; # 66 "/usr/include/netinet/tcp.h" 3 4 u_int16_t th_win; u_int16_t th_sum; u_int16_t th_urp; }; # 35 "mibII/tcp.c" 2 # 1 "/usr/include/netinet/tcpip.h" 1 3 4 # 41 "/usr/include/netinet/tcpip.h" 3 4 struct tcpiphdr { struct ipovly ti_i; struct tcphdr ti_t; }; # 38 "mibII/tcp.c" 2 # 1 "/usr/include/netinet/tcp_timer.h" 1 3 4 # 41 "mibII/tcp.c" 2 # 51 "mibII/tcp.c" # 1 "/usr/include/netinet/tcp_var.h" 1 3 4 # 40 "/usr/include/netinet/tcp_var.h" 3 4 struct sackblk { tcp_seq start; tcp_seq end; }; struct sackhole { tcp_seq start; tcp_seq end; int dups; tcp_seq rxmit; struct sackhole *next; }; # 60 "/usr/include/netinet/tcp_var.h" 3 4 struct tcpcb { struct ipqehead segq; struct timeout t_timer[4]; short t_state; short t_rxtshift; short t_rxtcur; short t_dupacks; u_short t_maxseg; char t_force; u_int t_flags; # 91 "/usr/include/netinet/tcp_var.h" 3 4 struct mbuf *t_template; struct inpcb *t_inpcb; struct timeout t_delack_to; tcp_seq snd_una; tcp_seq snd_nxt; tcp_seq snd_up; tcp_seq snd_wl1; tcp_seq snd_wl2; tcp_seq iss; u_long snd_wnd; int sack_enable; int snd_numholes; struct sackhole *snd_holes; tcp_seq snd_fack; u_long snd_awnd; int retran_data; tcp_seq snd_last; u_long rcv_wnd; tcp_seq rcv_nxt; tcp_seq rcv_up; tcp_seq irs; tcp_seq rcv_lastsack; int rcv_numsacks; struct sackblk sackblks[6]; tcp_seq rcv_adv; tcp_seq snd_max; u_long snd_cwnd; u_long snd_ssthresh; u_short t_maxopd; u_short t_peermss; uint32_t t_rcvtime; uint32_t t_rtttime; tcp_seq t_rtseq; short t_srtt; short t_rttvar; u_short t_rttmin; u_long max_sndwnd; char t_oobflags; char t_iobc; short t_softerror; u_char snd_scale; u_char rcv_scale; u_char request_r_scale; u_char requested_s_scale; u_int32_t ts_recent; u_int32_t ts_modulate; u_int32_t ts_recent_age; tcp_seq last_ack_sent; struct { struct syn_cache *lh_first; } t_sc; caddr_t t_tuba_pcb; int pf; struct timeout t_reap_to; }; # 356 "/usr/include/netinet/tcp_var.h" 3 4 struct tcpstat { u_int32_t tcps_connattempt; u_int32_t tcps_accepts; u_int32_t tcps_connects; u_int32_t tcps_drops; u_int32_t tcps_conndrops; u_int32_t tcps_closed; u_int32_t tcps_segstimed; u_int32_t tcps_rttupdated; u_int32_t tcps_delack; u_int32_t tcps_timeoutdrop; u_int32_t tcps_rexmttimeo; u_int32_t tcps_persisttimeo; u_int32_t tcps_persistdrop; u_int32_t tcps_keeptimeo; u_int32_t tcps_keepprobe; u_int32_t tcps_keepdrops; u_int32_t tcps_sndtotal; u_int32_t tcps_sndpack; u_int64_t tcps_sndbyte; u_int32_t tcps_sndrexmitpack; u_int64_t tcps_sndrexmitbyte; u_int64_t tcps_sndrexmitfast; u_int32_t tcps_sndacks; u_int32_t tcps_sndprobe; u_int32_t tcps_sndurg; u_int32_t tcps_sndwinup; u_int32_t tcps_sndctrl; u_int32_t tcps_rcvtotal; u_int32_t tcps_rcvpack; u_int64_t tcps_rcvbyte; u_int32_t tcps_rcvbadsum; u_int32_t tcps_rcvbadoff; u_int32_t tcps_rcvmemdrop; u_int32_t tcps_rcvnosec; u_int32_t tcps_rcvshort; u_int32_t tcps_rcvduppack; u_int64_t tcps_rcvdupbyte; u_int32_t tcps_rcvpartduppack; u_int64_t tcps_rcvpartdupbyte; u_int32_t tcps_rcvoopack; u_int64_t tcps_rcvoobyte; u_int32_t tcps_rcvpackafterwin; u_int64_t tcps_rcvbyteafterwin; u_int32_t tcps_rcvafterclose; u_int32_t tcps_rcvwinprobe; u_int32_t tcps_rcvdupack; u_int32_t tcps_rcvacktoomuch; u_int32_t tcps_rcvacktooold; u_int32_t tcps_rcvackpack; u_int64_t tcps_rcvackbyte; u_int32_t tcps_rcvwinupd; u_int32_t tcps_pawsdrop; u_int32_t tcps_predack; u_int32_t tcps_preddat; u_int32_t tcps_pcbhashmiss; u_int32_t tcps_noport; u_int32_t tcps_badsyn; u_int32_t tcps_rcvbadsig; u_int64_t tcps_rcvgoodsig; u_int32_t tcps_inhwcsum; u_int32_t tcps_outhwcsum; u_int32_t tcps_ecn_accepts; u_int32_t tcps_ecn_rcvece; u_int32_t tcps_ecn_rcvcwr; u_int32_t tcps_ecn_rcvce; u_int32_t tcps_ecn_sndect; u_int32_t tcps_ecn_sndece; u_int32_t tcps_ecn_sndcwr; u_int32_t tcps_cwr_ecn; u_int32_t tcps_cwr_frecovery; u_int32_t tcps_cwr_timeout; u_int64_t tcps_sc_added; u_int64_t tcps_sc_completed; u_int64_t tcps_sc_timed_out; u_int64_t tcps_sc_overflowed; u_int64_t tcps_sc_reset; u_int64_t tcps_sc_unreach; u_int64_t tcps_sc_bucketoverflow; u_int64_t tcps_sc_aborted; u_int64_t tcps_sc_dupesyn; u_int64_t tcps_sc_dropped; u_int64_t tcps_sc_collisions; u_int64_t tcps_sc_retransmitted; u_int64_t tcps_conndrained; }; # 526 "/usr/include/netinet/tcp_var.h" 3 4 struct tcp_ident_mapping { struct sockaddr_storage faddr, laddr; int euid, ruid; }; # 52 "mibII/tcp.c" 2 # 1 "/usr/include/netinet/tcp_fsm.h" 1 3 4 # 58 "mibII/tcp.c" 2 # 1 "../../include/net-snmp/net-snmp-includes.h" 1 # 71 "../../include/net-snmp/net-snmp-includes.h" # 1 "../../include/net-snmp/definitions.h" 1 # 22 "../../include/net-snmp/definitions.h" # 1 "../../include/net-snmp/types.h" 1 # 33 "../../include/net-snmp/types.h" # 1 "/usr/include/inttypes.h" 1 3 4 # 26 "/usr/include/inttypes.h" 3 4 typedef long intptr_t; typedef unsigned long uintptr_t; # 34 "../../include/net-snmp/types.h" 2 # 50 "../../include/net-snmp/types.h" typedef u_long oid; # 140 "../../include/net-snmp/types.h" # 1 "../../include/net-snmp/definitions.h" 1 # 141 "../../include/net-snmp/types.h" 2 # 1 "../../include/net-snmp/library/snmp_api.h" 1 # 62 "../../include/net-snmp/library/snmp_api.h" struct variable_list; typedef struct variable_list netsnmp_variable_list; struct timeval; struct netsnmp_transport_s; # 75 "../../include/net-snmp/library/snmp_api.h" typedef struct snmp_pdu { long version; int command; long reqid; long msgid; long transid; long sessid; long errstat; long errindex; u_long time; u_long flags; int securityModel; int securityLevel; int msgParseModel; void *transport_data; int transport_data_length; const oid *tDomain; size_t tDomainLen; netsnmp_variable_list *variables; u_char *community; size_t community_len; oid *enterprise; size_t enterprise_length; long trap_type; long specific_type; unsigned char agent_addr[4]; u_char *contextEngineID; size_t contextEngineIDLen; char *contextName; size_t contextNameLen; u_char *securityEngineID; size_t securityEngineIDLen; char *securityName; size_t securityNameLen; int priority; int range_subid; void *securityStateRef; } netsnmp_pdu; struct snmp_session; typedef struct snmp_session netsnmp_session; typedef int (*snmp_callback) (int, netsnmp_session *, int, netsnmp_pdu *, void *); typedef int (*netsnmp_callback) (int, netsnmp_session *, int, netsnmp_pdu *, void *); struct snmp_session { long version; int retries; long timeout; u_long flags; struct snmp_session *subsession; struct snmp_session *next; char *peername; u_short remote_port; char *localname; u_short local_port; u_char *(*authenticator) (u_char *, size_t *, u_char *, size_t); netsnmp_callback callback; void *callback_magic; int s_errno; int s_snmp_errno; long sessid; u_char *community; size_t community_len; size_t rcvMsgMaxSize; size_t sndMsgMaxSize; u_char isAuthoritative; u_char *contextEngineID; size_t contextEngineIDLen; u_int engineBoots; u_int engineTime; char *contextName; size_t contextNameLen; u_char *securityEngineID; size_t securityEngineIDLen; char *securityName; size_t securityNameLen; oid *securityAuthProto; size_t securityAuthProtoLen; u_char securityAuthKey[32]; size_t securityAuthKeyLen; u_char *securityAuthLocalKey; size_t securityAuthLocalKeyLen; oid *securityPrivProto; size_t securityPrivProtoLen; u_char securityPrivKey[32]; size_t securityPrivKeyLen; u_char *securityPrivLocalKey; size_t securityPrivLocalKeyLen; int securityModel; int securityLevel; char *paramName; void *securityInfo; void *myvoid; }; # 359 "../../include/net-snmp/library/snmp_api.h" extern const char *snmp_api_errstring(int); extern void snmp_perror(const char *); extern void snmp_set_detail(const char *); # 496 "../../include/net-snmp/library/snmp_api.h" typedef union { long *integer; u_char *string; oid *objid; u_char *bitstring; struct counter64 *counter64; float *floatVal; double *doubleVal; } netsnmp_vardata; struct variable_list { struct variable_list *next_variable; oid *name; size_t name_length; u_char type; netsnmp_vardata val; size_t val_len; oid name_loc[128]; u_char buf[40]; void *data; void (*dataFreeHook)(void *); int index; }; # 552 "../../include/net-snmp/library/snmp_api.h" netsnmp_session *snmp_open(netsnmp_session *); # 564 "../../include/net-snmp/library/snmp_api.h" int snmp_close(netsnmp_session *); int snmp_close_sessions(void); # 581 "../../include/net-snmp/library/snmp_api.h" int snmp_send(netsnmp_session *, netsnmp_pdu *); # 599 "../../include/net-snmp/library/snmp_api.h" int snmp_async_send(netsnmp_session *, netsnmp_pdu *, netsnmp_callback, void *); # 613 "../../include/net-snmp/library/snmp_api.h" void snmp_read(fd_set *); # 624 "../../include/net-snmp/library/snmp_api.h" void snmp_free_pdu(netsnmp_pdu *); void snmp_free_var(netsnmp_variable_list *); void snmp_free_varbind(netsnmp_variable_list * var); # 657 "../../include/net-snmp/library/snmp_api.h" int snmp_select_info(int *, fd_set *, struct timeval *, int *); # 674 "../../include/net-snmp/library/snmp_api.h" void snmp_timeout(void); # 714 "../../include/net-snmp/library/snmp_api.h" long snmp_get_next_msgid(void); long snmp_get_next_reqid(void); long snmp_get_next_sessid(void); long snmp_get_next_transid(void); int snmp_oid_compare(const oid *, size_t, const oid *, size_t); int snmp_oid_ncompare(const oid *, size_t, const oid *, size_t, size_t); int snmp_oidtree_compare(const oid *, size_t, const oid *, size_t); int netsnmp_oid_compare_ll(const oid * in_name1, size_t len1, const oid * in_name2, size_t len2, size_t *offpt); int netsnmp_oid_equals(const oid *, size_t, const oid *, size_t); int netsnmp_oid_tree_equals(const oid *, size_t, const oid *, size_t); int netsnmp_oid_is_subtree(const oid *, size_t, const oid *, size_t); int netsnmp_oid_find_prefix(const oid * in_name1, size_t len1, const oid * in_name2, size_t len2); void init_snmp(const char *); u_char *snmp_pdu_build(netsnmp_pdu *, u_char *, size_t *); u_char *snmp_pdu_rbuild(netsnmp_pdu *, u_char *, size_t *); int snmpv3_parse(netsnmp_pdu *, u_char *, size_t *, u_char **, netsnmp_session *); int snmpv3_packet_build(netsnmp_session *, netsnmp_pdu *pdu, u_char * packet, size_t * out_length, u_char * pdu_data, size_t pdu_data_len); int snmpv3_packet_rbuild(netsnmp_session *, netsnmp_pdu *pdu, u_char * packet, size_t * out_length, u_char * pdu_data, size_t pdu_data_len); int snmpv3_make_report(netsnmp_pdu *pdu, int error); int snmpv3_get_report_type(netsnmp_pdu *pdu); int snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length); u_char *snmpv3_scopedPDU_parse(netsnmp_pdu *pdu, u_char * cp, size_t * length); void snmp_store(const char *type); void snmp_shutdown(const char *type); netsnmp_variable_list *snmp_pdu_add_variable(netsnmp_pdu *, const oid *, size_t, u_char, const u_char *, size_t); netsnmp_variable_list *snmp_varlist_add_variable(netsnmp_variable_list ** varlist, const oid * name, size_t name_length, u_char type, const u_char * value, size_t len); int snmp_add_var(netsnmp_pdu *, const oid *, size_t, char, const char *); oid *snmp_duplicate_objid(const oid * objToCopy, size_t); u_int snmp_increment_statistic(int which); u_int snmp_increment_statistic_by(int which, int count); u_int snmp_get_statistic(int which); void snmp_init_statistics(void); int create_user_from_session(netsnmp_session * session); int snmp_get_fd_for_session(struct snmp_session *sessp); int snmpv3_packet_realloc_rbuild(u_char ** pkt, size_t * pkt_len, size_t * offset, netsnmp_session * session, netsnmp_pdu *pdu, u_char * pdu_data, size_t pdu_data_len); int snmp_pdu_realloc_rbuild(u_char ** pkt, size_t * pkt_len, size_t * offset, netsnmp_pdu *pdu); # 802 "../../include/net-snmp/library/snmp_api.h" netsnmp_session *snmp_open_ex(netsnmp_session *, int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fparse) (netsnmp_session *, netsnmp_pdu *, u_char *, size_t), int (*fpost_parse) (netsnmp_session *, netsnmp_pdu *, int), int (*fbuild) (netsnmp_session *, netsnmp_pdu *, u_char *, size_t *), int (*frbuild) (netsnmp_session *, netsnmp_pdu *, u_char **, size_t *, size_t *), int (*fcheck) (u_char *, size_t)); void snmp_set_do_debugging(int); int snmp_get_do_debugging(void); void snmp_error(netsnmp_session *, int *, int *, char **); # 873 "../../include/net-snmp/library/snmp_api.h" void snmp_sess_init(netsnmp_session *); void *snmp_sess_open(netsnmp_session *); void *snmp_sess_pointer(netsnmp_session *); netsnmp_session *snmp_sess_session(void *); struct netsnmp_transport_s *snmp_sess_transport(void *); void snmp_sess_transport_set(void *, struct netsnmp_transport_s *); # 900 "../../include/net-snmp/library/snmp_api.h" void *snmp_sess_add_ex(netsnmp_session *, struct netsnmp_transport_s *, int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fparse) (netsnmp_session *, struct snmp_pdu *, u_char *, size_t), int (*fpost_parse) (netsnmp_session *, struct snmp_pdu *, int), int (*fbuild) (netsnmp_session *, struct snmp_pdu *, u_char *, size_t *), int (*frbuild) (netsnmp_session *, struct snmp_pdu *, u_char **, size_t *, size_t *), int (*fcheck) (u_char *, size_t), netsnmp_pdu *(*fcreate_pdu) (struct netsnmp_transport_s *, void *, size_t)); void *snmp_sess_add(netsnmp_session *, struct netsnmp_transport_s *, int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fpost_parse) (netsnmp_session *, netsnmp_pdu *, int)); netsnmp_session *snmp_add(netsnmp_session *, struct netsnmp_transport_s *, int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fpost_parse) (netsnmp_session *, netsnmp_pdu *, int)); netsnmp_session *snmp_add_full(netsnmp_session * in_session, struct netsnmp_transport_s *transport, int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fparse) (netsnmp_session *, netsnmp_pdu *, u_char *, size_t), int (*fpost_parse) (netsnmp_session *, netsnmp_pdu *, int), int (*fbuild) (netsnmp_session *, netsnmp_pdu *, u_char *, size_t *), int (*frbuild) (netsnmp_session *, netsnmp_pdu *, u_char **, size_t *, size_t *), int (*fcheck) (u_char *, size_t), netsnmp_pdu *(*fcreate_pdu) (struct netsnmp_transport_s *, void *, size_t) ); int snmp_sess_send(void *, netsnmp_pdu *); int snmp_sess_async_send(void *, netsnmp_pdu *, netsnmp_callback, void *); int snmp_sess_select_info(void *, int *, fd_set *, struct timeval *, int *); int snmp_sess_read(void *, fd_set *); void snmp_sess_timeout(void *); int snmp_sess_close(void *); void snmp_sess_error(void *, int *, int *, char **); void netsnmp_sess_log_error(int priority, const char *prog_string, netsnmp_session * ss); void snmp_sess_perror(const char *prog_string, netsnmp_session * ss); const char * snmp_pdu_type(int type); # 142 "../../include/net-snmp/types.h" 2 typedef struct netsnmp_index_s { int len; oid *oids; } netsnmp_index; typedef struct netsnmp_void_array_s { size_t size; void * *array; } netsnmp_void_array; typedef struct netsnmp_ref_void { void * val; } netsnmp_ref_void; # 186 "../../include/net-snmp/types.h" typedef struct netsnmp_ref_size_t_s { size_t val; } * netsnmp_ref_size_t; # 23 "../../include/net-snmp/definitions.h" 2 # 1 "../../include/net-snmp/library/asn1.h" 1 # 83 "../../include/net-snmp/library/asn1.h" struct counter64 { u_long high; u_long low; }; typedef struct counter64 integer64; typedef struct counter64 unsigned64; # 188 "../../include/net-snmp/library/asn1.h" int asn_check_packet(u_char *, size_t); u_char *asn_parse_int(u_char *, size_t *, u_char *, long *, size_t); u_char *asn_build_int(u_char *, size_t *, u_char, const long *, size_t); u_char *asn_parse_unsigned_int(u_char *, size_t *, u_char *, u_long *, size_t); u_char *asn_build_unsigned_int(u_char *, size_t *, u_char, const u_long *, size_t); u_char *asn_parse_string(u_char *, size_t *, u_char *, u_char *, size_t *); u_char *asn_build_string(u_char *, size_t *, u_char, const u_char *, size_t); u_char *asn_parse_header(u_char *, size_t *, u_char *); u_char *asn_parse_sequence(u_char *, size_t *, u_char *, u_char expected_type, const char *estr); u_char *asn_build_header(u_char *, size_t *, u_char, size_t); u_char *asn_build_sequence(u_char *, size_t *, u_char, size_t); u_char *asn_parse_length(u_char *, u_long *); u_char *asn_build_length(u_char *, size_t *, size_t); u_char *asn_parse_objid(u_char *, size_t *, u_char *, oid *, size_t *); u_char *asn_build_objid(u_char *, size_t *, u_char, oid *, size_t); u_char *asn_parse_null(u_char *, size_t *, u_char *); u_char *asn_build_null(u_char *, size_t *, u_char); u_char *asn_parse_bitstring(u_char *, size_t *, u_char *, u_char *, size_t *); u_char *asn_build_bitstring(u_char *, size_t *, u_char, const u_char *, size_t); u_char *asn_parse_unsigned_int64(u_char *, size_t *, u_char *, struct counter64 *, size_t); u_char *asn_build_unsigned_int64(u_char *, size_t *, u_char, const struct counter64 *, size_t); u_char *asn_parse_signed_int64(u_char *, size_t *, u_char *, struct counter64 *, size_t); u_char *asn_build_signed_int64(u_char *, size_t *, u_char, const struct counter64 *, size_t); u_char *asn_build_float(u_char *, size_t *, u_char, const float *, size_t); u_char *asn_parse_float(u_char *, size_t *, u_char *, float *, size_t); u_char *asn_build_double(u_char *, size_t *, u_char, const double *, size_t); u_char *asn_parse_double(u_char *, size_t *, u_char *, double *, size_t); int asn_realloc(u_char **, size_t *); # 348 "../../include/net-snmp/library/asn1.h" int asn_realloc_rbuild_int(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const long *data, size_t data_size); int asn_realloc_rbuild_string(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const u_char * data, size_t data_size); int asn_realloc_rbuild_unsigned_int(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const u_long * data, size_t data_size); int asn_realloc_rbuild_header(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, size_t data_size); int asn_realloc_rbuild_sequence(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, size_t data_size); int asn_realloc_rbuild_length(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, size_t data_size); int asn_realloc_rbuild_objid(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const oid *, size_t); int asn_realloc_rbuild_null(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type); int asn_realloc_rbuild_bitstring(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const u_char * data, size_t data_size); int asn_realloc_rbuild_unsigned_int64(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, struct counter64 const *data, size_t); int asn_realloc_rbuild_signed_int64(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const struct counter64 *data, size_t); int asn_realloc_rbuild_float(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const float *data, size_t data_size); int asn_realloc_rbuild_double(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, u_char type, const double *data, size_t data_size); # 25 "../../include/net-snmp/definitions.h" 2 # 1 "../../include/net-snmp/library/snmp_impl.h" 1 # 117 "../../include/net-snmp/library/snmp_impl.h" extern u_char sid[]; extern int snmp_errno; # 132 "../../include/net-snmp/library/snmp_impl.h" u_char *snmp_comstr_parse(u_char *, size_t *, u_char *, size_t *, long *); u_char *snmp_comstr_build(u_char *, size_t *, u_char *, size_t *, long *, size_t); int has_access(u_char, int, int, int); # 26 "../../include/net-snmp/definitions.h" 2 # 1 "../../include/net-snmp/library/snmp.h" 1 # 322 "../../include/net-snmp/library/snmp.h" char *uptime_string(u_long, char *); char *uptime_string_n(u_long, char *, size_t); void xdump(const u_char *, size_t, const char *); u_char *snmp_parse_var_op(u_char *, oid *, size_t *, u_char *, size_t *, u_char **, size_t *); u_char *snmp_build_var_op(u_char *, oid *, size_t *, u_char, size_t, u_char *, size_t *); int snmp_realloc_rbuild_var_op(u_char ** pkt, size_t * pkt_len, size_t * offset, int allow_realloc, const oid * name, size_t * name_len, u_char value_type, u_char * value, size_t value_length); # 27 "../../include/net-snmp/definitions.h" 2 # 1 "../../include/net-snmp/library/snmp-tc.h" 1 # 12 "../../include/net-snmp/library/snmp-tc.h" int netsnmp_dateandtime_set_buf_from_vars(u_char *buf, size_t *bufsize, u_short y, u_char mon, u_char d, u_char h, u_char min, u_char s, u_char deci_seconds, int utc_offset_direction, u_char utc_offset_hours, u_char utc_offset_minutes); u_char *date_n_time(time_t *, size_t *); time_t ctime_to_timet(char *); # 55 "../../include/net-snmp/library/snmp-tc.h" char check_rowstatus_transition(int old_val, int new_val); char check_storage_transition(int old_val, int new_val); # 28 "../../include/net-snmp/definitions.h" 2 # 72 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/utilities.h" 1 # 29 "../../include/net-snmp/utilities.h" # 1 "../../include/net-snmp/library/snmp_client.h" 1 # 34 "../../include/net-snmp/library/snmp_client.h" struct snmp_pdu; struct snmp_session; struct variable_list; struct synch_state { int waiting; int status; int reqid; netsnmp_pdu *pdu; }; int snmp_set_var_value(netsnmp_variable_list *, const u_char *, size_t); int snmp_set_var_objid(netsnmp_variable_list * vp, const oid * objid, size_t name_length); int snmp_set_var_typed_value(netsnmp_variable_list * newvar, u_char type, const u_char * val_str, size_t val_len); int snmp_set_var_typed_integer(netsnmp_variable_list * newvar, u_char type, long val); void snmp_replace_var_types(netsnmp_variable_list * vbl, u_char old_type, u_char new_type); void snmp_reset_var_buffers(netsnmp_variable_list * var); void snmp_reset_var_types(netsnmp_variable_list * vbl, u_char new_type); int count_varbinds(netsnmp_variable_list * var_ptr); int count_varbinds_of_type(netsnmp_variable_list * var_ptr, u_char type); netsnmp_variable_list *find_varbind_of_type(netsnmp_variable_list * var_ptr, u_char type); netsnmp_variable_list *find_varbind_in_list(netsnmp_variable_list *vblist, oid *name, size_t len); netsnmp_variable_list *snmp_add_null_var(netsnmp_pdu *, const oid *, size_t); netsnmp_pdu *snmp_pdu_create(int); netsnmp_pdu *snmp_fix_pdu(netsnmp_pdu *, int); netsnmp_pdu *snmp_clone_pdu(netsnmp_pdu *); netsnmp_pdu *snmp_split_pdu(netsnmp_pdu *, int skipCount, int copyCount); unsigned long snmp_varbind_len(netsnmp_pdu *pdu); int snmp_clone_var(netsnmp_variable_list *, netsnmp_variable_list *); netsnmp_variable_list *snmp_clone_varbind(netsnmp_variable_list *); const char *snmp_errstring(int); int snmp_synch_response(netsnmp_session *, netsnmp_pdu *, netsnmp_pdu **); int snmp_synch_response_cb(netsnmp_session *, netsnmp_pdu *, netsnmp_pdu **, snmp_callback); int snmp_clone_mem(void **, void *, unsigned); int snmp_sess_synch_response(void *, netsnmp_pdu *, netsnmp_pdu **); int netsnmp_query_get( netsnmp_variable_list *, netsnmp_session *); int netsnmp_query_getnext( netsnmp_variable_list *, netsnmp_session *); int netsnmp_query_walk( netsnmp_variable_list *, netsnmp_session *); int netsnmp_query_set( netsnmp_variable_list *, netsnmp_session *); # 30 "../../include/net-snmp/utilities.h" 2 # 1 "/usr/include/getopt.h" 1 3 4 # 52 "/usr/include/getopt.h" 3 4 struct option { const char *name; int has_arg; int *flag; int val; }; int getopt_long(int, char * const *, const char *, const struct option *, int *); int getopt_long_only(int, char * const *, const char *, const struct option *, int *); # 83 "/usr/include/getopt.h" 3 4 # 32 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/system.h" 1 # 50 "../../include/net-snmp/library/system.h" int netsnmp_daemonize(int quit_immediately, int stderr_log); # 110 "../../include/net-snmp/library/system.h" in_addr_t get_myaddr(void); long get_uptime(void); # 120 "../../include/net-snmp/library/system.h" int calculate_time_diff(struct timeval *, struct timeval *); u_int calculate_sectime_diff(struct timeval *now, struct timeval *then); char *strcasestr(const char *, const char *); # 141 "../../include/net-snmp/library/system.h" int mkdirhier(const char *pathname, mode_t mode, int skiplast); int netsnmp_os_prematch(const char *ospmname, const char *ospmrelprefix); # 40 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/tools.h" 1 # 153 "../../include/net-snmp/library/tools.h" int snmp_realloc(u_char ** buf, size_t * buf_len); void free_zero(void *buf, size_t size); u_char *malloc_random(size_t * size); u_char *malloc_zero(size_t size); int memdup(u_char ** to, const u_char * from, size_t size); u_int binary_to_hex(const u_char * input, size_t len, char **output); int netsnmp_hex_to_binary(u_char ** buf, size_t * buf_len, size_t * offset, int allow_realloc, const char *hex, const char *delim); int snmp_hex_to_binary(u_char ** buf, size_t * buf_len, size_t * offset, int allow_realloc, const char *hex); int hex_to_binary2(const u_char * input, size_t len, char **output); int snmp_decimal_to_binary(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const char *decimal); int snmp_strcat(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const u_char * s); char *netsnmp_strdup_and_null(const u_char * from, size_t from_len); void dump_chunk(const char *debugtoken, const char *title, const u_char * buf, int size); char *dump_snmpEngineID(const u_char * buf, size_t * buflen); typedef void *marker_t; marker_t atime_newMarker(void); void atime_setMarker(marker_t pm); long atime_diff(marker_t first, marker_t second); u_long uatime_diff(marker_t first, marker_t second); u_long uatime_hdiff(marker_t first, marker_t second); int atime_ready(marker_t pm, int deltaT); int uatime_ready(marker_t pm, unsigned int deltaT); int marker_tticks(marker_t pm); int timeval_tticks(struct timeval *tv); char *netsnmp_getenv(const char *name); # 41 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/int64.h" 1 typedef struct counter64 U64; void divBy10(U64, U64 *, unsigned int *); void multBy10(U64, U64 *); void incrByU16(U64 *, unsigned int); void incrByU32(U64 *, unsigned int); void zeroU64(U64 *); int isZeroU64(const U64 *); void printU64(char *, const U64 *); void printI64(char *, const U64 *); int read64(U64 *, const char *); void u64Subtract(const U64 * pu64one, const U64 * pu64two, U64 * pu64out); void u64Incr(U64 * pu64out, const U64 * pu64one); void u64UpdateCounter(U64 * pu64out, const U64 * pu64one, const U64 * pu64two); void u64Copy(U64 * pu64one, const U64 * pu64two); int netsnmp_c64_check_for_32bit_wrap(U64 *old_val, U64 *new_val, int adjust); int netsnmp_c64_check32_and_update(struct counter64 *prev_val, struct counter64 *new_val, struct counter64 *old_prev_val, int *need_wrap_check); # 43 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/mt_support.h" 1 # 45 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/snmp_alarm.h" 1 typedef void (SNMPAlarmCallback) (unsigned int clientreg, void *clientarg); struct snmp_alarm { struct timeval t; unsigned int flags; unsigned int clientreg; struct timeval t_last; struct timeval t_next; void *clientarg; SNMPAlarmCallback *thecallback; struct snmp_alarm *next; }; void snmp_alarm_unregister(unsigned int clientreg); void snmp_alarm_unregister_all(void); unsigned int snmp_alarm_register(unsigned int when, unsigned int flags, SNMPAlarmCallback * thecallback, void *clientarg); unsigned int snmp_alarm_register_hr(struct timeval t, unsigned int flags, SNMPAlarmCallback * cb, void *cd); void init_snmp_alarm(void); int init_alarm_post_config(int majorid, int minorid, void *serverarg, void *clientarg); void sa_update_entry(struct snmp_alarm *alrm); struct snmp_alarm *sa_find_next(void); void run_alarms(void); void alarm_handler(int a); void set_an_alarm(void); int get_next_alarm_delay_time(struct timeval *delta); # 47 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/callback.h" 1 # 39 "../../include/net-snmp/library/callback.h" typedef int (SNMPCallback) (int majorID, int minorID, void *serverarg, void *clientarg); struct snmp_gen_callback { SNMPCallback *sc_callback; void *sc_client_arg; int priority; struct snmp_gen_callback *next; }; void init_callbacks(void); int netsnmp_register_callback(int major, int minor, SNMPCallback * new_callback, void *arg, int priority); int snmp_register_callback(int major, int minor, SNMPCallback * new_callback, void *arg); int snmp_call_callbacks(int major, int minor, void *caller_arg); int snmp_callback_available(int major, int minor); int snmp_count_callbacks(int major, int minor); int snmp_unregister_callback(int major, int minor, SNMPCallback * new_callback, void *arg, int matchargs); void clear_callback (void); int netsnmp_callback_clear_client_arg(void *, int i, int j); struct snmp_gen_callback *snmp_callback_list(int major, int minor); # 48 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/data_list.h" 1 # 34 "../../include/net-snmp/library/data_list.h" typedef void (Netsnmp_Free_List_Data) (void *); typedef int (Netsnmp_Save_List_Data) (char *buf, size_t buf_len, void *); typedef void * (Netsnmp_Read_List_Data) (char *buf, size_t buf_len); typedef struct netsnmp_data_list_s { struct netsnmp_data_list_s *next; char *name; void *data; Netsnmp_Free_List_Data *free_func; } netsnmp_data_list; typedef struct netsnmp_data_list_saveinfo_s { netsnmp_data_list **datalist; const char *type; const char *token; Netsnmp_Save_List_Data *data_list_save_ptr; Netsnmp_Read_List_Data *data_list_read_ptr; Netsnmp_Free_List_Data *data_list_free_ptr; } netsnmp_data_list_saveinfo; inline netsnmp_data_list * netsnmp_create_data_list(const char *, void *, Netsnmp_Free_List_Data* ); void netsnmp_data_list_add_node(netsnmp_data_list **head, netsnmp_data_list *node); netsnmp_data_list * netsnmp_data_list_add_data(netsnmp_data_list **head, const char *name, void *data, Netsnmp_Free_List_Data * beer); void *netsnmp_get_list_data(netsnmp_data_list *head, const char *node); void netsnmp_free_list_data(netsnmp_data_list *head); void netsnmp_free_all_list_data(netsnmp_data_list *head); int netsnmp_remove_list_node(netsnmp_data_list **realhead, const char *name); inline netsnmp_data_list * netsnmp_get_list_node(netsnmp_data_list *head, const char *name); void netsnmp_add_list_data(netsnmp_data_list **head, netsnmp_data_list *node); void netsnmp_register_save_list(netsnmp_data_list **datalist, const char *type, const char *token, Netsnmp_Save_List_Data *data_list_save_ptr, Netsnmp_Read_List_Data *data_list_read_ptr, Netsnmp_Free_List_Data *data_list_free_ptr); int netsnmp_save_all_data(netsnmp_data_list *head, const char *type, const char *token, Netsnmp_Save_List_Data * data_list_save_ptr); SNMPCallback netsnmp_save_all_data_callback; void netsnmp_read_data_callback(const char *token, char *line); # 49 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/oid_stash.h" 1 # 15 "../../include/net-snmp/library/oid_stash.h" struct netsnmp_oid_stash_node_s; typedef int (NetSNMPStashDump) (char *, size_t, void *, struct netsnmp_oid_stash_node_s *); typedef void (NetSNMPStashFreeNode) (void *); typedef struct netsnmp_oid_stash_node_s { oid value; struct netsnmp_oid_stash_node_s **children; size_t children_size; struct netsnmp_oid_stash_node_s *next_sibling; struct netsnmp_oid_stash_node_s *prev_sibling; struct netsnmp_oid_stash_node_s *parent; void *thedata; } netsnmp_oid_stash_node; typedef struct netsnmp_oid_stash_save_info_s { const char *token; netsnmp_oid_stash_node **root; NetSNMPStashDump *dumpfn; } netsnmp_oid_stash_save_info; int netsnmp_oid_stash_add_data(netsnmp_oid_stash_node **root, oid * lookup, size_t lookup_len, void *mydata); SNMPCallback netsnmp_oid_stash_store_all; netsnmp_oid_stash_node *netsnmp_oid_stash_get_node(netsnmp_oid_stash_node *root, oid * lookup, size_t lookup_len); void *netsnmp_oid_stash_get_data(netsnmp_oid_stash_node *root, oid * lookup, size_t lookup_len); netsnmp_oid_stash_node * netsnmp_oid_stash_getnext_node(netsnmp_oid_stash_node *root, oid * lookup, size_t lookup_len); netsnmp_oid_stash_node *netsnmp_oid_stash_create_sized_node(size_t mysize); netsnmp_oid_stash_node *netsnmp_oid_stash_create_node(void); void netsnmp_oid_stash_store(netsnmp_oid_stash_node *root, const char *tokenname, NetSNMPStashDump *dumpfn, oid *curoid, size_t curoid_len); void netsnmp_oid_stash_free(netsnmp_oid_stash_node **root, NetSNMPStashFreeNode *freefn); NetSNMPStashFreeNode netsnmp_oid_stash_no_free; # 50 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/check_varbind.h" 1 # 13 "../../include/net-snmp/library/check_varbind.h" int netsnmp_check_vb_type(const netsnmp_variable_list *var, int type); int netsnmp_check_vb_size(const netsnmp_variable_list *var, size_t size ); int netsnmp_check_vb_max_size(const netsnmp_variable_list *var, size_t size ); int netsnmp_check_vb_range(const netsnmp_variable_list *var, size_t low, size_t high ); int netsnmp_check_vb_size_range(const netsnmp_variable_list *var, size_t low, size_t high ); int netsnmp_check_vb_type_and_size(const netsnmp_variable_list *var, int type, size_t size); int netsnmp_check_vb_type_and_max_size(const netsnmp_variable_list *var, int type, size_t size); int netsnmp_check_vb_oid(const netsnmp_variable_list *var); int netsnmp_check_vb_int(const netsnmp_variable_list *var); int netsnmp_check_vb_uint(const netsnmp_variable_list *var); int netsnmp_check_vb_int_range(const netsnmp_variable_list *var, int low, int high); int netsnmp_check_vb_truthvalue(const netsnmp_variable_list *var); int netsnmp_check_vb_rowstatus_value(const netsnmp_variable_list *var); int netsnmp_check_vb_rowstatus(const netsnmp_variable_list *var, int old_val); int netsnmp_check_vb_storagetype(const netsnmp_variable_list *var, int old_val); # 54 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/container.h" 1 # 18 "../../include/net-snmp/library/container.h" # 1 "../../include/net-snmp/library/factory.h" 1 # 9 "../../include/net-snmp/library/factory.h" typedef void * (netsnmp_factory_produce_f)(void); typedef int (netsnmp_factory_produce_noalloc_f)(void *); typedef struct netsnmp_factory_s { const char *product; netsnmp_factory_produce_f *produce; netsnmp_factory_produce_noalloc_f *produce_noalloc; } netsnmp_factory; void netsnmp_factory_init(void); int netsnmp_factory_register(netsnmp_factory *f); netsnmp_factory* netsnmp_factory_get(const char* product); void * netsnmp_factory_produce(const char* product); int netsnmp_factory_produce_noalloc(const char *product, void *memory); enum { FACTORY_NOERROR = 0, FACTORY_EXISTS, FACTORY_NOTFOUND, FACTORY_NOMEMORY, FACTORY_GENERR, FACTORY_MAXIMUM_ERROR }; # 19 "../../include/net-snmp/library/container.h" 2 # 1 "../../include/net-snmp/library/snmp_logging.h" 1 # 9 "../../include/net-snmp/library/snmp_logging.h" # 1 "/usr/include/syslog.h" 1 3 4 # 148 "/usr/include/syslog.h" 3 4 struct syslog_data { int log_file; int connected; int opened; int log_stat; const char *log_tag; int log_fac; int log_mask; }; # 195 "/usr/include/syslog.h" 3 4 void closelog(void); void openlog(const char *, int, int); int setlogmask(int); void syslog(int, const char *, ...) __attribute__((__format__(__syslog__,2,3))); void vsyslog(int, const char *, __builtin_va_list); void closelog_r(struct syslog_data *); void openlog_r(const char *, int, int, struct syslog_data *); int setlogmask_r(int, struct syslog_data *); void syslog_r(int, struct syslog_data *, const char *, ...) __attribute__((__format__(__syslog__,3,4))); void vsyslog_r(int, struct syslog_data *, const char *, __builtin_va_list); # 10 "../../include/net-snmp/library/snmp_logging.h" 2 # 1 "/usr/include/stdarg.h" 1 3 4 # 28 "/usr/include/stdarg.h" 3 4 typedef __builtin_va_list __gnuc_va_list; # 42 "/usr/include/stdarg.h" 3 4 typedef __gnuc_va_list va_list; # 13 "../../include/net-snmp/library/snmp_logging.h" 2 # 28 "../../include/net-snmp/library/snmp_logging.h" struct snmp_log_message { int priority; const char *msg; }; void init_snmp_logging(void); int snmp_get_do_logging(void); void snmp_disable_syslog(void); void snmp_disable_filelog(void); void snmp_disable_stderrlog(void); void snmp_disable_calllog(void); void snmp_disable_log(void); void snmp_enable_syslog(void); void snmp_enable_syslog_ident(const char *ident, const int facility); void snmp_enable_filelog(const char *logfilename, int dont_zero_log); void snmp_enable_stderrlog(void); void snmp_enable_calllog(void); int snmp_stderrlog_status(void); int snmp_log(int priority, const char *format, ...) __attribute__ ((__format__ (__printf__, 2, 3))); int snmp_vlog(int priority, const char *format, va_list ap); # 79 "../../include/net-snmp/library/snmp_logging.h" void snmp_log_perror(const char *s); # 89 "../../include/net-snmp/library/snmp_logging.h" int snmp_log_options(char *optarg, int argc, char *const *argv); void snmp_log_options_usage(const char *lead, FILE *outf); char *snmp_log_syslogname(const char *syslogname); typedef struct netsnmp_log_handler_s netsnmp_log_handler; typedef int (NetsnmpLogHandler)(netsnmp_log_handler*, int, const char *); NetsnmpLogHandler log_handler_stdouterr; NetsnmpLogHandler log_handler_file; NetsnmpLogHandler log_handler_syslog; NetsnmpLogHandler log_handler_callback; NetsnmpLogHandler log_handler_null; struct netsnmp_log_handler_s { int enabled; int priority; int pri_max; int type; const char *token; NetsnmpLogHandler *handler; int imagic; void *magic; netsnmp_log_handler *next, *prev; }; netsnmp_log_handler *get_logh_head( void ); netsnmp_log_handler *netsnmp_register_loghandler( int type, int pri ); netsnmp_log_handler *netsnmp_find_loghandler( const char *token ); int netsnmp_add_loghandler( netsnmp_log_handler *logh ); int netsnmp_remove_loghandler( netsnmp_log_handler *logh ); int netsnmp_enable_loghandler( const char *token ); int netsnmp_disable_loghandler( const char *token ); void netsnmp_logging_restart(void); # 20 "../../include/net-snmp/library/container.h" 2 # 30 "../../include/net-snmp/library/container.h" struct netsnmp_iterator_s; struct netsnmp_container_s; typedef int (netsnmp_container_rc)(struct netsnmp_container_s *); typedef struct netsnmp_iterator_s * (netsnmp_container_it) (struct netsnmp_container_s *); typedef size_t (netsnmp_container_size)(struct netsnmp_container_s *); typedef int (netsnmp_container_op)(struct netsnmp_container_s *, const void *data); typedef void * (netsnmp_container_rtn)(struct netsnmp_container_s *, const void *data); typedef void (netsnmp_container_obj_func)(void *data, void *context); typedef void (netsnmp_container_func)(struct netsnmp_container_s *, netsnmp_container_obj_func *, void *context); typedef netsnmp_void_array * (netsnmp_container_set) (struct netsnmp_container_s *, void *data); typedef int (netsnmp_container_compare)(const void *lhs, const void *rhs); typedef struct netsnmp_container_s { void * container_data; netsnmp_container_size *get_size; netsnmp_container_rc *init; # 117 "../../include/net-snmp/library/container.h" netsnmp_container_rc *cfree; netsnmp_container_op *insert; netsnmp_container_op *remove; netsnmp_container_op *release; # 144 "../../include/net-snmp/library/container.h" netsnmp_container_rtn *find; netsnmp_container_rtn *find_next; # 160 "../../include/net-snmp/library/container.h" netsnmp_container_set *get_subset; netsnmp_container_it *get_iterator; netsnmp_container_func *for_each; netsnmp_container_func *clear; # 187 "../../include/net-snmp/library/container.h" netsnmp_container_compare *compare; netsnmp_container_compare *ncompare; char *container_name; u_long sync; struct netsnmp_container_s *next, *prev; } netsnmp_container; void netsnmp_container_init_list(void); void netsnmp_container_free_list(void); int netsnmp_container_register(const char* name, netsnmp_factory *f); netsnmp_container * netsnmp_container_find(const char *type_list); netsnmp_container * netsnmp_container_get(const char *type); void netsnmp_container_add_index(netsnmp_container *primary, netsnmp_container *new_index); netsnmp_factory *netsnmp_container_get_factory(const char *type); int netsnmp_compare_netsnmp_index(const void *lhs, const void *rhs); int netsnmp_ncompare_netsnmp_index(const void *lhs, const void *rhs); int netsnmp_compare_cstring(const void * lhs, const void * rhs); int netsnmp_ncompare_cstring(const void * lhs, const void * rhs); int netsnmp_compare_mem(const char * lhs, size_t lhs_len, const char * rhs, size_t rhs_len); void netsnmp_container_simple_free(void *data, void *context); # 308 "../../include/net-snmp/library/container.h" static inline int CONTAINER_INSERT(netsnmp_container *x, const void *k) { int rc2, rc = 0; while(x->prev) x = x->prev; while(x) { rc2 = x->insert(x,k); if (rc2) { snmp_log(3,"error on subcontainer insert (%d)\n", rc2); rc = rc2; } x = x->next; } return rc; } static inline int CONTAINER_REMOVE(netsnmp_container *x, const void *k) { int rc2, rc = 0; while(x->next) x = x->next; while(x) { rc2 = x->remove(x,k); if (rc2) { snmp_log(3,"error on subcontainer remove (%d)\n", rc2); rc = rc2; } x = x->prev; } return rc; } static inline int CONTAINER_FREE(netsnmp_container *x) { int rc2, rc = 0; while(x->next) x = x->next; while(x) { netsnmp_container *tmp; tmp = x->prev; if (0L != x->container_name) do { if (x->container_name) { free((void *)x->container_name); x->container_name=0L; } } while(0); rc2 = x->cfree(x); if (rc2) { snmp_log(3,"error on subcontainer cfree (%d)\n", rc2); rc = rc2; } x = tmp; } return rc; } # 387 "../../include/net-snmp/library/container.h" static inline void CONTAINER_CLEAR(netsnmp_container *x, netsnmp_container_obj_func *f, void *c) { while(x->next) x = x->next; while(x->prev) { x->clear(x, 0L, c); x = x->prev; } x->clear(x, f, c); } # 408 "../../include/net-snmp/library/container.h" static inline netsnmp_container *SUBCONTAINER_FIND(netsnmp_container *x, const char* name) { if ((0L == x) || (0L == name)) return 0L; while(x->prev) x = x->prev; while(x) { if ((0L != x->container_name) && (0 == strcmp(name,x->container_name))) break; x = x->next; } return x; } # 437 "../../include/net-snmp/library/container.h" typedef int (netsnmp_iterator_rc)(struct netsnmp_iterator_s *); typedef void * (netsnmp_iterator_rtn)(struct netsnmp_iterator_s *); typedef struct netsnmp_iterator_s { netsnmp_container *container; u_long sync; netsnmp_iterator_rc *reset; netsnmp_iterator_rc *release; netsnmp_iterator_rtn *first; netsnmp_iterator_rtn *curr; netsnmp_iterator_rtn *last; netsnmp_iterator_rtn *next; } netsnmp_iterator; # 55 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/container_binary_array.h" 1 # 20 "../../include/net-snmp/library/container_binary_array.h" void netsnmp_container_binary_array_init(void); netsnmp_container * netsnmp_container_get_binary_array(void); netsnmp_factory * netsnmp_container_get_binary_array_factory(void); int netsnmp_binary_array_remove(netsnmp_container *c, const void *key, void **save); void netsnmp_binary_array_release(netsnmp_container *c); void netsnmp_container_binary_array_init(void); # 56 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/container_list_ssll.h" 1 # 16 "../../include/net-snmp/library/container_list_ssll.h" netsnmp_container *netsnmp_container_get_sorted_singly_linked_list(void); netsnmp_container *netsnmp_container_get_singly_linked_list(int fifo); void netsnmp_container_ssll_init(void); # 57 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/container_iterator.h" 1 # 15 "../../include/net-snmp/library/container_iterator.h" typedef int (Netsnmp_Iterator_Loop_Key) (void *iterator_ctx, netsnmp_ref_void* loop_ctx, netsnmp_ref_void* key); typedef int (Netsnmp_Iterator_Loop_Data)(void *iterator_ctx, netsnmp_ref_void* loop_ctx, netsnmp_ref_void* data); typedef int (Netsnmp_Iterator_Ctx) (void *iterator_ctx, netsnmp_ref_void* loop_ctx); typedef int (Netsnmp_Iterator_Ctx_Dup) (void *iterator_ctx, netsnmp_ref_void* loop_ctx, netsnmp_ref_void* dup_ctx, int reuse); typedef int (Netsnmp_Iterator_Op) (void *iterator_ctx); typedef int (Netsnmp_Iterator_Data) (void *iterator_ctx, const void *data); void netsnmp_container_iterator_init(void); netsnmp_container* netsnmp_container_iterator_get( void *iterator_user_ctx, netsnmp_container_compare * compare, Netsnmp_Iterator_Loop_Key * get_first, Netsnmp_Iterator_Loop_Key * get_next, Netsnmp_Iterator_Loop_Data * get_data, Netsnmp_Iterator_Ctx_Dup * save_pos, Netsnmp_Iterator_Ctx * init_loop_ctx, Netsnmp_Iterator_Ctx * cleanup_loop_ctx, Netsnmp_Iterator_Data * free_user_ctx, int sorted); void netsnmp_container_iterator_set_data_cb(netsnmp_container *c, Netsnmp_Iterator_Data * insert_data, Netsnmp_Iterator_Data * remove_data, Netsnmp_Iterator_Op * get_size); # 58 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/library/snmp_assert.h" 1 # 60 "../../include/net-snmp/utilities.h" 2 # 1 "../../include/net-snmp/version.h" 1 # 12 "../../include/net-snmp/version.h" const char *netsnmp_get_version(void); # 62 "../../include/net-snmp/utilities.h" 2 # 75 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/session_api.h" 1 # 26 "../../include/net-snmp/session_api.h" # 1 "../../include/net-snmp/library/snmp_transport.h" 1 # 25 "../../include/net-snmp/library/snmp_transport.h" extern oid netsnmpUDPDomain[]; extern oid netsnmpCLNSDomain[]; extern oid netsnmpCONSDomain[]; extern oid netsnmpDDPDomain[]; extern oid netsnmpIPXDomain[]; extern size_t netsnmpUDPDomain_len; extern size_t netsnmpCLNSDomain_len; extern size_t netsnmpCONSDomain_len; extern size_t netsnmpDDPDomain_len; extern size_t netsnmpIPXDomain_len; typedef struct netsnmp_transport_s { const oid *domain; int domain_length; unsigned char *local; int local_length; unsigned char *remote; int remote_length; int sock; unsigned int flags; void *data; int data_length; size_t msgMaxSize; int (*f_recv) (struct netsnmp_transport_s *, void *, int, void **, int *); int (*f_send) (struct netsnmp_transport_s *, void *, int, void **, int *); int (*f_close) (struct netsnmp_transport_s *); int (*f_accept) (struct netsnmp_transport_s *); char *(*f_fmtaddr)(struct netsnmp_transport_s *, void *, int); } netsnmp_transport; typedef struct netsnmp_transport_list_s { netsnmp_transport *transport; struct netsnmp_transport_list_s *next; } netsnmp_transport_list; typedef struct netsnmp_tdomain_s { const oid *name; size_t name_length; const char **prefix; netsnmp_transport *(*f_create_from_tstring) (const char *, int); netsnmp_transport *(*f_create_from_ostring) (const u_char *, size_t, int); struct netsnmp_tdomain_s *next; } netsnmp_tdomain; int netsnmp_transport_add_to_list(netsnmp_transport_list **transport_list, netsnmp_transport *transport); int netsnmp_transport_remove_from_list(netsnmp_transport_list **transport_list, netsnmp_transport *transport); netsnmp_transport *netsnmp_transport_copy(netsnmp_transport *t); void netsnmp_transport_free(netsnmp_transport *t); # 137 "../../include/net-snmp/library/snmp_transport.h" int netsnmp_tdomain_support(const oid *in_oid, size_t in_len, const oid **out_oid, size_t *out_len); int netsnmp_tdomain_register(netsnmp_tdomain *domain); int netsnmp_tdomain_unregister(netsnmp_tdomain *domain); void netsnmp_clear_tdomain_list(void); void netsnmp_tdomain_init(void); netsnmp_transport *netsnmp_tdomain_transport(const char *string, int local, const char *default_domain); netsnmp_transport *netsnmp_tdomain_transport_oid(const oid * dom, size_t dom_len, const u_char * o, size_t o_len, int local); # 27 "../../include/net-snmp/session_api.h" 2 # 1 "../../include/net-snmp/library/snmpCallbackDomain.h" 1 # 16 "../../include/net-snmp/library/snmpCallbackDomain.h" typedef struct netsnmp_callback_pass_s { int return_transport_num; netsnmp_pdu *pdu; struct netsnmp_callback_pass_s *next; } netsnmp_callback_pass; typedef struct netsnmp_callback_info_s { int linkedto; void *parent_data; netsnmp_callback_pass *data; int callback_num; int pipefds[2]; } netsnmp_callback_info; netsnmp_transport *netsnmp_callback_transport(int); int netsnmp_callback_hook_parse(netsnmp_session * sp, netsnmp_pdu *pdu, u_char * packetptr, size_t len); int netsnmp_callback_hook_build(netsnmp_session * sp, netsnmp_pdu *pdu, u_char * ptk, size_t * len); int netsnmp_callback_check_packet(u_char * pkt, size_t len); netsnmp_pdu *netsnmp_callback_create_pdu(netsnmp_transport *transport, void *opaque, size_t olength); netsnmp_session *netsnmp_callback_open(int attach_to, int (*return_func) (int op, netsnmp_session * session, int reqid, netsnmp_pdu *pdu, void *magic), int (*fpre_parse) (netsnmp_session *, struct netsnmp_transport_s *, void *, int), int (*fpost_parse) (netsnmp_session *, netsnmp_pdu *, int)); void netsnmp_clear_callback_list(void); # 28 "../../include/net-snmp/session_api.h" 2 # 1 "../../include/net-snmp/library/snmpUnixDomain.h" 1 # 14 "../../include/net-snmp/library/snmpUnixDomain.h" # 1 "/usr/include/sys/un.h" 1 3 4 # 41 "/usr/include/sys/un.h" 3 4 struct sockaddr_un { unsigned char sun_len; unsigned char sun_family; char sun_path[104]; }; # 15 "../../include/net-snmp/library/snmpUnixDomain.h" 2 # 26 "../../include/net-snmp/library/snmpUnixDomain.h" extern oid netsnmp_UnixDomain[]; netsnmp_transport *netsnmp_unix_transport(struct sockaddr_un *addr, int local); void netsnmp_unix_agent_config_tokens_register(void); void netsnmp_unix_parse_security(const char *token, char *param); int netsnmp_unix_getSecName(void *opaque, int olength, const char *community, size_t community_len, char **secName, char **contextName); void netsnmp_unix_ctor(void); # 30 "../../include/net-snmp/session_api.h" 2 # 1 "../../include/net-snmp/library/snmpUDPDomain.h" 1 # 18 "../../include/net-snmp/library/snmpUDPDomain.h" netsnmp_transport *netsnmp_udp_transport(struct sockaddr_in *addr, int local); # 27 "../../include/net-snmp/library/snmpUDPDomain.h" int netsnmp_sockaddr_in(struct sockaddr_in *addr, const char *peername, int remote_port); void netsnmp_udp_agent_config_tokens_register(void); void netsnmp_udp_parse_security(const char *token, char *param); int netsnmp_udp_getSecName(void *opaque, int olength, const char *community, size_t community_len, char **secname, char **contextName); int netsnmp_sock_buffer_set(int s, int optname, int local, int size); void netsnmp_udp_ctor(void); # 33 "../../include/net-snmp/session_api.h" 2 # 1 "../../include/net-snmp/library/snmpTCPDomain.h" 1 # 26 "../../include/net-snmp/library/snmpTCPDomain.h" extern oid netsnmp_snmpTCPDomain[]; netsnmp_transport *netsnmp_tcp_transport(struct sockaddr_in *addr, int local); void netsnmp_tcp_ctor(void); # 36 "../../include/net-snmp/session_api.h" 2 # 50 "../../include/net-snmp/session_api.h" # 1 "../../include/net-snmp/library/ucd_compat.h" 1 # 16 "../../include/net-snmp/library/ucd_compat.h" void snmp_set_dump_packet(int); int snmp_get_dump_packet(void); void snmp_set_quick_print(int); int snmp_get_quick_print(void); void snmp_set_suffix_only(int); int snmp_get_suffix_only(void); void snmp_set_full_objid(int); int snmp_get_full_objid(void); void snmp_set_random_access(int); int snmp_get_random_access(void); void snmp_set_mib_warnings(int); void snmp_set_mib_errors(int); void snmp_set_save_descriptions(int); void snmp_set_mib_comment_term(int); void snmp_set_mib_parse_label(int); # 51 "../../include/net-snmp/session_api.h" 2 # 76 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/pdu_api.h" 1 # 77 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/mib_api.h" 1 # 22 "../../include/net-snmp/mib_api.h" # 1 "../../include/net-snmp/library/mib.h" 1 # 111 "../../include/net-snmp/library/mib.h" struct variable_list; struct enum_list; void print_mib(FILE * fp); void print_ascii_dump(FILE *); int read_objid(const char *, oid *, size_t *); void register_mib_handlers(void); void netsnmp_set_mib_directory(const char *dir); char *netsnmp_get_mib_directory(void); void netsnmp_fixup_mib_directory(void); void init_mib(void); void shutdown_mib(void); void print_description(oid *, size_t, int); void fprint_description(FILE *, oid *, size_t, int); int snprint_description(char *, size_t, oid *, size_t, int); int sprint_realloc_description(u_char **, size_t *, size_t *, int, oid *, size_t, int); int get_module_node(const char *, const char *, oid *, size_t *); int get_wild_node(const char *, oid *, size_t *); int get_node(const char *, oid *, size_t *); oid *snmp_parse_oid(const char *, oid *, size_t *); struct tree *get_symbol(oid *, size_t, struct tree *, char *); struct tree *get_tree(const oid *, size_t, struct tree *); struct tree *get_tree_head(void); void set_function(struct tree *); int parse_one_oid_index(oid ** oidStart, size_t * oidLen, netsnmp_variable_list * data, int complete); int parse_oid_indexes(oid * oidIndex, size_t oidLen, netsnmp_variable_list * data); int build_oid_noalloc(oid * in, size_t in_len, size_t * out_len, oid * prefix, size_t prefix_len, netsnmp_variable_list * indexes); int build_oid(oid ** out, size_t * out_len, oid * prefix, size_t prefix_len, netsnmp_variable_list * indexes); int build_oid_segment(netsnmp_variable_list * var); void print_variable(const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); void fprint_variable(FILE * fp, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); int snprint_variable(char *buf, size_t buf_len, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); int sprint_realloc_variable(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); struct tree * netsnmp_sprint_realloc_objid_tree(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, int *buf_overflow, const oid * objid, size_t objidlen); void netsnmp_sprint_realloc_objid(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, int *buf_overflow, const oid * objid, size_t objidlen); void print_value(const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); void fprint_value(FILE * fp, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); int snprint_value(char *buf, size_t buf_len, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); int sprint_realloc_value(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const oid * objid, size_t objidlen, const netsnmp_variable_list * variable); void print_objid(const oid * objid, size_t objidlen); void fprint_objid(FILE * fp, const oid * objid, size_t objidlen); int snprint_objid(char *buf, size_t buf_len, const oid * objid, size_t objidlen); int sprint_realloc_objid(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const oid * objid, size_t objidlen); int sprint_realloc_by_type(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list * var, const struct enum_list *enums, const char *hint, const char *units); int sprint_realloc_hexstring(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const u_char *, size_t); int sprint_realloc_asciistring(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const u_char * cp, size_t len); int sprint_realloc_octet_string(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_opaque(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_object_identifier(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_timeticks(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_hinted_integer(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, long, const char, const char *, const char *); int sprint_realloc_integer(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_uinteger(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_gauge(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_counter(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_networkaddress(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_ipaddress(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_null(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_bitstring(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_nsapaddress(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_counter64(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_badtype(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_float(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int sprint_realloc_double(u_char ** buf, size_t * buf_len, size_t * out_len, int allow_realloc, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_by_type(char *buf, size_t buf_len, netsnmp_variable_list * var, const struct enum_list *enums, const char *hint, const char *units); int snprint_hexstring(char *buf, size_t buf_len, const u_char *, size_t); int snprint_asciistring(char *buf, size_t buf_len, const u_char * cp, size_t len); int snprint_octet_string(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_opaque(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_object_identifier(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_timeticks(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_hinted_integer(char *buf, size_t buf_len, long, const char *, const char *); int snprint_integer(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_uinteger(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_gauge(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_counter(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_networkaddress(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_ipaddress(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_null(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_bitstring(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_nsapaddress(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_counter64(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_badtype(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_float(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); int snprint_double(char *buf, size_t buf_len, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); void print_oid_report(FILE *); void print_oid_report_enable_labeledoid(void); void print_oid_report_enable_oid(void); void print_oid_report_enable_suffix(void); void print_oid_report_enable_symbolic(void); void print_oid_report_enable_mibchildoid(void); const char *parse_octet_hint(const char *hint, const char *value, unsigned char **new_val, int *new_val_len); void clear_tree_flags(register struct tree *tp); char *snmp_out_toggle_options(char *); void snmp_out_toggle_options_usage(const char *, FILE *); char *snmp_in_toggle_options(char *); char *snmp_in_options(char *, int, char * const *); void snmp_in_toggle_options_usage(const char *, FILE *); u_char mib_to_asn_type(int mib_type); int netsnmp_str2oid(const char *S, oid * O, int L); # 23 "../../include/net-snmp/mib_api.h" 2 # 1 "../../include/net-snmp/library/parse.h" 1 # 36 "../../include/net-snmp/library/parse.h" struct variable_list; struct enum_list { struct enum_list *next; int value; char *label; }; struct range_list { struct range_list *next; int low, high; }; struct index_list { struct index_list *next; char *ilabel; char isimplied; }; struct varbind_list { struct varbind_list *next; char *vblabel; }; struct node { struct node *next; char *label; u_long subid; int modid; char *parent; int tc_index; int type; int access; int status; struct enum_list *enums; struct range_list *ranges; struct index_list *indexes; char *augments; struct varbind_list *varbinds; char *hint; char *units; char *description; char *reference; char *defaultValue; char *filename; int lineno; }; struct tree { struct tree *child_list; struct tree *next_peer; struct tree *next; struct tree *parent; char *label; u_long subid; int modid; int number_modules; int *module_list; int tc_index; int type; int access; int status; struct enum_list *enums; struct range_list *ranges; struct index_list *indexes; char *augments; struct varbind_list *varbinds; char *hint; char *units; int (*printomat) (u_char **, size_t *, size_t *, int, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); void (*printer) (char *, const netsnmp_variable_list *, const struct enum_list *, const char *, const char *); char *description; char *reference; int reported; char *defaultValue; }; struct module_import { char *label; int modid; }; struct module { char *name; char *file; struct module_import *imports; int no_imports; int modid; struct module *next; }; struct module_compatability { const char *old_module; const char *new_module; const char *tag; size_t tag_len; struct module_compatability *next; }; # 211 "../../include/net-snmp/library/parse.h" struct tree *netsnmp_read_module(const char *); struct tree *read_module(const char *); struct tree *read_mib(const char *); struct tree *read_all_mibs(void); int netsnmp_unload_module(const char *name); int unload_module(const char *name); void unload_all_mibs(void); void init_mib_internals(void); int add_mibfile(const char*, const char*, FILE *); int add_mibdir(const char *); void add_module_replacement(const char *, const char *, const char *, int); int which_module(const char *); char *module_name(int, char *); void print_subtree(FILE *, struct tree *, int); void print_ascii_dump_tree(FILE *, struct tree *, int); struct tree *find_tree_node(const char *, int); const char *get_tc_descriptor(int); const char *get_tc_description(int); struct tree *find_best_tree_node(const char *, struct tree *, u_int *); struct tree *find_node(const char *, struct tree *); struct tree *find_node2(const char *, const char *); struct module *find_module(int); void adopt_orphans(void); char *snmp_mib_toggle_options(char *options); void snmp_mib_toggle_options_usage(const char *lead, FILE * outf); void print_mib(FILE *); void print_mib_tree(FILE *, struct tree *, int); int get_mib_parse_error_count(void); int snmp_get_token(FILE * fp, char *token, int maxtlen); struct tree *find_best_tree_node(const char *name, struct tree *tree_top, u_int * match); # 25 "../../include/net-snmp/mib_api.h" 2 # 78 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/varbind_api.h" 1 # 79 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/config_api.h" 1 # 22 "../../include/net-snmp/config_api.h" # 1 "../../include/net-snmp/library/read_config.h" 1 # 24 "../../include/net-snmp/library/read_config.h" struct config_files { char *fileHeader; struct config_line *start; struct config_files *next; }; struct config_line { char *config_token; void (*parse_line) (const char *, char *); void (*free_func) (void); struct config_line *next; char config_time; char *help; }; struct read_config_memory { char *line; struct read_config_memory *next; }; int netsnmp_config(char *); void netsnmp_config_remember(char *); void netsnmp_config_process_memories(void); void read_config(const char *, struct config_line *, int); void read_configs(void); void read_premib_configs(void); void read_config_files(int); void free_config(void); void config_perror(const char *); void config_pwarn(const char *); char *skip_white(char *); char *skip_not_white(char *); char *skip_token(char *); char *copy_nword(char *, char *, int); char *copy_word(char *, char *); void read_config_with_type(const char *, const char *); struct config_line *register_config_handler(const char *, const char *, void (*parser) (const char *, char *), void (*releaser) (void), const char *); struct config_line *register_app_config_handler(const char *, void (*parser) (const char *, char *), void (*releaser) (void), const char *); struct config_line *register_prenetsnmp_mib_handler(const char *, const char *, void (*parser) (const char *, char *), void (*releaser) (void), const char *); struct config_line *register_app_prenetsnmp_mib_handler(const char *, void (*parser) (const char *, char *), void (*releaser) (void), const char *); void unregister_config_handler(const char *, const char *); void unregister_app_config_handler(const char *); void unregister_all_config_handlers(void); void read_config_print_usage(const char *lead); char *read_config_save_octet_string(char *saveto, u_char * str, size_t len); char *read_config_read_octet_string(char *readfrom, u_char ** str, size_t * len); char *read_config_read_objid(char *readfrom, oid ** objid, size_t * len); char *read_config_save_objid(char *saveto, oid * objid, size_t len); char *read_config_read_data(int type, char *readfrom, void *dataptr, size_t * len); char *read_config_read_memory(int type, char *readfrom, char *dataptr, size_t * len); char *read_config_store_data(int type, char *storeto, void *dataptr, size_t * len); char *read_config_store_data_prefix(char prefix, int type, char *storeto, void *dataptr, size_t len); void read_config_store(const char *type, const char *line); void read_app_config_store(const char *line); void snmp_save_persistent(const char *type); void snmp_clean_persistent(const char *type); struct config_line *read_config_get_handlers(const char *type); void snmp_config_remember_in_list(char *line, struct read_config_memory **mem); void snmp_config_process_memory_list(struct read_config_memory **mem, int, int); void snmp_config_remember_free_list(struct read_config_memory **mem); void set_configuration_directory(const char *dir); const char *get_configuration_directory(void); void set_persistent_directory(const char *dir); const char *get_persistent_directory(void); void set_temp_file_pattern(const char *pattern); const char *get_temp_file_pattern(void); void handle_long_opt(const char *myoptarg); # 23 "../../include/net-snmp/config_api.h" 2 # 1 "../../include/net-snmp/library/default_store.h" 1 # 143 "../../include/net-snmp/library/default_store.h" int netsnmp_ds_set_boolean(int storeid, int which, int value); int netsnmp_ds_get_boolean(int storeid, int which); int netsnmp_ds_toggle_boolean(int storeid, int which); int netsnmp_ds_set_int(int storeid, int which, int value); int netsnmp_ds_get_int(int storeid, int which); int netsnmp_ds_set_string(int storeid, int which, const char *value); char *netsnmp_ds_get_string(int storeid, int which); int netsnmp_ds_set_void(int storeid, int which, void *value); void *netsnmp_ds_get_void(int storeid, int which); int netsnmp_ds_register_config(u_char type, const char *ftype, const char *token, int storeid, int which); int netsnmp_ds_register_premib(u_char type, const char *ftype, const char *token, int storeid, int which); void netsnmp_ds_shutdown(void); # 24 "../../include/net-snmp/config_api.h" 2 # 1 "../../include/net-snmp/library/snmp_parse_args.h" 1 int snmp_parse_args(int argc, char **argv, netsnmp_session *session, const char *localOpts, void (*proc)(int, char *const *, int)); void snmp_parse_args_descriptions(FILE *); void snmp_parse_args_usage(FILE *); # 27 "../../include/net-snmp/config_api.h" 2 # 1 "../../include/net-snmp/library/snmp_enum.h" 1 struct snmp_enum_list { struct snmp_enum_list *next; int value; char *label; }; # 40 "../../include/net-snmp/library/snmp_enum.h" int init_snmp_enum(const char *type); struct snmp_enum_list *se_find_list(unsigned int major, unsigned int minor); struct snmp_enum_list *se_find_slist(const char *listname); int se_store_in_list(struct snmp_enum_list *, unsigned int major, unsigned int minor); int se_find_value(unsigned int major, unsigned int minor, const char *label); int se_find_free_value(unsigned int major, unsigned int minor); char *se_find_label(unsigned int major, unsigned int minor, int value); int se_add_pair(unsigned int major, unsigned int minor, char *label, int value); # 61 "../../include/net-snmp/library/snmp_enum.h" char *se_find_label_in_slist(const char *listname, int value); int se_find_value_in_slist(const char *listname, const char *label); int se_find_free_value_in_slist(const char *listname); int se_add_pair_to_slist(const char *listname, char *label, int value); char *se_find_label_in_list(struct snmp_enum_list *list, int value); int se_find_value_in_list(struct snmp_enum_list *list, const char *label); int se_find_free_value_in_list(struct snmp_enum_list *list); int se_add_pair_to_list(struct snmp_enum_list **list, char *label, int value); void se_store_enum_list(struct snmp_enum_list *new_list, const char *token, char *type); void se_store_list(unsigned int major, unsigned int minor, char *type); void se_store_slist(const char *listname, char *type); int se_store_slist_callback(int majorID, int minorID, void *serverargs, void *clientargs); void se_read_conf(const char *word, char *cptr); void clear_snmp_enum(void); # 28 "../../include/net-snmp/config_api.h" 2 # 1 "../../include/net-snmp/library/vacm.h" 1 # 50 "../../include/net-snmp/library/vacm.h" struct vacm_groupEntry { int securityModel; char securityName[34]; char groupName[34]; int storageType; int status; u_long bitMask; struct vacm_groupEntry *reserved; struct vacm_groupEntry *next; }; struct vacm_accessEntry { char groupName[34]; char contextPrefix[34]; int securityModel; int securityLevel; int contextMatch; char readView[34]; char writeView[34]; char notifyView[34]; int storageType; int status; u_long bitMask; struct vacm_accessEntry *reserved; struct vacm_accessEntry *next; }; struct vacm_viewEntry { char viewName[34]; oid viewSubtree[128]; size_t viewSubtreeLen; u_char viewMask[34]; size_t viewMaskLen; int viewType; int viewStorageType; int viewStatus; u_long bitMask; struct vacm_viewEntry *reserved; struct vacm_viewEntry *next; }; void vacm_destroyViewEntry(const char *, oid *, size_t); void vacm_destroyAllViewEntries(void); struct vacm_viewEntry *vacm_getViewEntry(const char *, oid *, size_t, int); int vacm_checkSubtree(const char *, oid *, size_t); # 126 "../../include/net-snmp/library/vacm.h" void vacm_scanViewInit(void); struct vacm_viewEntry *vacm_scanViewNext(void); # 145 "../../include/net-snmp/library/vacm.h" struct vacm_viewEntry *vacm_createViewEntry(const char *, oid *, size_t); void vacm_destroyGroupEntry(int, const char *); void vacm_destroyAllGroupEntries(void); struct vacm_groupEntry *vacm_createGroupEntry(int, const char *); struct vacm_groupEntry *vacm_getGroupEntry(int, const char *); void vacm_scanGroupInit(void); struct vacm_groupEntry *vacm_scanGroupNext(void); void vacm_destroyAccessEntry(const char *, const char *, int, int); void vacm_destroyAllAccessEntries(void); struct vacm_accessEntry *vacm_createAccessEntry(const char *, const char *, int, int); struct vacm_accessEntry *vacm_getAccessEntry(const char *, const char *, int, int); void vacm_scanAccessInit(void); struct vacm_accessEntry *vacm_scanAccessNext(void); void vacm_destroySecurityEntry(const char *); struct vacm_securityEntry *vacm_createSecurityEntry(const char *); struct vacm_securityEntry *vacm_getSecurityEntry(const char *); void vacm_scanSecurityInit(void); struct vacm_securityEntry *vacm_scanSecurityEntry(void); int vacm_is_configured(void); void vacm_save(const char *token, const char *type); void vacm_save_view(struct vacm_viewEntry *view, const char *token, const char *type); void vacm_save_access(struct vacm_accessEntry *access_entry, const char *token, const char *type); void vacm_save_group(struct vacm_groupEntry *group_entry, const char *token, const char *type); void vacm_parse_config_view(const char *token, char *line); void vacm_parse_config_group(const char *token, char *line); void vacm_parse_config_access(const char *token, char *line); int store_vacm(int majorID, int minorID, void *serverarg, void *clientarg); struct vacm_viewEntry *netsnmp_view_get(struct vacm_viewEntry *head, const char *viewName, oid * viewSubtree, size_t viewSubtreeLen, int mode); # 29 "../../include/net-snmp/config_api.h" 2 # 80 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/output_api.h" 1 # 22 "../../include/net-snmp/output_api.h" # 1 "../../include/net-snmp/library/snmp_debug.h" 1 # 23 "../../include/net-snmp/library/snmp_debug.h" void debugmsg(const char *token, const char *format, ...); void debugmsgtoken(const char *token, const char *format, ...); void debug_combo_nc(const char *token, const char *format, ...); void debugmsg_oid(const char *token, const oid * theoid, size_t len); void debugmsg_suboid(const char *token, const oid * theoid, size_t len); void debugmsg_var(const char *token, netsnmp_variable_list * var); void debugmsg_oidrange(const char *token, const oid * theoid, size_t len, size_t var_subid, oid range_ubound); void debugmsg_hex(const char *token, u_char * thedata, size_t len); void debugmsg_hextli(const char *token, u_char * thedata, size_t len); void debug_indent_add(int amount); char *debug_indent(void); # 257 "../../include/net-snmp/library/snmp_debug.h" void debug_register_tokens(char *tokens); int debug_is_token_registered(const char *token); void snmp_debug_init(void); void snmp_set_do_debugging(int); int snmp_get_do_debugging(void); typedef struct netsnmp_token_descr_s { char *token_name; char enabled; } netsnmp_token_descr; extern int debug_num_tokens; extern netsnmp_token_descr dbg_tokens[256]; # 23 "../../include/net-snmp/output_api.h" 2 # 81 "../../include/net-snmp/net-snmp-includes.h" 2 # 1 "../../include/net-snmp/snmpv3_api.h" 1 # 26 "../../include/net-snmp/snmpv3_api.h" # 1 "../../include/net-snmp/library/snmpv3.h" 1 # 22 "../../include/net-snmp/library/snmpv3.h" int setup_engineID(u_char ** eidp, const char *text); void engineID_conf(const char *word, char *cptr); void engineBoots_conf(const char *, char *); void engineIDType_conf(const char *, char *); void engineIDNic_conf(const char *, char *); void snmpv3_authtype_conf(const char *word, char *cptr); void snmpv3_privtype_conf(const char *word, char *cptr); void usm_parse_create_usmUser(const char *token, char *line); void init_snmpv3(const char *); int init_snmpv3_post_config(int majorid, int minorid, void *serverarg, void *clientarg); int init_snmpv3_post_premib_config(int majorid, int minorid, void *serverarg, void *clientarg); void shutdown_snmpv3(const char *type); int snmpv3_store(int majorID, int minorID, void *serverarg, void *clientarg); u_long snmpv3_local_snmpEngineBoots(void); int snmpv3_clone_engineID(u_char **, size_t *, u_char *, size_t); size_t snmpv3_get_engineID(u_char * buf, size_t buflen); u_char *snmpv3_generate_engineID(size_t *); u_long snmpv3_local_snmpEngineTime(void); int get_default_secLevel(void); const oid *get_default_authtype(size_t *); const oid *get_default_privtype(size_t *); void snmpv3_set_engineBootsAndTime(int boots, int ttime); int free_engineID(int majorid, int minorid, void *serverarg, void *clientarg); int parse_secLevel_conf(const char* word, char *cptr); # 27 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/transform_oids.h" 1 # 13 "../../include/net-snmp/library/transform_oids.h" extern oid usmNoAuthProtocol[10]; extern oid usmHMACMD5AuthProtocol[10]; extern oid usmHMACSHA1AuthProtocol[10]; extern oid usmNoPrivProtocol[10]; extern oid usmDESPrivProtocol[10]; extern oid usmAESPrivProtocol[10]; extern oid *usmAES128PrivProtocol; # 28 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/keytools.h" 1 # 27 "../../include/net-snmp/library/keytools.h" int generate_Ku(const oid * hashtype, u_int hashtype_len, u_char * P, size_t pplen, u_char * Ku, size_t * kulen); int generate_kul(const oid * hashtype, u_int hashtype_len, u_char * engineID, size_t engineID_len, u_char * Ku, size_t ku_len, u_char * Kul, size_t * kul_len); int encode_keychange(const oid * hashtype, u_int hashtype_len, u_char * oldkey, size_t oldkey_len, u_char * newkey, size_t newkey_len, u_char * kcstring, size_t * kcstring_len); int decode_keychange(const oid * hashtype, u_int hashtype_len, u_char * oldkey, size_t oldkey_len, u_char * kcstring, size_t kcstring_len, u_char * newkey, size_t * newkey_len); # 29 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/scapi.h" 1 # 33 "../../include/net-snmp/library/scapi.h" int sc_get_properlength(const oid * hashtype, u_int hashtype_len); int sc_get_proper_priv_length(const oid * privtype, u_int privtype_len); int sc_init(void); int sc_shutdown(int majorID, int minorID, void *serverarg, void *clientarg); int sc_random(u_char * buf, size_t * buflen); int sc_generate_keyed_hash(const oid * authtype, size_t authtypelen, u_char * key, u_int keylen, u_char * message, u_int msglen, u_char * MAC, size_t * maclen); int sc_check_keyed_hash(const oid * authtype, size_t authtypelen, u_char * key, u_int keylen, u_char * message, u_int msglen, u_char * MAC, u_int maclen); int sc_encrypt(const oid * privtype, size_t privtypelen, u_char * key, u_int keylen, u_char * iv, u_int ivlen, u_char * plaintext, u_int ptlen, u_char * ciphertext, size_t * ctlen); int sc_decrypt(const oid * privtype, size_t privtypelen, u_char * key, u_int keylen, u_char * iv, u_int ivlen, u_char * ciphertext, u_int ctlen, u_char * plaintext, size_t * ptlen); int sc_hash(const oid * hashtype, size_t hashtypelen, u_char * buf, size_t buf_len, u_char * MAC, size_t * MAC_len); int sc_get_transform_type(oid * hashtype, u_int hashtype_len, int (**hash_fn) (const int mode, void **context, const u_char * data, const int data_len, u_char ** digest, size_t * digest_len)); # 30 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/lcd_time.h" 1 # 25 "../../include/net-snmp/library/lcd_time.h" typedef struct enginetime_struct { u_char *engineID; u_int engineID_len; u_int engineTime; u_int engineBoot; time_t lastReceivedEngineTime; u_int authenticatedFlag; struct enginetime_struct *next; } enginetime , *Enginetime; # 102 "../../include/net-snmp/library/lcd_time.h" int get_enginetime(u_char * engineID, u_int engineID_len, u_int * engine_boot, u_int * engine_time, u_int authenticated); int get_enginetime_ex(u_char * engineID, u_int engineID_len, u_int * engine_boot, u_int * engine_time, u_int * last_engine_time, u_int authenticated); int set_enginetime(u_char * engineID, u_int engineID_len, u_int engine_boot, u_int engine_time, u_int authenticated); Enginetime search_enginetime_list(u_char * engineID, u_int engineID_len); int hash_engineID(u_char * engineID, u_int engineID_len); void dump_etimelist_entry(Enginetime e, int count); void dump_etimelist(void); void free_enginetime(unsigned char *engineID, size_t engineID_len); # 31 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/snmp_secmod.h" 1 # 16 "../../include/net-snmp/library/snmp_secmod.h" struct snmp_secmod_def; struct snmp_secmod_outgoing_params { int msgProcModel; u_char *globalData; size_t globalDataLen; int maxMsgSize; int secModel; u_char *secEngineID; size_t secEngineIDLen; char *secName; size_t secNameLen; int secLevel; u_char *scopedPdu; size_t scopedPduLen; void *secStateRef; u_char *secParams; size_t *secParamsLen; u_char **wholeMsg; size_t *wholeMsgLen; size_t *wholeMsgOffset; netsnmp_pdu *pdu; netsnmp_session *session; }; struct snmp_secmod_incoming_params { int msgProcModel; size_t maxMsgSize; u_char *secParams; int secModel; int secLevel; u_char *wholeMsg; size_t wholeMsgLen; u_char *secEngineID; size_t *secEngineIDLen; char *secName; size_t *secNameLen; u_char **scopedPdu; size_t *scopedPduLen; size_t *maxSizeResponse; void **secStateRef; netsnmp_session *sess; netsnmp_pdu *pdu; u_char msg_flags; }; # 82 "../../include/net-snmp/library/snmp_secmod.h" typedef int (SecmodSessionCallback) (netsnmp_session *); typedef int (SecmodPduCallback) (netsnmp_pdu *); typedef int (Secmod2PduCallback) (netsnmp_pdu *, netsnmp_pdu *); typedef int (SecmodOutMsg) (struct snmp_secmod_outgoing_params *); typedef int (SecmodInMsg) (struct snmp_secmod_incoming_params *); typedef void (SecmodFreeState) (void *); typedef void (SecmodHandleReport) (void *sessp, netsnmp_transport *transport, netsnmp_session *, int result, netsnmp_pdu *origpdu); # 102 "../../include/net-snmp/library/snmp_secmod.h" struct snmp_secmod_def { SecmodSessionCallback *session_open; SecmodSessionCallback *session_close; SecmodPduCallback *pdu_free; Secmod2PduCallback *pdu_clone; SecmodPduCallback *pdu_timeout; SecmodFreeState *pdu_free_state_ref; SecmodOutMsg *encode_reverse; SecmodOutMsg *encode_forward; SecmodInMsg *decode; SecmodHandleReport *handle_report; }; struct snmp_secmod_list { int securityModel; struct snmp_secmod_def *secDef; struct snmp_secmod_list *next; }; int register_sec_mod(int, const char *, struct snmp_secmod_def *); struct snmp_secmod_def *find_sec_mod(int); int unregister_sec_mod(int); void init_secmod(void); void clear_sec_mod(void); # 36 "../../include/net-snmp/snmpv3_api.h" 2 # 1 "../../include/net-snmp/library/snmpv3-security-includes.h" 1 # 1 "../../include/net-snmp/library/snmpusm.h" 1 # 34 "../../include/net-snmp/library/snmpusm.h" struct usmStateReference { char *usr_name; size_t usr_name_length; u_char *usr_engine_id; size_t usr_engine_id_length; oid *usr_auth_protocol; size_t usr_auth_protocol_length; u_char *usr_auth_key; size_t usr_auth_key_length; oid *usr_priv_protocol; size_t usr_priv_protocol_length; u_char *usr_priv_key; size_t usr_priv_key_length; u_int usr_sec_level; }; # 59 "../../include/net-snmp/library/snmpusm.h" struct usmUser; struct usmUser { u_char *engineID; size_t engineIDLen; char *name; char *secName; oid *cloneFrom; size_t cloneFromLen; oid *authProtocol; size_t authProtocolLen; u_char *authKey; size_t authKeyLen; oid *privProtocol; size_t privProtocolLen; u_char *privKey; size_t privKeyLen; u_char *userPublicString; int userStatus; int userStorageType; void *usmDHUserAuthKeyChange; void *usmDHUserPrivKeyChange; struct usmUser *next; struct usmUser *prev; }; struct usmStateReference *usm_malloc_usmStateReference(void); void usm_free_usmStateReference(void *old); int usm_set_usmStateReference_name(struct usmStateReference *ref, char *name, size_t name_len); int usm_set_usmStateReference_engine_id(struct usmStateReference *ref, u_char * engine_id, size_t engine_id_len); int usm_set_usmStateReference_auth_protocol(struct usmStateReference *ref, oid * auth_protocol, size_t auth_protocol_len); int usm_set_usmStateReference_auth_key(struct usmStateReference *ref, u_char * auth_key, size_t auth_key_len); int usm_set_usmStateReference_priv_protocol(struct usmStateReference *ref, oid * priv_protocol, size_t priv_protocol_len); int usm_set_usmStateReference_priv_key(struct usmStateReference *ref, u_char * priv_key, size_t priv_key_len); int usm_set_usmStateReference_sec_level(struct usmStateReference *ref, int sec_level); int asn_predict_int_length(int type, long number, size_t len); int asn_predict_length(int type, u_char * ptr, size_t u_char_len); int usm_set_salt(u_char * iv, size_t * iv_length, u_char * priv_salt, size_t priv_salt_length, u_char * msgSalt); int usm_parse_security_parameters(u_char * secParams, size_t remaining, u_char * secEngineID, size_t * secEngineIDLen, u_int * boots_uint, u_int * time_uint, char *secName, size_t * secNameLen, u_char * signature, size_t * signature_length, u_char * salt, size_t * salt_length, u_char ** data_ptr); int usm_check_and_update_timeliness(u_char * secEngineID, size_t secEngineIDLen, u_int boots_uint, u_int time_uint, int *error); SecmodOutMsg usm_secmod_generate_out_msg; SecmodOutMsg usm_secmod_generate_out_msg; SecmodInMsg usm_secmod_process_in_msg; int usm_generate_out_msg(int, u_char *, size_t, int, int, u_char *, size_t, char *, size_t, int, u_char *, size_t, void *, u_char *, size_t *, u_char **, size_t *); int usm_rgenerate_out_msg(int, u_char *, size_t, int, int, u_char *, size_t, char *, size_t, int, u_char *, size_t, void *, u_char **, size_t *, size_t *); int usm_process_in_msg(int, size_t, u_char *, int, int, u_char *, size_t, u_char *, size_t *, char *, size_t *, u_char **, size_t *, size_t *, void **, netsnmp_session *, u_char); int usm_check_secLevel(int level, struct usmUser *user); struct usmUser *usm_get_userList(void); struct usmUser *usm_get_user(u_char * engineID, size_t engineIDLen, char *name); struct usmUser *usm_get_user_from_list(u_char * engineID, size_t engineIDLen, char *name, struct usmUser *userList, int use_default); struct usmUser *usm_add_user(struct usmUser *user); struct usmUser *usm_add_user_to_list(struct usmUser *user, struct usmUser *userList); struct usmUser *usm_free_user(struct usmUser *user); struct usmUser *usm_create_user(void); struct usmUser *usm_create_initial_user(const char *name, const oid * authProtocol, size_t authProtocolLen, const oid * privProtocol, size_t privProtocolLen); struct usmUser *usm_cloneFrom_user(struct usmUser *from, struct usmUser *to); struct usmUser *usm_remove_user(struct usmUser *user); struct usmUser *usm_remove_user_from_list(struct usmUser *user, struct usmUser **userList); char *get_objid(char *line, oid ** optr, size_t * len); void usm_save_users(const char *token, const char *type); void usm_save_users_from_list(struct usmUser *user, const char *token, const char *type); void usm_save_user(struct usmUser *user, const char *token, const char *type); SNMPCallback usm_store_users; struct usmUser *usm_read_user(char *line); void usm_parse_config_usmUser(const char *token, char *line); void usm_set_password(const char *token, char *line); void usm_set_user_password(struct usmUser *user, const char *token, char *line); void init_usm(void); void init_usm_conf(const char *app); int init_usm_post_config(int majorid, int minorid, void *serverarg, void *clientarg); int deinit_usm_post_config(int majorid, int minorid, void *serverarg, void *clientarg); void clear_user_list(void); # 3 "../../include/net-snmp/library/snmpv3-security-includes.h" 2 # 37 "../../include/net-snmp/snmpv3_api.h" 2 # 82 "../../include/net-snmp/net-snmp-includes.h" 2 # 62 "mibII/tcp.c" 2 # 1 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 1 # 9 "../../include/net-snmp/agent/net-snmp-agent-includes.h" # 1 "../../include/net-snmp/agent/snmp_agent.h" 1 # 40 "../../include/net-snmp/agent/snmp_agent.h" extern int log_addresses; extern int lastAddrAge; typedef struct netsnmp_request_info_s { netsnmp_variable_list *requestvb; netsnmp_data_list *parent_data; struct netsnmp_agent_request_info_s *agent_req_info; oid *range_end; size_t range_end_len; int delegated; int processed; int inclusive; int status; int index; int repeat; int orig_repeat; netsnmp_variable_list *requestvb_start; struct netsnmp_request_info_s *next; struct netsnmp_request_info_s *prev; struct netsnmp_subtree_s *subtree; } netsnmp_request_info; typedef struct netsnmp_set_info_s { int action; void *stateRef; void **oldData; int setCleanupFlags; } netsnmp_set_info; typedef struct netsnmp_tree_cache_s { struct netsnmp_subtree_s *subtree; netsnmp_request_info *requests_begin; netsnmp_request_info *requests_end; } netsnmp_tree_cache; # 158 "../../include/net-snmp/agent/snmp_agent.h" typedef struct netsnmp_agent_request_info_s { int mode; struct netsnmp_agent_session_s *asp; netsnmp_data_list *agent_data; } netsnmp_agent_request_info; typedef struct netsnmp_cachemap_s { int globalid; int cacheid; struct netsnmp_cachemap_s *next; } netsnmp_cachemap; typedef struct netsnmp_agent_session_s { int mode; netsnmp_session *session; netsnmp_pdu *pdu; netsnmp_pdu *orig_pdu; int rw; int exact; int status; int index; int oldmode; struct netsnmp_agent_session_s *next; netsnmp_agent_request_info *reqinfo; netsnmp_request_info *requests; netsnmp_tree_cache *treecache; netsnmp_variable_list **bulkcache; int treecache_len; int treecache_num; netsnmp_cachemap *cache_store; int vbcount; } netsnmp_agent_session; void netsnmp_addrcache_initialise(void); void netsnmp_addrcache_age(void); int handle_snmp_packet(int, netsnmp_session *, int, netsnmp_pdu *, void *); void snmp_agent_parse_config(char *, char *); netsnmp_agent_session *init_agent_snmp_session(netsnmp_session *, netsnmp_pdu *); void free_agent_snmp_session(netsnmp_agent_session *); void netsnmp_remove_and_free_agent_snmp_session(netsnmp_agent_session *asp); int getNextSessID(void); void dump_sess_list(void); int init_master_agent(void); void shutdown_master_agent(void); int agent_check_and_process(int block); void netsnmp_check_outstanding_agent_requests(void); int netsnmp_request_set_error(netsnmp_request_info *request, int error_value); int netsnmp_check_requests_error(netsnmp_request_info *reqs); int netsnmp_check_all_requests_error(netsnmp_agent_session *asp, int look_for_specific); int netsnmp_set_all_requests_error(netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests, int error_value); int netsnmp_request_set_error_all(netsnmp_request_info *requests, int error_value); int netsnmp_set_request_error(netsnmp_agent_request_info *reqinfo, netsnmp_request_info *request, int error_value); int netsnmp_set_mode_request_error(int mode, netsnmp_request_info *request, int error_value); u_long netsnmp_marker_uptime(marker_t pm); u_long netsnmp_timeval_uptime(struct timeval *tv); u_long netsnmp_get_agent_uptime(void); int netsnmp_check_transaction_id(int transaction_id); int netsnmp_agent_check_packet(netsnmp_session *, struct netsnmp_transport_s *, void *, int); int netsnmp_agent_check_parse(netsnmp_session *, netsnmp_pdu *, int); int netsnmp_allocate_globalcacheid(void); int netsnmp_remove_delegated_requests_for_session(netsnmp_session *sess); struct netsnmp_transport_s; int netsnmp_register_agent_nsap(struct netsnmp_transport_s *t); void netsnmp_deregister_agent_nsap(int handle); inline void netsnmp_agent_add_list_data(netsnmp_agent_request_info *agent, netsnmp_data_list *node); inline int netsnmp_agent_remove_list_data(netsnmp_agent_request_info *ari, const char * name); inline void * netsnmp_agent_get_list_data(netsnmp_agent_request_info *agent, const char *name); inline void netsnmp_free_agent_data_set(netsnmp_agent_request_info *agent); inline void netsnmp_free_agent_data_sets(netsnmp_agent_request_info *agent); inline void netsnmp_free_agent_request_info(netsnmp_agent_request_info *ari); # 10 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/snmp_vars.h" 1 # 46 "../../include/net-snmp/agent/snmp_vars.h" struct variable; typedef int (WriteMethod) (int action, u_char * var_val, u_char var_val_type, size_t var_val_len, u_char * statP, oid * name, size_t length); typedef u_char *(FindVarMethod) (struct variable * vp, oid * name, size_t * length, int exact, size_t * var_len, WriteMethod ** write_method); typedef int (AddVarMethod) (netsnmp_agent_session *asp, netsnmp_variable_list * vbp); struct nlist; extern long long_return; extern u_char return_buf[]; extern oid nullOid[]; extern int nullOidLen; struct variable { u_char magic; char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[128]; }; int init_agent(const char *); void shutdown_agent(void); int should_init(const char *module_name); void add_to_init_list(char *module_list); # 1 "../../include/net-snmp/agent/agent_handler.h" 1 # 25 "../../include/net-snmp/agent/agent_handler.h" struct netsnmp_handler_registration_s; # 47 "../../include/net-snmp/agent/agent_handler.h" typedef struct netsnmp_mib_handler_s { char *handler_name; void *myvoid; int flags; int (*access_method) (struct netsnmp_mib_handler_s *, struct netsnmp_handler_registration_s *, struct netsnmp_agent_request_info_s *, struct netsnmp_request_info_s *); struct netsnmp_mib_handler_s *next; struct netsnmp_mib_handler_s *prev; } netsnmp_mib_handler; # 93 "../../include/net-snmp/agent/agent_handler.h" typedef struct netsnmp_handler_registration_s { char *handlerName; char *contextName; oid *rootoid; size_t rootoid_len; netsnmp_mib_handler *handler; int modes; int priority; int range_subid; oid range_ubound; int timeout; int global_cacheid; void * my_reg_void; } netsnmp_handler_registration; typedef int (Netsnmp_Node_Handler) (netsnmp_mib_handler *handler, netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests); typedef struct netsnmp_handler_args_s { netsnmp_mib_handler *handler; netsnmp_handler_registration *reginfo; netsnmp_agent_request_info *reqinfo; netsnmp_request_info *requests; } netsnmp_handler_args; typedef struct netsnmp_delegated_cache_s { int transaction_id; netsnmp_mib_handler *handler; netsnmp_handler_registration *reginfo; netsnmp_agent_request_info *reqinfo; netsnmp_request_info *requests; void *localinfo; } netsnmp_delegated_cache; void netsnmp_init_handler_conf(void); int netsnmp_register_handler(netsnmp_handler_registration *reginfo); int netsnmp_unregister_handler(netsnmp_handler_registration *reginfo); int netsnmp_register_handler_nocallback(netsnmp_handler_registration *reginfo); int netsnmp_inject_handler(netsnmp_handler_registration *reginfo, netsnmp_mib_handler *handler); int netsnmp_inject_handler_before(netsnmp_handler_registration *reginfo, netsnmp_mib_handler *handler, const char *before_what); netsnmp_mib_handler *netsnmp_find_handler_by_name(netsnmp_handler_registration *reginfo, const char *name); void *netsnmp_find_handler_data_by_name(netsnmp_handler_registration *reginfo, const char *name); int netsnmp_call_handlers(netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests); int netsnmp_call_handler(netsnmp_mib_handler *next_handler, netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests); int netsnmp_call_next_handler(netsnmp_mib_handler *current, netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests); int netsnmp_call_next_handler_one_request(netsnmp_mib_handler *current, netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests); netsnmp_mib_handler *netsnmp_create_handler(const char *name, Netsnmp_Node_Handler * handler_access_method); netsnmp_handler_registration * netsnmp_handler_registration_create(const char *name, netsnmp_mib_handler *handler, oid * reg_oid, size_t reg_oid_len, int modes); netsnmp_handler_registration * netsnmp_create_handler_registration(const char *name, Netsnmp_Node_Handler* handler_access_method, oid *reg_oid, size_t reg_oid_len, int modes); inline netsnmp_delegated_cache *netsnmp_create_delegated_cache(netsnmp_mib_handler *, netsnmp_handler_registration *, netsnmp_agent_request_info *, netsnmp_request_info *, void *); inline void netsnmp_free_delegated_cache(netsnmp_delegated_cache *dcache); inline netsnmp_delegated_cache *netsnmp_handler_check_cache(netsnmp_delegated_cache *dcache); void netsnmp_register_handler_by_name(const char *, netsnmp_mib_handler *); void netsnmp_clear_handler_list(void); inline void netsnmp_request_add_list_data(netsnmp_request_info *request, netsnmp_data_list *node); inline int netsnmp_request_remove_list_data(netsnmp_request_info *request, const char *name); inline void *netsnmp_request_get_list_data(netsnmp_request_info *request, const char *name); inline void netsnmp_free_request_data_set(netsnmp_request_info *request); inline void netsnmp_free_request_data_sets(netsnmp_request_info *request); void netsnmp_handler_free(netsnmp_mib_handler *); netsnmp_mib_handler *netsnmp_handler_dup(netsnmp_mib_handler *); netsnmp_handler_registration *netsnmp_handler_registration_dup(netsnmp_handler_registration *); void netsnmp_handler_registration_free(netsnmp_handler_registration *); void netsnmp_handler_mark_requests_as_delegated(netsnmp_request_info *, int); void *netsnmp_handler_get_parent_data(netsnmp_request_info *, const char *); # 108 "../../include/net-snmp/agent/snmp_vars.h" 2 # 1 "../../include/net-snmp/agent/var_struct.h" 1 # 21 "../../include/net-snmp/agent/var_struct.h" typedef struct netsnmp_subtree_s { oid *name_a; u_char namelen; oid *start_a; u_char start_len; oid *end_a; u_char end_len; struct variable *variables; int variables_len; int variables_width; char *label_a; netsnmp_session *session; u_char flags; u_char priority; int timeout; struct netsnmp_subtree_s *next; struct netsnmp_subtree_s *prev; struct netsnmp_subtree_s *children; int range_subid; oid range_ubound; netsnmp_handler_registration *reginfo; int cacheid; int global_cacheid; size_t oid_off; } netsnmp_subtree; # 54 "../../include/net-snmp/agent/var_struct.h" struct variable1 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[1]; }; struct variable2 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[2]; }; struct variable3 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[3]; }; struct variable4 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[4]; }; struct variable7 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[7]; }; struct variable8 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[8]; }; struct variable13 { u_char magic; u_char type; u_short acl; FindVarMethod *findVar; u_char namelen; oid name[13]; }; # 109 "../../include/net-snmp/agent/snmp_vars.h" 2 # 1 "../../include/net-snmp/agent/agent_registry.h" 1 # 11 "../../include/net-snmp/agent/agent_registry.h" # 1 "../../include/net-snmp/library/fd_event_manager.h" 1 # 38 "../../include/net-snmp/library/fd_event_manager.h" extern int external_readfd[32], external_readfdlen; extern int external_writefd[32], external_writefdlen; extern int external_exceptfd[32], external_exceptfdlen; extern void (*external_readfdfunc[32]) (int, void *); extern void (*external_writefdfunc[32]) (int, void *); extern void (*external_exceptfdfunc[32]) (int, void *); extern void *external_readfd_data[32]; extern void *external_writefd_data[32]; extern void *external_exceptfd_data[32]; int register_readfd(int, void (*func)(int, void *), void *); int register_writefd(int, void (*func)(int, void *), void *); int register_exceptfd(int, void (*func)(int, void *), void *); int unregister_readfd(int); int unregister_writefd(int); int unregister_exceptfd(int); # 91 "../../include/net-snmp/library/fd_event_manager.h" void netsnmp_external_event_info(int *numfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds); # 117 "../../include/net-snmp/library/fd_event_manager.h" void netsnmp_dispatch_external_events(int *count, fd_set *readfds, fd_set *writefds, fd_set *exceptfds); # 12 "../../include/net-snmp/agent/agent_registry.h" 2 # 26 "../../include/net-snmp/agent/agent_registry.h" struct view_parameters { netsnmp_pdu *pdu; oid *name; size_t namelen; int test; int errorcode; int check_subtree; }; struct register_parameters { oid *name; size_t namelen; int priority; int range_subid; oid range_ubound; int timeout; u_char flags; const char *contextName; }; typedef struct subtree_context_cache_s { char *context_name; struct netsnmp_subtree_s *first_subtree; struct subtree_context_cache_s *next; } subtree_context_cache; void setup_tree (void); void shutdown_tree (void); netsnmp_subtree *netsnmp_subtree_find (oid *, size_t, netsnmp_subtree *, const char *context_name); netsnmp_subtree *netsnmp_subtree_find_next(oid *, size_t, netsnmp_subtree *, const char *context_name); netsnmp_subtree *netsnmp_subtree_find_prev(oid *, size_t,netsnmp_subtree *, const char *context_name); netsnmp_subtree *netsnmp_subtree_find_first(const char *context_name); netsnmp_session *get_session_for_oid (oid *, size_t, const char *context_name); subtree_context_cache *get_top_context_cache(void); void netsnmp_set_lookup_cache_size(int newsize); int netsnmp_get_lookup_cache_size(void); # 87 "../../include/net-snmp/agent/agent_registry.h" int register_mib (const char *, struct variable *, size_t, size_t, oid *, size_t); int register_mib_priority (const char *, struct variable *, size_t, size_t, oid *, size_t, int); int register_mib_range (const char *, struct variable *, size_t, size_t, oid *, size_t, int, int, oid, netsnmp_session *); int register_mib_context (const char *, struct variable *, size_t, size_t, oid *, size_t, int, int, oid, netsnmp_session *, const char *, int, int); int netsnmp_register_mib_table_row (const char *, struct variable *, size_t, size_t, oid *, size_t, int, int, netsnmp_session *, const char *, int, int); int unregister_mib (oid *, size_t); int unregister_mib_priority (oid *, size_t, int); int unregister_mib_range (oid *, size_t, int, int, oid); int unregister_mib_context (oid *, size_t, int, int, oid, const char *); void clear_context (void); void unregister_mibs_by_session (netsnmp_session *); int netsnmp_unregister_mib_table_row (oid *mibloc, size_t mibloclen, int priority, int var_subid, oid range_ubound, const char *context); int compare_tree (const oid *, size_t, const oid *, size_t); int in_a_view (oid *, size_t *, netsnmp_pdu *, int); int check_access (netsnmp_pdu *pdu); int netsnmp_acm_check_subtree (netsnmp_pdu *, oid *, size_t); void register_mib_reattach (void); void register_mib_detach (void); # 152 "../../include/net-snmp/agent/agent_registry.h" extern int external_signal_scheduled[32]; extern void (*external_signal_handler[32])(int); int register_signal(int, void (*func)(int)); int unregister_signal(int); struct netsnmp_handler_registration_s; int netsnmp_register_mib(const char *, struct variable *, size_t, size_t, oid *, size_t, int, int, oid, netsnmp_session *, const char *, int, int, struct netsnmp_handler_registration_s *, int); # 110 "../../include/net-snmp/agent/snmp_vars.h" 2 # 11 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/ds_agent.h" 1 # 12 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/agent_read_config.h" 1 # 12 "../../include/net-snmp/agent/agent_read_config.h" 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 *); # 14 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/agent_trap.h" 1 struct agent_add_trap_args { netsnmp_session *ss; int confirm; }; void init_traps(void); void send_easy_trap(int, int); void send_trap_pdu(netsnmp_pdu *); void send_v2trap(netsnmp_variable_list *); void send_trap_vars(int, int, netsnmp_variable_list *); void send_enterprise_trap_vars(int trap, int specific, oid * enterprise, int enterprise_length, netsnmp_variable_list * vars); int netsnmp_send_traps(int trap, int specific, oid * enterprise, int enterprise_length, netsnmp_variable_list * vars, char * context, int flags); void snmpd_parse_config_authtrap(const char *, char *); void snmpd_parse_config_trapsink(const char *, char *); void snmpd_parse_config_trap2sink(const char *, char *); void snmpd_parse_config_informsink(const char *, char *); void snmpd_parse_config_trapsess(const char *, char *); void snmpd_free_trapsinks(void); void snmpd_parse_config_trapcommunity(const char *, char *); void snmpd_free_trapcommunity(void); void send_trap_to_sess(netsnmp_session * sess, netsnmp_pdu *template_pdu); int create_trap_session(char *, u_short, char *, int, int); int add_trap_session(netsnmp_session *, int, int, int); int remove_trap_session(netsnmp_session *); void convert_v2_to_v1(netsnmp_variable_list *, netsnmp_pdu *); netsnmp_variable_list *convert_v1_to_v2(netsnmp_pdu *); netsnmp_pdu *convert_v2pdu_to_v1(netsnmp_pdu *); netsnmp_pdu *convert_v1pdu_to_v2(netsnmp_pdu *); # 15 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/all_helpers.h" 1 # 1 "../../include/net-snmp/agent/instance.h" 1 # 23 "../../include/net-snmp/agent/instance.h" int netsnmp_register_instance(netsnmp_handler_registration *reginfo); int netsnmp_register_read_only_instance(netsnmp_handler_registration *reginfo); netsnmp_mib_handler *netsnmp_get_instance_handler(void); int netsnmp_register_read_only_ulong_instance(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_ulong_instance(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_counter32_instance(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_long_instance(const char *name, oid * reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_long_instance(const char *name, oid * reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_int_instance(const char *name, oid * reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_int_instance(const char *name, oid * reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_ulong_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_ulong_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_read_only_counter32_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_read_only_long_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_long_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_read_only_int_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler * subhandler, const char *contextName); int netsnmp_register_int_instance_context(const char *name, oid * reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler * subhandler, const char *contextName); Netsnmp_Node_Handler netsnmp_instance_helper_handler; Netsnmp_Node_Handler netsnmp_instance_ulong_handler; Netsnmp_Node_Handler netsnmp_instance_long_handler; Netsnmp_Node_Handler netsnmp_instance_int_handler; Netsnmp_Node_Handler netsnmp_instance_counter32_handler; # 9 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/baby_steps.h" 1 # 45 "../../include/net-snmp/agent/baby_steps.h" typedef struct netsnmp_baby_steps_modes_s { u_int registered; u_int completed; } netsnmp_baby_steps_modes; void netsnmp_baby_steps_init(void); netsnmp_mib_handler *netsnmp_baby_steps_handler_get(u_long modes); # 69 "../../include/net-snmp/agent/baby_steps.h" typedef struct netsnmp_baby_steps_access_methods_s { Netsnmp_Node_Handler *pre_request; Netsnmp_Node_Handler *object_lookup; Netsnmp_Node_Handler *get_values; Netsnmp_Node_Handler *object_syntax_checks; Netsnmp_Node_Handler *row_creation; Netsnmp_Node_Handler *undo_setup; Netsnmp_Node_Handler *set_values; Netsnmp_Node_Handler *consistency_checks; Netsnmp_Node_Handler *commit; Netsnmp_Node_Handler *undo_sets; Netsnmp_Node_Handler *undo_cleanup; Netsnmp_Node_Handler *undo_commit; Netsnmp_Node_Handler *irreversible_commit; Netsnmp_Node_Handler *post_request; void *my_access_void; } netsnmp_baby_steps_access_methods; netsnmp_mib_handler * netsnmp_baby_steps_access_multiplexer_get( netsnmp_baby_steps_access_methods *); int netsnmp_baby_step_mode2flag( u_int mode ); # 10 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/scalar.h" 1 # 23 "../../include/net-snmp/agent/scalar.h" int netsnmp_register_scalar(netsnmp_handler_registration *reginfo); int netsnmp_register_read_only_scalar(netsnmp_handler_registration *reginfo); netsnmp_mib_handler *netsnmp_get_scalar_handler(void); Netsnmp_Node_Handler netsnmp_scalar_helper_handler; # 11 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/scalar_group.h" 1 # 22 "../../include/net-snmp/agent/scalar_group.h" typedef struct netsnmp_scalar_group_s { oid lbound; oid ubound; } netsnmp_scalar_group; int netsnmp_register_scalar_group(netsnmp_handler_registration *reginfo, oid first, oid last); netsnmp_mib_handler *netsnmp_get_scalar_group_handler(oid first, oid last); Netsnmp_Node_Handler netsnmp_scalar_group_helper_handler; # 12 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/watcher.h" 1 # 22 "../../include/net-snmp/agent/watcher.h" typedef struct netsnmp_watcher_info_s { void *data; size_t data_size; size_t max_size; u_char type; int flags; } netsnmp_watcher_info; int netsnmp_register_watched_instance( netsnmp_handler_registration *reginfo, netsnmp_watcher_info *winfo); int netsnmp_register_watched_scalar( netsnmp_handler_registration *reginfo, netsnmp_watcher_info *winfo); int netsnmp_register_watched_timestamp(netsnmp_handler_registration *reginfo, marker_t timestamp); int netsnmp_watched_timestamp_register(netsnmp_mib_handler *whandler, netsnmp_handler_registration *reginfo, marker_t timestamp); int netsnmp_register_watched_spinlock(netsnmp_handler_registration *reginfo, int *spinlock); int netsnmp_register_ulong_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_ulong_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_long_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_long_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, long * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_int_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, int * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_int_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, int * it, Netsnmp_Node_Handler * subhandler); int netsnmp_register_read_only_counter32_scalar(const char *name, oid * reg_oid, size_t reg_oid_len, u_long * it, Netsnmp_Node_Handler * subhandler); netsnmp_mib_handler *netsnmp_get_watcher_handler(void); netsnmp_watcher_info *netsnmp_create_watcher_info(void *, size_t, u_char, int); Netsnmp_Node_Handler netsnmp_watcher_helper_handler; netsnmp_mib_handler *netsnmp_get_watched_timestamp_handler(void); Netsnmp_Node_Handler netsnmp_watched_timestamp_handler; netsnmp_mib_handler *netsnmp_get_watched_spinlock_handler(void); Netsnmp_Node_Handler netsnmp_watched_spinlock_handler; # 13 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/multiplexer.h" 1 # 18 "../../include/net-snmp/agent/multiplexer.h" typedef struct netsnmp_mib_handler_methods_s { netsnmp_mib_handler *get_handler; netsnmp_mib_handler *getnext_handler; netsnmp_mib_handler *getbulk_handler; netsnmp_mib_handler *set_handler; } netsnmp_mib_handler_methods; netsnmp_mib_handler *netsnmp_get_multiplexer_handler(netsnmp_mib_handler_methods *); Netsnmp_Node_Handler netsnmp_multiplexer_helper_handler; # 14 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/null.h" 1 # 18 "../../include/net-snmp/agent/null.h" int netsnmp_register_null(oid *, size_t); int netsnmp_register_null_context(oid *, size_t, const char *contextName); Netsnmp_Node_Handler netsnmp_null_handler; # 15 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/debug_handler.h" 1 netsnmp_mib_handler *netsnmp_get_debug_handler(void); void netsnmp_init_debug_helper(void); Netsnmp_Node_Handler netsnmp_debug_helper; # 16 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/cache_handler.h" 1 # 19 "../../include/net-snmp/agent/cache_handler.h" typedef struct netsnmp_cache_s netsnmp_cache; typedef int (NetsnmpCacheLoad)(netsnmp_cache *, void*); typedef void (NetsnmpCacheFree)(netsnmp_cache *, void*); struct netsnmp_cache_s { int flags; int enabled; int valid; char expired; int timeout; marker_t timestamp; u_long timer_id; NetsnmpCacheLoad *load_cache; NetsnmpCacheFree *free_cache; void *magic; netsnmp_handler_args *cache_hint; netsnmp_cache *next, *prev; oid *rootoid; int rootoid_len; }; void netsnmp_cache_reqinfo_insert(netsnmp_cache* cache, netsnmp_agent_request_info * reqinfo, const char *name); netsnmp_cache * netsnmp_cache_reqinfo_extract(netsnmp_agent_request_info * reqinfo, const char *name); netsnmp_cache* netsnmp_extract_cache_info(netsnmp_agent_request_info *); int netsnmp_cache_check_and_reload(netsnmp_cache * cache); int netsnmp_cache_check_expired(netsnmp_cache *cache); int netsnmp_cache_is_valid( netsnmp_agent_request_info *, const char *name); int netsnmp_is_cache_valid( netsnmp_agent_request_info *); netsnmp_mib_handler *netsnmp_get_cache_handler(int, NetsnmpCacheLoad *, NetsnmpCacheFree *, oid*, int); int netsnmp_register_cache_handler(netsnmp_handler_registration *reginfo, int, NetsnmpCacheLoad *, NetsnmpCacheFree *); Netsnmp_Node_Handler netsnmp_cache_helper_handler; netsnmp_cache * netsnmp_cache_create(int timeout, NetsnmpCacheLoad * load_hook, NetsnmpCacheFree * free_hook, oid * rootoid, int rootoid_len); netsnmp_mib_handler * netsnmp_cache_handler_get(netsnmp_cache* cache); netsnmp_cache * netsnmp_cache_find_by_oid(oid * rootoid, int rootoid_len); unsigned int netsnmp_cache_timer_start(netsnmp_cache *cache); void netsnmp_cache_timer_stop(netsnmp_cache *cache); # 17 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/old_api.h" 1 # 10 "../../include/net-snmp/agent/old_api.h" typedef struct netsnmp_old_api_info_s { struct variable *var; size_t varsize; size_t numvars; netsnmp_session *ss; int flags; } netsnmp_old_api_info; typedef struct old_opi_cache_s { u_char *data; WriteMethod *write_method; } netsnmp_old_api_cache; int netsnmp_register_old_api(const char *moduleName, struct variable *var, size_t varsize, size_t numvars, oid * mibloc, size_t mibloclen, int priority, int range_subid, oid range_ubound, netsnmp_session * ss, const char *context, int timeout, int flags); Netsnmp_Node_Handler netsnmp_old_api_helper; netsnmp_agent_session *netsnmp_get_current_agent_session(void); # 18 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/read_only.h" 1 # 20 "../../include/net-snmp/agent/read_only.h" netsnmp_mib_handler *netsnmp_get_read_only_handler(void); void netsnmp_init_read_only_helper(void); Netsnmp_Node_Handler netsnmp_read_only_helper; # 19 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/row_merge.h" 1 # 14 "../../include/net-snmp/agent/row_merge.h" typedef struct netsnmp_row_merge_status_x { char count; char rows; char current; char reserved; netsnmp_request_info **saved_requests; char *saved_status; } netsnmp_row_merge_status; netsnmp_mib_handler *netsnmp_get_row_merge_handler(int); int netsnmp_register_row_merge(netsnmp_handler_registration *reginfo); void netsnmp_init_row_merge(void); int netsnmp_row_merge_status_first(netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo); int netsnmp_row_merge_status_last(netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo); Netsnmp_Node_Handler netsnmp_row_merge_helper_handler; # 20 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/serialize.h" 1 # 14 "../../include/net-snmp/agent/serialize.h" netsnmp_mib_handler *netsnmp_get_serialize_handler(void); int netsnmp_register_serialize(netsnmp_handler_registration *reginfo); void netsnmp_init_serialize(void); Netsnmp_Node_Handler netsnmp_serialize_helper_handler; # 21 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/bulk_to_next.h" 1 # 18 "../../include/net-snmp/agent/bulk_to_next.h" netsnmp_mib_handler *netsnmp_get_bulk_to_next_handler(void); void netsnmp_init_bulk_to_next_helper(void); void netsnmp_bulk_to_next_fix_requests(netsnmp_request_info *requests); Netsnmp_Node_Handler netsnmp_bulk_to_next_helper; # 22 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/mode_end_call.h" 1 # 13 "../../include/net-snmp/agent/mode_end_call.h" typedef struct netsnmp_mode_handler_list_s { struct netsnmp_mode_handler_list_s *next; int mode; netsnmp_mib_handler *callback_handler; } netsnmp_mode_handler_list; netsnmp_mib_handler * netsnmp_get_mode_end_call_handler(netsnmp_mode_handler_list *endlist); netsnmp_mode_handler_list * netsnmp_mode_end_call_add_mode_callback(netsnmp_mode_handler_list *endlist, int mode, netsnmp_mib_handler *callbackh); Netsnmp_Node_Handler netsnmp_mode_end_call_helper; # 23 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table.h" 1 # 52 "../../include/net-snmp/agent/table.h" typedef struct netsnmp_column_info_t { char isRange; char list_count; union { unsigned int range[2]; unsigned int *list; } details; struct netsnmp_column_info_t *next; } netsnmp_column_info; # 74 "../../include/net-snmp/agent/table.h" typedef struct netsnmp_table_registration_info_s { netsnmp_variable_list *indexes; unsigned int number_indexes; unsigned int min_column; unsigned int max_column; netsnmp_column_info *valid_columns; } netsnmp_table_registration_info; # 102 "../../include/net-snmp/agent/table.h" typedef struct netsnmp_table_request_info_s { unsigned int colnum; unsigned int number_indexes; netsnmp_variable_list *indexes; oid index_oid[128]; size_t index_oid_len; netsnmp_table_registration_info *reg_info; } netsnmp_table_request_info; netsnmp_mib_handler *netsnmp_get_table_handler(netsnmp_table_registration_info *tabreq); int netsnmp_register_table(netsnmp_handler_registration *reginfo, netsnmp_table_registration_info *tabreq); int netsnmp_table_build_oid(netsnmp_handler_registration *reginfo, netsnmp_request_info *reqinfo, netsnmp_table_request_info *table_info); int netsnmp_table_build_oid_from_index(netsnmp_handler_registration *reginfo, netsnmp_request_info *reqinfo, netsnmp_table_request_info *table_info); int netsnmp_table_build_result(netsnmp_handler_registration *reginfo, netsnmp_request_info *reqinfo, netsnmp_table_request_info *table_info, u_char type, u_char * result, size_t result_len); int netsnmp_update_variable_list_from_index(netsnmp_table_request_info *); int netsnmp_update_indexes_from_variable_list (netsnmp_table_request_info *tri); netsnmp_table_registration_info *netsnmp_find_table_registration_info(netsnmp_handler_registration *reginfo); netsnmp_index * netsnmp_table_index_find_next_row(netsnmp_container *c, netsnmp_table_request_info *tblreq); unsigned int netsnmp_closest_column(unsigned int current, netsnmp_column_info *valid_columns); Netsnmp_Node_Handler table_helper_handler; void netsnmp_table_helper_add_indexes(netsnmp_table_registration_info *tinfo, ...); int netsnmp_check_getnext_reply(netsnmp_request_info *request, oid * prefix, size_t prefix_len, netsnmp_variable_list * newvar, netsnmp_variable_list ** outvar); netsnmp_table_request_info *netsnmp_extract_table_info(netsnmp_request_info *); netsnmp_oid_stash_node **netsnmp_table_get_or_create_row_stash(netsnmp_agent_request_info *reqinfo, const u_char * storage_name); unsigned int netsnmp_table_next_column(netsnmp_table_request_info *table_info); int netsnmp_sparse_table_register(netsnmp_handler_registration *reginfo, netsnmp_table_registration_info *tabreq); netsnmp_mib_handler *netsnmp_sparse_table_handler_get(void); # 27 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_data.h" 1 # 23 "../../include/net-snmp/agent/table_data.h" typedef struct netsnmp_table_row_s { netsnmp_variable_list *indexes; oid *index_oid; size_t index_oid_len; void *data; struct netsnmp_table_row_s *next, *prev; } netsnmp_table_row; typedef struct netsnmp_table_data_s { netsnmp_variable_list *indexes_template; char *name; int flags; int store_indexes; netsnmp_table_row *first_row; netsnmp_table_row *last_row; } netsnmp_table_data; netsnmp_mib_handler *netsnmp_get_table_data_handler(netsnmp_table_data *table); void netsnmp_table_data_generate_index_oid(netsnmp_table_row *row); int netsnmp_table_data_add_row(netsnmp_table_data *table, netsnmp_table_row *row); netsnmp_table_row *netsnmp_table_data_remove_row(netsnmp_table_data *table, netsnmp_table_row *row); void *netsnmp_table_data_delete_row(netsnmp_table_row *row); void *netsnmp_table_data_remove_and_delete_row(netsnmp_table_data *table, netsnmp_table_row *row); netsnmp_table_row *netsnmp_table_data_get(netsnmp_table_data *table, netsnmp_variable_list * indexes); netsnmp_table_row *netsnmp_table_data_get_from_oid(netsnmp_table_data *table, oid * searchfor, size_t searchfor_len); netsnmp_table_row *netsnmp_table_data_get_first_row(netsnmp_table_data *table); netsnmp_table_row *netsnmp_table_data_get_next_row(netsnmp_table_data *table, netsnmp_table_row *row); int netsnmp_register_table_data(netsnmp_handler_registration *reginfo, netsnmp_table_data *table, netsnmp_table_registration_info *table_info); int netsnmp_register_read_only_table_data(netsnmp_handler_registration *reginfo, netsnmp_table_data *table, netsnmp_table_registration_info *table_info); netsnmp_table_row *netsnmp_extract_table_row(netsnmp_request_info *); netsnmp_table_data *netsnmp_extract_table( netsnmp_request_info *); void *netsnmp_extract_table_row_data(netsnmp_request_info *); void netsnmp_insert_table_row(netsnmp_request_info *, netsnmp_table_row *); netsnmp_table_data *netsnmp_create_table_data(const char *name); netsnmp_table_row *netsnmp_create_table_data_row(void); netsnmp_table_row *netsnmp_table_data_clone_row(netsnmp_table_row *row); inline void netsnmp_table_data_replace_row(netsnmp_table_data *table, netsnmp_table_row *origrow, netsnmp_table_row *newrow); int netsnmp_table_data_build_result(netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *request, netsnmp_table_row *row, int column, u_char type, u_char * result_data, size_t result_data_len); int netsnmp_table_data_num_rows(netsnmp_table_data *table); Netsnmp_Node_Handler netsnmp_table_data_helper_handler; # 28 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_dataset.h" 1 # 19 "../../include/net-snmp/agent/table_dataset.h" void netsnmp_init_table_dataset(void); typedef int (Netsnmp_Value_Change_Ok) (char *old_value, size_t old_value_len, char *new_value, size_t new_value_len, void *mydata); typedef struct netsnmp_table_data_set_storage_s { unsigned int column; char writable; Netsnmp_Value_Change_Ok *change_ok_fn; void *my_change_data; u_char type; union { void *voidp; long *integer; u_char *string; oid *objid; u_char *bitstring; struct counter64 *counter64; float *floatVal; double *doubleVal; } data; u_long data_len; struct netsnmp_table_data_set_storage_s *next; } netsnmp_table_data_set_storage; typedef struct netsnmp_table_data_set_s { netsnmp_table_data *table; netsnmp_table_data_set_storage *default_row; int allow_creation; unsigned int rowstatus_column; } netsnmp_table_data_set; Netsnmp_Node_Handler netsnmp_table_data_set_helper_handler; # 83 "../../include/net-snmp/agent/table_dataset.h" int netsnmp_table_set_add_default_row(netsnmp_table_data_set *, unsigned int, int, int, void *default_value, size_t default_value_len); void netsnmp_table_set_multi_add_default_row(netsnmp_table_data_set *, ...); int netsnmp_set_row_column(netsnmp_table_row *, unsigned int, int, const char *, size_t); netsnmp_table_data_set_storage *netsnmp_table_data_set_find_column(netsnmp_table_data_set_storage *, unsigned int); netsnmp_table_data_set_storage *netsnmp_extract_table_data_set_column(netsnmp_request_info *, unsigned int); int netsnmp_register_table_data_set(netsnmp_handler_registration *, netsnmp_table_data_set *, netsnmp_table_registration_info *); netsnmp_mib_handler *netsnmp_get_table_data_set_handler(netsnmp_table_data_set *); netsnmp_table_data_set *netsnmp_create_table_data_set(const char *); int netsnmp_mark_row_column_writable(netsnmp_table_row *row, int column, int writable); inline netsnmp_table_data_set *netsnmp_extract_table_data_set(netsnmp_request_info *request); void netsnmp_config_parse_table_set(const char *token, char *line); void netsnmp_config_parse_add_row(const char *token, char *line); inline void netsnmp_table_dataset_add_index(netsnmp_table_data_set *table, u_char type); inline void netsnmp_table_dataset_add_row(netsnmp_table_data_set *table, netsnmp_table_row *row); inline void netsnmp_table_dataset_remove_row(netsnmp_table_data_set *table, netsnmp_table_row *row); inline void netsnmp_table_dataset_delete_row(netsnmp_table_row *row); inline void netsnmp_table_dataset_remove_and_delete_row(netsnmp_table_data_set *table, netsnmp_table_row *row); inline void netsnmp_table_dataset_delete_all_data (netsnmp_table_data_set_storage *data); inline void netsnmp_table_dataset_replace_row(netsnmp_table_data_set *table, netsnmp_table_row *origrow, netsnmp_table_row *newrow); netsnmp_table_row *netsnmp_table_data_set_clone_row(netsnmp_table_row *row); void netsnmp_register_auto_data_table(netsnmp_table_data_set *table_set, char *registration_name); int netsnmp_table_data_num_rows(netsnmp_table_data *table); void netsnmp_table_set_add_indexes(netsnmp_table_data_set *tset, ...); # 29 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_data2.h" 1 # 28 "../../include/net-snmp/agent/table_data2.h" typedef struct netsnmp_tdata_row_s { netsnmp_index oid_index; netsnmp_variable_list *indexes; void *data; struct netsnmp_tdata_row_s *next, *prev; } netsnmp_tdata_row; typedef struct netsnmp_tdata_s { netsnmp_variable_list *indexes_template; char *name; int flags; int store_indexes; netsnmp_container *container; } netsnmp_tdata; typedef struct netsnmp_tdata_row_s netsnmp_table_data2row; typedef struct netsnmp_tdata_s netsnmp_table_data2; void netsnmp_tdata_generate_index_oid(netsnmp_tdata_row *row); int netsnmp_tdata_add_row( netsnmp_tdata *table, netsnmp_tdata_row *row); netsnmp_tdata_row *netsnmp_tdata_remove_row(netsnmp_tdata *table, netsnmp_tdata_row *row); void *netsnmp_tdata_delete_row( netsnmp_tdata_row *row); void *netsnmp_tdata_remove_and_delete_row(netsnmp_tdata *table, netsnmp_tdata_row *row); inline void netsnmp_tdata_replace_row(netsnmp_tdata *table, netsnmp_tdata_row *origrow, netsnmp_tdata_row *newrow); netsnmp_tdata *netsnmp_tdata_create(const char *name); netsnmp_tdata_row *netsnmp_tdata_create_row(void); netsnmp_tdata_row *netsnmp_tdata_clone_row(netsnmp_tdata_row *row); netsnmp_mib_handler *netsnmp_get_tdata_handler(netsnmp_tdata *table); Netsnmp_Node_Handler netsnmp_tdata_helper_handler; int netsnmp_register_tdata(netsnmp_handler_registration *reginfo, netsnmp_tdata *table, netsnmp_table_registration_info *table_info); int netsnmp_register_read_only_tdata(netsnmp_handler_registration *reginfo, netsnmp_tdata *table, netsnmp_table_registration_info *table_info); netsnmp_tdata *netsnmp_tdata_extract( netsnmp_request_info *); netsnmp_container *netsnmp_tdata_extract_container(netsnmp_request_info *); netsnmp_tdata_row *netsnmp_tdata_extract_row( netsnmp_request_info *); void *netsnmp_tdata_extract_entry( netsnmp_request_info *); void netsnmp_insert_tdata_row(netsnmp_request_info *, netsnmp_tdata_row *); netsnmp_tdata_row *netsnmp_tdata_get( netsnmp_tdata *table, netsnmp_variable_list *indexes); netsnmp_tdata_row *netsnmp_tdata_getnext(netsnmp_tdata *table, netsnmp_variable_list *indexes); netsnmp_tdata_row *netsnmp_tdata_get_from_oid(netsnmp_tdata *table, oid *searchfor, size_t searchfor_len); netsnmp_tdata_row *netsnmp_tdata_getnext_from_oid(netsnmp_tdata *table, oid *searchfor, size_t searchfor_len); netsnmp_tdata_row* netsnmp_tdata_get_first_row(netsnmp_tdata *table); netsnmp_tdata_row* netsnmp_tdata_get_next_row( netsnmp_tdata *table, netsnmp_tdata_row *row); void * netsnmp_tdata_row_entry( netsnmp_tdata_row *row ); int netsnmp_tdata_num_rows(netsnmp_tdata *table); # 30 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_dataset2.h" 1 # 19 "../../include/net-snmp/agent/table_dataset2.h" void netsnmp_init_table_dataset2(void); typedef int (Netsnmp_Value_Change_Dataset2_Ok) (char *old_value, size_t old_value_len, char *new_value, size_t new_value_len, void *mydata); typedef struct netsnmp_table_data2_set_storage_s { unsigned int column; char writable; Netsnmp_Value_Change_Dataset2_Ok *change_ok_fn; void *my_change_data2; u_char type; union { void *voidp; long *integer; u_char *string; oid *objid; u_char *bitstring; struct counter64 *counter64; float *floatVal; double *doubleVal; } data; u_long data_len; struct netsnmp_table_data2_set_storage_s *next; } netsnmp_table_data2_set_storage; typedef struct netsnmp_table_data2_set_s { netsnmp_tdata *table; netsnmp_table_data2_set_storage *default_row; int allow_creation; unsigned int rowstatus_column; } netsnmp_table_data2_set; Netsnmp_Node_Handler netsnmp_table_data2_set_helper_handler; # 83 "../../include/net-snmp/agent/table_dataset2.h" int netsnmp_table_set2_add_default_row(netsnmp_table_data2_set *, unsigned int, int, int, void *default_value, size_t default_value_len); void netsnmp_table_set2_multi_add_default_row(netsnmp_table_data2_set *, ...); int netsnmp_set_data2_row_column(netsnmp_table_data2row *, unsigned int, int, const char *, size_t); netsnmp_table_data2_set_storage *netsnmp_table_data2_set_find_column(netsnmp_table_data2_set_storage *, unsigned int); netsnmp_table_data2_set_storage *netsnmp_extract_table_data2_set_column(netsnmp_request_info *, unsigned int); int netsnmp_register_table_data2_set(netsnmp_handler_registration *, netsnmp_table_data2_set *, netsnmp_table_registration_info *); netsnmp_mib_handler *netsnmp_get_table_data2_set_handler(netsnmp_table_data2_set *); netsnmp_table_data2_set *netsnmp_create_table_data2_set(const char *); int netsnmp_mark_data2_row_column_writable(netsnmp_table_data2row *row, int column, int writable); inline netsnmp_table_data2_set *netsnmp_extract_table_data2_set(netsnmp_request_info *request); netsnmp_table_data2row *netsnmp_table_data2_set_get_first_row(netsnmp_table_data2_set *table); netsnmp_table_data2row *netsnmp_table_data2_set_get_next_row(netsnmp_table_data2_set *table, netsnmp_table_data2row *row); void netsnmp_config_parse_table_set2(const char *token, char *line); void netsnmp_config_parse_add_row(const char *token, char *line); inline void netsnmp_table_dataset2_add_index(netsnmp_table_data2_set *table, u_char type); inline void netsnmp_table_dataset2_add_row(netsnmp_table_data2_set *table, netsnmp_table_data2row *row); inline void netsnmp_table_dataset2_remove_row(netsnmp_table_data2_set *table, netsnmp_table_data2row *row); inline void netsnmp_table_dataset2_delete_row(netsnmp_table_data2row *row); inline void netsnmp_table_dataset2_remove_and_delete_row(netsnmp_table_data2_set *table, netsnmp_table_data2row *row); inline void netsnmp_table_dataset2_delete_all_data2 (netsnmp_table_data2_set_storage *data); inline void netsnmp_table_dataset2_replace_row(netsnmp_table_data2_set *table, netsnmp_table_data2row *origrow, netsnmp_table_data2row *newrow); netsnmp_table_data2row *netsnmp_table_data2_set_clone_row(netsnmp_table_data2row *row); void netsnmp_register_auto_data2_table(netsnmp_table_data2_set *table_set2, char *registration_name); int netsnmp_table_dataset2_num_rows(netsnmp_table_data2_set *table); void netsnmp_table_set2_add_indexes(netsnmp_table_data2_set *tset, ...); # 31 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_iterator.h" 1 # 23 "../../include/net-snmp/agent/table_iterator.h" struct netsnmp_iterator_info_s; typedef netsnmp_variable_list *(Netsnmp_First_Data_Point) (void **loop_context, void **data_context, netsnmp_variable_list *, struct netsnmp_iterator_info_s *); typedef netsnmp_variable_list *(Netsnmp_Next_Data_Point) (void **loop_context, void **data_context, netsnmp_variable_list *, struct netsnmp_iterator_info_s *); typedef void *(Netsnmp_Make_Data_Context) (void *loop_context, struct netsnmp_iterator_info_s *); typedef void (Netsnmp_Free_Loop_Context) (void *, struct netsnmp_iterator_info_s *); typedef void (Netsnmp_Free_Data_Context) (void *, struct netsnmp_iterator_info_s *); # 67 "../../include/net-snmp/agent/table_iterator.h" typedef struct netsnmp_iterator_info_s { Netsnmp_First_Data_Point *get_first_data_point; Netsnmp_Next_Data_Point *get_next_data_point; Netsnmp_Make_Data_Context *make_data_context; Netsnmp_Free_Loop_Context *free_loop_context; Netsnmp_Free_Data_Context *free_data_context; Netsnmp_Free_Loop_Context *free_loop_context_at_end; void *myvoid; int flags; netsnmp_table_registration_info *table_reginfo; } netsnmp_iterator_info; netsnmp_mib_handler *netsnmp_get_table_iterator_handler(netsnmp_iterator_info *iinfo); int netsnmp_register_table_iterator(netsnmp_handler_registration *reginfo, netsnmp_iterator_info *iinfo); void *netsnmp_extract_iterator_context(netsnmp_request_info *); void netsnmp_insert_iterator_context(netsnmp_request_info *, void *); Netsnmp_Node_Handler netsnmp_table_iterator_helper_handler; # 32 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_container.h" 1 # 39 "../../include/net-snmp/agent/table_container.h" int netsnmp_container_table_register(netsnmp_handler_registration *reginfo, netsnmp_table_registration_info *tabreq, netsnmp_container *container, char key_type); netsnmp_mib_handler * netsnmp_container_table_handler_get(netsnmp_table_registration_info *tabreq, netsnmp_container *container, char key_type); static inline void * netsnmp_container_table_row_extract(netsnmp_request_info *request) { return netsnmp_request_get_list_data(request, "table_container:row"); } static inline void * netsnmp_container_table_extract_context(netsnmp_request_info *request) { return netsnmp_request_get_list_data(request, "table_container:row"); } void netsnmp_container_table_row_insert(netsnmp_request_info *request, netsnmp_index *row); netsnmp_container* netsnmp_container_table_container_extract(netsnmp_request_info *request); void * netsnmp_container_table_find_next_row(netsnmp_request_info *request, netsnmp_table_request_info *tblreq, netsnmp_container *container, char key_type ); # 33 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/table_array.h" 1 # 35 "../../include/net-snmp/agent/table_array.h" typedef struct netsnmp_request_group_item_s { netsnmp_request_info *ri; netsnmp_table_request_info *tri; struct netsnmp_request_group_item_s *next; } netsnmp_request_group_item; typedef struct netsnmp_request_group_s { netsnmp_index index; netsnmp_container *table; netsnmp_index *existing_row; netsnmp_index *undo_info; char row_created; char row_deleted; char fill1; char fill2; netsnmp_request_group_item *list; int status; void *rg_void; } netsnmp_request_group; typedef int (Netsnmp_User_Row_Operation_c) (const void *lhs, const void *rhs); typedef int (Netsnmp_User_Row_Operation) (void *lhs, void *rhs); typedef int (Netsnmp_User_Get_Processor) (netsnmp_request_info *, netsnmp_index *, netsnmp_table_request_info *); typedef netsnmp_index *(UserRowMethod) (netsnmp_index *); typedef int (Netsnmp_User_Row_Action) (netsnmp_index *, netsnmp_index *, netsnmp_request_group *); typedef void (Netsnmp_User_Group_Method) (netsnmp_request_group *); typedef struct netsnmp_table_array_callbacks_s { Netsnmp_User_Row_Operation *row_copy; Netsnmp_User_Row_Operation_c *row_compare; Netsnmp_User_Get_Processor *get_value; Netsnmp_User_Row_Action *can_activate; Netsnmp_User_Row_Action *activated; Netsnmp_User_Row_Action *can_deactivate; Netsnmp_User_Row_Action *deactivated; Netsnmp_User_Row_Action *can_delete; UserRowMethod *create_row; UserRowMethod *duplicate_row; UserRowMethod *delete_row; Netsnmp_User_Group_Method *set_reserve1; Netsnmp_User_Group_Method *set_reserve2; Netsnmp_User_Group_Method *set_action; Netsnmp_User_Group_Method *set_commit; Netsnmp_User_Group_Method *set_free; Netsnmp_User_Group_Method *set_undo; netsnmp_container* container; char can_set; } netsnmp_table_array_callbacks; int netsnmp_table_container_register(netsnmp_handler_registration *reginfo, netsnmp_table_registration_info *tabreq, netsnmp_table_array_callbacks *cb, netsnmp_container *container, int group_rows); int netsnmp_table_array_register(netsnmp_handler_registration *reginfo, netsnmp_table_registration_info *tabreq, netsnmp_table_array_callbacks *cb, netsnmp_container *container, int group_rows); netsnmp_container * netsnmp_extract_array_context(netsnmp_request_info *); Netsnmp_Node_Handler netsnmp_table_array_helper_handler; int netsnmp_table_array_check_row_status(netsnmp_table_array_callbacks *cb, netsnmp_request_group *ag, long *rs_new, long *rs_old); # 34 "../../include/net-snmp/agent/all_helpers.h" 2 # 1 "../../include/net-snmp/agent/mfd.h" 1 # 36 "../../include/net-snmp/agent/all_helpers.h" 2 void netsnmp_init_helpers(void); # 17 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/mib_module_config.h" 1 # 20 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 1 "../../include/net-snmp/agent/agent_module_config.h" 1 # 21 "../../include/net-snmp/agent/net-snmp-agent-includes.h" 2 # 63 "mibII/tcp.c" 2 # 1 "../../include/net-snmp/agent/auto_nlist.h" 1 # 15 "../../include/net-snmp/agent/auto_nlist.h" int auto_nlist(const char *, char *, int); long auto_nlist_value(const char *); int KNLookup(struct nlist *, int, char *, int); # 64 "mibII/tcp.c" 2 # 1 "util_funcs.h" 1 # 11 "util_funcs.h" # 1 "struct.h" 1 # 11 "struct.h" struct extensible { char name[1024]; char command[1024]; char fixcmd[1024]; int type; int result; char output[1024]; struct extensible *next; unsigned long miboid[30]; size_t miblen; int pid; }; struct myproc { char name[1024]; char fixcmd[1024]; int min; int max; struct myproc *next; }; # 12 "util_funcs.h" 2 void Exit(int); int shell_command(struct extensible *); int exec_command(struct extensible *); struct extensible *get_exten_instance(struct extensible *, size_t); int get_exec_output(struct extensible *); int get_exec_pipes(char *cmd, int *fdIn, int *fdOut, int *pid); WriteMethod clear_cache; void restart_doit(int); WriteMethod restart_hook; void print_mib_oid(oid *, size_t); void sprint_mib_oid(char *, oid *, size_t); int header_simple_table(struct variable *, oid *, size_t *, int, size_t *, WriteMethod ** write_method, int); int header_generic(struct variable *, oid *, size_t *, int, size_t *, WriteMethod **); int checkmib(struct variable *, oid *, size_t *, int, size_t *, WriteMethod ** write_method, int); char *find_field(char *, int); int parse_miboid(const char *, oid *); void string_append_int(char *, int); void wait_on_exec(struct extensible *); const char *make_tempfile(void); typedef void *mib_table_t; typedef int (RELOAD) (mib_table_t); typedef int (COMPARE) (const void *, const void *); mib_table_t Initialise_Table(int, int, RELOAD*, COMPARE*); int Search_Table(mib_table_t, void *, int); int Add_Entry(mib_table_t, void *); void *Retrieve_Table_Data(mib_table_t, int *); # 66 "mibII/tcp.c" 2 # 1 "mibII/tcp.h" 1 # 9 "mibII/tcp.h" extern void init_tcp(void); extern Netsnmp_Node_Handler tcp_handler; extern NetsnmpCacheLoad tcp_load; extern NetsnmpCacheFree tcp_free; # 67 "mibII/tcp.c" 2 # 1 "mibII/tcpTable.h" 1 # 26 "mibII/tcpTable.h" extern void init_tcpTable(void); extern Netsnmp_Node_Handler tcpTable_handler; extern NetsnmpCacheLoad tcpTable_load; extern NetsnmpCacheFree tcpTable_free; extern Netsnmp_First_Data_Point tcpTable_first_entry; extern Netsnmp_Next_Data_Point tcpTable_next_entry; # 68 "mibII/tcp.c" 2 # 1 "mibII/sysORTable.h" 1 struct sysORTable { char *OR_descr; oid *OR_oid; size_t OR_oidlen; struct timeval OR_uptime; netsnmp_session *OR_sess; struct sysORTable *next; }; struct register_sysOR_parameters { oid *name; int namelen; const char *descr; }; extern void init_sysORTable(void); extern FindVarMethod var_sysORTable; extern FindVarMethod var_sysORLastChange; extern int register_sysORTable(oid *, size_t, const char *); extern int unregister_sysORTable(oid *, size_t); extern int register_sysORTable_sess(oid *, size_t, const char *, netsnmp_session *); extern int unregister_sysORTable_sess(oid *, size_t, netsnmp_session *); extern void unregister_sysORTable_by_session(netsnmp_session *); # 69 "mibII/tcp.c" 2 # 94 "mibII/tcp.c" extern int TCP_Count_Connections( void ); # 106 "mibII/tcp.c" oid tcp_oid[] = { 1, 3, 6, 1, 2, 1, 6 }; oid tcp_module_oid[] = { 1, 3, 6, 1, 2, 1, 49 }; void init_tcp(void) { netsnmp_handler_registration *reginfo; do {if (snmp_get_do_debugging()) {debugmsgtoken ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",117), debugmsg ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",117), debugmsgtoken ("mibII/tcpScalar", "Initialising TCP scalar group\n"), debugmsg ("mibII/tcpScalar", "Initialising TCP scalar group\n");} }while(0); reginfo = netsnmp_create_handler_registration("tcp", tcp_handler, tcp_oid, (sizeof(tcp_oid)/sizeof(oid)), (0x01)); netsnmp_register_scalar_group(reginfo, 1, 15); netsnmp_inject_handler( reginfo, netsnmp_get_cache_handler(5, tcp_load, tcp_free, tcp_oid, (sizeof(tcp_oid)/sizeof(oid)))); (void)register_sysORTable(tcp_module_oid, sizeof(tcp_module_oid)/sizeof(oid), "The MIB module for managing TCP implementations");; auto_nlist("tcpstat", 0, 0); auto_nlist("tcbtable", 0, 0); } # 186 "mibII/tcp.c" struct tcpstat tcpstat; # 198 "mibII/tcp.c" int tcp_handler(netsnmp_mib_handler *handler, netsnmp_handler_registration *reginfo, netsnmp_agent_request_info *reqinfo, netsnmp_request_info *requests) { netsnmp_request_info *request; netsnmp_variable_list *requestvb; long ret_value = -1; oid subid; int type = (((u_char)0x40) | 1); if (!netsnmp_cache_is_valid(reqinfo, reginfo->handlerName)) { do { if ( "cache" == "valid" ) ; else snmp_log(3,"netsnmp_assert %s failed %s:%d %s()\n", "\"cache\" == \"valid\"","mibII/tcp.c",217,__FUNCTION__); }while(0); tcp_load( 0L, 0L ); } do {if (snmp_get_do_debugging()) {debugmsgtoken ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",228), debugmsg ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",228), debugmsgtoken ("mibII/tcpScalar", "Handler - mode %s\n", se_find_label_in_slist("agent_mode", reqinfo->mode)), debugmsg ("mibII/tcpScalar", "Handler - mode %s\n", se_find_label_in_slist("agent_mode", reqinfo->mode));} }while(0); switch (reqinfo->mode) { case (((u_char)0x80) | ((u_char)0x20) | 0x0): for (request=requests; request; request=request->next) { requestvb = request->requestvb; subid = requestvb->name[(sizeof(tcp_oid)/sizeof(oid))]; do {if (snmp_get_do_debugging()) {debugmsgtoken ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",235), debugmsg ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",235), debugmsgtoken ( "mibII/tcpScalar", "oid: "), debugmsg ( "mibII/tcpScalar", "oid: ");} }while(0); do {if (snmp_get_do_debugging()) {debugmsg_oid ("mibII/tcpScalar", requestvb->name, requestvb->name_length);} }while(0); do {if (snmp_get_do_debugging()) {debugmsg ( "mibII/tcpScalar", "\n");} }while(0); switch (subid) { # 323 "mibII/tcp.c" case 1: ret_value = 4; type = ((u_char)0x02); break; case 2: ret_value = ( 1*2) / 2 * 1000; type = ((u_char)0x02); break; case 3: ret_value = ( 64*2) / 2 * 1000; type = ((u_char)0x02); break; case 4: ret_value = -1; type = ((u_char)0x02); break; case 5: ret_value = tcpstat.tcps_connattempt; break; case 6: ret_value = tcpstat.tcps_accepts; break; case 7: ret_value = tcpstat.tcps_conndrops; break; case 8: ret_value = tcpstat.tcps_drops; break; case 9: ret_value = TCP_Count_Connections(); type = (((u_char)0x40) | 2); break; case 10: ret_value = tcpstat.tcps_rcvtotal; break; case 11: ret_value = tcpstat.tcps_sndtotal - tcpstat.tcps_sndrexmitpack; break; case 12: ret_value = tcpstat.tcps_sndrexmitpack; break; case 14: ret_value = tcpstat.tcps_rcvbadsum + tcpstat.tcps_rcvbadoff + tcpstat.tcps_rcvshort; break; case 15: ret_value = tcpstat.tcps_sndctrl - tcpstat.tcps_closed; break; # 484 "mibII/tcp.c" case 13: netsnmp_set_request_error(reqinfo, request, (((u_char)0x80) | ((u_char)0x00) | 0x0)); continue; } snmp_set_var_typed_value(request->requestvb, (u_char)type, (u_char *)&ret_value, sizeof(ret_value)); } break; case (((u_char)0x80) | ((u_char)0x20) | 0x1): case (((u_char)0x80) | ((u_char)0x20) | 0x5): case 0: case 1: case 2: case 3: case 4: case 5: snmp_log(4, "mibII/tcp: Unsupported mode (%d)\n", reqinfo->mode); break; default: snmp_log(4, "mibII/tcp: Unrecognised mode (%d)\n", reqinfo->mode); break; } return (0); } # 707 "mibII/tcp.c" int tcp_load(netsnmp_cache *cache, void *vmagic) { long ret_value = -1; if (auto_nlist("tcpstat", (char *)&tcpstat, sizeof(tcpstat))) ret_value = 0; if ( ret_value < 0 ) { do {if (snmp_get_do_debugging()) {debugmsgtoken ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",716), debugmsg ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",716), debugmsgtoken ("mibII/tcpScalar", "Failed to load TCP scalar Group (tcpstat)\n"), debugmsg ("mibII/tcpScalar", "Failed to load TCP scalar Group (tcpstat)\n");} }while(0); } else { do {if (snmp_get_do_debugging()) {debugmsgtoken ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",718), debugmsg ("trace","%s(): %s, %d:\n",__FUNCTION__, "mibII/tcp.c",718), debugmsgtoken ("mibII/tcpScalar", "Loaded TCP scalar Group (tcpstat)\n"), debugmsg ("mibII/tcpScalar", "Loaded TCP scalar Group (tcpstat)\n");} }while(0); } return ret_value; } # 740 "mibII/tcp.c" void tcp_free(netsnmp_cache *cache, void *magic) { memset(&tcpstat, 0, sizeof(tcpstat)); }