summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--package/net-snmp/Config.in29
-rw-r--r--package/net-snmp/Makefile159
-rw-r--r--package/net-snmp/files/snmpd.conf14
-rw-r--r--package/net-snmp/files/snmpd.default1
-rw-r--r--package/net-snmp/files/snmpd.init25
-rw-r--r--package/net-snmp/ipkg/libnetsnmp.control8
-rw-r--r--package/net-snmp/ipkg/snmp-utils.control9
-rw-r--r--package/net-snmp/ipkg/snmpd.conffiles2
-rw-r--r--package/net-snmp/ipkg/snmpd.control9
-rw-r--r--package/net-snmp/patches/500-debian-subset-5.1.2-6.1.patch7282
-rw-r--r--package/net-snmp/patches/750-ieee802dot11.patch6156
11 files changed, 13694 insertions, 0 deletions
diff --git a/package/net-snmp/Config.in b/package/net-snmp/Config.in
new file mode 100644
index 0000000000..8f0cdffff5
--- /dev/null
+++ b/package/net-snmp/Config.in
@@ -0,0 +1,29 @@
+config BR2_PACKAGE_NET_SNMP
+ prompt "net-snmp - Open source SNMP (Simple Network Management Protocol) implementation"
+ bool
+ default y if CONFIG_DEVEL
+ help
+ Simple Network Management Protocol (SNMP) is a widely used
+ protocol for monitoring the health and welfare of network
+ equipment (eg. routers), computer equipment and even devices
+ like UPSs. Net-SNMP is a suite of applications used to implement
+ SNMP v1, SNMP v2c and SNMP v3 using both IPv4 and IPv6.
+
+ http://www.net-snmp.org/
+
+
+config BR2_PACKAGE_LIBNETSNMP
+ tristate "libnet-snmp - SNMP libraries"
+ default m if CONFIG_DEVEL
+ depends BR2_PACKAGE_NET_SNMP
+
+config BR2_PACKAGE_SNMPD
+ tristate "snmdp - SNMP agent"
+ default m if CONFIG_DEVEL
+ depends BR2_PACKAGE_LIBNETSNMP
+
+config BR2_PACKAGE_SNMP_UTILS
+ tristate "snmp-utils - SNMP client utilities"
+ default m if CONFIG_DEVEL
+ depends BR2_PACKAGE_LIBNETSNMP
+
diff --git a/package/net-snmp/Makefile b/package/net-snmp/Makefile
new file mode 100644
index 0000000000..7211906998
--- /dev/null
+++ b/package/net-snmp/Makefile
@@ -0,0 +1,159 @@
+# $Id$
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=net-snmp
+PKG_VERSION:=5.1.2
+PKG_RELEASE:=1
+PKG_MD5SUM:=8080555ab3f90011f25d5122042d9a8d
+
+PKG_SOURCE_URL:=@SF/net-snmp
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_CAT:=zcat
+
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
+PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
+
+SNMP_MIB_MODULES_INCLUDED = \
+ host/hr_device \
+ host/hr_disk \
+ host/hr_filesys \
+ host/hr_network \
+ host/hr_partition \
+ host/hr_proc \
+ host/hr_storage \
+ host/hr_system \
+ ieee802dot11 \
+ mibII/at \
+ mibII/icmp \
+ mibII/interfaces \
+ mibII/ip \
+ mibII/snmp_mib \
+ mibII/sysORTable \
+ mibII/system_mib \
+ mibII/tcp \
+ mibII/udp \
+ mibII/vacm_context \
+ mibII/vacm_vars \
+ snmpv3/snmpEngine \
+ snmpv3/snmpMPDStats \
+ snmpv3/usmStats \
+ snmpv3/usmUser \
+ snmpv3mibs \
+ tunnel \
+ ucd-snmp/loadave \
+ ucd-snmp/memory \
+ ucd-snmp/proc \
+ ucd-snmp/vmstat \
+ util_funcs \
+ utilities/execute \
+
+SNMP_MIB_MODULES_EXCLUDED = \
+ agent_mibs \
+ agentx \
+ host \
+ mibII \
+ notification \
+ snmpv3mibs \
+ target \
+ ucd_snmp \
+ utilities \
+
+SNMP_TRANSPORTS_INCLUDED = UDP
+
+SNMP_TRANSPORTS_EXCLUDED = Callback TCP TCPv6 UDPv6 Unix
+
+PKG_CONFIGURE_OPTIONS = \
+ --enable-shared \
+ --enable-static \
+ --with-endianness=little \
+ --with-logfile=/var/log/snmpd.log \
+ --with-persistent-directory=/usr/lib/snmp/ \
+ --with-default-snmp-version=1 \
+ --with-sys-contact=root@localhost \
+ --with-sys-location=Unknown \
+ --enable-applications \
+ --disable-debugging \
+ --disable-ipv6 \
+ --disable-manuals \
+ --disable-mib-loading \
+ --disable-mibs \
+ --disable-scripts \
+ --with-out-mib-modules="$(SNMP_MIB_MODULES_EXCLUDED)" \
+ --with-mib-modules="$(SNMP_MIB_MODULES_INCLUDED)" \
+ --with-out-transports="$(SNMP_TRANSPORTS_EXCLUDED)" \
+ --with-transports="$(SNMP_TRANSPORTS_INCLUDED)" \
+ --without-opaque-special-types \
+ --without-openssl \
+ --without-libwrap \
+ --without-rpm \
+ --without-zlib \
+
+include $(TOPDIR)/package/rules.mk
+
+$(eval $(call PKG_template,LIBNETSNMP,libnetsnmp,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,SNMPD,snmpd,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,SNMP_UTILS,snmp-utils,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+
+$(PKG_BUILD_DIR)/.configured:
+ (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
+ $(TARGET_CONFIGURE_OPTS) \
+ CFLAGS="$(TARGET_CFLAGS)" \
+ CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
+ LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
+ ac_cv_header_pcap_h=no \
+ ./configure \
+ --target=$(GNU_TARGET_NAME) \
+ --host=$(GNU_TARGET_NAME) \
+ --build=$(GNU_HOST_NAME) \
+ --program-prefix="" \
+ --program-suffix="" \
+ --prefix=/usr \
+ --exec-prefix=/usr \
+ --bindir=/usr/bin \
+ --datadir=/usr/share \
+ --includedir=/usr/include \
+ --infodir=/usr/share/info \
+ --libdir=/usr/lib \
+ --libexecdir=/usr/lib \
+ --localstatedir=/var \
+ --mandir=/usr/share/man \
+ --sbindir=/usr/sbin \
+ --sysconfdir=/etc \
+ $(DISABLE_LARGEFILE) \
+ $(DISABLE_NLS) \
+ $(PKG_CONFIGURE_OPTIONS) \
+ );
+ touch $@
+
+$(PKG_BUILD_DIR)/.built:
+ rm -rf $(PKG_INSTALL_DIR)
+ mkdir -p $(PKG_INSTALL_DIR)
+ $(MAKE) -C $(PKG_BUILD_DIR) \
+ INSTALL_PREFIX="$(PKG_INSTALL_DIR)" \
+ all install
+ touch $@
+
+$(IPKG_LIBNETSNMP):
+ install -d -m0755 $(IDIR_LIBNETSNMP)/usr/lib
+ cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libnetsnmp{,agent,helpers,mibs}.so.* $(IDIR_LIBNETSNMP)/usr/lib/
+ $(RSTRIP) $(IDIR_LIBNETSNMP)
+ $(IPKG_BUILD) $(IDIR_LIBNETSNMP) $(PACKAGE_DIR)
+
+$(IPKG_SNMPD):
+ install -d -m0755 $(IDIR_SNMPD)/etc/snmp
+ install -m0644 ./files/snmpd.conf $(IDIR_SNMPD)/etc/snmp/snmpd.conf
+ install -d -m0755 $(IDIR_SNMPD)/etc/default
+ install -m0644 ./files/snmpd.default $(IDIR_SNMPD)/etc/default/snmpd
+ install -d -m0755 $(IDIR_SNMPD)/etc/init.d
+ install -m0755 ./files/snmpd.init $(IDIR_SNMPD)/etc/init.d/snmpd
+ install -d -m0755 $(IDIR_SNMPD)/usr/sbin
+ cp -fpR $(PKG_INSTALL_DIR)/usr/sbin/snmpd $(IDIR_SNMPD)/usr/sbin/
+ $(RSTRIP) $(IDIR_SNMPD)
+ $(IPKG_BUILD) $(IDIR_SNMPD) $(PACKAGE_DIR)
+
+$(IPKG_SNMP_UTILS):
+ install -d -m0755 $(IDIR_SNMP_UTILS)/usr/bin
+ cp -fpR $(PKG_INSTALL_DIR)/usr/bin/snmp{get,set,status,test,walk} $(IDIR_SNMP_UTILS)/usr/bin/
+ $(RSTRIP) $(IDIR_SNMP_UTILS)
+ $(IPKG_BUILD) $(IDIR_SNMP_UTILS) $(PACKAGE_DIR)
diff --git a/package/net-snmp/files/snmpd.conf b/package/net-snmp/files/snmpd.conf
new file mode 100644
index 0000000000..f6e872ab64
--- /dev/null
+++ b/package/net-snmp/files/snmpd.conf
@@ -0,0 +1,14 @@
+com2sec ro default public
+com2sec rw localhost private
+
+group public v1 ro
+group public v2c ro
+group public usm ro
+group private v1 rw
+group private v2c rw
+group private usm rw
+
+view all included .1
+
+access public "" any noauth exact all none none
+access private "" any noauth exact all all all
diff --git a/package/net-snmp/files/snmpd.default b/package/net-snmp/files/snmpd.default
new file mode 100644
index 0000000000..758c8e44fe
--- /dev/null
+++ b/package/net-snmp/files/snmpd.default
@@ -0,0 +1 @@
+OPTIONS="-Lf /dev/null -p /var/run/snmpd.pid"
diff --git a/package/net-snmp/files/snmpd.init b/package/net-snmp/files/snmpd.init
new file mode 100644
index 0000000000..46b429760b
--- /dev/null
+++ b/package/net-snmp/files/snmpd.init
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+DEFAULT=/etc/default/snmpd
+LIB_D=/var/lib/snmp
+LOG_D=/var/log
+RUN_D=/var/run
+PID_F=$RUN_D/snmpd.pid
+
+[ -f $DEFAULT ] && . $DEFAULT
+
+case $1 in
+ start)
+ [ -d $LIB_D ] || mkdir -p $LIB_D
+ [ -d $LOG_D ] || mkdir -p $LOG_D
+ [ -d $RUN_D ] || mkdir -p $RUN_D
+ snmpd $OPTIONS
+ ;;
+ stop)
+ [ -f $PID_F ] && kill $(cat $PID_F)
+ ;;
+ *)
+ echo "usage: $0 (start|stop)"
+ exit 1
+esac
+exit $?
diff --git a/package/net-snmp/ipkg/libnetsnmp.control b/package/net-snmp/ipkg/libnetsnmp.control
new file mode 100644
index 0000000000..e7046b07af
--- /dev/null
+++ b/package/net-snmp/ipkg/libnetsnmp.control
@@ -0,0 +1,8 @@
+Package: libnetsnmp
+Priority: optional
+Section: libs
+Version: [TBDL]
+Architecture: [TBDL]
+Maintainer: Nico <nthill@free.fr>
+Source: http://nthill.free.fr/openwrt/sources/net-snmp/
+Description: an SNMP library
diff --git a/package/net-snmp/ipkg/snmp-utils.control b/package/net-snmp/ipkg/snmp-utils.control
new file mode 100644
index 0000000000..58415fbdd4
--- /dev/null
+++ b/package/net-snmp/ipkg/snmp-utils.control
@@ -0,0 +1,9 @@
+Package: snmp-utils
+Priority: optional
+Section: admin
+Version: [TBDL]
+Architecture: [TBDL]
+Maintainer: Nico <nthill@free.fr>
+Source: http://nthill.free.fr/openwrt/sources/net-snmp/
+Description: a collection of SNMP utilities
+Depends: libsnmp
diff --git a/package/net-snmp/ipkg/snmpd.conffiles b/package/net-snmp/ipkg/snmpd.conffiles
new file mode 100644
index 0000000000..2864cc903a
--- /dev/null
+++ b/package/net-snmp/ipkg/snmpd.conffiles
@@ -0,0 +1,2 @@
+/etc/default/snmpd
+/etc/snmp/snmpd.conf
diff --git a/package/net-snmp/ipkg/snmpd.control b/package/net-snmp/ipkg/snmpd.control
new file mode 100644
index 0000000000..7b29393498
--- /dev/null
+++ b/package/net-snmp/ipkg/snmpd.control
@@ -0,0 +1,9 @@
+Package: snmpd
+Priority: optional
+Section: admin
+Version: [TBDL]
+Architecture: [TBDL]
+Maintainer: Nico <nthill@free.fr>
+Source: http://nthill.free.fr/openwrt/sources/net-snmp/
+Description: an SNMP agent
+Depends: libsnmp
diff --git a/package/net-snmp/patches/500-debian-subset-5.1.2-6.1.patch b/package/net-snmp/patches/500-debian-subset-5.1.2-6.1.patch
new file mode 100644
index 0000000000..fd99ed745c
--- /dev/null
+++ b/package/net-snmp/patches/500-debian-subset-5.1.2-6.1.patch
@@ -0,0 +1,7282 @@
+diff -ruN net-snmp-5.1.2-orig/EXAMPLE-trap.conf net-snmp-5.1.2-5/EXAMPLE-trap.conf
+--- net-snmp-5.1.2-orig/EXAMPLE-trap.conf 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/EXAMPLE-trap.conf 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,18 @@
++###############################################################################
++#
++# EXAMPLE.conf:
++# An example configuration file for configuring the ucd-snmp snmptrapd agent.
++#
++###############################################################################
++#
++# This file is intended to only be an example. If, however, you want
++# to use it, it should be placed in /etc/snmp/snmptrapd.conf.
++# When the snmptrapd agent starts up, this is where it will look for it.
++#
++# All lines beginning with a '#' are comments and are intended for you
++# to read. All other lines are configuration commands for the agent.
++
++#
++# PLEASE: read the snmptrapd.conf(5) manual page as well!
++#
++
+diff -ruN net-snmp-5.1.2-orig/EXAMPLE.conf.def net-snmp-5.1.2-5/EXAMPLE.conf.def
+--- net-snmp-5.1.2-orig/EXAMPLE.conf.def 2003-02-25 15:04:06.000000000 +0100
++++ net-snmp-5.1.2-5/EXAMPLE.conf.def 2005-03-13 16:17:21.000000000 +0100
+@@ -6,7 +6,7 @@
+ ###############################################################################
+ #
+ # This file is intended to only be an example. If, however, you want
+-# to use it, it should be placed in SYSCONFDIR/share/snmp/snmpd.conf.
++# to use it, it should be placed in /etc/snmp/snmpd.conf.
+ # When the snmpd agent starts up, this is where it will look for it.
+ #
+ # You might be interested in generating your own snmpd.conf file using
+@@ -58,31 +58,37 @@
+ # from):
+
+ # sec.name source community
+-com2sec local localhost COMMUNITY
+-com2sec mynetwork NETWORK/24 COMMUNITY
++com2sec paranoid default public
++#com2sec readonly default public
++#com2sec readwrite default private
+
+ ####
+ # Second, map the security names into group names:
+
+ # sec.model sec.name
+-group MyRWGroup v1 local
+-group MyRWGroup v2c local
+-group MyRWGroup usm local
+-group MyROGroup v1 mynetwork
+-group MyROGroup v2c mynetwork
+-group MyROGroup usm mynetwork
++group MyROSystem v1 paranoid
++group MyROSystem v2c paranoid
++group MyROSystem usm paranoid
++group MyROGroup v1 readonly
++group MyROGroup v2c readonly
++group MyROGroup usm readonly
++group MyRWGroup v1 readwrite
++group MyRWGroup v2c readwrite
++group MyRWGroup usm readwrite
+
+ ####
+ # Third, create a view for us to let the groups have rights to:
+
+ # incl/excl subtree mask
+ view all included .1 80
++view system included .iso.org.dod.internet.mgmt.mib-2.system
+
+ ####
+ # Finally, grant the 2 groups access to the 1 view with different
+ # write permissions:
+
+ # context sec.model sec.level match read write notif
++access MyROSystem "" any noauth exact system none none
+ access MyROGroup "" any noauth exact all none none
+ access MyRWGroup "" any noauth exact all all none
+
+@@ -100,8 +106,8 @@
+ # value of an object whose value is given here will fail with an error
+ # status of notWritable.
+
+-syslocation Right here, right now.
+-syscontact Me <me@somewhere.org>
++syslocation Unknown (configure /etc/snmp/snmpd.local.conf)
++syscontact Root <root@localhost> (configure /etc/snmp/snmpd.local.conf)
+
+ # Example output of snmpwalk:
+ # % snmpwalk -v 1 -c public localhost system
+@@ -135,13 +141,13 @@
+ #
+
+ # Make sure mountd is running
+-proc mountd
++#proc mountd
+
+ # Make sure there are no more than 4 ntalkds running, but 0 is ok too.
+-proc ntalkd 4
++#proc ntalkd 4
+
+ # Make sure at least one sendmail, but less than or equal to 10 are running.
+-proc sendmail 10 1
++#proc sendmail 10 1
+
+ # A snmpwalk of the prTable would look something like this:
+ #
+@@ -199,7 +205,7 @@
+ # ARGS: optional arguments to be passed to the program
+
+ # a simple hello world
+-exec echotest /bin/echo hello world
++#exec echotest /bin/echo hello world
+
+ # Run a shell script containing:
+ #
+@@ -250,7 +256,7 @@
+
+ # Check the / partition and make sure it contains at least 10 megs.
+
+-disk / 10000
++#disk / 10000
+
+ # % snmpwalk -v 1 -c public localhost .EXTENSIBLEDOTMIB.DISKMIBNUM
+ # enterprises.ucdavis.diskTable.dskEntry.diskIndex.1 = 0
+@@ -279,7 +285,7 @@
+ # 15MAX: Similar, but for 15 min average.
+
+ # Check for loads:
+-load 12 14 14
++#load 12 14 14
+
+ # % snmpwalk -v 1 -c public localhost .EXTENSIBLEDOTMIB.LOADAVEMIBNUM
+ # enterprises.ucdavis.loadTable.laEntry.loadaveIndex.1 = 1
+@@ -365,7 +371,7 @@
+ # (commented out here since it requires that you place the
+ # script in the right location. (its not installed by default))
+
+-# pass .EXTENSIBLEDOTMIB.255 /bin/sh PREFIX/local/passtest
++# pass .EXTENSIBLEDOTMIB.255 /bin/sh /usr/local/passtest
+
+ # % snmpwalk -v 1 -c public localhost .EXTENSIBLEDOTMIB.255
+ # enterprises.ucdavis.255.1 = "life the universe and everything"
+diff -ruN net-snmp-5.1.2-orig/FAQ net-snmp-5.1.2-5/FAQ
+--- net-snmp-5.1.2-orig/FAQ 2004-08-07 10:02:45.000000000 +0200
++++ net-snmp-5.1.2-5/FAQ 2005-03-13 16:17:21.000000000 +0100
+@@ -104,7 +104,7 @@
+ I don't understand the new access control stuff - what does it mean?
+ How do I configure SNMPv3 users?
+ The 'createUser' line disappears when I start the agent. Why?
+- What's the difference between /var/ucd-snmp and /usr/local/share/snmp?
++ What's the difference between /var/ucd-snmp and /usr/share/snmp?
+ My new agent is ignoring the old snmpd.conf file. Why?
+ Why am I getting "Connection refused"?
+ I'm getting errors about "bad security model" - why?
+@@ -620,7 +620,7 @@
+
+ Firstly,
+
+- cp MY-MIB.txt /usr/local/share/snmp/mibs
++ cp MY-MIB.txt /usr/share/snmp/mibs
+
+ or
+
+@@ -639,7 +639,7 @@
+ Note that you need *both* steps.
+ The first command copies the file defining the new MIB to a
+ expected location for MIB files. This defaults to
+- /usr/local/share/snmp/mibs (or PREFIX/share/snmp/mibs if the the
++ /usr/share/snmp/mibs (or PREFIX/share/snmp/mibs if the the
+ suite was installed into a different base location). Some
+ ready-packaged distributions (such as Linux RPM packages) may look
+ for MIB files in a different location, such as /etc/snmp/mibs - put
+@@ -1111,7 +1111,7 @@
+ If this is the case, then you can specify this interpreter
+ explicitly as part of the trap handle directive:
+
+- traphandle default /usr/bin/perl /usr/local/bin/log_it
++ traphandle default /usr/bin/perl /usr/bin/log_it
+
+ Note that in this case, it's almost certain that you'll also
+ need to give the full path to the traphandle script (as shown)
+@@ -1263,7 +1263,7 @@
+ (if appropriate) the community string to use.
+
+ Some of these (such as the MIB file location), might belong in a
+- shared snmp.conf file (typically /usr/local/share/snmp/snmp.conf or
++ shared snmp.conf file (typically /usr/share/snmp/snmp.conf or
+ /etc/snmp/snmp.conf) to apply to all users of the system. Others
+ (particularly the SNMPv3 security settings), are more likely to refer
+ to a particular user, and should go in a personal snmp.conf file
+@@ -1522,7 +1522,7 @@
+
+
+ Alternatively, the tools may be looking in the wrong place.
+- The default location for the mib files is /usr/local/share/snmp/mibs.
++ The default location for the mib files is /usr/share/snmp/mibs.
+ Again, this is set when the suite is first configured and compiled.
+ This can be changed using the environmental variable 'MIBDIRS'
+ or the snmp.conf directive 'mibdirs'.
+@@ -2507,11 +2507,11 @@
+
+
+
+-What's the difference between /var/ucd-snmp and /usr/local/share/snmp?
++What's the difference between /var/ucd-snmp and /usr/share/snmp?
+ ---------------------------------------------------------------------
+
+ Most "static" agent configuration should go in the traditional location
+- (typically /usr/local/share/snmp/snmpd.conf or /etc/snmp). The
++ (typically /usr/share/snmp/snmpd.conf or /etc/snmp). The
+ /var/ucd-snmp (or /var/net-snmp) location is used for information set during
+ the running of the agent, which needs to be persistent between one run of
+ the agent and the next.
+@@ -2531,7 +2531,7 @@
+ distribution), with the current release installed from the source.
+
+ The default location for this file with the basic distribution is
+- /usr/local/share/snmp/snmpd.conf (or PREFIX/share/snmp/snmpd.conf).
++ /usr/share/snmp/snmpd.conf (or PREFIX/share/snmp/snmpd.conf).
+ Ready-installed versions often look for the file as /etc/snmpd.conf,
+ or /etc/snmp/snmpd.conf. Try moving the old config file to the new
+ location, and restart the agent.
+diff -ruN net-snmp-5.1.2-orig/Makefile.in net-snmp-5.1.2-5/Makefile.in
+--- net-snmp-5.1.2-orig/Makefile.in 2004-08-04 14:48:14.000000000 +0200
++++ net-snmp-5.1.2-5/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -163,6 +163,11 @@
+ ( cd perl ; $(MAKE) clean ) ; \
+ fi
+
++perlrealclean:
++ @if test -f perl/Makefile; then \
++ ( cd perl ; $(MAKE) realclean ) ; \
++ fi
++
+ #
+ # make distclean completely removes all traces of building including
+ # any files generated by configure itself.
+diff -ruN net-snmp-5.1.2-orig/Makefile.rules net-snmp-5.1.2-5/Makefile.rules
+--- net-snmp-5.1.2-orig/Makefile.rules 2004-02-13 23:42:28.000000000 +0100
++++ net-snmp-5.1.2-5/Makefile.rules 2005-03-13 16:17:21.000000000 +0100
+@@ -301,7 +301,7 @@
+ # cleaning targets
+ #
+ clean: cleansubdirs $(OTHERCLEANTODOS)
+- rm -f core ${OBJS} ${LOBJS} $(STANDARDCLEANTARGETS) $(OTHERCLEANTARGETS)
++ rm -f -- core ${OBJS} ${LOBJS} $(STANDARDCLEANTARGETS) $(OTHERCLEANTARGETS)
+ rm -rf .libs
+
+ cleansubdirs:
+diff -ruN net-snmp-5.1.2-orig/Makefile.top net-snmp-5.1.2-5/Makefile.top
+--- net-snmp-5.1.2-orig/Makefile.top 2004-08-07 09:29:36.000000000 +0200
++++ net-snmp-5.1.2-5/Makefile.top 2005-03-13 16:17:21.000000000 +0100
+@@ -27,6 +27,7 @@
+ snmplibdir = $(datadir)/snmp
+ mibdir = $(snmplibdir)/mibs
+ persistentdir = @PERSISTENT_DIRECTORY@
++sysconfdir = @sysconfdir@
+ INSTALL_PREFIX = @INSTALL_PREFIX@
+
+ #
+diff -ruN net-snmp-5.1.2-orig/acconfig.h net-snmp-5.1.2-5/acconfig.h
+--- net-snmp-5.1.2-orig/acconfig.h 2004-06-28 20:54:17.000000000 +0200
++++ net-snmp-5.1.2-5/acconfig.h 2005-03-13 16:17:21.000000000 +0100
+@@ -560,6 +560,9 @@
+ /* define if you have getservbyname */
+ #undef HAVE_GETSERVBYNAME
+
++/* define if you have dlopen */
++#undef HAVE_DLOPEN
++
+ /* printing system */
+ #undef HAVE_LPSTAT
+ #undef LPSTAT_PATH
+diff -ruN net-snmp-5.1.2-orig/acinclude.m4 net-snmp-5.1.2-5/acinclude.m4
+--- net-snmp-5.1.2-orig/acinclude.m4 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/acinclude.m4 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,193 @@
++dnl @synopsis AC_PROMPT_USER_NO_DEFINE(VARIABLENAME,QUESTION,[DEFAULT])
++dnl
++dnl Asks a QUESTION and puts the results in VARIABLENAME with an optional
++dnl DEFAULT value if the user merely hits return.
++dnl
++dnl @version 1.15
++dnl @author Wes Hardaker <hardaker@users.sourceforge.net>
++dnl
++AC_DEFUN([AC_PROMPT_USER_NO_DEFINE],
++dnl changequote(<<, >>) dnl
++dnl <<
++[
++if test "x$defaults" = "xno"; then
++echo $ac_n "$2 ($3): $ac_c"
++read tmpinput
++if test "$tmpinput" = "" -a "$3" != ""; then
++ tmpinput="$3"
++fi
++eval $1=\"$tmpinput\"
++else
++tmpinput="$3"
++eval $1=\"$tmpinput\"
++fi
++]
++dnl >>
++dnl changequote([, ])
++) dnl done AC_PROMPT_USER
++
++dnl @synopsis AC_PROMPT_USER(VARIABLENAME,QUESTION,[DEFAULT],QUOTED)
++dnl
++dnl Asks a QUESTION and puts the results in VARIABLENAME with an optional
++dnl DEFAULT value if the user merely hits return. Also calls
++dnl AC_DEFINE_UNQUOTED() on the VARIABLENAME for VARIABLENAMEs that should
++dnl be entered into the config.h file as well. If QUOTED is "quoted" then
++dnl the result will be defined within quotes.
++dnl
++dnl @version 1.15
++dnl @author Wes Hardaker <hardaker@users.sourceforge.net>
++dnl
++AC_DEFUN([AC_PROMPT_USER],
++[
++MSG_CHECK=`echo "$2" | tail -1`
++AC_CACHE_CHECK($MSG_CHECK, ac_cv_user_prompt_$1,
++[echo "" >&AC_FD_MSG
++AC_PROMPT_USER_NO_DEFINE($1,[$2],$3)
++eval ac_cv_user_prompt_$1=\$$1
++echo $ac_n "setting $MSG_CHECK to... $ac_c" >&AC_FD_MSG
++])
++if test "$ac_cv_user_prompt_$1" != "none"; then
++ if test "x$4" = "xquoted" -o "x$4" = "xQUOTED"; then
++ AC_DEFINE_UNQUOTED($1,"$ac_cv_user_prompt_$1")
++ else
++ AC_DEFINE_UNQUOTED($1,$ac_cv_user_prompt_$1)
++ fi
++fi
++]) dnl
++
++dnl @synopsis AC_CHECK_STRUCT_FOR(INCLUDES,STRUCT,MEMBER,DEFINE,[no])
++dnl
++dnl Checks STRUCT for MEMBER and defines DEFINE if found.
++dnl
++dnl @version 1.15
++dnl @author Wes Hardaker <hardaker@users.sourceforge.net>
++dnl
++AC_DEFUN(AC_CHECK_STRUCT_FOR,[
++
++ac_safe_struct=`echo "$2" | sed 'y%./+-%__p_%'`
++ac_safe_member=`echo "$3" | sed 'y%./+-%__p_%'`
++ac_safe_all="ac_cv_struct_${ac_safe_struct}_has_${ac_safe_member}"
++changequote(, )dnl
++ ac_uc_define=STRUCT_`echo "${ac_safe_struct}_HAS_${ac_safe_member}" | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
++changequote([, ])dnl
++
++AC_MSG_CHECKING([for $2.$3])
++AC_CACHE_VAL($ac_safe_all,
++[
++if test "x$4" = "x"; then
++ defineit="= 0"
++elif test "x$4" = "xno"; then
++ defineit=""
++else
++ defineit="$4"
++fi
++AC_TRY_COMPILE([
++$1
++],[
++struct $2 testit;
++testit.$3 $defineit;
++], eval "${ac_safe_all}=yes", eval "${ac_safe_all}=no" )
++])
++
++if eval "test \"x$`echo ${ac_safe_all}`\" = \"xyes\""; then
++ AC_MSG_RESULT(yes)
++ AC_DEFINE_UNQUOTED($ac_uc_define)
++else
++ AC_MSG_RESULT(no)
++fi
++
++])
++
++dnl AC_CHECK_IFNET_FOR(SUBSTRUCT,[no])
++AC_DEFUN(AC_CHECK_IFNET_FOR,[
++dnl check for $1 in struct ifnet
++AC_CHECK_STRUCT_FOR([
++#ifdef IFNET_NEEDS_KERNEL
++#define _KERNEL 1
++#endif
++#include <sys/types.h>
++#include <sys/socket.h>
++#ifdef HAVE_SYS_TIME_H
++#include <sys/time.h>
++#endif
++#include <net/if.h>
++#ifdef HAVE_NET_IF_VAR_H
++#include <net/if_var.h>
++#endif
++#ifdef HAVE_SYS_QUEUE_H
++#include <sys/queue.h>
++#endif
++#ifdef linux
++struct ifnet {
++ char *if_name; /* name, e.g. "en" or "lo" */
++ short if_unit; /* sub-unit for lower level driver */
++ short if_mtu; /* maximum transmission unit */
++ short if_flags; /* up/down, broadcast, etc. */
++ int if_metric; /* routing metric (external only) */
++ char if_hwaddr [6]; /* ethernet address */
++ int if_type; /* interface type: 1=generic,
++ 28=slip, ether=6, loopback=24 */
++ int if_speed; /* interface speed: in bits/sec */
++
++ struct sockaddr if_addr; /* interface's address */
++ struct sockaddr ifu_broadaddr; /* broadcast address */
++ struct sockaddr ia_subnetmask; /* interface's mask */
++
++ struct ifqueue {
++ int ifq_len;
++ int ifq_drops;
++ } if_snd; /* output queue */
++ int if_ibytes; /* octets received on interface */
++ int if_ipackets; /* packets received on interface */
++ int if_ierrors; /* input errors on interface */
++ int if_iqdrops; /* input queue overruns */
++ int if_obytes; /* octets sent on interface */
++ int if_opackets; /* packets sent on interface */
++ int if_oerrors; /* output errors on interface */
++ int if_collisions; /* collisions on csma interfaces */
++/* end statistics */
++ struct ifnet *if_next;
++};
++#endif
++], ifnet, $1, $2)
++])
++
++dnl
++dnl Add a search path to the LIBS and CFLAGS variables
++dnl
++AC_DEFUN(AC_ADD_SEARCH_PATH,[
++ if test "x$1" != x -a -d $1; then
++ if test -d $1/lib; then
++ LDFLAGS="-L$1/lib $LDFLAGS"
++ fi
++ if test -d $1/include; then
++ CPPFLAGS="-I$1/include $CPPFLAGS"
++ fi
++ fi
++])
++
++dnl
++dnl Store information for displaying later.
++dnl
++AC_DEFUN(AC_MSG_CACHE_INIT,[
++ rm -f configure-summary
++])
++
++AC_DEFUN(AC_MSG_CACHE_ADD,[
++ cat >> configure-summary << EOF
++ $1
++EOF
++])
++
++AC_DEFUN(AC_MSG_CACHE_DISPLAY,[
++ echo ""
++ echo "---------------------------------------------------------"
++ echo " Net-SNMP configuration summary:"
++ echo "---------------------------------------------------------"
++ echo ""
++ cat configure-summary
++ echo ""
++ echo "---------------------------------------------------------"
++ echo ""
++])
++
+diff -ruN net-snmp-5.1.2-orig/agent/Makefile.in net-snmp-5.1.2-5/agent/Makefile.in
+--- net-snmp-5.1.2-orig/agent/Makefile.in 2003-10-14 15:30:48.000000000 +0200
++++ net-snmp-5.1.2-5/agent/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -82,7 +82,7 @@
+ # libnetsnmpagent objects
+ LIBAGENTOBJS=snmp_agent.o snmp_vars.o agent_read_config.o \
+ agent_registry.o agent_index.o agent_trap.o kernel.o \
+- agent_handler.o @OTHERAGENTLIBOBJS@
++ agent_handler.o @OTHERAGENTLIBOBJS@ @WRAPLIBS@
+ LLIBAGENTOBJS=snmp_agent.lo snmp_vars.lo agent_read_config.lo \
+ agent_registry.lo agent_index.lo agent_trap.lo kernel.lo \
+ agent_handler.lo @OTHERAGENTLIBLOBJS@
+@@ -120,11 +120,11 @@
+
+
+ libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION): ${LLIBAGENTOBJS} libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION)
+- $(LIB_LD_CMD) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBAGENTOBJS} $(LIB_LD_LIBS)
++ $(LIB_LD_CMD) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBAGENTOBJS} $(LIB_LD_LIBS) $(AGENT_RELINK_LIBS)
+ $(RANLIB) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION)
+
+ libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION): ${LMIBOBJS}
+- $(LIB_LD_CMD) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION) ${LMIBOBJS} $(LIB_LD_LIBS)
++ $(LIB_LD_CMD) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION) ${LMIBOBJS} $(LIB_LD_LIBS) $(MIBS_RELINK_LIBS) $(LIBSENSORS)
+ $(RANLIB) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION)
+
+ embedperlinstall:
+diff -ruN net-snmp-5.1.2-orig/agent/helpers/Makefile.in net-snmp-5.1.2-5/agent/helpers/Makefile.in
+--- net-snmp-5.1.2-orig/agent/helpers/Makefile.in 2004-03-01 06:26:12.000000000 +0100
++++ net-snmp-5.1.2-5/agent/helpers/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -68,5 +68,5 @@
+ all: standardall
+
+ libnetsnmphelpers.$(LIB_EXTENSION)$(LIB_VERSION): ${LOBJS}
+- $(LIB_LD_CMD) libnetsnmphelpers.$(LIB_EXTENSION)$(LIB_VERSION) ${LOBJS} $(LIB_LD_LIBS)
++ $(LIB_LD_CMD) libnetsnmphelpers.$(LIB_EXTENSION)$(LIB_VERSION) ${LOBJS} $(LIB_LD_LIBS) $(HELPERS_RELINK_LIBS)
+ $(RANLIB) libnetsnmphelpers.$(LIB_EXTENSION)$(LIB_VERSION)
+diff -ruN net-snmp-5.1.2-orig/agent/mibgroup/agentx/protocol.h net-snmp-5.1.2-5/agent/mibgroup/agentx/protocol.h
+--- net-snmp-5.1.2-orig/agent/mibgroup/agentx/protocol.h 2002-04-20 09:30:01.000000000 +0200
++++ net-snmp-5.1.2-5/agent/mibgroup/agentx/protocol.h 2005-03-13 16:17:21.000000000 +0100
+@@ -10,7 +10,7 @@
+ */
+
+ #define AGENTX_PORT 705
+-#define AGENTX_SOCKET "/var/agentx/master"
++#define AGENTX_SOCKET "/var/run/agentx"
+
+ /*
+ * AgentX versions
+diff -ruN net-snmp-5.1.2-orig/agent/mibgroup/mibII/interfaces.c net-snmp-5.1.2-5/agent/mibgroup/mibII/interfaces.c
+--- net-snmp-5.1.2-orig/agent/mibgroup/mibII/interfaces.c 2004-07-23 02:55:41.000000000 +0200
++++ net-snmp-5.1.2-5/agent/mibgroup/mibII/interfaces.c 2005-03-13 16:17:21.000000000 +0100
+@@ -1512,14 +1512,28 @@
+ struct ifreq ifrq;
+ struct ifnet **ifnetaddr_ptr;
+ FILE *devin;
+- unsigned long rec_pkt, rec_oct, rec_err, rec_drop;
+- unsigned long snd_pkt, snd_oct, snd_err, snd_drop, coll;
+ int i, fd;
+ conf_if_list *if_ptr;
++#ifdef SCNuMAX
++ uintmax_t rec_pkt, rec_oct, rec_err, rec_drop, rec_mcast;
++ uintmax_t snd_pkt, snd_oct, snd_err, snd_drop, coll;
++ const char *scan_line_2_2 =
++ "%" SCNuMAX " %" SCNuMAX " %" SCNuMAX " %" SCNuMAX
++ " %*" SCNuMAX " %*" SCNuMAX " %*" SCNuMAX " %*" SCNuMAX
++ " %" SCNuMAX " %" SCNuMAX " %" SCNuMAX " %" SCNuMAX
++ " %*" SCNuMAX " %" SCNuMAX;
++ const char *scan_line_2_0 =
++ "%" SCNuMAX " %" SCNuMAX " %*" SCNuMAX " %*" SCNuMAX
++ " %*" SCNuMAX " %" SCNuMAX " %" SCNuMAX " %*" SCNuMAX
++ " %*" SCNuMAX " %" SCNuMAX;
++#else
++ unsigned long rec_pkt, rec_oct, rec_err, rec_drop;
++ unsigned long snd_pkt, snd_oct, snd_err, snd_drop, coll;
+ const char *scan_line_2_2 =
+ "%lu %lu %lu %lu %*lu %*lu %*lu %*lu %lu %lu %lu %lu %*lu %lu";
+ const char *scan_line_2_0 =
+ "%lu %lu %*lu %*lu %*lu %lu %lu %*lu %*lu %lu";
++#endif
+ const char *scan_line_to_use;
+ struct timeval et; /* elapsed time */
+
+@@ -1598,6 +1612,10 @@
+ struct ifnet *nnew;
+ char *stats, *ifstart = line;
+
++ /* Ignore interfaces with no statistics. */
++ if (strstr(line, "No statistics available."))
++ continue;
++
+ if (line[strlen(line) - 1] == '\n')
+ line[strlen(line) - 1] = '\0';
+
+@@ -1631,7 +1649,7 @@
+ &coll) != 5)) {
+ if ((scan_line_to_use == scan_line_2_2)
+ && !strstr(line, "No statistics available"))
+- snmp_log(LOG_ERR,
++ snmp_log(LOG_DEBUG,
+ "/proc/net/dev data format error, line ==|%s|",
+ line);
+ continue;
+diff -ruN net-snmp-5.1.2-orig/agent/mibgroup/smux/smux.c net-snmp-5.1.2-5/agent/mibgroup/smux/smux.c
+--- net-snmp-5.1.2-orig/agent/mibgroup/smux/smux.c 2004-02-04 12:25:20.000000000 +0100
++++ net-snmp-5.1.2-5/agent/mibgroup/smux/smux.c 2005-03-13 16:17:21.000000000 +0100
+@@ -819,14 +819,14 @@
+ passwd[string_len] = '\0';
+ if (!smux_auth_peer(oid_name, oid_name_len, passwd, fd)) {
+ snmp_log(LOG_WARNING,
+- "refused smux peer: oid %s, password %s, descr %s\n",
+- oid_print, passwd, descr);
++ "refused smux peer: oid %s, descr %s\n",
++ oid_print, descr);
+ *fail = TRUE;
+ return ptr;
+ }
+ snmp_log(LOG_INFO,
+- "accepted smux peer: oid %s, password %s, descr %s\n",
+- oid_print, passwd, descr);
++ "accepted smux peer: oid %s, descr %s\n",
++ oid_print, descr);
+ *fail = FALSE;
+ return ptr;
+ }
+diff -ruN net-snmp-5.1.2-orig/apps/Makefile.in net-snmp-5.1.2-5/apps/Makefile.in
+--- net-snmp-5.1.2-orig/apps/Makefile.in 2004-03-09 16:51:28.000000000 +0100
++++ net-snmp-5.1.2-5/apps/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -129,7 +129,7 @@
+ $(LINK) -o $@ snmpdf.$(OSUFFIX) $(LOCAL_LIBS) ${LDFLAGS} ${LIBS}
+
+ libnetsnmptrapd.$(LIB_EXTENSION)$(LIB_VERSION): $(LLIBTRAPD_OBJS)
+- $(LIB_LD_CMD) libnetsnmptrapd.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBTRAPD_OBJS} $(LIB_LD_LIBS)
++ $(LIB_LD_CMD) libnetsnmptrapd.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBTRAPD_OBJS} $(LIB_LD_LIBS) $(TRAPD_RELINK_LIBS)
+ $(RANLIB) libnetsnmptrapd.$(LIB_EXTENSION)$(LIB_VERSION)
+
+ snmpinforminstall:
+diff -ruN net-snmp-5.1.2-orig/apps/snmpnetstat/if.c net-snmp-5.1.2-5/apps/snmpnetstat/if.c
+--- net-snmp-5.1.2-orig/apps/snmpnetstat/if.c 2002-04-20 09:30:10.000000000 +0200
++++ net-snmp-5.1.2-5/apps/snmpnetstat/if.c 2005-03-13 16:17:21.000000000 +0100
+@@ -300,8 +300,9 @@
+ case IFINDEX:
+ ifindex = *var->val.integer;
+ for (cur_if = if_table;
+- cur_if->ifindex != ifindex && cur_if->ifindex != 0;
+- cur_if++);
++ cur_if < (if_table + cfg_nnets) &&
++ cur_if->ifindex != ifindex &&
++ cur_if->ifindex != 0; cur_if++);
+ if (cur_if >= (if_table + cfg_nnets)) {
+ fprintf(stderr,
+ "Inconsistent reponse from server. Aborting\n");
+@@ -492,8 +493,14 @@
+ case IPIFINDEX:
+ ifindex = *var->val.integer;
+ for (cur_if = if_table;
+- cur_if->ifindex != ifindex && cur_if->ifindex != 0;
+- cur_if++);
++ cur_if < (if_table + cfg_nnets) &&
++ cur_if->ifindex != ifindex &&
++ cur_if->ifindex != 0; cur_if++);
++ if (cur_if >= (if_table + cfg_nnets)) {
++ fprintf(stderr,
++ "Inconsistent reponse from server. Aborting.\n");
++ exit(0);
++ }
+ cur_if->ifindex = ifindex;
+ break;
+ case IPADDR:
+@@ -567,8 +574,14 @@
+ case IFINDEX:
+ ifindex = *var->val.integer;
+ for (cur_if = if_table;
+- cur_if->ifindex != ifindex && cur_if->ifindex != 0;
+- cur_if++);
++ cur_if < (if_table + cfg_nnets) &&
++ cur_if->ifindex != ifindex &&
++ cur_if->ifindex != 0; cur_if++);
++ if (cur_if >= (if_table + cfg_nnets)) {
++ fprintf(stderr,
++ "Inconsistent reponse from server. Aborting.\n");
++ exit(0);
++ }
+ cur_if->ifindex = ifindex;
+ break;
+ case INOCTETS:
+diff -ruN net-snmp-5.1.2-orig/configure.in net-snmp-5.1.2-5/configure.in
+--- net-snmp-5.1.2-orig/configure.in 2004-06-23 00:06:40.000000000 +0200
++++ net-snmp-5.1.2-5/configure.in 2005-03-13 16:17:21.000000000 +0100
+@@ -161,6 +161,9 @@
+ AC_DEFINE(SNMP_NO_DEBUGGING)
+ fi
+
++AC_ARG_WITH(rpm,
++[ --without-rpm Don't use RPM even if available.])
++
+ AC_ARG_WITH(dmalloc,
+ [ --with-dmalloc=PATH Use dmalloc library (www.dmalloc.com)],
+ if test "x$withval" = "xyes"; then
+@@ -1539,12 +1542,13 @@
+ AC_CHECK_LIB(RSAglue, RSA_PKCS1_RSAref)
+ fi
+
+- AC_CHECK_LIB(crypto, EVP_md5)
++ AC_CHECK_LIB(crypto, EVP_md5, [CRYPTOLIBS=-lcrypto], , )
+ AC_CHECK_FUNCS(AES_cfb128_encrypt)
+ fi
+ elif test "x$askedpkcs" = "xyes"; then
+ AC_CHECK_LIB(pkcs11, C_Initialize)
+ fi
++AC_SUBST(CRYPTOLIBS)
+
+ # Check for libraries that the agent needs
+ # saving old libraries
+@@ -1664,8 +1668,9 @@
+ # Replace `main' with a function in -lkvm:
+ AC_CHECK_LIB(kvm, kvm_read)
+ # DYNAMIC MODULE SUPPORT
+-AC_CHECK_LIB(dl, dlopen)
+-AC_CHECK_FUNCS(dlopen)
++AC_CHECK_FUNC(dlopen, AC_DEFINE(HAVE_DLOPEN),
++ AC_CHECK_LIB(dl, dlopen, AC_DEFINE(HAVE_DLOPEN)
++ LIBS="${LIBS} -ldl"))
+
+ AC_CHECK_FUNCS(kvm_openfiles nlist knlist kvm_getprocs)
+ echo "$with_mib_modules" | grep "ucd-snmp/diskio" >/dev/null
+@@ -1979,7 +1984,7 @@
+
+ AC_MSG_RESULT([$ac_cv_type_ssize_t])
+ if test $ac_cv_type_ssize_t = yes; then
+- AC_DEFINE(HAVE_SSIZE_T)
++ AC_DEFINE(HAVE_SSIZE_T, 1, [Define if type ssize_t is available])
+ fi
+
+ # Check ps args
+diff -ruN net-snmp-5.1.2-orig/debian/README.Debian net-snmp-5.1.2-5/debian/README.Debian
+diff -ruN net-snmp-5.1.2-orig/debian/changelog net-snmp-5.1.2-5/debian/changelog
+diff -ruN net-snmp-5.1.2-orig/debian/control net-snmp-5.1.2-5/debian/control
+diff -ruN net-snmp-5.1.2-orig/debian/copyright net-snmp-5.1.2-5/debian/copyright
+diff -ruN net-snmp-5.1.2-orig/debian/fixman net-snmp-5.1.2-5/debian/fixman
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-base.dirs net-snmp-5.1.2-5/debian/libsnmp-base.dirs
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-base.docs net-snmp-5.1.2-5/debian/libsnmp-base.docs
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-base.files net-snmp-5.1.2-5/debian/libsnmp-base.files
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-base.postrm net-snmp-5.1.2-5/debian/libsnmp-base.postrm
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-base.prerm net-snmp-5.1.2-5/debian/libsnmp-base.prerm
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-perl.docs net-snmp-5.1.2-5/debian/libsnmp-perl.docs
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp-perl.files net-snmp-5.1.2-5/debian/libsnmp-perl.files
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5-dev.files net-snmp-5.1.2-5/debian/libsnmp5-dev.files
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5-dev.manpages net-snmp-5.1.2-5/debian/libsnmp5-dev.manpages
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5.dirs net-snmp-5.1.2-5/debian/libsnmp5.dirs
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5.docs net-snmp-5.1.2-5/debian/libsnmp5.docs
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5.files net-snmp-5.1.2-5/debian/libsnmp5.files
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5.postinst net-snmp-5.1.2-5/debian/libsnmp5.postinst
+diff -ruN net-snmp-5.1.2-orig/debian/libsnmp5.prerm net-snmp-5.1.2-5/debian/libsnmp5.prerm
+diff -ruN net-snmp-5.1.2-orig/debian/manpages/encode_keychange.1 net-snmp-5.1.2-5/debian/manpages/encode_keychange.1
+diff -ruN net-snmp-5.1.2-orig/debian/manpages/net-snmp-config.1 net-snmp-5.1.2-5/debian/manpages/net-snmp-config.1
+diff -ruN net-snmp-5.1.2-orig/debian/manpages/snmpvacm.1 net-snmp-5.1.2-5/debian/manpages/snmpvacm.1
+diff -ruN net-snmp-5.1.2-orig/debian/manpages/tkmib.1 net-snmp-5.1.2-5/debian/manpages/tkmib.1
+diff -ruN net-snmp-5.1.2-orig/debian/rules net-snmp-5.1.2-5/debian/rules
+diff -ruN net-snmp-5.1.2-orig/debian/snmp.files net-snmp-5.1.2-5/debian/snmp.files
+diff -ruN net-snmp-5.1.2-orig/debian/snmp.manpages net-snmp-5.1.2-5/debian/snmp.manpages
+diff -ruN net-snmp-5.1.2-orig/debian/snmp.preinst net-snmp-5.1.2-5/debian/snmp.preinst
+diff -ruN net-snmp-5.1.2-orig/debian/snmpd.default net-snmp-5.1.2-5/debian/snmpd.default
+diff -ruN net-snmp-5.1.2-orig/debian/snmpd.files net-snmp-5.1.2-5/debian/snmpd.files
+diff -ruN net-snmp-5.1.2-orig/debian/snmpd.init net-snmp-5.1.2-5/debian/snmpd.init
+diff -ruN net-snmp-5.1.2-orig/debian/snmpd.postinst net-snmp-5.1.2-5/debian/snmpd.postinst
+diff -ruN net-snmp-5.1.2-orig/debian/snmpd.postrm net-snmp-5.1.2-5/debian/snmpd.postrm
+diff -ruN net-snmp-5.1.2-orig/debian/tkmib.docs net-snmp-5.1.2-5/debian/tkmib.docs
+diff -ruN net-snmp-5.1.2-orig/debian/tkmib.files net-snmp-5.1.2-5/debian/tkmib.files
+diff -ruN net-snmp-5.1.2-orig/debian/tkmib.manpages net-snmp-5.1.2-5/debian/tkmib.manpages
+diff -ruN net-snmp-5.1.2-orig/debian/watch net-snmp-5.1.2-5/debian/watch
+diff -ruN net-snmp-5.1.2-orig/ipkg/libsnmp/CONTROL/control net-snmp-5.1.2-5/ipkg/libsnmp/CONTROL/control
+diff -ruN net-snmp-5.1.2-orig/ipkg/libsnmp-dev/CONTROL/control net-snmp-5.1.2-5/ipkg/libsnmp-dev/CONTROL/control
+diff -ruN net-snmp-5.1.2-orig/ipkg/rules net-snmp-5.1.2-5/ipkg/rules
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmp-utils/CONTROL/control net-snmp-5.1.2-5/ipkg/snmp-utils/CONTROL/control
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd/CONTROL/conffiles net-snmp-5.1.2-5/ipkg/snmpd/CONTROL/conffiles
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd/CONTROL/control net-snmp-5.1.2-5/ipkg/snmpd/CONTROL/control
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd/etc/default/snmpd net-snmp-5.1.2-5/ipkg/snmpd/etc/default/snmpd
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd/etc/init.d/snmpd net-snmp-5.1.2-5/ipkg/snmpd/etc/init.d/snmpd
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd/etc/snmp/snmpd.conf net-snmp-5.1.2-5/ipkg/snmpd/etc/snmp/snmpd.conf
+diff -ruN net-snmp-5.1.2-orig/ipkg/snmpd-static/CONTROL/control net-snmp-5.1.2-5/ipkg/snmpd-static/CONTROL/control
+diff -ruN net-snmp-5.1.2-orig/ipkg/version net-snmp-5.1.2-5/ipkg/version
+diff -ruN net-snmp-5.1.2-orig/local/Makefile.in net-snmp-5.1.2-5/local/Makefile.in
+--- net-snmp-5.1.2-orig/local/Makefile.in 2003-12-20 05:38:17.000000000 +0100
++++ net-snmp-5.1.2-5/local/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -58,7 +58,7 @@
+
+ mib2c.made: $(srcdir)/mib2c
+ if test "x$(PERLPROG)" != "x" ; then \
+- $(PERLPROG) -p -e 's%^#!.*/perl.*%#!$(PERLPROG)%;s#/usr/local/share/snmp#$(snmplibdir)#;' ${srcdir}/mib2c > mib2c.made; \
++ $(PERLPROG) -p -e 's%^#!.*/perl.*%#!$(PERLPROG)%;s#/usr/local/share/snmp#$(snmplibdir)#;s#/usr/local/etc/snmp#$(SNMPCONFPATH)#;' ${srcdir}/mib2c > mib2c.made; \
+ else \
+ touch mib2c.made; \
+ fi
+diff -ruN net-snmp-5.1.2-orig/local/mib2c net-snmp-5.1.2-5/local/mib2c
+--- net-snmp-5.1.2-orig/local/mib2c 2004-06-15 16:26:37.000000000 +0200
++++ net-snmp-5.1.2-5/local/mib2c 2005-03-13 16:17:21.000000000 +0100
+@@ -56,7 +56,8 @@
+ if($ENV{MIB2C_DIR}) {
+ push @def_search_dirs, $ENV{MIB2C_DIR};
+ }
+-push @def_search_dirs, "/usr/local/share/snmp/";
++push @def_search_dirs, "/etc/snmp/";
++push @def_search_dirs, "/usr/share/snmp/";
+
+
+ sub usage {
+diff -ruN net-snmp-5.1.2-orig/man/mib2c.1.def net-snmp-5.1.2-5/man/mib2c.1.def
+--- net-snmp-5.1.2-orig/man/mib2c.1.def 2003-10-02 20:04:19.000000000 +0200
++++ net-snmp-5.1.2-5/man/mib2c.1.def 2005-03-13 16:17:21.000000000 +0100
+@@ -72,8 +72,9 @@
+ .TP
+ .BI -c " CONFIGFILE"
+ Use CONFIGFILE when generating code. These files will be searched for
+-first in the current directory and then in the DATADIR directory
+-(which is where the default mib2c configuration files can be found).
++first in the current directory and then in /etc/snmp
++(which is where the default mib2c configuration files can be found)
++and finally in the DATADIR directory.
+ Running mib2c without the -c CONFIGFILE option will display
+ a description of the valid values for CONFIGFILE, that is,
+ the available config files, including new ones that you might
+diff -ruN net-snmp-5.1.2-orig/man/mib_api.3.def net-snmp-5.1.2-5/man/mib_api.3.def
+--- net-snmp-5.1.2-orig/man/mib_api.3.def 2004-04-15 00:41:32.000000000 +0200
++++ net-snmp-5.1.2-5/man/mib_api.3.def 2005-03-13 16:17:21.000000000 +0100
+@@ -5,7 +5,7 @@
+ add_module_replacement,
+ read_module, read_mib, read_all_mibs,
+ read_objid, read_module_node,
+-get_module_node, read_objid
++get_module_node
+ snmp_set_mib_warnings, snmp_set_save_descriptions,
+ shutdown_mib,
+ print_mib,
+@@ -34,9 +34,9 @@
+ .PP
+ .BI "void print_mib(FILE *" "fp" );
+ .PP
+-.BI "int read_objid(char *" "input" ", oid *" "output" ", int *" "out_len" );
++.BI "int read_objid(char *" "input" ", oid *" "output" ", size_t *" "out_len" );
+ .br
+-.BI "int get_module_node(char *" "name" ", char *" "module" ", oid *" "objid" ", int *" "objidlen" );
++.BI "int get_module_node(char *" "name" ", char *" "module" ", oid *" "objid" ", size_t *" "objidlen" );
+ .PP
+ .BI "void print_variable(const oid *" "objid" ", size_t " "objidlen" ", struct variable_list *" "variable" );
+ .br
+diff -ruN net-snmp-5.1.2-orig/man/snmp_config.5.def net-snmp-5.1.2-5/man/snmp_config.5.def
+--- net-snmp-5.1.2-orig/man/snmp_config.5.def 2003-12-10 11:41:41.000000000 +0100
++++ net-snmp-5.1.2-5/man/snmp_config.5.def 2005-03-13 16:17:21.000000000 +0100
+@@ -11,7 +11,7 @@
+ found and read from. By default, the applications look for
+ configuration files in the following 4 directories, in order:
+ SYSCONFDIR/snmp,
+-DATADIR/snmp, LIBDIR/snmp, and $HOME/.snmp. In each of these
++/etc/snmp, LIBDIR/snmp, and $HOME/.snmp. In each of these
+ directories, it looks for files with the extension of both
+ .IR conf " and " local.conf
+ (reading the second ones last). In this manner, there are
+diff -ruN net-snmp-5.1.2-orig/man/snmp_trap_api.3.def net-snmp-5.1.2-5/man/snmp_trap_api.3.def
+--- net-snmp-5.1.2-orig/man/snmp_trap_api.3.def 2003-09-29 04:58:18.000000000 +0200
++++ net-snmp-5.1.2-5/man/snmp_trap_api.3.def 2005-03-13 16:17:21.000000000 +0100
+@@ -1,8 +1,7 @@
+ .TH SNMP_TRAP_API 3 "7 Mar 2002" VVERSIONINFO "Net-SNMP"
+ .UC 5
+ .SH NAME
+-send_easy_trap, send_trap_vars, send_v2trap - send TRAPs or INFORMs
+-from a Net-SNMP MIB module
++send_easy_trap, send_trap_vars, send_v2trap - send TRAPs or INFORMs from a Net-SNMP MIB module
+ .SH SYNOPSIS
+ .B #include <net-snmp/agent/agent_trap.h>
+ .PP
+diff -ruN net-snmp-5.1.2-orig/mibs/BGP4-MIB.txt net-snmp-5.1.2-5/mibs/BGP4-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/BGP4-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/BGP4-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,929 @@
++ BGP4-MIB DEFINITIONS ::= BEGIN
++
++ IMPORTS
++ MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE,
++ IpAddress, Integer32, Counter32, Gauge32, mib-2
++ FROM SNMPv2-SMI
++ MODULE-COMPLIANCE, OBJECT-GROUP, NOTIFICATION-GROUP
++ FROM SNMPv2-CONF;
++
++ bgp MODULE-IDENTITY
++ LAST-UPDATED "9902100000Z"
++ ORGANIZATION "IETF IDR Working Group"
++ CONTACT-INFO "E-mail: idr@merit.net
++
++ Susan Hares (Editor)
++ Merit Network
++ 4251 Plymouth Road
++ Suite C
++ Ann Arbor, MI 48105-2785
++ Tel: +1 734 936 2095
++ Fax: +1 734 647 3185
++ E-mail: skh@merit.edu
++
++ Jeff Johnson (Editor)
++ RedBack Networks, Inc.
++ 1389 Moffett Park Drive
++ Sunnyvale, CA 94089-1134
++ Tel: +1 408 548 3516
++ Fax: +1 408 548 3599
++ E-mail: jeff@redback.com"
++ DESCRIPTION
++ "The MIB module for BGP-4."
++ REVISION "9902100000Z"
++ DESCRIPTION
++ "Corrected duplicate OBJECT IDENTIFIER
++ assignment in the conformance information."
++ REVISION "9601080000Z"
++ DESCRIPTION
++ "1) Fixed the definitions of the traps to
++ make them equivalent to their initial
++ definition in RFC 1269.
++ 2) Added compliance and conformance info."
++ ::= { mib-2 15 }
++
++ bgpVersion OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (1..255))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Vector of supported BGP protocol version
++ numbers. Each peer negotiates the version
++ from this vector. Versions are identified
++ via the string of bits contained within this
++ object. The first octet contains bits 0 to
++ 7, the second octet contains bits 8 to 15,
++ and so on, with the most significant bit
++ referring to the lowest bit number in the
++ octet (e.g., the MSB of the first octet
++ refers to bit 0). If a bit, i, is present
++ and set, then the version (i+1) of the BGP
++ is supported."
++ ::= { bgp 1 }
++
++ bgpLocalAs OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The local autonomous system number."
++ ::= { bgp 2 }
++
++
++
++ -- BGP Peer table. This table contains, one entry per BGP
++ -- peer, information about the BGP peer.
++
++ bgpPeerTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF BgpPeerEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "BGP peer table. This table contains,
++ one entry per BGP peer, information about the
++ connections with BGP peers."
++ ::= { bgp 3 }
++
++ bgpPeerEntry OBJECT-TYPE
++ SYNTAX BgpPeerEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Entry containing information about the
++ connection with a BGP peer."
++ INDEX { bgpPeerRemoteAddr }
++ ::= { bgpPeerTable 1 }
++
++ BgpPeerEntry ::= SEQUENCE {
++ bgpPeerIdentifier
++ IpAddress,
++ bgpPeerState
++ INTEGER,
++ bgpPeerAdminStatus
++ INTEGER,
++ bgpPeerNegotiatedVersion
++ Integer32,
++ bgpPeerLocalAddr
++ IpAddress,
++ bgpPeerLocalPort
++ INTEGER,
++ bgpPeerRemoteAddr
++ IpAddress,
++ bgpPeerRemotePort
++ INTEGER,
++ bgpPeerRemoteAs
++ INTEGER,
++ bgpPeerInUpdates
++ Counter32,
++ bgpPeerOutUpdates
++ Counter32,
++ bgpPeerInTotalMessages
++ Counter32,
++ bgpPeerOutTotalMessages
++ Counter32,
++ bgpPeerLastError
++ OCTET STRING,
++ bgpPeerFsmEstablishedTransitions
++ Counter32,
++ bgpPeerFsmEstablishedTime
++ Gauge32,
++ bgpPeerConnectRetryInterval
++ INTEGER,
++ bgpPeerHoldTime
++ INTEGER,
++ bgpPeerKeepAlive
++ INTEGER,
++ bgpPeerHoldTimeConfigured
++ INTEGER,
++ bgpPeerKeepAliveConfigured
++ INTEGER,
++ bgpPeerMinASOriginationInterval
++ INTEGER,
++ bgpPeerMinRouteAdvertisementInterval
++ INTEGER,
++ bgpPeerInUpdateElapsedTime
++ Gauge32
++ }
++
++ bgpPeerIdentifier OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The BGP Identifier of this entry's BGP peer."
++ ::= { bgpPeerEntry 1 }
++
++ bgpPeerState OBJECT-TYPE
++ SYNTAX INTEGER {
++ idle(1),
++ connect(2),
++ active(3),
++ opensent(4),
++ openconfirm(5),
++ established(6)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The BGP peer connection state."
++ ::= { bgpPeerEntry 2 }
++
++ bgpPeerAdminStatus OBJECT-TYPE
++ SYNTAX INTEGER {
++ stop(1),
++ start(2)
++ }
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The desired state of the BGP connection. A
++ transition from 'stop' to 'start' will cause
++ the BGP Start Event to be generated. A
++ transition from 'start' to 'stop' will cause
++ the BGP Stop Event to be generated. This
++ parameter can be used to restart BGP peer
++ connections. Care should be used in providing
++ write access to this object without adequate
++ authentication."
++ ::= { bgpPeerEntry 3 }
++
++ bgpPeerNegotiatedVersion OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The negotiated version of BGP running between
++ the two peers."
++ ::= { bgpPeerEntry 4 }
++
++ bgpPeerLocalAddr OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The local IP address of this entry's BGP
++ connection."
++ ::= { bgpPeerEntry 5 }
++
++ bgpPeerLocalPort OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The local port for the TCP connection between
++ the BGP peers."
++ ::= { bgpPeerEntry 6 }
++
++ bgpPeerRemoteAddr OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The remote IP address of this entry's BGP
++ peer."
++ ::= { bgpPeerEntry 7 }
++
++ bgpPeerRemotePort OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The remote port for the TCP connection between
++ the BGP peers. Note that the objects
++ bgpPeerLocalAddr, bgpPeerLocalPort,
++ bgpPeerRemoteAddr and bgpPeerRemotePort
++ provide the appropriate reference to the
++ standard MIB TCP connection table."
++ ::= { bgpPeerEntry 8 }
++
++ bgpPeerRemoteAs OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The remote autonomous system number."
++ ::= { bgpPeerEntry 9 }
++
++ bgpPeerInUpdates OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of BGP UPDATE messages received on
++ this connection. This object should be
++ initialized to zero (0) when the connection is
++ established."
++ ::= { bgpPeerEntry 10 }
++
++ bgpPeerOutUpdates OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of BGP UPDATE messages transmitted
++ on this connection. This object should be
++ initialized to zero (0) when the connection is
++ established."
++ ::= { bgpPeerEntry 11 }
++
++ bgpPeerInTotalMessages OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of messages received from the
++ remote peer on this connection. This object
++ should be initialized to zero when the
++ connection is established."
++ ::= { bgpPeerEntry 12 }
++
++ bgpPeerOutTotalMessages OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of messages transmitted to
++ the remote peer on this connection. This object
++ should be initialized to zero when the
++ connection is established."
++ ::= { bgpPeerEntry 13 }
++
++ bgpPeerLastError OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (2))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The last error code and subcode seen by this
++ peer on this connection. If no error has
++ occurred, this field is zero. Otherwise, the
++ first byte of this two byte OCTET STRING
++ contains the error code, and the second byte
++ contains the subcode."
++ ::= { bgpPeerEntry 14 }
++
++ bgpPeerFsmEstablishedTransitions OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of times the BGP FSM
++ transitioned into the established state."
++ ::= { bgpPeerEntry 15 }
++
++ bgpPeerFsmEstablishedTime OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This timer indicates how long (in seconds) this
++ peer has been in the Established state or how long
++ since this peer was last in the Established state.
++ It is set to zero when a new peer is configured or
++ the router is booted."
++ ::= { bgpPeerEntry 16 }
++
++ bgpPeerConnectRetryInterval OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the ConnectRetry
++ timer. The suggested value for this timer is
++ 120 seconds."
++ ::= { bgpPeerEntry 17 }
++
++ bgpPeerHoldTime OBJECT-TYPE
++ SYNTAX INTEGER ( 0 | 3..65535 )
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the Hold Timer
++ established with the peer. The value of this
++ object is calculated by this BGP speaker by
++ using the smaller of the value in
++ bgpPeerHoldTimeConfigured and the Hold Time
++ received in the OPEN message. This value
++ must be at lease three seconds if it is not
++ zero (0) in which case the Hold Timer has
++ not been established with the peer, or, the
++ value of bgpPeerHoldTimeConfigured is zero (0)."
++ ::= { bgpPeerEntry 18 }
++
++ bgpPeerKeepAlive OBJECT-TYPE
++ SYNTAX INTEGER ( 0 | 1..21845 )
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the KeepAlive
++ timer established with the peer. The value of
++ this object is calculated by this BGP speaker
++ such that, when compared with bgpPeerHoldTime,
++ it has the same proportion as what
++ bgpPeerKeepAliveConfigured has when compared
++ with bgpPeerHoldTimeConfigured. If the value
++ of this object is zero (0), it indicates that
++ the KeepAlive timer has not been established
++ with the peer, or, the value of
++ bgpPeerKeepAliveConfigured is zero (0)."
++ ::= { bgpPeerEntry 19 }
++
++ bgpPeerHoldTimeConfigured OBJECT-TYPE
++ SYNTAX INTEGER ( 0 | 3..65535 )
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the Hold Time
++ configured for this BGP speaker with this peer.
++ This value is placed in an OPEN message sent to
++ this peer by this BGP speaker, and is compared
++ with the Hold Time field in an OPEN message
++ received from the peer when determining the Hold
++ Time (bgpPeerHoldTime) with the peer. This value
++ must not be less than three seconds if it is not
++ zero (0) in which case the Hold Time is NOT to be
++ established with the peer. The suggested value for
++ this timer is 90 seconds."
++ ::= { bgpPeerEntry 20 }
++
++ bgpPeerKeepAliveConfigured OBJECT-TYPE
++ SYNTAX INTEGER ( 0 | 1..21845 )
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the KeepAlive timer
++ configured for this BGP speaker with this peer.
++ The value of this object will only determine the
++ KEEPALIVE messages' frequency relative to the value
++ specified in bgpPeerHoldTimeConfigured; the actual
++ time interval for the KEEPALIVE messages is
++ indicated by bgpPeerKeepAlive. A reasonable
++ maximum value for this timer would be configured to
++ be one third of that of bgpPeerHoldTimeConfigured.
++ If the value of this object is zero (0), no
++ periodical KEEPALIVE messages are sent to the peer
++ after the BGP connection has been established. The
++ suggested value for this timer is 30 seconds."
++ ::= { bgpPeerEntry 21 }
++
++ bgpPeerMinASOriginationInterval OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the
++ MinASOriginationInterval timer.
++ The suggested value for this timer is 15 seconds."
++ ::= { bgpPeerEntry 22 }
++
++ bgpPeerMinRouteAdvertisementInterval OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "Time interval in seconds for the
++ MinRouteAdvertisementInterval timer.
++ The suggested value for this timer is 30 seconds."
++ ::= { bgpPeerEntry 23 }
++
++ bgpPeerInUpdateElapsedTime OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Elapsed time in seconds since the last BGP
++ UPDATE message was received from the peer.
++ Each time bgpPeerInUpdates is incremented,
++ the value of this object is set to zero (0)."
++ ::= { bgpPeerEntry 24 }
++
++
++
++ bgpIdentifier OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The BGP Identifier of local system."
++ ::= { bgp 4 }
++
++
++
++ -- Received Path Attribute Table. This table contains,
++ -- one entry per path to a network, path attributes
++ -- received from all peers running BGP version 3 or less.
++ -- This table is obsolete, having been replaced in
++ -- functionality with the bgp4PathAttrTable.
++
++ bgpRcvdPathAttrTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF BgpPathAttrEntry
++ MAX-ACCESS not-accessible
++ STATUS obsolete
++ DESCRIPTION
++ "The BGP Received Path Attribute Table contains
++ information about paths to destination networks
++ received from all peers running BGP version 3 or
++ less."
++ ::= { bgp 5 }
++
++ bgpPathAttrEntry OBJECT-TYPE
++ SYNTAX BgpPathAttrEntry
++ MAX-ACCESS not-accessible
++ STATUS obsolete
++ DESCRIPTION
++ "Information about a path to a network."
++ INDEX { bgpPathAttrDestNetwork,
++ bgpPathAttrPeer }
++ ::= { bgpRcvdPathAttrTable 1 }
++
++ BgpPathAttrEntry ::= SEQUENCE {
++ bgpPathAttrPeer
++ IpAddress,
++ bgpPathAttrDestNetwork
++ IpAddress,
++ bgpPathAttrOrigin
++ INTEGER,
++ bgpPathAttrASPath
++ OCTET STRING,
++ bgpPathAttrNextHop
++ IpAddress,
++ bgpPathAttrInterASMetric
++ Integer32
++ }
++
++ bgpPathAttrPeer OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The IP address of the peer where the path
++ information was learned."
++ ::= { bgpPathAttrEntry 1 }
++
++ bgpPathAttrDestNetwork OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The address of the destination network."
++ ::= { bgpPathAttrEntry 2 }
++
++ bgpPathAttrOrigin OBJECT-TYPE
++ SYNTAX INTEGER {
++ igp(1),-- networks are interior
++ egp(2),-- networks learned via EGP
++ incomplete(3) -- undetermined
++ }
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The ultimate origin of the path information."
++ ::= { bgpPathAttrEntry 3 }
++
++ bgpPathAttrASPath OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (2..255))
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The set of ASs that must be traversed to reach
++ the network. This object is probably best
++ represented as SEQUENCE OF INTEGER. For SMI
++ compatibility, though, it is represented as
++ OCTET STRING. Each AS is represented as a pair
++ of octets according to the following algorithm:
++
++ first-byte-of-pair = ASNumber / 256;
++ second-byte-of-pair = ASNumber & 255;"
++ ::= { bgpPathAttrEntry 4 }
++
++ bgpPathAttrNextHop OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The address of the border router that should
++ be used for the destination network."
++ ::= { bgpPathAttrEntry 5 }
++
++ bgpPathAttrInterASMetric OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The optional inter-AS metric. If this
++ attribute has not been provided for this route,
++ the value for this object is 0."
++ ::= { bgpPathAttrEntry 6 }
++
++
++
++ -- BGP-4 Received Path Attribute Table. This table contains,
++ -- one entry per path to a network, path attributes
++ -- received from all peers running BGP-4.
++
++ bgp4PathAttrTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Bgp4PathAttrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The BGP-4 Received Path Attribute Table contains
++ information about paths to destination networks
++ received from all BGP4 peers."
++ ::= { bgp 6 }
++
++ bgp4PathAttrEntry OBJECT-TYPE
++ SYNTAX Bgp4PathAttrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information about a path to a network."
++ INDEX { bgp4PathAttrIpAddrPrefix,
++ bgp4PathAttrIpAddrPrefixLen,
++ bgp4PathAttrPeer }
++ ::= { bgp4PathAttrTable 1 }
++
++ Bgp4PathAttrEntry ::= SEQUENCE {
++ bgp4PathAttrPeer
++ IpAddress,
++ bgp4PathAttrIpAddrPrefixLen
++ INTEGER,
++ bgp4PathAttrIpAddrPrefix
++ IpAddress,
++ bgp4PathAttrOrigin
++ INTEGER,
++ bgp4PathAttrASPathSegment
++ OCTET STRING,
++ bgp4PathAttrNextHop
++ IpAddress,
++ bgp4PathAttrMultiExitDisc
++ INTEGER,
++ bgp4PathAttrLocalPref
++ INTEGER,
++ bgp4PathAttrAtomicAggregate
++ INTEGER,
++ bgp4PathAttrAggregatorAS
++ INTEGER,
++ bgp4PathAttrAggregatorAddr
++ IpAddress,
++ bgp4PathAttrCalcLocalPref
++ INTEGER,
++ bgp4PathAttrBest
++ INTEGER,
++ bgp4PathAttrUnknown
++ OCTET STRING
++ }
++
++ bgp4PathAttrPeer OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address of the peer where the path
++ information was learned."
++ ::= { bgp4PathAttrEntry 1 }
++ bgp4PathAttrIpAddrPrefixLen OBJECT-TYPE
++ SYNTAX INTEGER (0..32)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Length in bits of the IP address prefix in the
++ Network Layer Reachability Information field."
++ ::= { bgp4PathAttrEntry 2 }
++
++ bgp4PathAttrIpAddrPrefix OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "An IP address prefix in the Network Layer
++ Reachability Information field. This object
++ is an IP address containing the prefix with
++ length specified by bgp4PathAttrIpAddrPrefixLen.
++ Any bits beyond the length specified by
++ bgp4PathAttrIpAddrPrefixLen are zeroed."
++ ::= { bgp4PathAttrEntry 3 }
++
++ bgp4PathAttrOrigin OBJECT-TYPE
++ SYNTAX INTEGER {
++ igp(1),-- networks are interior
++ egp(2),-- networks learned via EGP
++ incomplete(3) -- undetermined
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The ultimate origin of the path information."
++ ::= { bgp4PathAttrEntry 4 }
++
++ bgp4PathAttrASPathSegment OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (2..255))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The sequence of AS path segments. Each AS
++ path segment is represented by a triple
++ <type, length, value>.
++
++ The type is a 1-octet field which has two
++ possible values:
++ 1 AS_SET: unordered set of ASs a
++ route in the UPDATE message
++ has traversed
++ 2 AS_SEQUENCE: ordered set of ASs
++ a route in the UPDATE message
++ has traversed.
++
++ The length is a 1-octet field containing the
++ number of ASs in the value field.
++
++ The value field contains one or more AS
++ numbers, each AS is represented in the octet
++ string as a pair of octets according to the
++ following algorithm:
++
++ first-byte-of-pair = ASNumber / 256;
++ second-byte-of-pair = ASNumber & 255;"
++ ::= { bgp4PathAttrEntry 5 }
++
++ bgp4PathAttrNextHop OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The address of the border router that should
++ be used for the destination network."
++ ::= { bgp4PathAttrEntry 6 }
++
++ bgp4PathAttrMultiExitDisc OBJECT-TYPE
++ SYNTAX INTEGER (-1..2147483647)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This metric is used to discriminate between
++ multiple exit points to an adjacent autonomous
++ system. A value of -1 indicates the absence of
++ this attribute."
++ ::= { bgp4PathAttrEntry 7 }
++
++ bgp4PathAttrLocalPref OBJECT-TYPE
++ SYNTAX INTEGER (-1..2147483647)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The originating BGP4 speaker's degree of
++ preference for an advertised route. A value of
++ -1 indicates the absence of this attribute."
++ ::= { bgp4PathAttrEntry 8 }
++
++ bgp4PathAttrAtomicAggregate OBJECT-TYPE
++ SYNTAX INTEGER {
++ lessSpecificRrouteNotSelected(1),
++ lessSpecificRouteSelected(2)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Whether or not a system has selected
++ a less specific route without selecting a
++ more specific route."
++ ::= { bgp4PathAttrEntry 9 }
++
++ bgp4PathAttrAggregatorAS OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The AS number of the last BGP4 speaker that
++ performed route aggregation. A value of zero (0)
++ indicates the absence of this attribute."
++ ::= { bgp4PathAttrEntry 10 }
++
++ bgp4PathAttrAggregatorAddr OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address of the last BGP4 speaker that
++ performed route aggregation. A value of
++ 0.0.0.0 indicates the absence of this attribute."
++ ::= { bgp4PathAttrEntry 11 }
++
++ bgp4PathAttrCalcLocalPref OBJECT-TYPE
++ SYNTAX INTEGER (-1..2147483647)
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The degree of preference calculated by the
++ receiving BGP4 speaker for an advertised route.
++ A value of -1 indicates the absence of this
++ attribute."
++ ::= { bgp4PathAttrEntry 12 }
++
++ bgp4PathAttrBest OBJECT-TYPE
++ SYNTAX INTEGER {
++ false(1),-- not chosen as best route
++ true(2) -- chosen as best route
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "An indication of whether or not this route
++ was chosen as the best BGP4 route."
++ ::= { bgp4PathAttrEntry 13 }
++
++ bgp4PathAttrUnknown OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE(0..255))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "One or more path attributes not understood
++ by this BGP4 speaker. Size zero (0) indicates
++ the absence of such attribute(s). Octets
++ beyond the maximum size, if any, are not
++ recorded by this object."
++ ::= { bgp4PathAttrEntry 14 }
++
++
++ -- Traps.
++
++ -- note that in RFC 1657, bgpTraps was incorrectly
++ -- assigned a value of { bgp 7 }, and each of the
++ -- traps had the bgpPeerRemoteAddr object inappropriately
++ -- removed from their OBJECTS clause. The following
++ -- definitions restore the semantics of the traps as
++ -- they were initially defined in RFC 1269.
++
++ -- { bgp 7 } is unused
++
++ bgpTraps OBJECT IDENTIFIER ::= { bgp 0 }
++
++ bgpEstablished NOTIFICATION-TYPE
++ OBJECTS { bgpPeerRemoteAddr,
++ bgpPeerLastError,
++ bgpPeerState }
++ STATUS current
++ DESCRIPTION
++ "The BGP Established event is generated when
++ the BGP FSM enters the ESTABLISHED state."
++ ::= { bgpTraps 1 }
++
++ bgpBackwardTransition NOTIFICATION-TYPE
++ OBJECTS { bgpPeerRemoteAddr,
++ bgpPeerLastError,
++ bgpPeerState }
++ STATUS current
++ DESCRIPTION
++ "The BGPBackwardTransition Event is generated
++ when the BGP FSM moves from a higher numbered
++ state to a lower numbered state."
++ ::= { bgpTraps 2 }
++
++ -- conformance information
++
++ bgpMIBConformance OBJECT IDENTIFIER ::= { bgp 8 }
++ bgpMIBCompliances OBJECT IDENTIFIER ::= { bgpMIBConformance 1 }
++ bgpMIBGroups OBJECT IDENTIFIER ::= { bgpMIBConformance 2 }
++
++ -- compliance statements
++
++ bgpMIBCompliance MODULE-COMPLIANCE
++ STATUS current
++ DESCRIPTION
++ "The compliance statement for entities which
++ implement the BGP4 mib."
++ MODULE -- this module
++ MANDATORY-GROUPS { bgp4MIBGlobalsGroup,
++ bgp4MIBPeerGroup,
++ bgp4MIBPathAttrGroup,
++ bgp4MIBNotificationGroup }
++ ::= { bgpMIBCompliances 1 }
++
++ -- units of conformance
++
++ bgp4MIBGlobalsGroup OBJECT-GROUP
++ OBJECTS { bgpVersion,
++ bgpLocalAs,
++ bgpIdentifier }
++ STATUS current
++ DESCRIPTION
++ "A collection of objects providing information
++ on global BGP state."
++ ::= { bgpMIBGroups 1 }
++
++ bgp4MIBPeerGroup OBJECT-GROUP
++ OBJECTS { bgpPeerIdentifier,
++ bgpPeerState,
++ bgpPeerAdminStatus,
++ bgpPeerNegotiatedVersion,
++ bgpPeerLocalAddr,
++ bgpPeerLocalPort,
++ bgpPeerRemoteAddr,
++ bgpPeerRemotePort,
++ bgpPeerRemoteAs,
++ bgpPeerInUpdates,
++ bgpPeerOutUpdates,
++ bgpPeerInTotalMessages,
++ bgpPeerOutTotalMessages,
++ bgpPeerLastError,
++ bgpPeerFsmEstablishedTransitions,
++ bgpPeerFsmEstablishedTime,
++ bgpPeerConnectRetryInterval,
++ bgpPeerHoldTime,
++ bgpPeerKeepAlive,
++ bgpPeerHoldTimeConfigured,
++ bgpPeerKeepAliveConfigured,
++ bgpPeerMinASOriginationInterval,
++ bgpPeerMinRouteAdvertisementInterval,
++ bgpPeerInUpdateElapsedTime }
++ STATUS current
++ DESCRIPTION
++ "A collection of objects for managing
++ BGP peers."
++ ::= { bgpMIBGroups 2 }
++
++ bgp4MIBRcvdPathAttrGroup OBJECT-GROUP
++ OBJECTS { bgpPathAttrPeer,
++ bgpPathAttrDestNetwork,
++ bgpPathAttrOrigin,
++ bgpPathAttrASPath,
++ bgpPathAttrNextHop,
++ bgpPathAttrInterASMetric }
++ STATUS obsolete
++ DESCRIPTION
++ "A collection of objects for managing BGP
++ path entries.
++
++ This conformance group is obsolete,
++ replaced by bgp4MIBPathAttrGroup."
++ ::= { bgpMIBGroups 3 }
++
++ bgp4MIBPathAttrGroup OBJECT-GROUP
++ OBJECTS { bgp4PathAttrPeer,
++ bgp4PathAttrIpAddrPrefixLen,
++ bgp4PathAttrIpAddrPrefix,
++ bgp4PathAttrOrigin,
++ bgp4PathAttrASPathSegment,
++ bgp4PathAttrNextHop,
++ bgp4PathAttrMultiExitDisc,
++ bgp4PathAttrLocalPref,
++ bgp4PathAttrAtomicAggregate,
++ bgp4PathAttrAggregatorAS,
++ bgp4PathAttrAggregatorAddr,
++ bgp4PathAttrCalcLocalPref,
++ bgp4PathAttrBest,
++ bgp4PathAttrUnknown }
++ STATUS current
++ DESCRIPTION
++ "A collection of objects for managing
++ BGP path entries."
++ ::= { bgpMIBGroups 4 }
++
++ bgp4MIBNotificationGroup NOTIFICATION-GROUP
++ NOTIFICATIONS { bgpEstablished,
++ bgpBackwardTransition }
++ STATUS current
++ DESCRIPTION
++ "A collection of notifications for signaling
++ changes in BGP peer relationships."
++ ::= { bgpMIBGroups 5 }
++
++ END
+diff -ruN net-snmp-5.1.2-orig/mibs/BRIDGE-MIB.txt net-snmp-5.1.2-5/mibs/BRIDGE-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/BRIDGE-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/BRIDGE-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,1075 @@
++BRIDGE-MIB DEFINITIONS ::= BEGIN
++
++IMPORTS
++ Counter, TimeTicks
++ FROM RFC1155-SMI
++ mib-2
++ FROM RFC1213-MIB
++ OBJECT-TYPE
++ FROM RFC-1212
++ TRAP-TYPE
++ FROM RFC-1215;
++
++-- All representations of MAC addresses in this MIB Module
++-- use, as a textual convention (i.e. this convention does
++-- not affect their encoding), the data type:
++MacAddress ::= OCTET STRING (SIZE (6)) -- a 6 octet address
++ -- in the
++ -- "canonical"
++ -- order
++-- defined by IEEE 802.1a, i.e., as if it were transmitted
++-- least significant bit first, even though 802.5 (in
++-- contrast to other n802.x protocols) requires MAC
++-- addresses to be transmitted most significant bit first.
++--
++-- 16-bit addresses, if needed, are represented by setting
++-- their upper 4 octets to all 0's, i.e., AAFF would be
++-- represented as 00000000AAFF.
++
++-- Similarly, all representations of Bridge-Id in this MIB
++-- Module use, as a textual convention (i.e. this
++-- convention does not affect their encoding), the data
++-- type:
++BridgeId ::= OCTET STRING (SIZE (8)) -- the
++ -- Bridge-Identifier
++ -- as used in the
++ -- Spanning Tree
++-- Protocol to uniquely identify a bridge. Its first two
++-- octets (in network byte order) contain a priority
++-- value and its last 6 octets contain the MAC address
++-- used to refer to a bridge in a unique fashion
++-- (typically, the numerically smallest MAC address
++-- of all ports on the bridge).
++
++-- Several objects in this MIB module represent values of
++-- timers used by the Spanning Tree Protocol. In this
++-- MIB, these timers have values in units of hundreths of
++-- a second (i.e. 1/100 secs).
++-- These timers, when stored in a Spanning Tree Protocol's
++-- BPDU, are in units of 1/256 seconds. Note, however,
++-- that 802.1D-1990 specifies a settable granularity of
++-- no more than 1 second for these timers. To avoid
++-- ambiguity, a data type is defined here as a textual
++-- convention and all representation of these timers
++-- in this MIB module are defined using this data type. An
++-- algorithm is also defined for converting between the
++-- different units, to ensure a timer's value is not
++-- distorted by multiple conversions.
++-- The data type is:
++
++Timeout ::= INTEGER -- a STP timer in units of 1/100 seconds
++
++-- To convert a Timeout value into a value in units of
++-- 1/256 seconds, the following algorithm should be used:
++--
++-- b = floor( (n * 256) / 100)
++--
++-- where:
++-- floor = quotient [ignore remainder]
++-- n is the value in 1/100 second units
++-- b is the value in 1/256 second units
++--
++-- To convert the value from 1/256 second units back to
++-- 1/100 seconds, the following algorithm should be used:
++--
++-- n = ceiling( (b * 100) / 256)
++--
++-- where:
++-- ceiling = quotient [if remainder is 0], or
++-- quotient + 1 [if remainder is non-zero]
++-- n is the value in 1/100 second units
++-- b is the value in 1/256 second units
++--
++-- Note: it is important that the arithmetic operations are
++-- done in the order specified (i.e., multiply first, divide
++-- second).
++
++ dot1dBridge OBJECT IDENTIFIER ::= { mib-2 17 }
++
++-- groups in the Bridge MIB
++
++dot1dBase OBJECT IDENTIFIER ::= { dot1dBridge 1 }
++
++dot1dStp OBJECT IDENTIFIER ::= { dot1dBridge 2 }
++
++dot1dSr OBJECT IDENTIFIER ::= { dot1dBridge 3 }
++-- separately documented
++
++dot1dTp OBJECT IDENTIFIER ::= { dot1dBridge 4 }
++
++dot1dStatic OBJECT IDENTIFIER ::= { dot1dBridge 5 }
++
++-- the dot1dBase group
++
++-- Implementation of the dot1dBase group is mandatory for all
++-- bridges.
++
++dot1dBaseBridgeAddress OBJECT-TYPE
++ SYNTAX MacAddress
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The MAC address used by this bridge when it must
++ be referred to in a unique fashion. It is
++ recommended that this be the numerically smallest
++ MAC address of all ports that belong to this
++ bridge. However it is only required to be unique.
++ When concatenated with dot1dStpPriority a unique
++ BridgeIdentifier is formed which is used in the
++ Spanning Tree Protocol."
++ REFERENCE
++ "IEEE 802.1D-1990: Sections 6.4.1.1.3 and 3.12.5"
++ ::= { dot1dBase 1 }
++
++dot1dBaseNumPorts OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of ports controlled by this bridging
++ entity."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.4.1.1.3"
++ ::= { dot1dBase 2 }
++
++dot1dBaseType OBJECT-TYPE
++ SYNTAX INTEGER {
++ unknown(1),
++ transparent-only(2),
++ sourceroute-only(3),
++ srt(4)
++ }
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "Indicates what type of bridging this bridge can
++ perform. If a bridge is actually performing a
++ certain type of bridging this will be indicated by
++ entries in the port table for the given type."
++ ::= { dot1dBase 3 }
++
++-- The Generic Bridge Port Table
++
++dot1dBasePortTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dBasePortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains generic information about
++ every port that is associated with this bridge.
++ Transparent, source-route, and srt ports are
++ included."
++ ::= { dot1dBase 4 }
++
++dot1dBasePortEntry OBJECT-TYPE
++ SYNTAX Dot1dBasePortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A list of information for each port of the
++ bridge."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.4.2, 6.6.1"
++ INDEX { dot1dBasePort }
++ ::= { dot1dBasePortTable 1 }
++
++Dot1dBasePortEntry ::=
++ SEQUENCE {
++ dot1dBasePort
++ INTEGER,
++ dot1dBasePortIfIndex
++ INTEGER,
++ dot1dBasePortCircuit
++
++ OBJECT IDENTIFIER,
++ dot1dBasePortDelayExceededDiscards
++ Counter,
++ dot1dBasePortMtuExceededDiscards
++ Counter
++ }
++
++dot1dBasePort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the port for which this entry
++ contains bridge management information."
++ ::= { dot1dBasePortEntry 1 }
++
++dot1dBasePortIfIndex OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The value of the instance of the ifIndex object,
++ defined in MIB-II, for the interface corresponding
++ to this port."
++ ::= { dot1dBasePortEntry 2 }
++
++dot1dBasePortCircuit OBJECT-TYPE
++ SYNTAX OBJECT IDENTIFIER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "For a port which (potentially) has the same value
++ of dot1dBasePortIfIndex as another port on the
++ same bridge, this object contains the name of an
++ object instance unique to this port. For example,
++ in the case where multiple ports correspond one-
++ to-one with multiple X.25 virtual circuits, this
++ value might identify an (e.g., the first) object
++ instance associated with the X.25 virtual circuit
++ corresponding to this port.
++
++ For a port which has a unique value of
++ dot1dBasePortIfIndex, this object can have the
++ value { 0 0 }."
++ ::= { dot1dBasePortEntry 3 }
++
++dot1dBasePortDelayExceededDiscards OBJECT-TYPE
++ SYNTAX Counter
++
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of frames discarded by this port due
++ to excessive transit delay through the bridge. It
++ is incremented by both transparent and source
++ route bridges."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.6.1.1.3"
++ ::= { dot1dBasePortEntry 4 }
++
++dot1dBasePortMtuExceededDiscards OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of frames discarded by this port due
++ to an excessive size. It is incremented by both
++ transparent and source route bridges."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.6.1.1.3"
++ ::= { dot1dBasePortEntry 5 }
++
++-- the dot1dStp group
++
++-- Implementation of the dot1dStp group is optional. It is
++-- implemented by those bridges that support the Spanning Tree
++-- Protocol.
++
++dot1dStpProtocolSpecification OBJECT-TYPE
++ SYNTAX INTEGER {
++ unknown(1),
++ decLb100(2),
++ ieee8021d(3)
++ }
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "An indication of what version of the Spanning
++ Tree Protocol is being run. The value
++ 'decLb100(2)' indicates the DEC LANbridge 100
++ Spanning Tree protocol. IEEE 802.1d
++ implementations will return 'ieee8021d(3)'. If
++ future versions of the IEEE Spanning Tree Protocol
++ are released that are incompatible with the
++ current version a new value will be defined."
++
++ ::= { dot1dStp 1 }
++
++dot1dStpPriority OBJECT-TYPE
++ SYNTAX INTEGER (0..65535)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The value of the write-able portion of the Bridge
++ ID, i.e., the first two octets of the (8 octet
++ long) Bridge ID. The other (last) 6 octets of the
++ Bridge ID are given by the value of
++ dot1dBaseBridgeAddress."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.7"
++ ::= { dot1dStp 2 }
++
++dot1dStpTimeSinceTopologyChange OBJECT-TYPE
++ SYNTAX TimeTicks
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The time (in hundredths of a second) since the
++ last time a topology change was detected by the
++ bridge entity."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.8.1.1.3"
++ ::= { dot1dStp 3 }
++
++dot1dStpTopChanges OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The total number of topology changes detected by
++ this bridge since the management entity was last
++ reset or initialized."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.8.1.1.3"
++ ::= { dot1dStp 4 }
++
++dot1dStpDesignatedRoot OBJECT-TYPE
++ SYNTAX BridgeId
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The bridge identifier of the root of the spanning
++ tree as determined by the Spanning Tree Protocol
++ as executed by this node. This value is used as
++
++ the Root Identifier parameter in all Configuration
++ Bridge PDUs originated by this node."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.1"
++ ::= { dot1dStp 5 }
++
++dot1dStpRootCost OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The cost of the path to the root as seen from
++ this bridge."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.2"
++ ::= { dot1dStp 6 }
++
++dot1dStpRootPort OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the port which offers the
++ lowest cost path from this bridge to the root
++ bridge."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.3"
++ ::= { dot1dStp 7 }
++
++dot1dStpMaxAge OBJECT-TYPE
++ SYNTAX Timeout
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The maximum age of Spanning Tree Protocol
++ information learned from the network on any port
++ before it is discarded, in units of hundredths of
++ a second. This is the actual value that this
++ bridge is currently using."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.4"
++ ::= { dot1dStp 8 }
++
++dot1dStpHelloTime OBJECT-TYPE
++ SYNTAX Timeout
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++
++ "The amount of time between the transmission of
++ Configuration bridge PDUs by this node on any port
++ when it is the root of the spanning tree or trying
++ to become so, in units of hundredths of a second.
++ This is the actual value that this bridge is
++ currently using."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.5"
++ ::= { dot1dStp 9 }
++
++dot1dStpHoldTime OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "This time value determines the interval length
++ during which no more than two Configuration bridge
++ PDUs shall be transmitted by this node, in units
++ of hundredths of a second."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.14"
++ ::= { dot1dStp 10 }
++
++dot1dStpForwardDelay OBJECT-TYPE
++ SYNTAX Timeout
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "This time value, measured in units of hundredths
++ of a second, controls how fast a port changes its
++ spanning state when moving towards the Forwarding
++ state. The value determines how long the port
++ stays in each of the Listening and Learning
++ states, which precede the Forwarding state. This
++ value is also used, when a topology change has
++ been detected and is underway, to age all dynamic
++ entries in the Forwarding Database. [Note that
++ this value is the one that this bridge is
++ currently using, in contrast to
++ dot1dStpBridgeForwardDelay which is the value that
++ this bridge and all others would start using
++ if/when this bridge were to become the root.]"
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.6"
++ ::= { dot1dStp 11 }
++
++dot1dStpBridgeMaxAge OBJECT-TYPE
++ SYNTAX Timeout (600..4000)
++
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The value that all bridges use for MaxAge when
++ this bridge is acting as the root. Note that
++ 802.1D-1990 specifies that the range for this
++ parameter is related to the value of
++ dot1dStpBridgeHelloTime. The granularity of this
++ timer is specified by 802.1D-1990 to be 1 second.
++ An agent may return a badValue error if a set is
++ attempted to a value which is not a whole number
++ of seconds."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.8"
++ ::= { dot1dStp 12 }
++
++dot1dStpBridgeHelloTime OBJECT-TYPE
++ SYNTAX Timeout (100..1000)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The value that all bridges use for HelloTime when
++ this bridge is acting as the root. The
++ granularity of this timer is specified by 802.1D-
++ 1990 to be 1 second. An agent may return a
++ badValue error if a set is attempted to a value
++ which is not a whole number of seconds."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.9"
++ ::= { dot1dStp 13 }
++
++dot1dStpBridgeForwardDelay OBJECT-TYPE
++ SYNTAX Timeout (400..3000)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The value that all bridges use for ForwardDelay
++ when this bridge is acting as the root. Note that
++ 802.1D-1990 specifies that the range for this
++ parameter is related to the value of
++ dot1dStpBridgeMaxAge. The granularity of this
++ timer is specified by 802.1D-1990 to be 1 second.
++ An agent may return a badValue error if a set is
++ attempted to a value which is not a whole number
++ of seconds."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.3.10"
++ ::= { dot1dStp 14 }
++
++-- The Spanning Tree Port Table
++
++dot1dStpPortTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dStpPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains port-specific information
++ for the Spanning Tree Protocol."
++ ::= { dot1dStp 15 }
++
++dot1dStpPortEntry OBJECT-TYPE
++ SYNTAX Dot1dStpPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A list of information maintained by every port
++ about the Spanning Tree Protocol state for that
++ port."
++ INDEX { dot1dStpPort }
++ ::= { dot1dStpPortTable 1 }
++
++Dot1dStpPortEntry ::=
++ SEQUENCE {
++ dot1dStpPort
++ INTEGER,
++ dot1dStpPortPriority
++ INTEGER,
++ dot1dStpPortState
++ INTEGER,
++ dot1dStpPortEnable
++ INTEGER,
++ dot1dStpPortPathCost
++ INTEGER,
++ dot1dStpPortDesignatedRoot
++ BridgeId,
++ dot1dStpPortDesignatedCost
++ INTEGER,
++ dot1dStpPortDesignatedBridge
++ BridgeId,
++ dot1dStpPortDesignatedPort
++ OCTET STRING,
++ dot1dStpPortForwardTransitions
++ Counter
++ }
++
++dot1dStpPort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the port for which this entry
++ contains Spanning Tree Protocol management
++ information."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.8.2.1.2"
++ ::= { dot1dStpPortEntry 1 }
++
++dot1dStpPortPriority OBJECT-TYPE
++ SYNTAX INTEGER (0..255)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The value of the priority field which is
++ contained in the first (in network byte order)
++ octet of the (2 octet long) Port ID. The other
++ octet of the Port ID is given by the value of
++ dot1dStpPort."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.1"
++ ::= { dot1dStpPortEntry 2 }
++
++dot1dStpPortState OBJECT-TYPE
++ SYNTAX INTEGER {
++ disabled(1),
++ blocking(2),
++ listening(3),
++ learning(4),
++ forwarding(5),
++ broken(6)
++ }
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port's current state as defined by
++ application of the Spanning Tree Protocol. This
++ state controls what action a port takes on
++ reception of a frame. If the bridge has detected
++ a port that is malfunctioning it will place that
++ port into the broken(6) state. For ports which
++ are disabled (see dot1dStpPortEnable), this object
++ will have a value of disabled(1)."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.2"
++ ::= { dot1dStpPortEntry 3 }
++
++dot1dStpPortEnable OBJECT-TYPE
++ SYNTAX INTEGER {
++ enabled(1),
++ disabled(2)
++ }
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The enabled/disabled status of the port."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.2"
++ ::= { dot1dStpPortEntry 4 }
++
++dot1dStpPortPathCost OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The contribution of this port to the path cost of
++ paths towards the spanning tree root which include
++ this port. 802.1D-1990 recommends that the
++ default value of this parameter be in inverse
++ proportion to the speed of the attached LAN."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.3"
++ ::= { dot1dStpPortEntry 5 }
++
++dot1dStpPortDesignatedRoot OBJECT-TYPE
++ SYNTAX BridgeId
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The unique Bridge Identifier of the Bridge
++ recorded as the Root in the Configuration BPDUs
++ transmitted by the Designated Bridge for the
++ segment to which the port is attached."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.4"
++ ::= { dot1dStpPortEntry 6 }
++
++dot1dStpPortDesignatedCost OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The path cost of the Designated Port of the
++ segment connected to this port. This value is
++ compared to the Root Path Cost field in received
++
++ bridge PDUs."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.5"
++ ::= { dot1dStpPortEntry 7 }
++
++dot1dStpPortDesignatedBridge OBJECT-TYPE
++ SYNTAX BridgeId
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The Bridge Identifier of the bridge which this
++ port considers to be the Designated Bridge for
++ this port's segment."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.6"
++ ::= { dot1dStpPortEntry 8 }
++
++dot1dStpPortDesignatedPort OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (2))
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The Port Identifier of the port on the Designated
++ Bridge for this port's segment."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 4.5.5.7"
++ ::= { dot1dStpPortEntry 9 }
++
++dot1dStpPortForwardTransitions OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of times this port has transitioned
++ from the Learning state to the Forwarding state."
++ ::= { dot1dStpPortEntry 10 }
++
++-- the dot1dTp group
++
++-- Implementation of the dot1dTp group is optional. It is
++-- implemented by those bridges that support the transparent
++-- bridging mode. A transparent or SRT bridge will implement
++-- this group.
++
++dot1dTpLearnedEntryDiscards OBJECT-TYPE
++ SYNTAX Counter
++
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The total number of Forwarding Database entries,
++ which have been or would have been learnt, but
++ have been discarded due to a lack of space to
++ store them in the Forwarding Database. If this
++ counter is increasing, it indicates that the
++ Forwarding Database is regularly becoming full (a
++ condition which has unpleasant performance effects
++ on the subnetwork). If this counter has a
++ significant value but is not presently increasing,
++ it indicates that the problem has been occurring
++ but is not persistent."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.7.1.1.3"
++ ::= { dot1dTp 1 }
++
++dot1dTpAgingTime OBJECT-TYPE
++ SYNTAX INTEGER (10..1000000)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The timeout period in seconds for aging out
++ dynamically learned forwarding information.
++ 802.1D-1990 recommends a default of 300 seconds."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.7.1.1.3"
++ ::= { dot1dTp 2 }
++
++-- The Forwarding Database for Transparent Bridges
++
++dot1dTpFdbTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dTpFdbEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains information about unicast
++ entries for which the bridge has forwarding and/or
++ filtering information. This information is used
++ by the transparent bridging function in
++ determining how to propagate a received frame."
++ ::= { dot1dTp 3 }
++
++dot1dTpFdbEntry OBJECT-TYPE
++ SYNTAX Dot1dTpFdbEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "Information about a specific unicast MAC address
++ for which the bridge has some forwarding and/or
++ filtering information."
++ INDEX { dot1dTpFdbAddress }
++ ::= { dot1dTpFdbTable 1 }
++
++Dot1dTpFdbEntry ::=
++ SEQUENCE {
++ dot1dTpFdbAddress
++ MacAddress,
++ dot1dTpFdbPort
++ INTEGER,
++ dot1dTpFdbStatus
++ INTEGER
++ }
++
++dot1dTpFdbAddress OBJECT-TYPE
++ SYNTAX MacAddress
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "A unicast MAC address for which the bridge has
++ forwarding and/or filtering information."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 3.9.1, 3.9.2"
++ ::= { dot1dTpFdbEntry 1 }
++
++dot1dTpFdbPort OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "Either the value '0', or the port number of the
++ port on which a frame having a source address
++ equal to the value of the corresponding instance
++ of dot1dTpFdbAddress has been seen. A value of
++ '0' indicates that the port number has not been
++ learned but that the bridge does have some
++ forwarding/filtering information about this
++ address (e.g. in the dot1dStaticTable).
++ Implementors are encouraged to assign the port
++ value to this object whenever it is learned even
++ for addresses for which the corresponding value of
++ dot1dTpFdbStatus is not learned(3)."
++ ::= { dot1dTpFdbEntry 2 }
++
++dot1dTpFdbStatus OBJECT-TYPE
++ SYNTAX INTEGER {
++ other(1),
++ invalid(2),
++ learned(3),
++ self(4),
++ mgmt(5)
++ }
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The status of this entry. The meanings of the
++ values are:
++ other(1) : none of the following. This would
++ include the case where some other
++ MIB object (not the corresponding
++ instance of dot1dTpFdbPort, nor an
++ entry in the dot1dStaticTable) is
++ being used to determine if and how
++ frames addressed to the value of
++ the corresponding instance of
++ dot1dTpFdbAddress are being
++ forwarded.
++ invalid(2) : this entry is not longer valid
++ (e.g., it was learned but has since
++ aged-out), but has not yet been
++ flushed from the table.
++ learned(3) : the value of the corresponding
++ instance of dot1dTpFdbPort was
++ learned, and is being used.
++ self(4) : the value of the corresponding
++ instance of dot1dTpFdbAddress
++ represents one of the bridge's
++ addresses. The corresponding
++ instance of dot1dTpFdbPort
++ indicates which of the bridge's
++ ports has this address.
++ mgmt(5) : the value of the corresponding
++ instance of dot1dTpFdbAddress is
++ also the value of an existing
++ instance of dot1dStaticAddress."
++ ::= { dot1dTpFdbEntry 3 }
++
++-- Port Table for Transparent Bridges
++
++dot1dTpPortTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dTpPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains information about every
++ port that is associated with this transparent
++ bridge."
++ ::= { dot1dTp 4 }
++
++dot1dTpPortEntry OBJECT-TYPE
++ SYNTAX Dot1dTpPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A list of information for each port of a
++ transparent bridge."
++ INDEX { dot1dTpPort }
++ ::= { dot1dTpPortTable 1 }
++
++Dot1dTpPortEntry ::=
++ SEQUENCE {
++ dot1dTpPort
++ INTEGER,
++ dot1dTpPortMaxInfo
++ INTEGER,
++ dot1dTpPortInFrames
++ Counter,
++ dot1dTpPortOutFrames
++ Counter,
++ dot1dTpPortInDiscards
++ Counter
++ }
++
++dot1dTpPort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the port for which this entry
++ contains Transparent bridging management
++ information."
++ ::= { dot1dTpPortEntry 1 }
++
++-- It would be nice if we could use ifMtu as the size of the
++-- largest INFO field, but we can't because ifMtu is defined
++-- to be the size that the (inter-)network layer can use which
++-- can differ from the MAC layer (especially if several layers
++-- of encapsulation are used).
++
++dot1dTpPortMaxInfo OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The maximum size of the INFO (non-MAC) field that
++ this port will receive or transmit."
++ ::= { dot1dTpPortEntry 2 }
++
++dot1dTpPortInFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of frames that have been received by
++ this port from its segment. Note that a frame
++ received on the interface corresponding to this
++ port is only counted by this object if and only if
++ it is for a protocol being processed by the local
++ bridging function, including bridge management
++ frames."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.6.1.1.3"
++ ::= { dot1dTpPortEntry 3 }
++
++dot1dTpPortOutFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of frames that have been transmitted
++ by this port to its segment. Note that a frame
++ transmitted on the interface corresponding to this
++ port is only counted by this object if and only if
++ it is for a protocol being processed by the local
++ bridging function, including bridge management
++ frames."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.6.1.1.3"
++ ::= { dot1dTpPortEntry 4 }
++
++dot1dTpPortInDiscards OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "Count of valid frames received which were
++ discarded (i.e., filtered) by the Forwarding
++ Process."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.6.1.1.3"
++ ::= { dot1dTpPortEntry 5 }
++-- The Static (Destination-Address Filtering) Database
++
++-- Implementation of this group is optional.
++
++dot1dStaticTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dStaticEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table containing filtering information
++ configured into the bridge by (local or network)
++ management specifying the set of ports to which
++ frames received from specific ports and containing
++ specific destination addresses are allowed to be
++ forwarded. The value of zero in this table as the
++ port number from which frames with a specific
++ destination address are received, is used to
++ specify all ports for which there is no specific
++ entry in this table for that particular
++ destination address. Entries are valid for
++ unicast and for group/broadcast addresses."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.7.2"
++ ::= { dot1dStatic 1 }
++
++dot1dStaticEntry OBJECT-TYPE
++ SYNTAX Dot1dStaticEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "Filtering information configured into the bridge
++ by (local or network) management specifying the
++ set of ports to which frames received from a
++ specific port and containing a specific
++ destination address are allowed to be forwarded."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 6.7.2"
++ INDEX { dot1dStaticAddress, dot1dStaticReceivePort }
++ ::= { dot1dStaticTable 1 }
++
++Dot1dStaticEntry ::=
++ SEQUENCE {
++ dot1dStaticAddress
++ MacAddress,
++ dot1dStaticReceivePort
++ INTEGER,
++ dot1dStaticAllowedToGoTo
++ OCTET STRING,
++ dot1dStaticStatus
++ INTEGER
++ }
++
++dot1dStaticAddress OBJECT-TYPE
++ SYNTAX MacAddress
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The destination MAC address in a frame to which
++ this entry's filtering information applies. This
++ object can take the value of a unicast address, a
++ group address or the broadcast address."
++ REFERENCE
++ "IEEE 802.1D-1990: Section 3.9.1, 3.9.2"
++ ::= { dot1dStaticEntry 1 }
++
++dot1dStaticReceivePort OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "Either the value '0', or the port number of the
++ port from which a frame must be received in order
++ for this entry's filtering information to apply.
++ A value of zero indicates that this entry applies
++ on all ports of the bridge for which there is no
++ other applicable entry."
++ ::= { dot1dStaticEntry 2 }
++
++dot1dStaticAllowedToGoTo OBJECT-TYPE
++ SYNTAX OCTET STRING
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The set of ports to which frames received from a
++ specific port and destined for a specific MAC
++
++ address, are allowed to be forwarded. Each octet
++ within the value of this object specifies a set of
++ eight ports, with the first octet specifying ports
++ 1 through 8, the second octet specifying ports 9
++ through 16, etc. Within each octet, the most
++ significant bit represents the lowest numbered
++ port, and the least significant bit represents the
++ highest numbered port. Thus, each port of the
++ bridge is represented by a single bit within the
++ value of this object. If that bit has a value of
++ '1' then that port is included in the set of
++ ports; the port is not included if its bit has a
++ value of '0'. (Note that the setting of the bit
++ corresponding to the port from which a frame is
++ received is irrelevant.) The default value of
++ this object is a string of ones of appropriate
++ length."
++ ::= { dot1dStaticEntry 3 }
++
++dot1dStaticStatus OBJECT-TYPE
++ SYNTAX INTEGER {
++ other(1),
++ invalid(2),
++ permanent(3),
++ deleteOnReset(4),
++ deleteOnTimeout(5)
++ }
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "This object indicates the status of this entry.
++ The default value is permanent(3).
++ other(1) - this entry is currently in use but
++ the conditions under which it will
++ remain so are different from each of the
++ following values.
++ invalid(2) - writing this value to the object
++ removes the corresponding entry.
++ permanent(3) - this entry is currently in use
++ and will remain so after the next reset
++ of the bridge.
++ deleteOnReset(4) - this entry is currently in
++ use and will remain so until the next
++ reset of the bridge.
++ deleteOnTimeout(5) - this entry is currently
++ in use and will remain so until it is
++ aged out."
++
++ ::= { dot1dStaticEntry 4 }
++
++-- Traps for use by Bridges
++
++-- Traps for the Spanning Tree Protocol
++
++newRoot TRAP-TYPE
++ ENTERPRISE dot1dBridge
++ DESCRIPTION
++ "The newRoot trap indicates that the sending agent
++ has become the new root of the Spanning Tree; the
++ trap is sent by a bridge soon after its election
++ as the new root, e.g., upon expiration of the
++ Topology Change Timer immediately subsequent to
++ its election. Implementation of this trap is
++ optional."
++ ::= 1
++
++topologyChange TRAP-TYPE
++ ENTERPRISE dot1dBridge
++ DESCRIPTION
++ "A topologyChange trap is sent by a bridge when
++ any of its configured ports transitions from the
++ Learning state to the Forwarding state, or from
++ the Forwarding state to the Blocking state. The
++ trap is not sent if a newRoot trap is sent for the
++ same transition. Implementation of this trap is
++ optional."
++ ::= 2
++
++END
+diff -ruN net-snmp-5.1.2-orig/mibs/GNOME-SMI.txt net-snmp-5.1.2-5/mibs/GNOME-SMI.txt
+--- net-snmp-5.1.2-orig/mibs/GNOME-SMI.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/GNOME-SMI.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,72 @@
++GNOME-SMI DEFINITIONS ::= BEGIN
++
++IMPORTS
++ MODULE-IDENTITY,
++ OBJECT-IDENTITY,
++ enterprises
++ FROM SNMPv2-SMI;
++
++gnome MODULE-IDENTITY
++ LAST-UPDATED "200312070000Z"
++ ORGANIZATION "GNOME project"
++ CONTACT-INFO
++ "GNU Network Object Model Environment project
++
++ see http://www.gnome.org for contact persons of a particular
++ area or subproject of GNOME.
++
++ Administrative contact for MIB module:
++
++ Jochen Friedrich
++ Buedingerstr. 30b
++ 63546 Hammersbach
++ Germany
++
++ email: jochen@scram.de"
++ DESCRIPTION
++ "The Structure of GNOME."
++
++ -- revision history
++
++ REVISION "9809010000Z" -- September 01, 1998
++ DESCRIPTION
++ "Initial version."
++
++ REVISION "200312070000Z" -- December 07, 2003
++ DESCRIPTION
++ "Added gnomeSysadmin subtree for GNOME project system administration.
++ Updated contact info."
++
++ ::= { enterprises 3317 } -- assigned by IANA
++
++gnomeProducts OBJECT-IDENTITY
++ STATUS current
++ DESCRIPTION
++ "gnomeProducts is the root OBJECT IDENTIFIER from
++ which sysObjectID values are assigned."
++ ::= { gnome 1 }
++
++gnomeMgmt OBJECT-IDENTITY
++ STATUS current
++ DESCRIPTION
++ "gnomeMgmt defines the subtree for production GNOME related
++ MIB registrations."
++ ::= { gnome 2 }
++
++gnomeTest OBJECT-IDENTITY
++ STATUS current
++ DESCRIPTION
++ "gnomeTest defines the subtree for testing GNOME related
++ MIB registrations."
++ ::= { gnome 3 }
++
++gnomeSysadmin OBJECT-IDENTITY
++ STATUS current
++ DESCRIPTION
++ "gnomeSysadmin defines the subtree for GNOME related Sysadmin
++ MIB registrations."
++ ::= { gnome 4 }
++
++-- more to come if necessary.
++
++END
+diff -ruN net-snmp-5.1.2-orig/mibs/Makefile.in net-snmp-5.1.2-5/mibs/Makefile.in
+--- net-snmp-5.1.2-orig/mibs/Makefile.in 2004-06-18 20:11:15.000000000 +0200
++++ net-snmp-5.1.2-5/mibs/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -43,11 +43,15 @@
+ UCDMIBS = UCD-SNMP-MIB.txt UCD-DEMO-MIB.txt UCD-IPFWACC-MIB.txt \
+ UCD-DLMOD-MIB.txt UCD-DISKIO-MIB.txt
+
++EXTRAMIBS = BGP4-MIB.txt BRIDGE-MIB.txt GNOME-SMI.txt OSPF-MIB.txt \
++ OSPF-TRAP-MIB.txt RIPv2-MIB.txt SOURCE-ROUTING-MIB.txt \
++ LM-SENSORS-MIB.txt
++
+ DEFAULTMIBS = @default_mibs_install@
+
+ MIBS = $(V1MIBS) $(V2MIBS) $(V3MIBS) $(RFCMIBS) \
+ $(AGENTMIBS) $(IANAMIBS) \
+- $(NETSNMPMIBS) $(UCDMIBS) $(DEFAULTMIBS)
++ $(NETSNMPMIBS) $(UCDMIBS) $(DEFAULTMIBS) $(EXTRAMIBS)
+
+ all: standardall
+
+diff -ruN net-snmp-5.1.2-orig/mibs/OSPF-MIB.txt net-snmp-5.1.2-5/mibs/OSPF-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/OSPF-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/OSPF-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,2723 @@
++OSPF-MIB DEFINITIONS ::= BEGIN
++
++ IMPORTS
++ MODULE-IDENTITY, OBJECT-TYPE, Counter32, Gauge32,
++ Integer32, IpAddress
++ FROM SNMPv2-SMI
++ TEXTUAL-CONVENTION, TruthValue, RowStatus
++ FROM SNMPv2-TC
++ MODULE-COMPLIANCE, OBJECT-GROUP FROM SNMPv2-CONF
++ mib-2 FROM RFC1213-MIB;
++
++-- This MIB module uses the extended OBJECT-TYPE macro as
++-- defined in [9].
++
++ospf MODULE-IDENTITY
++ LAST-UPDATED "9501201225Z" -- Fri Jan 20 12:25:50 PST 1995
++ ORGANIZATION "IETF OSPF Working Group"
++ CONTACT-INFO
++ " Fred Baker
++ Postal: Cisco Systems
++ 519 Lado Drive
++ Santa Barbara, California 93111
++ Tel: +1 805 681 0115
++ E-Mail: fred@cisco.com
++
++ Rob Coltun
++ Postal: RainbowBridge Communications
++ Tel: (301) 340-9416
++ E-Mail: rcoltun@rainbow-bridge.com"
++ DESCRIPTION
++ "The MIB module to describe the OSPF Version 2
++ Protocol"
++ ::= { mib-2 14 }
++
++-- The Area ID, in OSPF, has the same format as an IP Address,
++-- but has the function of defining a summarization point for
++-- Link State Advertisements
++
++AreaID ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "An OSPF Area Identifier."
++ SYNTAX IpAddress
++
++
++-- The Router ID, in OSPF, has the same format as an IP Address,
++-- but identifies the router independent of its IP Address.
++
++RouterID ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "A OSPF Router Identifier."
++ SYNTAX IpAddress
++
++
++-- The OSPF Metric is defined as an unsigned value in the range
++
++Metric ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The OSPF Internal Metric."
++ SYNTAX Integer32 (0..'FFFF'h)
++
++BigMetric ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The OSPF External Metric."
++ SYNTAX Integer32 (0..'FFFFFF'h)
++
++-- Status Values
++
++Status ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The status of an interface: 'enabled' indicates that
++ it is willing to communicate with other OSPF Routers,
++ while 'disabled' indicates that it is not."
++ SYNTAX INTEGER { enabled (1), disabled (2) }
++
++-- Time Durations measured in seconds
++
++PositiveInteger ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "A positive integer. Values in excess are precluded as
++ unnecessary and prone to interoperability issues."
++ SYNTAX Integer32 (0..'7FFFFFFF'h)
++
++HelloRange ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The range of intervals on which hello messages are
++ exchanged."
++ SYNTAX Integer32 (1..'FFFF'h)
++
++UpToMaxAge ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The values that one might find or configure for
++ variables bounded by the maximum age of an LSA."
++ SYNTAX Integer32 (0..3600)
++
++
++-- The range of ifIndex
++
++InterfaceIndex ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The range of ifIndex."
++ SYNTAX Integer32
++
++
++-- Potential Priorities for the Designated Router Election
++
++DesignatedRouterPriority ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "The values defined for the priority of a system for
++ becoming the designated router."
++ SYNTAX Integer32 (0..'FF'h)
++
++TOSType ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "Type of Service is defined as a mapping to the IP Type of
++ Service Flags as defined in the IP Forwarding Table MIB
++
++ +-----+-----+-----+-----+-----+-----+-----+-----+
++ | | | |
++ | PRECEDENCE | TYPE OF SERVICE | 0 |
++ | | | |
++ +-----+-----+-----+-----+-----+-----+-----+-----+
++
++ IP TOS IP TOS
++ Field Policy Field Policy
++
++ Contents Code Contents Code
++ 0 0 0 0 ==> 0 0 0 0 1 ==> 2
++ 0 0 1 0 ==> 4 0 0 1 1 ==> 6
++ 0 1 0 0 ==> 8 0 1 0 1 ==> 10
++ 0 1 1 0 ==> 12 0 1 1 1 ==> 14
++ 1 0 0 0 ==> 16 1 0 0 1 ==> 18
++ 1 0 1 0 ==> 20 1 0 1 1 ==> 22
++ 1 1 0 0 ==> 24 1 1 0 1 ==> 26
++ 1 1 1 0 ==> 28 1 1 1 1 ==> 30
++
++ The remaining values are left for future definition."
++ SYNTAX Integer32 (0..30)
++
++
++-- OSPF General Variables
++
++-- These parameters apply globally to the Router's
++-- OSPF Process.
++
++ospfGeneralGroup OBJECT IDENTIFIER ::= { ospf 1 }
++
++
++ ospfRouterId OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "A 32-bit integer uniquely identifying the
++ router in the Autonomous System.
++
++ By convention, to ensure uniqueness, this
++ should default to the value of one of the
++ router's IP interface addresses."
++ REFERENCE
++ "OSPF Version 2, C.1 Global parameters"
++ ::= { ospfGeneralGroup 1 }
++
++
++ ospfAdminStat OBJECT-TYPE
++ SYNTAX Status
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The administrative status of OSPF in the
++ router. The value 'enabled' denotes that the
++ OSPF Process is active on at least one inter-
++ face; 'disabled' disables it on all inter-
++ faces."
++ ::= { ospfGeneralGroup 2 }
++
++ ospfVersionNumber OBJECT-TYPE
++ SYNTAX INTEGER { version2 (2) }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The current version number of the OSPF proto-
++ col is 2."
++ REFERENCE
++ "OSPF Version 2, Title"
++ ::= { ospfGeneralGroup 3 }
++
++
++ ospfAreaBdrRtrStatus OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A flag to note whether this router is an area
++ border router."
++ REFERENCE
++ "OSPF Version 2, Section 3 Splitting the AS into
++ Areas"
++ ::= { ospfGeneralGroup 4 }
++
++
++ ospfASBdrRtrStatus OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "A flag to note whether this router is config-
++ ured as an Autonomous System border router."
++ REFERENCE
++ "OSPF Version 2, Section 3.3 Classification of
++ routers"
++ ::= { ospfGeneralGroup 5 }
++
++ ospfExternLsaCount OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of external (LS type 5) link-state
++ advertisements in the link-state database."
++ REFERENCE
++ "OSPF Version 2, Appendix A.4.5 AS external link
++ advertisements"
++ ::= { ospfGeneralGroup 6 }
++
++
++ ospfExternLsaCksumSum OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32-bit unsigned sum of the LS checksums of
++ the external link-state advertisements con-
++ tained in the link-state database. This sum
++ can be used to determine if there has been a
++ change in a router's link state database, and
++ to compare the link-state database of two
++ routers."
++ ::= { ospfGeneralGroup 7 }
++
++
++ ospfTOSSupport OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The router's support for type-of-service rout-
++ ing."
++ REFERENCE
++ "OSPF Version 2, Appendix F.1.2 Optional TOS
++ support"
++ ::= { ospfGeneralGroup 8 }
++
++ ospfOriginateNewLsas OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of new link-state advertisements
++ that have been originated. This number is in-
++ cremented each time the router originates a new
++ LSA."
++ ::= { ospfGeneralGroup 9 }
++
++
++ ospfRxNewLsas OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of link-state advertisements re-
++ ceived determined to be new instantiations.
++ This number does not include newer instantia-
++ tions of self-originated link-state advertise-
++ ments."
++ ::= { ospfGeneralGroup 10 }
++
++ ospfExtLsdbLimit OBJECT-TYPE
++ SYNTAX Integer32 (-1..'7FFFFFFF'h)
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The maximum number of non-default AS-
++ external-LSAs entries that can be stored in the
++ link-state database. If the value is -1, then
++ there is no limit.
++
++ When the number of non-default AS-external-LSAs
++ in a router's link-state database reaches
++ ospfExtLsdbLimit, the router enters Overflow-
++ State. The router never holds more than
++ ospfExtLsdbLimit non-default AS-external-LSAs
++ in its database. OspfExtLsdbLimit MUST be set
++ identically in all routers attached to the OSPF
++ backbone and/or any regular OSPF area. (i.e.,
++ OSPF stub areas and NSSAs are excluded)."
++ DEFVAL { -1 }
++ ::= { ospfGeneralGroup 11 }
++
++ ospfMulticastExtensions OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "A Bit Mask indicating whether the router is
++ forwarding IP multicast (Class D) datagrams
++ based on the algorithms defined in the Multi-
++ cast Extensions to OSPF.
++
++ Bit 0, if set, indicates that the router can
++ forward IP multicast datagrams in the router's
++ directly attached areas (called intra-area mul-
++ ticast routing).
++
++ Bit 1, if set, indicates that the router can
++ forward IP multicast datagrams between OSPF
++ areas (called inter-area multicast routing).
++
++ Bit 2, if set, indicates that the router can
++ forward IP multicast datagrams between Auto-
++ nomous Systems (called inter-AS multicast rout-
++ ing).
++
++ Only certain combinations of bit settings are
++ allowed, namely: 0 (no multicast forwarding is
++ enabled), 1 (intra-area multicasting only), 3
++ (intra-area and inter-area multicasting), 5
++ (intra-area and inter-AS multicasting) and 7
++ (multicasting everywhere). By default, no mul-
++ ticast forwarding is enabled."
++ DEFVAL { 0 }
++ ::= { ospfGeneralGroup 12 }
++
++ ospfExitOverflowInterval OBJECT-TYPE
++ SYNTAX PositiveInteger
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The number of seconds that, after entering
++ OverflowState, a router will attempt to leave
++ OverflowState. This allows the router to again
++ originate non-default AS-external-LSAs. When
++ set to 0, the router will not leave Overflow-
++ State until restarted."
++ DEFVAL { 0 }
++ ::= { ospfGeneralGroup 13 }
++
++
++ ospfDemandExtensions OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "The router's support for demand routing."
++ REFERENCE
++ "OSPF Version 2, Appendix on Demand Routing"
++ ::= { ospfGeneralGroup 14 }
++
++
++-- The OSPF Area Data Structure contains information
++-- regarding the various areas. The interfaces and
++-- virtual links are configured as part of these areas.
++-- Area 0.0.0.0, by definition, is the Backbone Area
++
++
++ ospfAreaTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfAreaEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information describing the configured parame-
++ ters and cumulative statistics of the router's
++ attached areas."
++ REFERENCE
++ "OSPF Version 2, Section 6 The Area Data Struc-
++ ture"
++ ::= { ospf 2 }
++
++
++ ospfAreaEntry OBJECT-TYPE
++ SYNTAX OspfAreaEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information describing the configured parame-
++ ters and cumulative statistics of one of the
++ router's attached areas."
++ INDEX { ospfAreaId }
++ ::= { ospfAreaTable 1 }
++
++OspfAreaEntry ::=
++ SEQUENCE {
++ ospfAreaId
++ AreaID,
++ ospfAuthType
++ Integer32,
++ ospfImportAsExtern
++ INTEGER,
++ ospfSpfRuns
++ Counter32,
++ ospfAreaBdrRtrCount
++ Gauge32,
++ ospfAsBdrRtrCount
++ Gauge32,
++ ospfAreaLsaCount
++ Gauge32,
++ ospfAreaLsaCksumSum
++ Integer32,
++ ospfAreaSummary
++ INTEGER,
++ ospfAreaStatus
++ RowStatus
++ }
++
++ ospfAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A 32-bit integer uniquely identifying an area.
++ Area ID 0.0.0.0 is used for the OSPF backbone."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaEntry 1 }
++
++
++ ospfAuthType OBJECT-TYPE
++ SYNTAX Integer32
++ -- none (0),
++ -- simplePassword (1)
++ -- md5 (2)
++ -- reserved for specification by IANA (> 2)
++ MAX-ACCESS read-create
++ STATUS obsolete
++ DESCRIPTION
++ "The authentication type specified for an area.
++ Additional authentication types may be assigned
++ locally on a per Area basis."
++ REFERENCE
++ "OSPF Version 2, Appendix E Authentication"
++ DEFVAL { 0 } -- no authentication, by default
++ ::= { ospfAreaEntry 2 }
++
++ ospfImportAsExtern OBJECT-TYPE
++ SYNTAX INTEGER {
++ importExternal (1),
++ importNoExternal (2),
++ importNssa (3)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The area's support for importing AS external
++ link- state advertisements."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ DEFVAL { importExternal }
++ ::= { ospfAreaEntry 3 }
++
++
++ ospfSpfRuns OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of times that the intra-area route
++ table has been calculated using this area's
++ link-state database. This is typically done
++ using Dijkstra's algorithm."
++ ::= { ospfAreaEntry 4 }
++
++
++ ospfAreaBdrRtrCount OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of area border routers reach-
++ able within this area. This is initially zero,
++ and is calculated in each SPF Pass."
++ ::= { ospfAreaEntry 5 }
++
++ ospfAsBdrRtrCount OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of Autonomous System border
++ routers reachable within this area. This is
++ initially zero, and is calculated in each SPF
++ Pass."
++ ::= { ospfAreaEntry 6 }
++
++
++ ospfAreaLsaCount OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The total number of link-state advertisements
++ in this area's link-state database, excluding
++ AS External LSA's."
++ ::= { ospfAreaEntry 7 }
++
++
++ ospfAreaLsaCksumSum OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32-bit unsigned sum of the link-state ad-
++ vertisements' LS checksums contained in this
++ area's link-state database. This sum excludes
++ external (LS type 5) link-state advertisements.
++ The sum can be used to determine if there has
++ been a change in a router's link state data-
++ base, and to compare the link-state database of
++ two routers."
++ DEFVAL { 0 }
++ ::= { ospfAreaEntry 8 }
++
++ ospfAreaSummary OBJECT-TYPE
++ SYNTAX INTEGER {
++ noAreaSummary (1),
++ sendAreaSummary (2)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The variable ospfAreaSummary controls the im-
++ port of summary LSAs into stub areas. It has
++ no effect on other areas.
++
++ If it is noAreaSummary, the router will neither
++ originate nor propagate summary LSAs into the
++ stub area. It will rely entirely on its de-
++ fault route.
++
++ If it is sendAreaSummary, the router will both
++ summarize and propagate summary LSAs."
++ DEFVAL { noAreaSummary }
++ ::= { ospfAreaEntry 9 }
++
++
++ ospfAreaStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfAreaEntry 10 }
++
++
++-- OSPF Area Default Metric Table
++
++-- The OSPF Area Default Metric Table describes the metrics
++-- that a default Area Border Router will advertise into a
++-- Stub area.
++
++
++ ospfStubAreaTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfStubAreaEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The set of metrics that will be advertised by
++ a default Area Border Router into a stub area."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2, Area Parameters"
++ ::= { ospf 3 }
++
++
++ ospfStubAreaEntry OBJECT-TYPE
++ SYNTAX OspfStubAreaEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The metric for a given Type of Service that
++ will be advertised by a default Area Border
++ Router into a stub area."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2, Area Parameters"
++ INDEX { ospfStubAreaId, ospfStubTOS }
++ ::= { ospfStubAreaTable 1 }
++
++OspfStubAreaEntry ::=
++ SEQUENCE {
++ ospfStubAreaId
++ AreaID,
++ ospfStubTOS
++ TOSType,
++ ospfStubMetric
++ BigMetric,
++ ospfStubStatus
++ RowStatus,
++ ospfStubMetricType
++ INTEGER
++ }
++
++ ospfStubAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32 bit identifier for the Stub Area. On
++ creation, this can be derived from the in-
++ stance."
++ ::= { ospfStubAreaEntry 1 }
++
++
++ ospfStubTOS OBJECT-TYPE
++ SYNTAX TOSType
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Type of Service associated with the
++ metric. On creation, this can be derived from
++ the instance."
++ ::= { ospfStubAreaEntry 2 }
++
++
++ ospfStubMetric OBJECT-TYPE
++ SYNTAX BigMetric
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The metric value applied at the indicated type
++ of service. By default, this equals the least
++ metric at the type of service among the inter-
++ faces to other areas."
++ ::= { ospfStubAreaEntry 3 }
++
++
++ ospfStubStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfStubAreaEntry 4 }
++
++ ospfStubMetricType OBJECT-TYPE
++ SYNTAX INTEGER {
++ ospfMetric (1), -- OSPF Metric
++ comparableCost (2), -- external type 1
++ nonComparable (3) -- external type 2
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the type of metric ad-
++ vertised as a default route."
++ DEFVAL { ospfMetric }
++ ::= { ospfStubAreaEntry 5 }
++
++-- OSPF Link State Database
++
++-- The Link State Database contains the Link State
++-- Advertisements from throughout the areas that the
++-- device is attached to.
++
++
++ ospfLsdbTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfLsdbEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The OSPF Process's Link State Database."
++ REFERENCE
++ "OSPF Version 2, Section 12 Link State Adver-
++ tisements"
++ ::= { ospf 4 }
++
++
++ ospfLsdbEntry OBJECT-TYPE
++ SYNTAX OspfLsdbEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A single Link State Advertisement."
++ INDEX { ospfLsdbAreaId, ospfLsdbType,
++ ospfLsdbLsid, ospfLsdbRouterId }
++ ::= { ospfLsdbTable 1 }
++
++OspfLsdbEntry ::=
++ SEQUENCE {
++ ospfLsdbAreaId
++ AreaID,
++ ospfLsdbType
++ INTEGER,
++ ospfLsdbLsid
++ IpAddress,
++ ospfLsdbRouterId
++ RouterID,
++ ospfLsdbSequence
++ Integer32,
++ ospfLsdbAge
++ Integer32,
++ ospfLsdbChecksum
++ Integer32,
++ ospfLsdbAdvertisement
++ OCTET STRING
++ }
++ ospfLsdbAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32 bit identifier of the Area from which
++ the LSA was received."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfLsdbEntry 1 }
++
++-- External Link State Advertisements are permitted
++-- for backward compatibility, but should be displayed in
++-- the ospfExtLsdbTable rather than here.
++
++ ospfLsdbType OBJECT-TYPE
++ SYNTAX INTEGER {
++ routerLink (1),
++ networkLink (2),
++ summaryLink (3),
++ asSummaryLink (4),
++ asExternalLink (5), -- but see ospfExtLsdbTable
++ multicastLink (6),
++ nssaExternalLink (7)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The type of the link state advertisement.
++ Each link state type has a separate advertise-
++ ment format."
++ REFERENCE
++ "OSPF Version 2, Appendix A.4.1 The Link State
++ Advertisement header"
++ ::= { ospfLsdbEntry 2 }
++
++ ospfLsdbLsid OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Link State ID is an LS Type Specific field
++ containing either a Router ID or an IP Address;
++ it identifies the piece of the routing domain
++ that is being described by the advertisement."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.4 Link State ID"
++ ::= { ospfLsdbEntry 3 }
++ ospfLsdbRouterId OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32 bit number that uniquely identifies the
++ originating router in the Autonomous System."
++ REFERENCE
++ "OSPF Version 2, Appendix C.1 Global parameters"
++ ::= { ospfLsdbEntry 4 }
++
++-- Note that the OSPF Sequence Number is a 32 bit signed
++-- integer. It starts with the value '80000001'h,
++-- or -'7FFFFFFF'h, and increments until '7FFFFFFF'h
++-- Thus, a typical sequence number will be very negative.
++
++ ospfLsdbSequence OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The sequence number field is a signed 32-bit
++ integer. It is used to detect old and dupli-
++ cate link state advertisements. The space of
++ sequence numbers is linearly ordered. The
++ larger the sequence number the more recent the
++ advertisement."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.6 LS sequence
++ number"
++ ::= { ospfLsdbEntry 5 }
++
++
++ ospfLsdbAge OBJECT-TYPE
++ SYNTAX Integer32 -- Should be 0..MaxAge
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This field is the age of the link state adver-
++ tisement in seconds."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.1 LS age"
++ ::= { ospfLsdbEntry 6 }
++
++ ospfLsdbChecksum OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This field is the checksum of the complete
++ contents of the advertisement, excepting the
++ age field. The age field is excepted so that
++ an advertisement's age can be incremented
++ without updating the checksum. The checksum
++ used is the same that is used for ISO connec-
++ tionless datagrams; it is commonly referred to
++ as the Fletcher checksum."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.7 LS checksum"
++ ::= { ospfLsdbEntry 7 }
++
++
++ ospfLsdbAdvertisement OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (1..65535))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The entire Link State Advertisement, including
++ its header."
++ REFERENCE
++ "OSPF Version 2, Section 12 Link State Adver-
++ tisements"
++ ::= { ospfLsdbEntry 8 }
++
++
++-- Address Range Table
++
++-- The Address Range Table acts as an adjunct to the Area
++-- Table; It describes those Address Range Summaries that
++-- are configured to be propagated from an Area to reduce
++-- the amount of information about it which is known beyond
++-- its borders.
++
++ ospfAreaRangeTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfAreaRangeEntry
++ MAX-ACCESS not-accessible
++ STATUS obsolete
++ DESCRIPTION
++ "A range if IP addresses specified by an IP
++ address/IP network mask pair. For example,
++ class B address range of X.X.X.X with a network
++ mask of 255.255.0.0 includes all IP addresses
++ from X.X.0.0 to X.X.255.255"
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospf 5 }
++ ospfAreaRangeEntry OBJECT-TYPE
++ SYNTAX OspfAreaRangeEntry
++ MAX-ACCESS not-accessible
++ STATUS obsolete
++ DESCRIPTION
++ "A range if IP addresses specified by an IP
++ address/IP network mask pair. For example,
++ class B address range of X.X.X.X with a network
++ mask of 255.255.0.0 includes all IP addresses
++ from X.X.0.0 to X.X.255.255"
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ INDEX { ospfAreaRangeAreaId, ospfAreaRangeNet }
++ ::= { ospfAreaRangeTable 1 }
++
++OspfAreaRangeEntry ::=
++ SEQUENCE {
++ ospfAreaRangeAreaId
++ AreaID,
++ ospfAreaRangeNet
++ IpAddress,
++ ospfAreaRangeMask
++ IpAddress,
++ ospfAreaRangeStatus
++ RowStatus,
++ ospfAreaRangeEffect
++ INTEGER
++ }
++
++ ospfAreaRangeAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The Area the Address Range is to be found
++ within."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaRangeEntry 1 }
++
++
++ ospfAreaRangeNet OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS obsolete
++ DESCRIPTION
++ "The IP Address of the Net or Subnet indicated
++ by the range."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaRangeEntry 2 }
++
++
++ ospfAreaRangeMask OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-create
++ STATUS obsolete
++ DESCRIPTION
++ "The Subnet Mask that pertains to the Net or
++ Subnet."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaRangeEntry 3 }
++
++ ospfAreaRangeStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS obsolete
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfAreaRangeEntry 4 }
++
++
++ ospfAreaRangeEffect OBJECT-TYPE
++ SYNTAX INTEGER {
++ advertiseMatching (1),
++ doNotAdvertiseMatching (2)
++ }
++ MAX-ACCESS read-create
++ STATUS obsolete
++ DESCRIPTION
++ "Subnets subsumed by ranges either trigger the
++ advertisement of the indicated summary (adver-
++ tiseMatching), or result in the subnet's not
++ being advertised at all outside the area."
++ DEFVAL { advertiseMatching }
++ ::= { ospfAreaRangeEntry 5 }
++
++
++
++-- OSPF Host Table
++
++-- The Host/Metric Table indicates what hosts are directly
++-- attached to the Router, and what metrics and types of
++-- service should be advertised for them.
++
++ ospfHostTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfHostEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The list of Hosts, and their metrics, that the
++ router will advertise as host routes."
++ REFERENCE
++ "OSPF Version 2, Appendix C.6 Host route param-
++ eters"
++ ::= { ospf 6 }
++
++
++ ospfHostEntry OBJECT-TYPE
++ SYNTAX OspfHostEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A metric to be advertised, for a given type of
++ service, when a given host is reachable."
++ INDEX { ospfHostIpAddress, ospfHostTOS }
++ ::= { ospfHostTable 1 }
++
++OspfHostEntry ::=
++ SEQUENCE {
++ ospfHostIpAddress
++ IpAddress,
++ ospfHostTOS
++ TOSType,
++ ospfHostMetric
++ Metric,
++ ospfHostStatus
++ RowStatus,
++ ospfHostAreaID
++ AreaID
++ }
++
++ ospfHostIpAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of the Host."
++ REFERENCE
++ "OSPF Version 2, Appendix C.6 Host route parame-
++ ters"
++ ::= { ospfHostEntry 1 }
++
++
++ ospfHostTOS OBJECT-TYPE
++ SYNTAX TOSType
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Type of Service of the route being config-
++ ured."
++ REFERENCE
++ "OSPF Version 2, Appendix C.6 Host route parame-
++ ters"
++ ::= { ospfHostEntry 2 }
++
++
++ ospfHostMetric OBJECT-TYPE
++ SYNTAX Metric
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The Metric to be advertised."
++ REFERENCE
++ "OSPF Version 2, Appendix C.6 Host route parame-
++ ters"
++ ::= { ospfHostEntry 3 }
++
++ ospfHostStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfHostEntry 4 }
++
++
++ ospfHostAreaID OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Area the Host Entry is to be found within.
++ By default, the area that a subsuming OSPF in-
++ terface is in, or 0.0.0.0"
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfHostEntry 5 }
++
++
++-- OSPF Interface Table
++
++-- The OSPF Interface Table augments the ipAddrTable
++-- with OSPF specific information.
++
++ ospfIfTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfIfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The OSPF Interface Table describes the inter-
++ faces from the viewpoint of OSPF."
++ REFERENCE
++ "OSPF Version 2, Appendix C.3 Router interface
++ parameters"
++ ::= { ospf 7 }
++
++
++ ospfIfEntry OBJECT-TYPE
++ SYNTAX OspfIfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The OSPF Interface Entry describes one inter-
++ face from the viewpoint of OSPF."
++ INDEX { ospfIfIpAddress, ospfAddressLessIf }
++ ::= { ospfIfTable 1 }
++
++OspfIfEntry ::=
++ SEQUENCE {
++ ospfIfIpAddress
++ IpAddress,
++ ospfAddressLessIf
++ Integer32,
++ ospfIfAreaId
++ AreaID,
++ ospfIfType
++ INTEGER,
++ ospfIfAdminStat
++ Status,
++ ospfIfRtrPriority
++ DesignatedRouterPriority,
++ ospfIfTransitDelay
++ UpToMaxAge,
++ ospfIfRetransInterval
++ UpToMaxAge,
++ ospfIfHelloInterval
++ HelloRange,
++ ospfIfRtrDeadInterval
++ PositiveInteger,
++ ospfIfPollInterval
++ PositiveInteger,
++ ospfIfState
++ INTEGER,
++ ospfIfDesignatedRouter
++ IpAddress,
++ ospfIfBackupDesignatedRouter
++ IpAddress,
++ ospfIfEvents
++ Counter32,
++ ospfIfAuthType
++ INTEGER,
++ ospfIfAuthKey
++ OCTET STRING,
++ ospfIfStatus
++ RowStatus,
++ ospfIfMulticastForwarding
++ INTEGER,
++ ospfIfDemand
++ TruthValue
++ }
++
++ ospfIfIpAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address of this OSPF interface."
++ ::= { ospfIfEntry 1 }
++
++ ospfAddressLessIf OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "For the purpose of easing the instancing of
++ addressed and addressless interfaces; This
++ variable takes the value 0 on interfaces with
++ IP Addresses, and the corresponding value of
++ ifIndex for interfaces having no IP Address."
++ ::= { ospfIfEntry 2 }
++ ospfIfAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "A 32-bit integer uniquely identifying the area
++ to which the interface connects. Area ID
++ 0.0.0.0 is used for the OSPF backbone."
++ DEFVAL { '00000000'H } -- 0.0.0.0
++ ::= { ospfIfEntry 3 }
++
++ ospfIfType OBJECT-TYPE
++ SYNTAX INTEGER {
++ broadcast (1),
++ nbma (2),
++ pointToPoint (3),
++ pointToMultipoint (5)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The OSPF interface type.
++
++ By way of a default, this field may be intuited
++ from the corresponding value of ifType. Broad-
++ cast LANs, such as Ethernet and IEEE 802.5,
++ take the value 'broadcast', X.25 and similar
++ technologies take the value 'nbma', and links
++ that are definitively point to point take the
++ value 'pointToPoint'."
++ ::= { ospfIfEntry 4 }
++
++
++ ospfIfAdminStat OBJECT-TYPE
++ SYNTAX Status
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The OSPF interface's administrative status.
++ The value formed on the interface, and the in-
++ terface will be advertised as an internal route
++ to some area. The value 'disabled' denotes
++ that the interface is external to OSPF."
++ DEFVAL { enabled }
++ ::= { ospfIfEntry 5 }
++
++ ospfIfRtrPriority OBJECT-TYPE
++ SYNTAX DesignatedRouterPriority
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The priority of this interface. Used in
++ multi-access networks, this field is used in
++ the designated router election algorithm. The
++ value 0 signifies that the router is not eligi-
++ ble to become the designated router on this
++ particular network. In the event of a tie in
++ this value, routers will use their Router ID as
++ a tie breaker."
++ DEFVAL { 1 }
++ ::= { ospfIfEntry 6 }
++
++
++ ospfIfTransitDelay OBJECT-TYPE
++ SYNTAX UpToMaxAge
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The estimated number of seconds it takes to
++ transmit a link state update packet over this
++ interface."
++ DEFVAL { 1 }
++ ::= { ospfIfEntry 7 }
++
++
++ ospfIfRetransInterval OBJECT-TYPE
++ SYNTAX UpToMaxAge
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The number of seconds between link-state ad-
++ vertisement retransmissions, for adjacencies
++ belonging to this interface. This value is
++ also used when retransmitting database descrip-
++ tion and link-state request packets."
++ DEFVAL { 5 }
++ ::= { ospfIfEntry 8 }
++
++
++ ospfIfHelloInterval OBJECT-TYPE
++ SYNTAX HelloRange
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The length of time, in seconds, between the
++ Hello packets that the router sends on the in-
++ terface. This value must be the same for all
++ routers attached to a common network."
++ DEFVAL { 10 }
++ ::= { ospfIfEntry 9 }
++
++
++ ospfIfRtrDeadInterval OBJECT-TYPE
++ SYNTAX PositiveInteger
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The number of seconds that a router's Hello
++ packets have not been seen before it's neigh-
++ bors declare the router down. This should be
++ some multiple of the Hello interval. This
++ value must be the same for all routers attached
++ to a common network."
++ DEFVAL { 40 }
++ ::= { ospfIfEntry 10 }
++
++
++ ospfIfPollInterval OBJECT-TYPE
++ SYNTAX PositiveInteger
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The larger time interval, in seconds, between
++ the Hello packets sent to an inactive non-
++ broadcast multi- access neighbor."
++ DEFVAL { 120 }
++ ::= { ospfIfEntry 11 }
++
++
++ ospfIfState OBJECT-TYPE
++ SYNTAX INTEGER {
++ down (1),
++ loopback (2),
++ waiting (3),
++ pointToPoint (4),
++ designatedRouter (5),
++ backupDesignatedRouter (6),
++ otherDesignatedRouter (7)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The OSPF Interface State."
++ DEFVAL { down }
++ ::= { ospfIfEntry 12 }
++
++
++ ospfIfDesignatedRouter OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of the Designated Router."
++ DEFVAL { '00000000'H } -- 0.0.0.0
++ ::= { ospfIfEntry 13 }
++
++
++ ospfIfBackupDesignatedRouter OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of the Backup Designated
++ Router."
++ DEFVAL { '00000000'H } -- 0.0.0.0
++ ::= { ospfIfEntry 14 }
++
++ ospfIfEvents OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of times this OSPF interface has
++ changed its state, or an error has occurred."
++ ::= { ospfIfEntry 15 }
++
++
++ ospfIfAuthKey OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE (0..256))
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The Authentication Key. If the Area's Author-
++ ization Type is simplePassword, and the key
++ length is shorter than 8 octets, the agent will
++ left adjust and zero fill to 8 octets.
++
++ Note that unauthenticated interfaces need no
++ authentication key, and simple password authen-
++ tication cannot use a key of more than 8 oc-
++ tets. Larger keys are useful only with authen-
++ tication mechanisms not specified in this docu-
++ ment.
++
++ When read, ospfIfAuthKey always returns an Oc-
++ tet String of length zero."
++ REFERENCE
++ "OSPF Version 2, Section 9 The Interface Data
++ Structure"
++ DEFVAL { '0000000000000000'H } -- 0.0.0.0.0.0.0.0
++ ::= { ospfIfEntry 16 }
++
++ ospfIfStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfIfEntry 17 }
++
++
++ ospfIfMulticastForwarding OBJECT-TYPE
++ SYNTAX INTEGER {
++ blocked (1), -- no multicast forwarding
++ multicast (2), -- using multicast address
++ unicast (3) -- to each OSPF neighbor
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The way multicasts should forwarded on this
++ interface; not forwarded, forwarded as data
++ link multicasts, or forwarded as data link uni-
++ casts. Data link multicasting is not meaning-
++ ful on point to point and NBMA interfaces, and
++ setting ospfMulticastForwarding to 0 effective-
++ ly disables all multicast forwarding."
++ DEFVAL { blocked }
++ ::= { ospfIfEntry 18 }
++
++
++ ospfIfDemand OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "Indicates whether Demand OSPF procedures (hel-
++ lo supression to FULL neighbors and setting the
++ DoNotAge flag on proogated LSAs) should be per-
++ formed on this interface."
++ DEFVAL { false }
++ ::= { ospfIfEntry 19 }
++
++
++ ospfIfAuthType OBJECT-TYPE
++ SYNTAX INTEGER (0..255)
++ -- none (0),
++ -- simplePassword (1)
++ -- md5 (2)
++ -- reserved for specification by IANA (> 2)
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The authentication type specified for an in-
++ terface. Additional authentication types may
++ be assigned locally."
++ REFERENCE
++ "OSPF Version 2, Appendix E Authentication"
++ DEFVAL { 0 } -- no authentication, by default
++ ::= { ospfIfEntry 20 }
++
++
++-- OSPF Interface Metric Table
++
++-- The Metric Table describes the metrics to be advertised
++-- for a specified interface at the various types of service.
++-- As such, this table is an adjunct of the OSPF Interface
++-- Table.
++
++-- Types of service, as defined by RFC 791, have the ability
++-- to request low delay, high bandwidth, or reliable linkage.
++
++-- For the purposes of this specification, the measure of
++-- bandwidth
++
++-- Metric = 10^8 / ifSpeed
++
++-- is the default value. For multiple link interfaces, note
++-- that ifSpeed is the sum of the individual link speeds.
++-- This yields a number having the following typical values:
++
++-- Network Type/bit rate Metric
++
++-- >= 100 MBPS 1
++-- Ethernet/802.3 10
++-- E1 48
++-- T1 (ESF) 65
++-- 64 KBPS 1562
++-- 56 KBPS 1785
++-- 19.2 KBPS 5208
++-- 9.6 KBPS 10416
++
++-- Routes that are not specified use the default (TOS 0) metric
++
++ ospfIfMetricTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfIfMetricEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The TOS metrics for a non-virtual interface
++ identified by the interface index."
++ REFERENCE
++ "OSPF Version 2, Appendix C.3 Router interface
++ parameters"
++ ::= { ospf 8 }
++
++ ospfIfMetricEntry OBJECT-TYPE
++ SYNTAX OspfIfMetricEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A particular TOS metric for a non-virtual in-
++ terface identified by the interface index."
++ REFERENCE
++ "OSPF Version 2, Appendix C.3 Router interface
++ parameters"
++ INDEX { ospfIfMetricIpAddress,
++ ospfIfMetricAddressLessIf,
++ ospfIfMetricTOS }
++ ::= { ospfIfMetricTable 1 }
++
++OspfIfMetricEntry ::=
++ SEQUENCE {
++ ospfIfMetricIpAddress
++ IpAddress,
++ ospfIfMetricAddressLessIf
++ Integer32,
++ ospfIfMetricTOS
++ TOSType,
++ ospfIfMetricValue
++ Metric,
++ ospfIfMetricStatus
++ RowStatus
++ }
++
++ ospfIfMetricIpAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address of this OSPF interface. On row
++ creation, this can be derived from the in-
++ stance."
++ ::= { ospfIfMetricEntry 1 }
++
++ ospfIfMetricAddressLessIf OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "For the purpose of easing the instancing of
++ addressed and addressless interfaces; This
++ variable takes the value 0 on interfaces with
++ IP Addresses, and the value of ifIndex for in-
++ terfaces having no IP Address. On row crea-
++ tion, this can be derived from the instance."
++ ::= { ospfIfMetricEntry 2 }
++
++
++ ospfIfMetricTOS OBJECT-TYPE
++ SYNTAX TOSType
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The type of service metric being referenced.
++ On row creation, this can be derived from the
++ instance."
++ ::= { ospfIfMetricEntry 3 }
++
++
++ ospfIfMetricValue OBJECT-TYPE
++ SYNTAX Metric
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The metric of using this type of service on
++ this interface. The default value of the TOS 0
++ Metric is 10^8 / ifSpeed."
++ ::= { ospfIfMetricEntry 4 }
++
++ ospfIfMetricStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfIfMetricEntry 5 }
++
++
++-- OSPF Virtual Interface Table
++
++-- The Virtual Interface Table describes the virtual
++-- links that the OSPF Process is configured to
++-- carry on.
++
++ ospfVirtIfTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfVirtIfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information about this router's virtual inter-
++ faces."
++ REFERENCE
++ "OSPF Version 2, Appendix C.4 Virtual link
++ parameters"
++ ::= { ospf 9 }
++
++
++ ospfVirtIfEntry OBJECT-TYPE
++ SYNTAX OspfVirtIfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information about a single Virtual Interface."
++ INDEX { ospfVirtIfAreaId, ospfVirtIfNeighbor }
++ ::= { ospfVirtIfTable 1 }
++
++OspfVirtIfEntry ::=
++ SEQUENCE {
++ ospfVirtIfAreaId
++ AreaID,
++ ospfVirtIfNeighbor
++ RouterID,
++ ospfVirtIfTransitDelay
++ UpToMaxAge,
++ ospfVirtIfRetransInterval
++ UpToMaxAge,
++ ospfVirtIfHelloInterval
++ HelloRange,
++ ospfVirtIfRtrDeadInterval
++ PositiveInteger,
++ ospfVirtIfState
++ INTEGER,
++ ospfVirtIfEvents
++ Counter32,
++ ospfVirtIfAuthType
++ INTEGER,
++ ospfVirtIfAuthKey
++ OCTET STRING,
++ ospfVirtIfStatus
++ RowStatus
++ }
++
++ ospfVirtIfAreaId OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Transit Area that the Virtual Link
++ traverses. By definition, this is not 0.0.0.0"
++ ::= { ospfVirtIfEntry 1 }
++
++
++ ospfVirtIfNeighbor OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Router ID of the Virtual Neighbor."
++ ::= { ospfVirtIfEntry 2 }
++
++
++ ospfVirtIfTransitDelay OBJECT-TYPE
++ SYNTAX UpToMaxAge
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The estimated number of seconds it takes to
++ transmit a link- state update packet over this
++ interface."
++ DEFVAL { 1 }
++ ::= { ospfVirtIfEntry 3 }
++
++
++ ospfVirtIfRetransInterval OBJECT-TYPE
++ SYNTAX UpToMaxAge
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The number of seconds between link-state ad-
++ vertisement retransmissions, for adjacencies
++ belonging to this interface. This value is
++ also used when retransmitting database descrip-
++ tion and link-state request packets. This
++ value should be well over the expected round-
++ trip time."
++ DEFVAL { 5 }
++ ::= { ospfVirtIfEntry 4 }
++
++
++ ospfVirtIfHelloInterval OBJECT-TYPE
++ SYNTAX HelloRange
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The length of time, in seconds, between the
++ Hello packets that the router sends on the in-
++ terface. This value must be the same for the
++ virtual neighbor."
++ DEFVAL { 10 }
++ ::= { ospfVirtIfEntry 5 }
++
++
++ ospfVirtIfRtrDeadInterval OBJECT-TYPE
++ SYNTAX PositiveInteger
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The number of seconds that a router's Hello
++ packets have not been seen before it's neigh-
++ bors declare the router down. This should be
++ some multiple of the Hello interval. This
++ value must be the same for the virtual neigh-
++ bor."
++ DEFVAL { 60 }
++ ::= { ospfVirtIfEntry 6 }
++
++
++ ospfVirtIfState OBJECT-TYPE
++ SYNTAX INTEGER {
++ down (1), -- these use the same encoding
++ pointToPoint (4) -- as the ospfIfTable
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "OSPF virtual interface states."
++ DEFVAL { down }
++ ::= { ospfVirtIfEntry 7 }
++
++
++ ospfVirtIfEvents OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of state changes or error events on
++ this Virtual Link"
++ ::= { ospfVirtIfEntry 8 }
++
++
++ ospfVirtIfAuthKey OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE(0..256))
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "If Authentication Type is simplePassword, the
++ device will left adjust and zero fill to 8 oc-
++ tets.
++
++ Note that unauthenticated interfaces need no
++ authentication key, and simple password authen-
++ tication cannot use a key of more than 8 oc-
++ tets. Larger keys are useful only with authen-
++ tication mechanisms not specified in this docu-
++ ment.
++
++ When read, ospfVifAuthKey always returns a
++ string of length zero."
++ REFERENCE
++ "OSPF Version 2, Section 9 The Interface Data
++ Structure"
++ DEFVAL { '0000000000000000'H } -- 0.0.0.0.0.0.0.0
++ ::= { ospfVirtIfEntry 9 }
++
++
++ ospfVirtIfStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfVirtIfEntry 10 }
++
++
++ ospfVirtIfAuthType OBJECT-TYPE
++ SYNTAX INTEGER (0..255)
++ -- none (0),
++ -- simplePassword (1)
++ -- md5 (2)
++ -- reserved for specification by IANA (> 2)
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The authentication type specified for a virtu-
++ al interface. Additional authentication types
++ may be assigned locally."
++ REFERENCE
++ "OSPF Version 2, Appendix E Authentication"
++ DEFVAL { 0 } -- no authentication, by default
++ ::= { ospfVirtIfEntry 11 }
++
++
++-- OSPF Neighbor Table
++
++-- The OSPF Neighbor Table describes all neighbors in
++-- the locality of the subject router.
++
++ ospfNbrTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfNbrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A table of non-virtual neighbor information."
++ REFERENCE
++ "OSPF Version 2, Section 10 The Neighbor Data
++ Structure"
++ ::= { ospf 10 }
++
++
++ ospfNbrEntry OBJECT-TYPE
++ SYNTAX OspfNbrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The information regarding a single neighbor."
++ REFERENCE
++ "OSPF Version 2, Section 10 The Neighbor Data
++ Structure"
++ INDEX { ospfNbrIpAddr, ospfNbrAddressLessIndex }
++ ::= { ospfNbrTable 1 }
++
++OspfNbrEntry ::=
++ SEQUENCE {
++ ospfNbrIpAddr
++ IpAddress,
++ ospfNbrAddressLessIndex
++ InterfaceIndex,
++ ospfNbrRtrId
++ RouterID,
++ ospfNbrOptions
++ Integer32,
++ ospfNbrPriority
++ DesignatedRouterPriority,
++ ospfNbrState
++ INTEGER,
++ ospfNbrEvents
++ Counter32,
++ ospfNbrLsRetransQLen
++ Gauge32,
++ ospfNbmaNbrStatus
++ RowStatus,
++ ospfNbmaNbrPermanence
++ INTEGER,
++ ospfNbrHelloSuppressed
++ TruthValue
++ }
++
++ ospfNbrIpAddr OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address this neighbor is using in its
++ IP Source Address. Note that, on addressless
++ links, this will not be 0.0.0.0, but the ad-
++ dress of another of the neighbor's interfaces."
++ ::= { ospfNbrEntry 1 }
++
++
++ ospfNbrAddressLessIndex OBJECT-TYPE
++ SYNTAX InterfaceIndex
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "On an interface having an IP Address, zero.
++ On addressless interfaces, the corresponding
++ value of ifIndex in the Internet Standard MIB.
++ On row creation, this can be derived from the
++ instance."
++ ::= { ospfNbrEntry 2 }
++
++
++ ospfNbrRtrId OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A 32-bit integer (represented as a type IpAd-
++ dress) uniquely identifying the neighboring
++ router in the Autonomous System."
++ DEFVAL { '00000000'H } -- 0.0.0.0
++ ::= { ospfNbrEntry 3 }
++
++
++ ospfNbrOptions OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A Bit Mask corresponding to the neighbor's op-
++ tions field.
++
++ Bit 0, if set, indicates that the system will
++ operate on Type of Service metrics other than
++ TOS 0. If zero, the neighbor will ignore all
++ metrics except the TOS 0 metric.
++
++ Bit 1, if set, indicates that the associated
++ area accepts and operates on external informa-
++ tion; if zero, it is a stub area.
++
++ Bit 2, if set, indicates that the system is ca-
++ pable of routing IP Multicast datagrams; i.e.,
++ that it implements the Multicast Extensions to
++ OSPF.
++
++ Bit 3, if set, indicates that the associated
++ area is an NSSA. These areas are capable of
++ carrying type 7 external advertisements, which
++ are translated into type 5 external advertise-
++ ments at NSSA borders."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.2 Options"
++ DEFVAL { 0 }
++ ::= { ospfNbrEntry 4 }
++
++
++ ospfNbrPriority OBJECT-TYPE
++ SYNTAX DesignatedRouterPriority
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The priority of this neighbor in the designat-
++ ed router election algorithm. The value 0 sig-
++ nifies that the neighbor is not eligible to be-
++ come the designated router on this particular
++ network."
++ DEFVAL { 1 }
++ ::= { ospfNbrEntry 5 }
++
++
++ ospfNbrState OBJECT-TYPE
++ SYNTAX INTEGER {
++ down (1),
++ attempt (2),
++ init (3),
++ twoWay (4),
++ exchangeStart (5),
++ exchange (6),
++ loading (7),
++ full (8)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The State of the relationship with this Neigh-
++ bor."
++ REFERENCE
++ "OSPF Version 2, Section 10.1 Neighbor States"
++ DEFVAL { down }
++ ::= { ospfNbrEntry 6 }
++
++
++ ospfNbrEvents OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of times this neighbor relationship
++ has changed state, or an error has occurred."
++ ::= { ospfNbrEntry 7 }
++
++
++ ospfNbrLsRetransQLen OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The current length of the retransmission
++ queue."
++ ::= { ospfNbrEntry 8 }
++
++
++ ospfNbmaNbrStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfNbrEntry 9 }
++
++
++ ospfNbmaNbrPermanence OBJECT-TYPE
++ SYNTAX INTEGER {
++ dynamic (1), -- learned through protocol
++ permanent (2) -- configured address
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. 'dynamic' and 'permanent' refer to how
++ the neighbor became known."
++ DEFVAL { permanent }
++ ::= { ospfNbrEntry 10 }
++
++
++ ospfNbrHelloSuppressed OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Indicates whether Hellos are being suppressed
++ to the neighbor"
++ ::= { ospfNbrEntry 11 }
++
++
++-- OSPF Virtual Neighbor Table
++
++-- This table describes all virtual neighbors.
++-- Since Virtual Links are configured in the
++-- virtual interface table, this table is read-only.
++
++ ospfVirtNbrTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfVirtNbrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A table of virtual neighbor information."
++ REFERENCE
++ "OSPF Version 2, Section 15 Virtual Links"
++ ::= { ospf 11 }
++
++
++ ospfVirtNbrEntry OBJECT-TYPE
++ SYNTAX OspfVirtNbrEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Virtual neighbor information."
++ INDEX { ospfVirtNbrArea, ospfVirtNbrRtrId }
++ ::= { ospfVirtNbrTable 1 }
++
++OspfVirtNbrEntry ::=
++ SEQUENCE {
++ ospfVirtNbrArea
++ AreaID,
++ ospfVirtNbrRtrId
++ RouterID,
++ ospfVirtNbrIpAddr
++ IpAddress,
++ ospfVirtNbrOptions
++ Integer32,
++ ospfVirtNbrState
++ INTEGER,
++ ospfVirtNbrEvents
++ Counter32,
++ ospfVirtNbrLsRetransQLen
++ Gauge32,
++ ospfVirtNbrHelloSuppressed
++ TruthValue
++ }
++
++ ospfVirtNbrArea OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Transit Area Identifier."
++ ::= { ospfVirtNbrEntry 1 }
++
++
++ ospfVirtNbrRtrId OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A 32-bit integer uniquely identifying the
++ neighboring router in the Autonomous System."
++ ::= { ospfVirtNbrEntry 2 }
++
++
++ ospfVirtNbrIpAddr OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address this Virtual Neighbor is us-
++ ing."
++ ::= { ospfVirtNbrEntry 3 }
++
++
++ ospfVirtNbrOptions OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "A Bit Mask corresponding to the neighbor's op-
++ tions field.
++
++ Bit 1, if set, indicates that the system will
++ operate on Type of Service metrics other than
++ TOS 0. If zero, the neighbor will ignore all
++ metrics except the TOS 0 metric.
++
++ Bit 2, if set, indicates that the system is
++ Network Multicast capable; ie, that it imple-
++ ments OSPF Multicast Routing."
++ ::= { ospfVirtNbrEntry 4 }
++ ospfVirtNbrState OBJECT-TYPE
++ SYNTAX INTEGER {
++ down (1),
++ attempt (2),
++ init (3),
++ twoWay (4),
++ exchangeStart (5),
++ exchange (6),
++ loading (7),
++ full (8)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The state of the Virtual Neighbor Relation-
++ ship."
++ ::= { ospfVirtNbrEntry 5 }
++
++
++ ospfVirtNbrEvents OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of times this virtual link has
++ changed its state, or an error has occurred."
++ ::= { ospfVirtNbrEntry 6 }
++
++
++ ospfVirtNbrLsRetransQLen OBJECT-TYPE
++ SYNTAX Gauge32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The current length of the retransmission
++ queue."
++ ::= { ospfVirtNbrEntry 7 }
++
++
++ ospfVirtNbrHelloSuppressed OBJECT-TYPE
++ SYNTAX TruthValue
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Indicates whether Hellos are being suppressed
++ to the neighbor"
++ ::= { ospfVirtNbrEntry 8 }
++
++-- OSPF Link State Database, External
++
++-- The Link State Database contains the Link State
++-- Advertisements from throughout the areas that the
++-- device is attached to.
++
++-- This table is identical to the OSPF LSDB Table in
++-- format, but contains only External Link State
++-- Advertisements. The purpose is to allow external
++-- LSAs to be displayed once for the router rather
++-- than once in each non-stub area.
++
++ ospfExtLsdbTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfExtLsdbEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "The OSPF Process's Links State Database."
++ REFERENCE
++ "OSPF Version 2, Section 12 Link State Adver-
++ tisements"
++ ::= { ospf 12 }
++
++
++ ospfExtLsdbEntry OBJECT-TYPE
++ SYNTAX OspfExtLsdbEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A single Link State Advertisement."
++ INDEX { ospfExtLsdbType, ospfExtLsdbLsid, ospfExtLsdbRouterId }
++ ::= { ospfExtLsdbTable 1 }
++
++OspfExtLsdbEntry ::=
++ SEQUENCE {
++ ospfExtLsdbType
++ INTEGER,
++ ospfExtLsdbLsid
++ IpAddress,
++ ospfExtLsdbRouterId
++ RouterID,
++ ospfExtLsdbSequence
++ Integer32,
++ ospfExtLsdbAge
++ Integer32,
++ ospfExtLsdbChecksum
++ Integer32,
++ ospfExtLsdbAdvertisement
++ OCTET STRING
++ }
++
++ ospfExtLsdbType OBJECT-TYPE
++ SYNTAX INTEGER {
++ asExternalLink (5)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The type of the link state advertisement.
++ Each link state type has a separate advertise-
++ ment format."
++ REFERENCE
++ "OSPF Version 2, Appendix A.4.1 The Link State
++ Advertisement header"
++ ::= { ospfExtLsdbEntry 1 }
++
++
++ ospfExtLsdbLsid OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Link State ID is an LS Type Specific field
++ containing either a Router ID or an IP Address;
++ it identifies the piece of the routing domain
++ that is being described by the advertisement."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.4 Link State ID"
++ ::= { ospfExtLsdbEntry 2 }
++
++
++ ospfExtLsdbRouterId OBJECT-TYPE
++ SYNTAX RouterID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The 32 bit number that uniquely identifies the
++ originating router in the Autonomous System."
++ REFERENCE
++ "OSPF Version 2, Appendix C.1 Global parameters"
++ ::= { ospfExtLsdbEntry 3 }
++
++-- Note that the OSPF Sequence Number is a 32 bit signed
++-- integer. It starts with the value '80000001'h,
++-- or -'7FFFFFFF'h, and increments until '7FFFFFFF'h
++-- Thus, a typical sequence number will be very negative.
++ ospfExtLsdbSequence OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The sequence number field is a signed 32-bit
++ integer. It is used to detect old and dupli-
++ cate link state advertisements. The space of
++ sequence numbers is linearly ordered. The
++ larger the sequence number the more recent the
++ advertisement."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.6 LS sequence
++ number"
++ ::= { ospfExtLsdbEntry 4 }
++
++
++ ospfExtLsdbAge OBJECT-TYPE
++ SYNTAX Integer32 -- Should be 0..MaxAge
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This field is the age of the link state adver-
++ tisement in seconds."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.1 LS age"
++ ::= { ospfExtLsdbEntry 5 }
++
++
++ ospfExtLsdbChecksum OBJECT-TYPE
++ SYNTAX Integer32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "This field is the checksum of the complete
++ contents of the advertisement, excepting the
++ age field. The age field is excepted so that
++ an advertisement's age can be incremented
++ without updating the checksum. The checksum
++ used is the same that is used for ISO connec-
++ tionless datagrams; it is commonly referred to
++ as the Fletcher checksum."
++ REFERENCE
++ "OSPF Version 2, Section 12.1.7 LS checksum"
++ ::= { ospfExtLsdbEntry 6 }
++
++
++ ospfExtLsdbAdvertisement OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE(36))
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The entire Link State Advertisement, including
++ its header."
++ REFERENCE
++ "OSPF Version 2, Section 12 Link State Adver-
++ tisements"
++ ::= { ospfExtLsdbEntry 7 }
++
++
++-- OSPF Use of the CIDR Route Table
++
++ospfRouteGroup OBJECT IDENTIFIER ::= { ospf 13 }
++
++-- The IP Forwarding Table defines a number of objects for use by
++-- the routing protocol to externalize its information. Most of
++-- the variables (ipForwardDest, ipForwardMask, ipForwardPolicy,
++-- ipForwardNextHop, ipForwardIfIndex, ipForwardType,
++-- ipForwardProto, ipForwardAge, and ipForwardNextHopAS) are
++-- defined there.
++
++-- Those that leave some discretion are defined here.
++
++-- ipCidrRouteProto is, of course, ospf (13).
++
++-- ipCidrRouteAge is the time since the route was first calculated,
++-- as opposed to the time since the last SPF run.
++
++-- ipCidrRouteInfo is an OBJECT IDENTIFIER for use by the routing
++-- protocol. The following values shall be found there depending
++-- on the way the route was calculated.
++
++ospfIntraArea OBJECT IDENTIFIER ::= { ospfRouteGroup 1 }
++ospfInterArea OBJECT IDENTIFIER ::= { ospfRouteGroup 2 }
++ospfExternalType1 OBJECT IDENTIFIER ::= { ospfRouteGroup 3 }
++ospfExternalType2 OBJECT IDENTIFIER ::= { ospfRouteGroup 4 }
++
++-- ipCidrRouteMetric1 is, by definition, the primary routing
++-- metric. Therefore, it should be the metric that route
++-- selection is based on. For intra-area and inter-area routes,
++-- it is an OSPF metric. For External Type 1 (comparable value)
++-- routes, it is an OSPF metric plus the External Metric. For
++-- external Type 2 (non-comparable value) routes, it is the
++-- external metric.
++
++-- ipCidrRouteMetric2 is, by definition, a secondary routing
++-- metric. Therefore, it should be the metric that breaks a tie
++-- among routes having equal metric1 values and the same
++-- calculation rule. For intra-area, inter-area routes, and
++-- External Type 1 (comparable value) routes, it is unused. For
++-- external Type 2 (non-comparable value) routes, it is the metric
++-- to the AS border router.
++
++-- ipCidrRouteMetric3, ipCidrRouteMetric4, and ipCidrRouteMetric5 are
++-- unused.
++
++--
++-- The OSPF Area Aggregate Table
++--
++-- This table replaces the OSPF Area Summary Table, being an
++-- extension of that for CIDR routers.
++
++ ospfAreaAggregateTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF OspfAreaAggregateEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A range of IP addresses specified by an IP
++ address/IP network mask pair. For example,
++ class B address range of X.X.X.X with a network
++ mask of 255.255.0.0 includes all IP addresses
++ from X.X.0.0 to X.X.255.255. Note that if
++ ranges are configured such that one range sub-
++ sumes another range (e.g., 10.0.0.0 mask
++ 255.0.0.0 and 10.1.0.0 mask 255.255.0.0), the
++ most specific match is the preferred one."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospf 14 }
++
++
++ ospfAreaAggregateEntry OBJECT-TYPE
++ SYNTAX OspfAreaAggregateEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A range of IP addresses specified by an IP
++ address/IP network mask pair. For example,
++ class B address range of X.X.X.X with a network
++ mask of 255.255.0.0 includes all IP addresses
++ from X.X.0.0 to X.X.255.255. Note that if
++ ranges are range configured such that one range
++ subsumes another range (e.g., 10.0.0.0 mask
++ 255.0.0.0 and 10.1.0.0 mask 255.255.0.0), the
++ most specific match is the preferred one."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ INDEX { ospfAreaAggregateAreaID, ospfAreaAggregateLsdbType,
++ ospfAreaAggregateNet, ospfAreaAggregateMask }
++ ::= { ospfAreaAggregateTable 1 }
++
++
++OspfAreaAggregateEntry ::=
++ SEQUENCE {
++ ospfAreaAggregateAreaID
++ AreaID,
++ ospfAreaAggregateLsdbType
++ INTEGER,
++ ospfAreaAggregateNet
++ IpAddress,
++ ospfAreaAggregateMask
++ IpAddress,
++ ospfAreaAggregateStatus
++ RowStatus,
++ ospfAreaAggregateEffect
++ INTEGER
++ }
++
++ ospfAreaAggregateAreaID OBJECT-TYPE
++ SYNTAX AreaID
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Area the Address Aggregate is to be found
++ within."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaAggregateEntry 1 }
++
++
++ ospfAreaAggregateLsdbType OBJECT-TYPE
++ SYNTAX INTEGER {
++ summaryLink (3),
++ nssaExternalLink (7)
++ }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The type of the Address Aggregate. This field
++ specifies the Lsdb type that this Address Ag-
++ gregate applies to."
++ REFERENCE
++ "OSPF Version 2, Appendix A.4.1 The Link State
++ Advertisement header"
++ ::= { ospfAreaAggregateEntry 2 }
++
++
++ ospfAreaAggregateNet OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of the Net or Subnet indicated
++ by the range."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaAggregateEntry 3 }
++
++
++ ospfAreaAggregateMask OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The Subnet Mask that pertains to the Net or
++ Subnet."
++ REFERENCE
++ "OSPF Version 2, Appendix C.2 Area parameters"
++ ::= { ospfAreaAggregateEntry 4 }
++
++
++ ospfAreaAggregateStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable displays the status of the en-
++ try. Setting it to 'invalid' has the effect of
++ rendering it inoperative. The internal effect
++ (row removal) is implementation dependent."
++ ::= { ospfAreaAggregateEntry 5 }
++
++
++ ospfAreaAggregateEffect OBJECT-TYPE
++ SYNTAX INTEGER {
++ advertiseMatching (1),
++ doNotAdvertiseMatching (2)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "Subnets subsumed by ranges either trigger the
++ advertisement of the indicated aggregate (ad-
++ vertiseMatching), or result in the subnet's not
++ being advertised at all outside the area."
++ DEFVAL { advertiseMatching }
++ ::= { ospfAreaAggregateEntry 6 }
++
++
++-- conformance information
++
++ospfConformance OBJECT IDENTIFIER ::= { ospf 15 }
++
++ospfGroups OBJECT IDENTIFIER ::= { ospfConformance 1 }
++ospfCompliances OBJECT IDENTIFIER ::= { ospfConformance 2 }
++
++-- compliance statements
++
++ ospfCompliance MODULE-COMPLIANCE
++ STATUS current
++ DESCRIPTION
++ "The compliance statement "
++ MODULE -- this module
++ MANDATORY-GROUPS {
++ ospfBasicGroup,
++ ospfAreaGroup,
++ ospfStubAreaGroup,
++ ospfIfGroup,
++ ospfIfMetricGroup,
++ ospfVirtIfGroup,
++ ospfNbrGroup,
++ ospfVirtNbrGroup,
++ ospfAreaAggregateGroup
++ }
++ ::= { ospfCompliances 1 }
++
++
++-- units of conformance
++
++ ospfBasicGroup OBJECT-GROUP
++ OBJECTS {
++ ospfRouterId,
++ ospfAdminStat,
++ ospfVersionNumber,
++ ospfAreaBdrRtrStatus,
++ ospfASBdrRtrStatus,
++ ospfExternLsaCount,
++ ospfExternLsaCksumSum,
++ ospfTOSSupport,
++ ospfOriginateNewLsas,
++ ospfRxNewLsas,
++ ospfExtLsdbLimit,
++ ospfMulticastExtensions,
++ ospfExitOverflowInterval,
++ ospfDemandExtensions
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 1 }
++
++
++ ospfAreaGroup OBJECT-GROUP
++ OBJECTS {
++ ospfAreaId,
++ ospfImportAsExtern,
++ ospfSpfRuns,
++ ospfAreaBdrRtrCount,
++ ospfAsBdrRtrCount,
++ ospfAreaLsaCount,
++ ospfAreaLsaCksumSum,
++ ospfAreaSummary,
++ ospfAreaStatus
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems
++ supporting areas."
++ ::= { ospfGroups 2 }
++
++
++ ospfStubAreaGroup OBJECT-GROUP
++ OBJECTS {
++ ospfStubAreaId,
++ ospfStubTOS,
++ ospfStubMetric,
++ ospfStubStatus,
++ ospfStubMetricType
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems
++ supporting stub areas."
++ ::= { ospfGroups 3 }
++
++
++ ospfLsdbGroup OBJECT-GROUP
++ OBJECTS {
++ ospfLsdbAreaId,
++ ospfLsdbType,
++ ospfLsdbLsid,
++ ospfLsdbRouterId,
++ ospfLsdbSequence,
++ ospfLsdbAge,
++ ospfLsdbChecksum,
++ ospfLsdbAdvertisement
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems
++ that display their link state database."
++ ::= { ospfGroups 4 }
++
++
++ ospfAreaRangeGroup OBJECT-GROUP
++ OBJECTS {
++ ospfAreaRangeAreaId,
++ ospfAreaRangeNet,
++ ospfAreaRangeMask,
++ ospfAreaRangeStatus,
++ ospfAreaRangeEffect
++ }
++ STATUS obsolete
++ DESCRIPTION
++ "These objects are required for non-CIDR OSPF
++ systems that support multiple areas."
++ ::= { ospfGroups 5 }
++
++
++ ospfHostGroup OBJECT-GROUP
++ OBJECTS {
++ ospfHostIpAddress,
++ ospfHostTOS,
++ ospfHostMetric,
++ ospfHostStatus,
++ ospfHostAreaID
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems
++ that support attached hosts."
++ ::= { ospfGroups 6 }
++
++
++ ospfIfGroup OBJECT-GROUP
++ OBJECTS {
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfIfAreaId,
++ ospfIfType,
++ ospfIfAdminStat,
++ ospfIfRtrPriority,
++ ospfIfTransitDelay,
++ ospfIfRetransInterval,
++ ospfIfHelloInterval,
++ ospfIfRtrDeadInterval,
++ ospfIfPollInterval,
++ ospfIfState,
++ ospfIfDesignatedRouter,
++ ospfIfBackupDesignatedRouter,
++ ospfIfEvents,
++ ospfIfAuthType,
++ ospfIfAuthKey,
++ ospfIfStatus,
++ ospfIfMulticastForwarding,
++ ospfIfDemand
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 7 }
++
++
++ ospfIfMetricGroup OBJECT-GROUP
++ OBJECTS {
++ ospfIfMetricIpAddress,
++ ospfIfMetricAddressLessIf,
++ ospfIfMetricTOS,
++ ospfIfMetricValue,
++ ospfIfMetricStatus
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 8 }
++
++
++ ospfVirtIfGroup OBJECT-GROUP
++ OBJECTS {
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfVirtIfTransitDelay,
++ ospfVirtIfRetransInterval,
++ ospfVirtIfHelloInterval,
++ ospfVirtIfRtrDeadInterval,
++ ospfVirtIfState,
++ ospfVirtIfEvents,
++ ospfVirtIfAuthType,
++ ospfVirtIfAuthKey,
++ ospfVirtIfStatus
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 9 }
++
++
++ ospfNbrGroup OBJECT-GROUP
++ OBJECTS {
++ ospfNbrIpAddr,
++ ospfNbrAddressLessIndex,
++ ospfNbrRtrId,
++ ospfNbrOptions,
++ ospfNbrPriority,
++ ospfNbrState,
++ ospfNbrEvents,
++ ospfNbrLsRetransQLen,
++ ospfNbmaNbrStatus,
++ ospfNbmaNbrPermanence,
++ ospfNbrHelloSuppressed
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 10 }
++
++
++ ospfVirtNbrGroup OBJECT-GROUP
++ OBJECTS {
++ ospfVirtNbrArea,
++ ospfVirtNbrRtrId,
++ ospfVirtNbrIpAddr,
++ ospfVirtNbrOptions,
++ ospfVirtNbrState,
++ ospfVirtNbrEvents,
++ ospfVirtNbrLsRetransQLen,
++ ospfVirtNbrHelloSuppressed
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 11 }
++
++
++ ospfExtLsdbGroup OBJECT-GROUP
++ OBJECTS {
++ ospfExtLsdbType,
++ ospfExtLsdbLsid,
++ ospfExtLsdbRouterId,
++ ospfExtLsdbSequence,
++ ospfExtLsdbAge,
++ ospfExtLsdbChecksum,
++ ospfExtLsdbAdvertisement
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems
++ that display their link state database."
++ ::= { ospfGroups 12 }
++
++
++ ospfAreaAggregateGroup OBJECT-GROUP
++ OBJECTS {
++ ospfAreaAggregateAreaID,
++ ospfAreaAggregateLsdbType,
++ ospfAreaAggregateNet,
++ ospfAreaAggregateMask,
++ ospfAreaAggregateStatus,
++ ospfAreaAggregateEffect
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required for OSPF systems."
++ ::= { ospfGroups 13 }
++
++END
+diff -ruN net-snmp-5.1.2-orig/mibs/OSPF-TRAP-MIB.txt net-snmp-5.1.2-5/mibs/OSPF-TRAP-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/OSPF-TRAP-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/OSPF-TRAP-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,443 @@
++OSPF-TRAP-MIB DEFINITIONS ::= BEGIN
++
++ IMPORTS
++ MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE, IpAddress
++ FROM SNMPv2-SMI
++ MODULE-COMPLIANCE, OBJECT-GROUP
++ FROM SNMPv2-CONF
++ ospfRouterId, ospfIfIpAddress, ospfAddressLessIf, ospfIfState,
++ ospfVirtIfAreaId, ospfVirtIfNeighbor, ospfVirtIfState,
++ ospfNbrIpAddr, ospfNbrAddressLessIndex, ospfNbrRtrId,
++ ospfNbrState, ospfVirtNbrArea, ospfVirtNbrRtrId, ospfVirtNbrState,
++ ospfLsdbType, ospfLsdbLsid, ospfLsdbRouterId, ospfLsdbAreaId,
++ ospfExtLsdbLimit, ospf
++ FROM OSPF-MIB;
++
++ ospfTrap MODULE-IDENTITY
++ LAST-UPDATED "9501201225Z" -- Fri Jan 20 12:25:50 PST 1995
++ ORGANIZATION "IETF OSPF Working Group"
++ CONTACT-INFO
++ " Fred Baker
++ Postal: Cisco Systems
++ 519 Lado Drive
++ Santa Barbara, California 93111
++ Tel: +1 805 681 0115
++ E-Mail: fred@cisco.com
++
++ Rob Coltun
++ Postal: RainbowBridge Communications
++ Tel: (301) 340-9416
++ E-Mail: rcoltun@rainbow-bridge.com"
++ DESCRIPTION
++ "The MIB module to describe traps for the OSPF
++ Version 2 Protocol."
++ ::= { ospf 16 }
++
++-- Trap Support Objects
++
++-- The following are support objects for the OSPF traps.
++
++ospfTrapControl OBJECT IDENTIFIER ::= { ospfTrap 1 }
++ospfTraps OBJECT IDENTIFIER ::= { ospfTrap 2 }
++
++ ospfSetTrap OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE(4))
++ MAX-ACCESS read-write
++ STATUS current
++ DESCRIPTION
++ "A four-octet string serving as a bit map for
++ the trap events defined by the OSPF traps. This
++ object is used to enable and disable specific
++ OSPF traps where a 1 in the bit field
++ represents enabled. The right-most bit (least
++ significant) represents trap 0."
++ ::= { ospfTrapControl 1 }
++
++
++ ospfConfigErrorType OBJECT-TYPE
++ SYNTAX INTEGER {
++ badVersion (1),
++ areaMismatch (2),
++ unknownNbmaNbr (3), -- Router is Dr eligible
++ unknownVirtualNbr (4),
++ authTypeMismatch(5),
++ authFailure (6),
++ netMaskMismatch (7),
++ helloIntervalMismatch (8),
++ deadIntervalMismatch (9),
++ optionMismatch (10) }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "Potential types of configuration conflicts.
++ Used by the ospfConfigError and ospfConfigVir-
++ tError traps."
++ ::= { ospfTrapControl 2 }
++
++
++ ospfPacketType OBJECT-TYPE
++ SYNTAX INTEGER {
++ hello (1),
++ dbDescript (2),
++ lsReq (3),
++ lsUpdate (4),
++ lsAck (5) }
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "OSPF packet types."
++ ::= { ospfTrapControl 3 }
++
++
++ ospfPacketSrc OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP address of an inbound packet that can-
++ not be identified by a neighbor instance."
++ ::= { ospfTrapControl 4 }
++
++
++-- Traps
++
++
++ ospfIfStateChange NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfIfState -- The new state
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfStateChange trap signifies that there
++ has been a change in the state of a non-virtual
++ OSPF interface. This trap should be generated
++ when the interface state regresses (e.g., goes
++ from Dr to Down) or progresses to a terminal
++ state (i.e., Point-to-Point, DR Other, Dr, or
++ Backup)."
++ ::= { ospfTraps 16 }
++
++
++ ospfVirtIfStateChange NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfVirtIfState -- The new state
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfStateChange trap signifies that there
++ has been a change in the state of an OSPF vir-
++ tual interface.
++ This trap should be generated when the inter-
++ face state regresses (e.g., goes from Point-
++ to-Point to Down) or progresses to a terminal
++ state (i.e., Point-to-Point)."
++ ::= { ospfTraps 1 }
++
++
++ ospfNbrStateChange NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfNbrIpAddr,
++ ospfNbrAddressLessIndex,
++ ospfNbrRtrId,
++ ospfNbrState -- The new state
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfNbrStateChange trap signifies that
++ there has been a change in the state of a non-
++ virtual OSPF neighbor. This trap should be
++ generated when the neighbor state regresses
++ (e.g., goes from Attempt or Full to 1-Way or
++ Down) or progresses to a terminal state (e.g.,
++ 2-Way or Full). When an neighbor transitions
++ from or to Full on non-broadcast multi-access
++ and broadcast networks, the trap should be gen-
++ erated by the designated router. A designated
++ router transitioning to Down will be noted by
++ ospfIfStateChange."
++ ::= { ospfTraps 2 }
++
++
++ ospfVirtNbrStateChange NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtNbrArea,
++ ospfVirtNbrRtrId,
++ ospfVirtNbrState -- The new state
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfStateChange trap signifies that there
++ has been a change in the state of an OSPF vir-
++ tual neighbor. This trap should be generated
++ when the neighbor state regresses (e.g., goes
++ from Attempt or Full to 1-Way or Down) or
++ progresses to a terminal state (e.g., Full)."
++ ::= { ospfTraps 3 }
++ ospfIfConfigError NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfPacketSrc, -- The source IP address
++ ospfConfigErrorType, -- Type of error
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfConfigError trap signifies that a
++ packet has been received on a non-virtual in-
++ terface from a router whose configuration
++ parameters conflict with this router's confi-
++ guration parameters. Note that the event op-
++ tionMismatch should cause a trap only if it
++ prevents an adjacency from forming."
++ ::= { ospfTraps 4 }
++
++
++ ospfVirtIfConfigError NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfConfigErrorType, -- Type of error
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfConfigError trap signifies that a pack-
++ et has been received on a virtual interface
++ from a router whose configuration parameters
++ conflict with this router's configuration
++ parameters. Note that the event optionMismatch
++ should cause a trap only if it prevents an ad-
++ jacency from forming."
++ ::= { ospfTraps 5 }
++
++
++ ospfIfAuthFailure NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfPacketSrc, -- The source IP address
++ ospfConfigErrorType, -- authTypeMismatch or
++ -- authFailure
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfAuthFailure trap signifies that a
++ packet has been received on a non-virtual in-
++ terface from a router whose authentication key
++ or authentication type conflicts with this
++ router's authentication key or authentication
++ type."
++ ::= { ospfTraps 6 }
++
++
++ ospfVirtIfAuthFailure NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfConfigErrorType, -- authTypeMismatch or
++ -- authFailure
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfVirtIfAuthFailure trap signifies that a
++ packet has been received on a virtual interface
++ from a router whose authentication key or au-
++ thentication type conflicts with this router's
++ authentication key or authentication type."
++ ::= { ospfTraps 7 }
++
++
++ ospfIfRxBadPacket NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfPacketSrc, -- The source IP address
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfIfRxBadPacket trap signifies that an
++ OSPF packet has been received on a non-virtual
++ interface that cannot be parsed."
++ ::= { ospfTraps 8 }
++
++ ospfVirtIfRxBadPacket NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfPacketType
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfRxBadPacket trap signifies that an OSPF
++ packet has been received on a virtual interface
++ that cannot be parsed."
++ ::= { ospfTraps 9 }
++
++
++ ospfTxRetransmit NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfIfIpAddress,
++ ospfAddressLessIf,
++ ospfNbrRtrId, -- Destination
++ ospfPacketType,
++ ospfLsdbType,
++ ospfLsdbLsid,
++ ospfLsdbRouterId
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfTxRetransmit trap signifies than an
++ OSPF packet has been retransmitted on a non-
++ virtual interface. All packets that may be re-
++ transmitted are associated with an LSDB entry.
++ The LS type, LS ID, and Router ID are used to
++ identify the LSDB entry."
++ ::= { ospfTraps 10 }
++
++
++ ospfVirtIfTxRetransmit NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfVirtIfAreaId,
++ ospfVirtIfNeighbor,
++ ospfPacketType,
++ ospfLsdbType,
++ ospfLsdbLsid,
++ ospfLsdbRouterId
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfTxRetransmit trap signifies than an
++ OSPF packet has been retransmitted on a virtual
++ interface. All packets that may be retransmit-
++ ted are associated with an LSDB entry. The LS
++ type, LS ID, and Router ID are used to identify
++ the LSDB entry."
++ ::= { ospfTraps 11 }
++
++
++ ospfOriginateLsa NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfLsdbAreaId, -- 0.0.0.0 for AS Externals
++ ospfLsdbType,
++ ospfLsdbLsid,
++ ospfLsdbRouterId
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfOriginateLsa trap signifies that a new
++ LSA has been originated by this router. This
++ trap should not be invoked for simple refreshes
++ of LSAs (which happesn every 30 minutes), but
++ instead will only be invoked when an LSA is
++ (re)originated due to a topology change. Addi-
++ tionally, this trap does not include LSAs that
++ are being flushed because they have reached
++ MaxAge."
++ ::= { ospfTraps 12 }
++
++
++ ospfMaxAgeLsa NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfLsdbAreaId, -- 0.0.0.0 for AS Externals
++ ospfLsdbType,
++ ospfLsdbLsid,
++ ospfLsdbRouterId
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfMaxAgeLsa trap signifies that one of
++ the LSA in the router's link-state database has
++ aged to MaxAge."
++ ::= { ospfTraps 13 }
++
++
++ ospfLsdbOverflow NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfExtLsdbLimit
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfLsdbOverflow trap signifies that the
++ number of LSAs in the router's link-state data-
++ base has exceeded ospfExtLsdbLimit."
++ ::= { ospfTraps 14 }
++
++
++ ospfLsdbApproachingOverflow NOTIFICATION-TYPE
++ OBJECTS {
++ ospfRouterId, -- The originator of the trap
++ ospfExtLsdbLimit
++ }
++ STATUS current
++ DESCRIPTION
++ "An ospfLsdbApproachingOverflow trap signifies
++ that the number of LSAs in the router's link-
++ state database has exceeded ninety percent of
++ ospfExtLsdbLimit."
++ ::= { ospfTraps 15 }
++
++
++-- conformance information
++
++ospfTrapConformance OBJECT IDENTIFIER ::= { ospfTrap 3 }
++
++ospfTrapGroups OBJECT IDENTIFIER ::= { ospfTrapConformance 1 }
++ospfTrapCompliances OBJECT IDENTIFIER ::= { ospfTrapConformance 2 }
++
++-- compliance statements
++
++ ospfTrapCompliance MODULE-COMPLIANCE
++ STATUS current
++ DESCRIPTION
++ "The compliance statement "
++ MODULE -- this module
++ MANDATORY-GROUPS { ospfTrapControlGroup }
++
++
++ GROUP ospfTrapControlGroup
++ DESCRIPTION
++ "This group is optional but recommended for all
++ OSPF systems"
++ ::= { ospfTrapCompliances 1 }
++
++
++-- units of conformance
++
++ ospfTrapControlGroup OBJECT-GROUP
++ OBJECTS {
++ ospfSetTrap,
++ ospfConfigErrorType,
++ ospfPacketType,
++ ospfPacketSrc
++ }
++ STATUS current
++ DESCRIPTION
++ "These objects are required to control traps
++ from OSPF systems."
++ ::= { ospfTrapGroups 1 }
++
++
++END
+diff -ruN net-snmp-5.1.2-orig/mibs/RIPv2-MIB.txt net-snmp-5.1.2-5/mibs/RIPv2-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/RIPv2-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/RIPv2-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,530 @@
++ RIPv2-MIB DEFINITIONS ::= BEGIN
++
++ IMPORTS
++ MODULE-IDENTITY, OBJECT-TYPE, Counter32,
++ TimeTicks, IpAddress FROM SNMPv2-SMI
++ TEXTUAL-CONVENTION, RowStatus FROM SNMPv2-TC
++ MODULE-COMPLIANCE, OBJECT-GROUP FROM SNMPv2-CONF
++ mib-2 FROM RFC1213-MIB;
++
++ -- This MIB module uses the extended OBJECT-TYPE macro as
++ -- defined in [9].
++
++ rip2 MODULE-IDENTITY
++ LAST-UPDATED "9407272253Z" -- Wed Jul 27 22:53:04 PDT 1994
++ ORGANIZATION "IETF RIP-II Working Group"
++ CONTACT-INFO
++ " Fred Baker
++ Postal: Cisco Systems
++ 519 Lado Drive
++ Santa Barbara, California 93111
++ Tel: +1 805 681 0115
++ E-Mail: fbaker@cisco.com
++
++ Postal: Gary Malkin
++ Xylogics, Inc.
++ 53 Third Avenue
++ Burlington, MA 01803
++
++ Phone: (617) 272-8140
++ EMail: gmalkin@Xylogics.COM"
++ DESCRIPTION
++ "The MIB module to describe the RIP2 Version 2 Protocol"
++ ::= { mib-2 23 }
++
++ -- RIP-2 Management Information Base
++
++ -- the RouteTag type represents the contents of the
++ -- Route Domain field in the packet header or route entry.
++ -- The use of the Route Domain is deprecated.
++
++ RouteTag ::= TEXTUAL-CONVENTION
++ STATUS current
++ DESCRIPTION
++ "the RouteTag type represents the contents of the Route Domain
++ field in the packet header or route entry"
++ SYNTAX OCTET STRING (SIZE (2))
++
++--4.1 Global Counters
++
++-- The RIP-2 Globals Group.
++-- Implementation of this group is mandatory for systems
++-- which implement RIP-2.
++
++-- These counters are intended to facilitate debugging quickly
++-- changing routes or failing neighbors
++
++rip2Globals OBJECT IDENTIFIER ::= { rip2 1 }
++
++ rip2GlobalRouteChanges OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of route changes made to the IP Route
++ Database by RIP. This does not include the refresh
++ of a route's age."
++ ::= { rip2Globals 1 }
++
++ rip2GlobalQueries OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of responses sent to RIP queries
++ from other systems."
++ ::= { rip2Globals 2 }
++
++--4.2 RIP Interface Tables
++
++-- RIP Interfaces Groups
++-- Implementation of these Groups is mandatory for systems
++-- which implement RIP-2.
++
++-- The RIP Interface Status Table.
++
++ rip2IfStatTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Rip2IfStatEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A list of subnets which require separate
++ status monitoring in RIP."
++ ::= { rip2 2 }
++
++ rip2IfStatEntry OBJECT-TYPE
++ SYNTAX Rip2IfStatEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A Single Routing Domain in a single Subnet."
++ INDEX { rip2IfStatAddress }
++ ::= { rip2IfStatTable 1 }
++
++ Rip2IfStatEntry ::=
++ SEQUENCE {
++ rip2IfStatAddress
++ IpAddress,
++ rip2IfStatRcvBadPackets
++ Counter32,
++ rip2IfStatRcvBadRoutes
++ Counter32,
++ rip2IfStatSentUpdates
++ Counter32,
++ rip2IfStatStatus
++ RowStatus
++ }
++
++ rip2IfStatAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of this system on the indicated
++ subnet. For unnumbered interfaces, the value 0.0.0.N,
++ where the least significant 24 bits (N) is the ifIndex
++ for the IP Interface in network byte order."
++ ::= { rip2IfStatEntry 1 }
++
++ rip2IfStatRcvBadPackets OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of RIP response packets received by
++ the RIP process which were subsequently discarded
++ for any reason (e.g. a version 0 packet, or an
++ unknown command type)."
++ ::= { rip2IfStatEntry 2 }
++
++ rip2IfStatRcvBadRoutes OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of routes, in valid RIP packets,
++ which were ignored for any reason (e.g. unknown
++ address family, or invalid metric)."
++ ::= { rip2IfStatEntry 3 }
++
++ rip2IfStatSentUpdates OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of triggered RIP updates actually
++ sent on this interface. This explicitly does
++ NOT include full updates sent containing new
++ information."
++ ::= { rip2IfStatEntry 4 }
++
++ rip2IfStatStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "Writing invalid has the effect of deleting
++ this interface."
++ ::= { rip2IfStatEntry 5 }
++
++-- The RIP Interface Configuration Table.
++
++ rip2IfConfTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Rip2IfConfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A list of subnets which require separate
++ configuration in RIP."
++ ::= { rip2 3 }
++
++ rip2IfConfEntry OBJECT-TYPE
++ SYNTAX Rip2IfConfEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A Single Routing Domain in a single Subnet."
++ INDEX { rip2IfConfAddress }
++ ::= { rip2IfConfTable 1 }
++
++ Rip2IfConfEntry ::=
++ SEQUENCE {
++ rip2IfConfAddress
++ IpAddress,
++ rip2IfConfDomain
++ RouteTag,
++ rip2IfConfAuthType
++ INTEGER,
++ rip2IfConfAuthKey
++ OCTET STRING (SIZE(0..16)),
++ rip2IfConfSend
++ INTEGER,
++ rip2IfConfReceive
++ INTEGER,
++ rip2IfConfDefaultMetric
++ INTEGER,
++ rip2IfConfStatus
++ RowStatus,
++ rip2IfConfSrcAddress
++ IpAddress
++ }
++
++ rip2IfConfAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address of this system on the indicated
++ subnet. For unnumbered interfaces, the value 0.0.0.N,
++ where the least significant 24 bits (N) is the ifIndex
++ for the IP Interface in network byte order."
++ ::= { rip2IfConfEntry 1 }
++
++ rip2IfConfDomain OBJECT-TYPE
++ SYNTAX RouteTag
++ MAX-ACCESS read-create
++ STATUS obsolete
++ DESCRIPTION
++ "Value inserted into the Routing Domain field
++ of all RIP packets sent on this interface."
++ DEFVAL { '0000'h }
++ ::= { rip2IfConfEntry 2 }
++
++ rip2IfConfAuthType OBJECT-TYPE
++ SYNTAX INTEGER {
++ noAuthentication (1),
++ simplePassword (2),
++ md5 (3)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The type of Authentication used on this
++ interface."
++ DEFVAL { noAuthentication }
++ ::= { rip2IfConfEntry 3 }
++
++ rip2IfConfAuthKey OBJECT-TYPE
++ SYNTAX OCTET STRING (SIZE(0..16))
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The value to be used as the Authentication Key
++ whenever the corresponding instance of
++ rip2IfConfAuthType has a value other than
++ noAuthentication. A modification of the corresponding
++ instance of rip2IfConfAuthType does not modify
++ the rip2IfConfAuthKey value. If a string shorter
++ than 16 octets is supplied, it will be left-
++ justified and padded to 16 octets, on the right,
++ with nulls (0x00).
++
++ Reading this object always results in an OCTET
++ STRING of length zero; authentication may not
++ be bypassed by reading the MIB object."
++ DEFVAL { ''h }
++ ::= { rip2IfConfEntry 4 }
++
++ rip2IfConfSend OBJECT-TYPE
++ SYNTAX INTEGER {
++ doNotSend (1),
++ ripVersion1 (2),
++ rip1Compatible (3),
++ ripVersion2 (4),
++ ripV1Demand (5),
++ ripV2Demand (6)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "What the router sends on this interface.
++ ripVersion1 implies sending RIP updates compliant
++ with RFC 1058. rip1Compatible implies
++ broadcasting RIP-2 updates using RFC 1058 route
++ subsumption rules. ripVersion2 implies
++ multicasting RIP-2 updates. ripV1Demand indicates
++ the use of Demand RIP on a WAN interface under RIP
++ Version 1 rules. ripV2Demand indicates the use of
++ Demand RIP on a WAN interface under Version 2 rules."
++ DEFVAL { rip1Compatible }
++ ::= { rip2IfConfEntry 5 }
++
++ rip2IfConfReceive OBJECT-TYPE
++ SYNTAX INTEGER {
++ rip1 (1),
++ rip2 (2),
++ rip1OrRip2 (3),
++ doNotRecieve (4)
++ }
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This indicates which version of RIP updates
++ are to be accepted. Note that rip2 and
++ rip1OrRip2 implies reception of multicast
++ packets."
++ DEFVAL { rip1OrRip2 }
++ ::= { rip2IfConfEntry 6 }
++
++ rip2IfConfDefaultMetric OBJECT-TYPE
++ SYNTAX INTEGER ( 0..15 )
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "This variable indicates the metric that is to
++ be used for the default route entry in RIP updates
++ originated on this interface. A value of zero
++ indicates that no default route should be
++ originated; in this case, a default route via
++ another router may be propagated."
++ ::= { rip2IfConfEntry 7 }
++
++ rip2IfConfStatus OBJECT-TYPE
++ SYNTAX RowStatus
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "Writing invalid has the effect of deleting
++ this interface."
++ ::= { rip2IfConfEntry 8 }
++
++ rip2IfConfSrcAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-create
++ STATUS current
++ DESCRIPTION
++ "The IP Address this system will use as a source
++ address on this interface. If it is a numbered
++ interface, this MUST be the same value as
++ rip2IfConfAddress. On unnumbered interfaces,
++ it must be the value of rip2IfConfAddress for
++ some interface on the system."
++ ::= { rip2IfConfEntry 9 }
++
++--4.3 Peer Table
++
++-- Peer Table
++
++-- The RIP Peer Group
++-- Implementation of this Group is Optional
++
++-- This group provides information about active peer
++-- relationships intended to assist in debugging. An
++-- active peer is a router from which a valid RIP
++-- updated has been heard in the last 180 seconds.
++
++ rip2PeerTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Rip2PeerEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "A list of RIP Peers."
++ ::= { rip2 4 }
++
++ rip2PeerEntry OBJECT-TYPE
++ SYNTAX Rip2PeerEntry
++ MAX-ACCESS not-accessible
++ STATUS current
++ DESCRIPTION
++ "Information regarding a single routing peer."
++ INDEX { rip2PeerAddress, rip2PeerDomain }
++ ::= { rip2PeerTable 1 }
++
++ Rip2PeerEntry ::=
++ SEQUENCE {
++ rip2PeerAddress
++ IpAddress,
++ rip2PeerDomain
++ RouteTag,
++ rip2PeerLastUpdate
++ TimeTicks,
++ rip2PeerVersion
++ INTEGER,
++ rip2PeerRcvBadPackets
++ Counter32,
++ rip2PeerRcvBadRoutes
++ Counter32
++ }
++
++ rip2PeerAddress OBJECT-TYPE
++ SYNTAX IpAddress
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The IP Address that the peer is using as its source
++ address. Note that on an unnumbered link, this may
++ not be a member of any subnet on the system."
++ ::= { rip2PeerEntry 1 }
++
++ rip2PeerDomain OBJECT-TYPE
++ SYNTAX RouteTag
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The value in the Routing Domain field in RIP
++ packets received from the peer. As domain suuport
++ is deprecated, this must be zero."
++ ::= { rip2PeerEntry 2 }
++
++ rip2PeerLastUpdate OBJECT-TYPE
++ SYNTAX TimeTicks
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The value of sysUpTime when the most recent
++ RIP update was received from this system."
++ ::= { rip2PeerEntry 3 }
++
++ rip2PeerVersion OBJECT-TYPE
++ SYNTAX INTEGER ( 0..255 )
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The RIP version number in the header of the
++ last RIP packet received."
++ ::= { rip2PeerEntry 4 }
++
++ rip2PeerRcvBadPackets OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of RIP response packets from this
++ peer discarded as invalid."
++ ::= { rip2PeerEntry 5 }
++
++
++ rip2PeerRcvBadRoutes OBJECT-TYPE
++ SYNTAX Counter32
++ MAX-ACCESS read-only
++ STATUS current
++ DESCRIPTION
++ "The number of routes from this peer that were
++ ignored because the entry format was invalid."
++ ::= { rip2PeerEntry 6 }
++
++-- conformance information
++
++rip2Conformance OBJECT IDENTIFIER ::= { rip2 5 }
++
++rip2Groups OBJECT IDENTIFIER ::= { rip2Conformance 1 }
++rip2Compliances OBJECT IDENTIFIER ::= { rip2Conformance 2 }
++
++-- compliance statements
++rip2Compliance MODULE-COMPLIANCE
++ STATUS current
++ DESCRIPTION
++ "The compliance statement "
++ MODULE -- this module
++ MANDATORY-GROUPS {
++ rip2GlobalGroup,
++ rip2IfStatGroup,
++ rip2IfConfGroup,
++ rip2PeerGroup
++ }
++ GROUP rip2GlobalGroup
++ DESCRIPTION
++ "This group defines global controls for RIP-II systems."
++ GROUP rip2IfStatGroup
++ DESCRIPTION
++ "This group defines interface statistics for RIP-II systems."
++ GROUP rip2IfConfGroup
++ DESCRIPTION
++ "This group defines interface configuration for RIP-II systems."
++ GROUP rip2PeerGroup
++ DESCRIPTION
++ "This group defines peer information for RIP-II systems."
++ ::= { rip2Compliances 1 }
++
++-- units of conformance
++
++rip2GlobalGroup OBJECT-GROUP
++ OBJECTS {
++ rip2GlobalRouteChanges,
++ rip2GlobalQueries
++ }
++ STATUS current
++ DESCRIPTION
++ "This group defines global controls for RIP-II systems."
++ ::= { rip2Groups 1 }
++rip2IfStatGroup OBJECT-GROUP
++ OBJECTS {
++ rip2IfStatAddress,
++ rip2IfStatRcvBadPackets,
++ rip2IfStatRcvBadRoutes,
++ rip2IfStatSentUpdates,
++ rip2IfStatStatus
++ }
++ STATUS current
++ DESCRIPTION
++ "This group defines interface statistics for RIP-II systems."
++ ::= { rip2Groups 2 }
++rip2IfConfGroup OBJECT-GROUP
++ OBJECTS {
++ rip2IfConfAddress,
++ rip2IfConfAuthType,
++ rip2IfConfAuthKey,
++ rip2IfConfSend,
++ rip2IfConfReceive,
++ rip2IfConfDefaultMetric,
++ rip2IfConfStatus,
++ rip2IfConfSrcAddress
++ }
++ STATUS current
++ DESCRIPTION
++ "This group defines interface configuration for RIP-II systems."
++ ::= { rip2Groups 3 }
++rip2PeerGroup OBJECT-GROUP
++ OBJECTS {
++ rip2PeerAddress,
++ rip2PeerDomain,
++ rip2PeerLastUpdate,
++ rip2PeerVersion,
++ rip2PeerRcvBadPackets,
++ rip2PeerRcvBadRoutes
++ }
++ STATUS current
++ DESCRIPTION
++ "This group defines peer information for RIP-II systems."
++ ::= { rip2Groups 4 }
++END
+diff -ruN net-snmp-5.1.2-orig/mibs/SOURCE-ROUTING-MIB.txt net-snmp-5.1.2-5/mibs/SOURCE-ROUTING-MIB.txt
+--- net-snmp-5.1.2-orig/mibs/SOURCE-ROUTING-MIB.txt 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/mibs/SOURCE-ROUTING-MIB.txt 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,452 @@
++SOURCE-ROUTING-MIB DEFINITIONS ::= BEGIN
++
++IMPORTS
++ Counter, Gauge
++ FROM RFC1155-SMI
++ dot1dBridge, dot1dSr
++ FROM BRIDGE-MIB
++ OBJECT-TYPE
++ FROM RFC-1212;
++
++-- groups in the SR MIB
++
++-- dot1dSr is imported from the Bridge MIB
++
++dot1dPortPair OBJECT IDENTIFIER ::= { dot1dBridge 10 }
++
++-- the dot1dSr group
++
++-- this group is implemented by those bridges that
++-- support the source route bridging mode, including Source
++-- Routing and SRT bridges.
++
++dot1dSrPortTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dSrPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains information about every
++ port that is associated with this source route
++ bridge."
++ ::= { dot1dSr 1 }
++
++dot1dSrPortEntry OBJECT-TYPE
++ SYNTAX Dot1dSrPortEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A list of information for each port of a source
++ route bridge."
++ INDEX { dot1dSrPort }
++
++ ::= { dot1dSrPortTable 1 }
++
++Dot1dSrPortEntry ::=
++ SEQUENCE {
++ dot1dSrPort
++ INTEGER,
++ dot1dSrPortHopCount
++ INTEGER,
++ dot1dSrPortLocalSegment
++ INTEGER,
++ dot1dSrPortBridgeNum
++ INTEGER,
++ dot1dSrPortTargetSegment
++ INTEGER,
++ dot1dSrPortLargestFrame
++ INTEGER,
++ dot1dSrPortSTESpanMode
++ INTEGER,
++ dot1dSrPortSpecInFrames
++ Counter,
++ dot1dSrPortSpecOutFrames
++ Counter,
++ dot1dSrPortApeInFrames
++ Counter,
++ dot1dSrPortApeOutFrames
++ Counter,
++ dot1dSrPortSteInFrames
++ Counter,
++ dot1dSrPortSteOutFrames
++ Counter,
++ dot1dSrPortSegmentMismatchDiscards
++ Counter,
++ dot1dSrPortDuplicateSegmentDiscards
++ Counter,
++ dot1dSrPortHopCountExceededDiscards
++ Counter,
++ dot1dSrPortDupLanIdOrTreeErrors
++ Counter,
++ dot1dSrPortLanIdMismatches
++ Counter
++ }
++
++dot1dSrPort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the port for which this entry
++
++ contains Source Route management information."
++ ::= { dot1dSrPortEntry 1 }
++
++dot1dSrPortHopCount OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The maximum number of routing descriptors allowed
++ in an All Paths or Spanning Tree Explorer frames."
++ ::= { dot1dSrPortEntry 2 }
++
++dot1dSrPortLocalSegment OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The segment number that uniquely identifies the
++ segment to which this port is connected. Current
++ source routing protocols limit this value to the
++ range: 0 through 4095. (The value 0 is used by
++ some management applications for special test
++ cases.) A value of 65535 signifies that no segment
++ number is assigned to this port."
++ ::= { dot1dSrPortEntry 3 }
++
++dot1dSrPortBridgeNum OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "A bridge number uniquely identifies a bridge when
++ more than one bridge is used to span the same two
++ segments. Current source routing protocols limit
++ this value to the range: 0 through 15. A value of
++ 65535 signifies that no bridge number is assigned
++ to this bridge."
++ ::= { dot1dSrPortEntry 4 }
++
++dot1dSrPortTargetSegment OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The segment number that corresponds to the target
++ segment this port is considered to be connected to
++ by the bridge. Current source routing protocols
++ limit this value to the range: 0 through 4095.
++
++ (The value 0 is used by some management
++ applications for special test cases.) A value of
++ 65535 signifies that no target segment is assigned
++ to this port."
++ ::= { dot1dSrPortEntry 5 }
++
++-- It would be nice if we could use ifMtu as the size of the
++-- largest frame, but we can't because ifMtu is defined to be
++-- the size that the (inter-)network layer can use which can
++-- differ from the MAC layer (especially if several layers of
++-- encapsulation are used).
++
++dot1dSrPortLargestFrame OBJECT-TYPE
++ SYNTAX INTEGER
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The maximum size of the INFO field (LLC and
++ above) that this port can send/receive. It does
++ not include any MAC level (framing) octets. The
++ value of this object is used by this bridge to
++ determine whether a modification of the
++ LargestFrame (LF, see [14]) field of the Routing
++ Control field of the Routing Information Field is
++ necessary.
++
++ 64 valid values are defined by the IEEE 802.5M SRT
++ Addendum: 516, 635, 754, 873, 993, 1112, 1231,
++ 1350, 1470, 1542, 1615, 1688, 1761, 1833, 1906,
++ 1979, 2052, 2345, 2638, 2932, 3225, 3518, 3812,
++ 4105, 4399, 4865, 5331, 5798, 6264, 6730, 7197,
++ 7663, 8130, 8539, 8949, 9358, 9768, 10178, 10587,
++ 10997, 11407, 12199, 12992, 13785, 14578, 15370,
++ 16163, 16956, 17749, 20730, 23711, 26693, 29674,
++ 32655, 35637, 38618, 41600, 44591, 47583, 50575,
++ 53567, 56559, 59551, and 65535.
++
++ An illegal value will not be accepted by the
++ bridge."
++ ::= { dot1dSrPortEntry 6 }
++
++dot1dSrPortSTESpanMode OBJECT-TYPE
++ SYNTAX INTEGER {
++ auto-span(1),
++ disabled(2),
++ forced(3)
++ }
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "Determines how this port behaves when presented
++ with a Spanning Tree Explorer frame. The value
++ 'disabled(2)' indicates that the port will not
++ accept or send Spanning Tree Explorer packets; any
++ STE packets received will be silently discarded.
++ The value 'forced(3)' indicates the port will
++ always accept and propagate Spanning Tree Explorer
++ frames. This allows a manually configured
++ Spanning Tree for this class of packet to be
++ configured. Note that unlike transparent
++ bridging, this is not catastrophic to the network
++ if there are loops. The value 'auto-span(1)' can
++ only be returned by a bridge that both implements
++ the Spanning Tree Protocol and has use of the
++ protocol enabled on this port. The behavior of the
++ port for Spanning Tree Explorer frames is
++ determined by the state of dot1dStpPortState. If
++ the port is in the 'forwarding' state, the frame
++ will be accepted or propagated. Otherwise, it
++ will be silently discarded."
++ ::= { dot1dSrPortEntry 7 }
++
++dot1dSrPortSpecInFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of Specifically Routed frames, also
++ referred to as Source Routed Frames, that have
++ been received from this port's segment."
++ ::= { dot1dSrPortEntry 8 }
++
++dot1dSrPortSpecOutFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of Specifically Routed frames, also
++ referred to as Source Routed Frames, that this
++ port has transmitted on its segment."
++ ::= { dot1dSrPortEntry 9 }
++
++dot1dSrPortApeInFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of All Paths Explorer frames, also
++ referred to as All Routes Explorer frames, that
++ have been received by this port from its segment."
++ ::= { dot1dSrPortEntry 10 }
++
++dot1dSrPortApeOutFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of all Paths Explorer Frames, also
++ referred to as All Routes Explorer frames, that
++ have been transmitted by this port on its
++ segment."
++ ::= { dot1dSrPortEntry 11 }
++
++dot1dSrPortSteInFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of spanning tree explorer frames that
++ have been received by this port from its segment."
++ ::= { dot1dSrPortEntry 12 }
++
++dot1dSrPortSteOutFrames OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of spanning tree explorer frames that
++ have been transmitted by this port on its
++ segment."
++ ::= { dot1dSrPortEntry 13 }
++
++dot1dSrPortSegmentMismatchDiscards OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of explorer frames that have been
++ discarded by this port because the routing
++ descriptor field contained an invalid adjacent
++ segment value."
++ ::= { dot1dSrPortEntry 14 }
++
++dot1dSrPortDuplicateSegmentDiscards OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of frames that have been discarded by
++ this port because the routing descriptor field
++ contained a duplicate segment identifier."
++ ::= { dot1dSrPortEntry 15 }
++
++dot1dSrPortHopCountExceededDiscards OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of explorer frames that have been
++ discarded by this port because the Routing
++ Information Field has exceeded the maximum route
++ descriptor length."
++ ::= { dot1dSrPortEntry 16 }
++
++dot1dSrPortDupLanIdOrTreeErrors OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of duplicate LAN IDs or Tree errors.
++ This helps in detection of problems in networks
++ containing older IBM Source Routing Bridges."
++ ::= { dot1dSrPortEntry 17 }
++
++dot1dSrPortLanIdMismatches OBJECT-TYPE
++ SYNTAX Counter
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The number of ARE and STE frames that were
++ discarded because the last LAN ID in the routing
++ information field did not equal the LAN-in ID.
++ This error can occur in implementations which do
++ only a LAN-in ID and Bridge Number check instead
++ of a LAN-in ID, Bridge Number, and LAN-out ID
++ check before they forward broadcast frames."
++ ::= { dot1dSrPortEntry 18 }
++
++-- scalar object in dot1dSr
++
++dot1dSrBridgeLfMode OBJECT-TYPE
++ SYNTAX INTEGER {
++ mode3(1),
++ mode6(2)
++ }
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "Indicates whether the bridge operates using older
++ 3 bit length negotiation fields or the newer 6 bit
++ length field in its RIF."
++ ::= { dot1dSr 2 }
++
++-- The Port-Pair Database
++
++-- Implementation of this group is optional.
++
++-- This group is implemented by those bridges that support
++-- the direct multiport model of the source route bridging
++-- mode as defined in the IEEE 802.5 SRT Addendum to
++-- 802.1d.
++
++-- Bridges implementing this group may report 65535 for
++-- dot1dSrPortBridgeNumber and dot1dSrPortTargetSegment,
++-- indicating that those objects are not applicable.
++
++dot1dPortPairTableSize OBJECT-TYPE
++ SYNTAX Gauge
++ ACCESS read-only
++ STATUS mandatory
++ DESCRIPTION
++ "The total number of entries in the Bridge Port
++ Pair Database."
++ ::= { dot1dPortPair 1 }
++
++-- the Bridge Port-Pair table
++
++-- this table represents port pairs within a bridge forming
++-- a unique bridge path, as defined in the IEEE 802.5M SRT
++-- Addendum.
++
++dot1dPortPairTable OBJECT-TYPE
++ SYNTAX SEQUENCE OF Dot1dPortPairEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A table that contains information about every
++
++ port pair database entity associated with this
++ source routing bridge."
++ ::= { dot1dPortPair 2 }
++
++dot1dPortPairEntry OBJECT-TYPE
++ SYNTAX Dot1dPortPairEntry
++ ACCESS not-accessible
++ STATUS mandatory
++ DESCRIPTION
++ "A list of information for each port pair entity
++ of a bridge."
++ INDEX { dot1dPortPairLowPort, dot1dPortPairHighPort }
++ ::= { dot1dPortPairTable 1 }
++
++Dot1dPortPairEntry ::=
++ SEQUENCE {
++ dot1dPortPairLowPort
++ INTEGER,
++ dot1dPortPairHighPort
++ INTEGER,
++ dot1dPortPairBridgeNum
++ INTEGER,
++ dot1dPortPairBridgeState
++ INTEGER
++ }
++
++dot1dPortPairLowPort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the lower numbered port for
++ which this entry contains port pair database
++ information."
++ ::= { dot1dPortPairEntry 1 }
++
++dot1dPortPairHighPort OBJECT-TYPE
++ SYNTAX INTEGER (1..65535)
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The port number of the higher numbered port for
++ which this entry contains port pair database
++ information."
++ ::= { dot1dPortPairEntry 2 }
++
++dot1dPortPairBridgeNum OBJECT-TYPE
++ SYNTAX INTEGER
++
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "A bridge number that uniquely identifies the path
++ provided by this source routing bridge between the
++ segments connected to dot1dPortPairLowPort and
++ dot1dPortPairHighPort. The purpose of bridge
++ number is to disambiguate between multiple paths
++ connecting the same two LANs."
++ ::= { dot1dPortPairEntry 3 }
++
++dot1dPortPairBridgeState OBJECT-TYPE
++ SYNTAX INTEGER {
++ enabled(1),
++ disabled(2),
++ invalid(3)
++ }
++ ACCESS read-write
++ STATUS mandatory
++ DESCRIPTION
++ "The state of dot1dPortPairBridgeNum. Writing
++ 'invalid(3)' to this object removes the
++ corresponding entry."
++ ::= { dot1dPortPairEntry 4 }
++
++END
+diff -ruN net-snmp-5.1.2-orig/net-snmp-config.in net-snmp-5.1.2-5/net-snmp-config.in
+--- net-snmp-5.1.2-orig/net-snmp-config.in 2004-06-17 15:39:28.000000000 +0200
++++ net-snmp-5.1.2-5/net-snmp-config.in 2005-03-13 16:17:21.000000000 +0100
+@@ -113,13 +113,13 @@
+ #################################################### client lib
+ --libs)
+ # use this one == --netsnmp-libs + --external-libs
+- echo $NSC_LDFLAGS $NSC_LIBDIR -lnetsnmp $NSC_LIBS
++ echo $NSC_LDFLAGS $NSC_LIBDIR -lnetsnmp $NSC_LIBS @WRAPLIBS@
+ ;;
+ --netsnmp-libs)
+ echo $NSC_LIBDIR -lnetsnmp
+ ;;
+ --external-libs)
+- echo $NSC_LDFLAGS $NSC_LIBS
++ echo $NSC_LDFLAGS $NSC_LIBS @WRAPLIBS@
+ ;;
+ #################################################### agent lib
+ --base-agent-libs)
+@@ -130,13 +130,13 @@
+ ;;
+ --agent-libs)
+ # use this one == --netsnmp-agent-libs + --external-libs
+- echo $NSC_LDFLAGS $NSC_LIBDIR $NSC_BASE_AGENT_LIBS $NSC_AGENTLIBS
++ echo $NSC_LDFLAGS $NSC_LIBDIR $NSC_BASE_AGENT_LIBS $NSC_AGENTLIBS @WRAPLIBS@
+ ;;
+ --netsnmp-agent-libs)
+ echo $NSC_LIBDIR $NSC_BASE_AGENT_LIBS
+ ;;
+ --external-agent-libs)
+- echo $NSC_LDFLAGS $NSC_AGENTLIBS
++ echo $NSC_LDFLAGS $NSC_AGENTLIBS @WRAPLIBS@
+ ;;
+ ####################################################
+ --version)
+@@ -409,7 +409,7 @@
+ echo "Ack. Can't create $tmpfile."
+ exit 1
+ fi
+- cmd="@CC@ $cflags @CFLAGS@ @DEVFLAGS@ -I. -I@includedir@ -o $outname $tmpfile $cfiles $NSC_LDFLAGS -L$NSC_EXEC_PREFIX/lib -lnetsnmpagent -lnetsnmphelpers -lnetsnmpmibs -lnetsnmp $NSC_AGENTLIBS $ldflags"
++ cmd="@CC@ $cflags @CFLAGS@ @DEVFLAGS@ -I. -I@includedir@ -o $outname $tmpfile $cfiles $NSC_LDFLAGS -L$NSC_EXEC_PREFIX/lib -lnetsnmpagent -lnetsnmphelpers -lnetsnmpmibs -lnetsnmp $NSC_AGENTLIBS @WRAPLIBS@ $ldflags"
+ echo "running: $cmd"
+ `$cmd`
+ if test "x$norm" != "x1" ; then
+diff -ruN net-snmp-5.1.2-orig/perl/agent/netsnmp_request_infoPtr.pm net-snmp-5.1.2-5/perl/agent/netsnmp_request_infoPtr.pm
+--- net-snmp-5.1.2-orig/perl/agent/netsnmp_request_infoPtr.pm 2002-09-19 22:38:24.000000000 +0200
++++ net-snmp-5.1.2-5/perl/agent/netsnmp_request_infoPtr.pm 2005-03-13 16:17:21.000000000 +0100
+@@ -4,6 +4,7 @@
+
+ 1;
+ __END__
++
+ =head1 NAME
+
+ NetSNMP::agent::netsnmp_request_infoPtr - Perl extension for request information
+diff -ruN net-snmp-5.1.2-orig/snmplib/Makefile.in net-snmp-5.1.2-5/snmplib/Makefile.in
+--- net-snmp-5.1.2-orig/snmplib/Makefile.in 2004-03-04 14:41:19.000000000 +0100
++++ net-snmp-5.1.2-5/snmplib/Makefile.in 2005-03-13 16:17:21.000000000 +0100
+@@ -178,11 +178,11 @@
+
+ # how to build the libraries.
+ libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION): ${TOBJS}
+- $(LIB_LD_CMD) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS}
++ $(LIB_LD_CMD) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS} @CRYPTOLIBS@
+ $(RANLIB) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION)
+
+ libsnmp.$(LIB_EXTENSION)$(LIB_VERSION): ${TOBJS}
+- $(LIB_LD_CMD) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS}
++ $(LIB_LD_CMD) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS} @CRYPTOLIBS@
+ $(RANLIB) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION)
+
+ #
+diff -ruN net-snmp-5.1.2-orig/snmplib/snmpUDPDomain.c net-snmp-5.1.2-5/snmplib/snmpUDPDomain.c
+--- net-snmp-5.1.2-orig/snmplib/snmpUDPDomain.c 2004-07-07 14:21:32.000000000 +0200
++++ net-snmp-5.1.2-5/snmplib/snmpUDPDomain.c 2005-03-13 16:17:21.000000000 +0100
+@@ -233,18 +233,6 @@
+ netsnmp_transport_free(t);
+ return NULL;
+ }
+-#ifdef SO_BSDCOMPAT
+- /*
+- * Patch for Linux. Without this, UDP packets that fail get an ICMP
+- * response. Linux turns the failed ICMP response into an error message
+- * and return value, unlike all other OS's.
+- */
+- {
+- int one = 1;
+- setsockopt(t->sock, SOL_SOCKET, SO_BSDCOMPAT, (void *) &one,
+- sizeof(one));
+- }
+-#endif /*SO_BSDCOMPAT */
+ /*
+ * SO_REUSEADDR will allow multiple apps to open the same port at
+ * the same time. Only the last one to open the socket will get
+diff -ruN net-snmp-5.1.2-orig/snmplib/snmpUDPIPv6Domain.c net-snmp-5.1.2-5/snmplib/snmpUDPIPv6Domain.c
+--- net-snmp-5.1.2-orig/snmplib/snmpUDPIPv6Domain.c 2004-07-22 19:45:00.000000000 +0200
++++ net-snmp-5.1.2-5/snmplib/snmpUDPIPv6Domain.c 2005-03-13 16:17:21.000000000 +0100
+@@ -249,17 +249,6 @@
+ netsnmp_transport_free(t);
+ return NULL;
+ }
+-#ifdef SO_BSDCOMPAT
+- /*
+- * Patch for Linux. Without this, UDP packets that fail get an ICMP
+- * response. Linux turns the failed ICMP response into an error message
+- * and return value, unlike all other OS's.
+- */
+- {
+- int one = 1;
+- setsockopt(t->sock, SOL_SOCKET, SO_BSDCOMPAT, &one, sizeof(one));
+- }
+-#endif /*SO_BSDCOMPAT */
+
+ /*
+ * Try to set the send and receive buffers to a reasonably large value, so
+diff -ruN net-snmp-5.1.2-orig/snmplib/snmp_logging.c net-snmp-5.1.2-5/snmplib/snmp_logging.c
+--- net-snmp-5.1.2-orig/snmplib/snmp_logging.c 2004-03-31 03:06:08.000000000 +0200
++++ net-snmp-5.1.2-5/snmplib/snmp_logging.c 2005-03-13 16:17:21.000000000 +0100
+@@ -860,13 +860,14 @@
+ } else {
+ strcpy(sbuf, "");
+ }
+- newline = string[strlen(string) - 1] == '\n'; /* XXX - Eh ? */
+
+ if (logh->imagic)
+ printf( "%s%s", sbuf, string);
+ else
+ fprintf(stderr, "%s%s", sbuf, string);
+
++ newline = string[strlen(string) - 1] == '\n'; /* XXX - Eh ? */
++
+ return 1;
+ }
+
+diff -ruN net-snmp-5.1.2-orig/snmplib/winservice.mc net-snmp-5.1.2-5/snmplib/winservice.mc
+--- net-snmp-5.1.2-orig/snmplib/winservice.mc 2002-04-20 09:30:21.000000000 +0200
++++ net-snmp-5.1.2-5/snmplib/winservice.mc 2005-03-13 16:17:21.000000000 +0100
+@@ -1,11 +1,11 @@
+-;//Message catalog for Windows Serivce Support routines
+-;//To support event logging functionality
+-;//By Raju Krishnappa(raju_krishnappa@yahoo.com)
+-
+-;//Message ID descriptions
+-
+-MessageId=100
+-SymbolicName=DISPLAY_MSG
+-Language=English
+-%1.
+-.
++;//Message catalog for Windows Serivce Support routines
++;//To support event logging functionality
++;//By Raju Krishnappa(raju_krishnappa@yahoo.com)
++
++;//Message ID descriptions
++
++MessageId=100
++SymbolicName=DISPLAY_MSG
++Language=English
++%1.
++.
+diff -ruN net-snmp-5.1.2-orig/snmplib/winservice.rc net-snmp-5.1.2-5/snmplib/winservice.rc
+--- net-snmp-5.1.2-orig/snmplib/winservice.rc 2002-04-20 09:30:21.000000000 +0200
++++ net-snmp-5.1.2-5/snmplib/winservice.rc 2005-03-13 16:17:21.000000000 +0100
+@@ -1,2 +1,2 @@
+-LANGUAGE 0x9,0x1
+-1 11 MSG00001.bin
++LANGUAGE 0x9,0x1
++1 11 MSG00001.bin
diff --git a/package/net-snmp/patches/750-ieee802dot11.patch b/package/net-snmp/patches/750-ieee802dot11.patch
new file mode 100644
index 0000000000..8939a44f23
--- /dev/null
+++ b/package/net-snmp/patches/750-ieee802dot11.patch
@@ -0,0 +1,6156 @@
+--- net-snmp-5.1.2-orig/agent/mibgroup/ieee802dot11.c 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/agent/mibgroup/ieee802dot11.c 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,4915 @@
++/****************************************************************************
++* *
++* File Name: ieee802dot11.c *
++* Used By: *
++* *
++* Operating System: *
++* Purpose: *
++* *
++* Comments: *
++* *
++* Author: Larry Simmons *
++* lsimmons@avantcom.com *
++* www.avantcom.com *
++* *
++* Creation Date: 09/02/03 *
++* *
++* Ver Date Inits Modification *
++* ----- -------- ----- ------------ *
++* 0.0.1 09/02/03 LRS created *
++* 0.0.2 09/24/03 LRS wouldn't build after fresh ./configure *
++****************************************************************************/
++/****************************************************************************
++* Includes *
++****************************************************************************/
++#include <net-snmp/net-snmp-config.h>
++#include <net-snmp/net-snmp-includes.h>
++#include <net-snmp/agent/net-snmp-agent-includes.h>
++#include "ieee802dot11.h"
++#include "iwlib.h"
++
++/****************************************************************************
++* Defines *
++****************************************************************************/
++#define DISPLAYWIEXT // display wireless ext info
++#define TABLE_SIZE 1
++//#define MINLOADFREQ 15 // min reload frequency in seconds
++#define MINLOADFREQ 5 // min reload frequency in seconds // for testing
++#define PROC_NET_DEV "/proc/net/dev"
++#define PROC_NET_WIRELESS "/proc/net/wireless"
++
++#ifndef UCHAR
++ typedef unsigned char UCHAR;
++#endif
++
++/****************************************************************************
++* Private Functions *
++****************************************************************************/
++static void loadTables();
++static void loadWiExt ( int, char *, struct wireless_info * );
++static void load80211Structs ( int, char *, struct wireless_info * );
++static void initStructs();
++
++// Wireless Extensions Specific Functions
++static void loadWiExtTo80211Structs ( int, char *, struct wireless_info * );
++static void displayWiExt ( struct wireless_info );
++
++// Linked List Functions
++static void addList ( char *, char *, int );
++static void initLists(); // initialize all the linked lists
++static void flushLists(); // flush all the linked lists
++static void flushList ( char * ); // flush a single linked list
++
++// Utility Functions
++static int openSocket ( void );
++static int mWatt2dbm ( int );
++static char *htob ( char * );
++static int hasChanged ( char *, int );
++
++/****************************************************************************
++* Private Variables *
++****************************************************************************/
++static unsigned long lastLoad = 0; // ET in secs at last table load
++
++static struct avNode *lastNode, *newNode, *np;
++
++/****************************************************************************
++* External Functions *
++****************************************************************************/
++
++/****************************************************************************
++* ieee802dot11_variables_oid: *
++* this is the top level oid that we want to register under. This *
++* is essentially a prefix, with the suffix appearing in the *
++* variable below. *
++****************************************************************************/
++oid ieee802dot11_variables_oid[] = { 1,2,840,10036 };
++
++/****************************************************************************
++* variable7 ieee802dot11_variables: *
++* this variable defines function callbacks and type return information *
++* for the ieee802dot11 mib section *
++****************************************************************************/
++struct variable7 ieee802dot11_variables[] = {
++/* magic number , variable type , ro/rw , callback fn , L, oidsuffix */
++#define DOT11STATIONID 3
++ { DOT11STATIONID , ASN_OCTET_STR , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,1 } },
++#define DOT11MEDIUMOCCUPANCYLIMIT 4
++ { DOT11MEDIUMOCCUPANCYLIMIT, ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,2 } },
++#define DOT11CFPOLLABLE 5
++ { DOT11CFPOLLABLE , ASN_INTEGER , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,3 } },
++#define DOT11CFPPERIOD 6
++ { DOT11CFPPERIOD , ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,4 } },
++#define DOT11CFPMAXDURATION 7
++ { DOT11CFPMAXDURATION , ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,5 } },
++#define DOT11AUTHENTICATIONRESPONSETIMEOUT 8
++ { DOT11AUTHENTICATIONRESPONSETIMEOUT, ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,6 } },
++#define DOT11PRIVACYOPTIONIMPLEMENTED 9
++ { DOT11PRIVACYOPTIONIMPLEMENTED, ASN_INTEGER , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,7 } },
++#define DOT11POWERMANAGEMENTMODE 10
++ { DOT11POWERMANAGEMENTMODE, ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,8 } },
++#define DOT11DESIREDSSID 11
++ { DOT11DESIREDSSID , ASN_OCTET_STR , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,9 } },
++#define DOT11DESIREDBSSTYPE 12
++ { DOT11DESIREDBSSTYPE , ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,10 } },
++#define DOT11OPERATIONALRATESET 13
++ { DOT11OPERATIONALRATESET, ASN_OCTET_STR , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,11 } },
++#define DOT11BEACONPERIOD 14
++ { DOT11BEACONPERIOD , ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,12 } },
++#define DOT11DTIMPERIOD 15
++ { DOT11DTIMPERIOD , ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,13 } },
++#define DOT11ASSOCIATIONRESPONSETIMEOUT 16
++ { DOT11ASSOCIATIONRESPONSETIMEOUT, ASN_INTEGER , RWRITE, var_dot11StationConfigTable, 4, { 1,1,1,14 } },
++#define DOT11DISASSOCIATEREASON 17
++ { DOT11DISASSOCIATEREASON, ASN_INTEGER , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,15 } },
++#define DOT11DISASSOCIATESTATION 18
++ { DOT11DISASSOCIATESTATION, ASN_OCTET_STR , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,16 } },
++#define DOT11DEAUTHENTICATEREASON 19
++ { DOT11DEAUTHENTICATEREASON, ASN_INTEGER , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,17 } },
++#define DOT11DEAUTHENTICATESTATION 20
++ { DOT11DEAUTHENTICATESTATION, ASN_OCTET_STR , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,18 } },
++#define DOT11AUTHENTICATEFAILSTATUS 21
++ { DOT11AUTHENTICATEFAILSTATUS, ASN_INTEGER , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,19 } },
++#define DOT11AUTHENTICATEFAILSTATION 22
++ { DOT11AUTHENTICATEFAILSTATION, ASN_OCTET_STR , RONLY , var_dot11StationConfigTable, 4, { 1,1,1,20 } },
++
++#define DOT11AUTHENTICATIONALGORITHM 26
++ { DOT11AUTHENTICATIONALGORITHM, ASN_INTEGER , RONLY , var_dot11AuthenticationAlgorithmsTable, 4, { 1,2,1,2 } },
++#define DOT11AUTHENTICATIONALGORITHMSENABLE 27
++ { DOT11AUTHENTICATIONALGORITHMSENABLE, ASN_INTEGER , RWRITE, var_dot11AuthenticationAlgorithmsTable, 4, { 1,2,1,3 } },
++
++#define DOT11WEPDEFAULTKEYVALUE 31
++ { DOT11WEPDEFAULTKEYVALUE, ASN_OCTET_STR , RWRITE, var_dot11WEPDefaultKeysTable, 4, { 1,3,1,2 } },
++
++#define DOT11WEPKEYMAPPINGADDRESS 35
++ { DOT11WEPKEYMAPPINGADDRESS, ASN_OCTET_STR , RWRITE, var_dot11WEPKeyMappingsTable, 4, { 1,4,1,2 } },
++#define DOT11WEPKEYMAPPINGWEPON 36
++ { DOT11WEPKEYMAPPINGWEPON, ASN_INTEGER , RWRITE, var_dot11WEPKeyMappingsTable, 4, { 1,4,1,3 } },
++#define DOT11WEPKEYMAPPINGVALUE 37
++ { DOT11WEPKEYMAPPINGVALUE, ASN_OCTET_STR , RWRITE, var_dot11WEPKeyMappingsTable, 4, { 1,4,1,4 } },
++#define DOT11WEPKEYMAPPINGSTATUS 38
++ { DOT11WEPKEYMAPPINGSTATUS, ASN_INTEGER , RWRITE, var_dot11WEPKeyMappingsTable, 4, { 1,4,1,5 } },
++
++#define DOT11PRIVACYINVOKED 41
++ { DOT11PRIVACYINVOKED , ASN_INTEGER , RWRITE, var_dot11PrivacyTable, 4, { 1,5,1,1 } },
++#define DOT11WEPDEFAULTKEYID 42
++ { DOT11WEPDEFAULTKEYID, ASN_INTEGER , RWRITE, var_dot11PrivacyTable, 4, { 1,5,1,2 } },
++#define DOT11WEPKEYMAPPINGLENGTH 43
++ { DOT11WEPKEYMAPPINGLENGTH, ASN_INTEGER , RWRITE, var_dot11PrivacyTable, 4, { 1,5,1,3 } },
++#define DOT11EXCLUDEUNENCRYPTED 44
++ { DOT11EXCLUDEUNENCRYPTED, ASN_INTEGER , RWRITE, var_dot11PrivacyTable, 4, { 1,5,1,4 } },
++#define DOT11WEPICVERRORCOUNT 45
++ { DOT11WEPICVERRORCOUNT, ASN_COUNTER , RONLY , var_dot11PrivacyTable, 4, { 1,5,1,5 } },
++#define DOT11WEPEXCLUDEDCOUNT 46
++ { DOT11WEPEXCLUDEDCOUNT, ASN_COUNTER , RONLY , var_dot11PrivacyTable, 4, { 1,5,1,6 } },
++
++#define DOT11MACADDRESS 49
++ { DOT11MACADDRESS , ASN_OCTET_STR , RONLY , var_dot11OperationTable, 4, { 2,1,1,1 } },
++#define DOT11RTSTHRESHOLD 50
++ { DOT11RTSTHRESHOLD , ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,2 } },
++#define DOT11SHORTRETRYLIMIT 51
++ { DOT11SHORTRETRYLIMIT, ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,3 } },
++#define DOT11LONGRETRYLIMIT 52
++ { DOT11LONGRETRYLIMIT , ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,4 } },
++#define DOT11FRAGMENTATIONTHRESHOLD 53
++ { DOT11FRAGMENTATIONTHRESHOLD, ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,5 } },
++#define DOT11MAXTRANSMITMSDULIFETIME 54
++ { DOT11MAXTRANSMITMSDULIFETIME, ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,6 } },
++#define DOT11MAXRECEIVELIFETIME 55
++ { DOT11MAXRECEIVELIFETIME, ASN_INTEGER , RWRITE, var_dot11OperationTable, 4, { 2,1,1,7 } },
++#define DOT11MANUFACTURERID 56
++ { DOT11MANUFACTURERID , ASN_OCTET_STR , RONLY , var_dot11OperationTable, 4, { 2,1,1,8 } },
++#define DOT11PRODUCTID 57
++ { DOT11PRODUCTID , ASN_OCTET_STR , RONLY , var_dot11OperationTable, 4, { 2,1,1,9 } },
++
++#define DOT11TRANSMITTEDFRAGMENTCOUNT 60
++ { DOT11TRANSMITTEDFRAGMENTCOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,1 } },
++#define DOT11MULTICASTTRANSMITTEDFRAMECOUNT 61
++ { DOT11MULTICASTTRANSMITTEDFRAMECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,2 } },
++#define DOT11FAILEDCOUNT 62
++ { DOT11FAILEDCOUNT , ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,3 } },
++#define DOT11RETRYCOUNT 63
++ { DOT11RETRYCOUNT , ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,4 } },
++#define DOT11MULTIPLERETRYCOUNT 64
++ { DOT11MULTIPLERETRYCOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,5 } },
++#define DOT11FRAMEDUPLICATECOUNT 65
++ { DOT11FRAMEDUPLICATECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,6 } },
++#define DOT11RTSSUCCESSCOUNT 66
++ { DOT11RTSSUCCESSCOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,7 } },
++#define DOT11RTSFAILURECOUNT 67
++ { DOT11RTSFAILURECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,8 } },
++#define DOT11ACKFAILURECOUNT 68
++ { DOT11ACKFAILURECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,9 } },
++#define DOT11RECEIVEDFRAGMENTCOUNT 69
++ { DOT11RECEIVEDFRAGMENTCOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,10 } },
++#define DOT11MULTICASTRECEIVEDFRAMECOUNT 70
++ { DOT11MULTICASTRECEIVEDFRAMECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,11 } },
++#define DOT11FCSERRORCOUNT 71
++ { DOT11FCSERRORCOUNT , ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,12 } },
++#define DOT11TRANSMITTEDFRAMECOUNT 72
++ { DOT11TRANSMITTEDFRAMECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,13 } },
++#define DOT11WEPUNDECRYPTABLECOUNT 73
++ { DOT11WEPUNDECRYPTABLECOUNT, ASN_COUNTER , RONLY , var_dot11CountersTable, 4, { 2,2,1,14 } },
++
++#define DOT11ADDRESS 77
++ { DOT11ADDRESS , ASN_OCTET_STR , RWRITE, var_dot11GroupAddressesTable, 4, { 2,3,1,2 } },
++#define DOT11GROUPADDRESSESSTATUS 78
++ { DOT11GROUPADDRESSESSTATUS, ASN_INTEGER , RWRITE, var_dot11GroupAddressesTable, 4, { 2,3,1,3 } },
++
++#define DOT11RESOURCETYPEIDNAME 79
++ { DOT11RESOURCETYPEIDNAME, ASN_OCTET_STR , RONLY , var_ieee802dot11, 3, { 3,1,1 } },
++#define DOT11MANUFACTUREROUI 82
++ { DOT11MANUFACTUREROUI, ASN_OCTET_STR , RONLY , var_dot11ResourceInfoTable, 5, { 3,1,2,1,1 } },
++#define DOT11MANUFACTURERNAME 83
++ { DOT11MANUFACTURERNAME, ASN_OCTET_STR , RONLY , var_dot11ResourceInfoTable, 5, { 3,1,2,1,2 } },
++#define DOT11MANUFACTURERPRODUCTNAME 84
++ { DOT11MANUFACTURERPRODUCTNAME, ASN_OCTET_STR , RONLY , var_dot11ResourceInfoTable, 5, { 3,1,2,1,3 } },
++#define DOT11MANUFACTURERPRODUCTVERSION 85
++ { DOT11MANUFACTURERPRODUCTVERSION, ASN_OCTET_STR , RONLY , var_dot11ResourceInfoTable, 5, { 3,1,2,1,4 } },
++
++#define DOT11PHYTYPE 88
++ { DOT11PHYTYPE , ASN_INTEGER , RONLY , var_dot11PhyOperationTable, 4, { 4,1,1,1 } },
++#define DOT11CURRENTREGDOMAIN 89
++ { DOT11CURRENTREGDOMAIN, ASN_INTEGER , RWRITE, var_dot11PhyOperationTable, 4, { 4,1,1,2 } },
++#define DOT11TEMPTYPE 90
++ { DOT11TEMPTYPE , ASN_INTEGER , RONLY , var_dot11PhyOperationTable, 4, { 4,1,1,3 } },
++#define DOT11CURRENTTXANTENNA 93
++ { DOT11CURRENTTXANTENNA, ASN_INTEGER , RWRITE, var_dot11PhyAntennaTable, 4, { 4,2,1,1 } },
++#define DOT11DIVERSITYSUPPORT 94
++ { DOT11DIVERSITYSUPPORT, ASN_INTEGER , RONLY , var_dot11PhyAntennaTable, 4, { 4,2,1,2 } },
++#define DOT11CURRENTRXANTENNA 95
++ { DOT11CURRENTRXANTENNA, ASN_INTEGER , RWRITE, var_dot11PhyAntennaTable, 4, { 4,2,1,3 } },
++#define DOT11NUMBERSUPPORTEDPOWERLEVELS 98
++ { DOT11NUMBERSUPPORTEDPOWERLEVELS, ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,1 } },
++#define DOT11TXPOWERLEVEL1 99
++ { DOT11TXPOWERLEVEL1 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,2 } },
++#define DOT11TXPOWERLEVEL2 100
++ { DOT11TXPOWERLEVEL2 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,3 } },
++#define DOT11TXPOWERLEVEL3 101
++ { DOT11TXPOWERLEVEL3 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,4 } },
++#define DOT11TXPOWERLEVEL4 102
++ { DOT11TXPOWERLEVEL4 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,5 } },
++#define DOT11TXPOWERLEVEL5 103
++ { DOT11TXPOWERLEVEL5 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,6 } },
++#define DOT11TXPOWERLEVEL6 104
++ { DOT11TXPOWERLEVEL6 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,7 } },
++#define DOT11TXPOWERLEVEL7 105
++ { DOT11TXPOWERLEVEL7 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,8 } },
++#define DOT11TXPOWERLEVEL8 106
++ { DOT11TXPOWERLEVEL8 , ASN_INTEGER , RONLY , var_dot11PhyTxPowerTable, 4, { 4,3,1,9 } },
++#define DOT11CURRENTTXPOWERLEVEL 107
++ { DOT11CURRENTTXPOWERLEVEL, ASN_INTEGER , RWRITE, var_dot11PhyTxPowerTable, 4, { 4,3,1,10 } },
++
++#define DOT11HOPTIME 110
++ { DOT11HOPTIME , ASN_INTEGER , RONLY , var_dot11PhyFHSSTable, 4, { 4,4,1,1 } },
++#define DOT11CURRENTCHANNELNUMBER 111
++ { DOT11CURRENTCHANNELNUMBER, ASN_INTEGER , RWRITE, var_dot11PhyFHSSTable, 4, { 4,4,1,2 } },
++#define DOT11MAXDWELLTIME 112
++ { DOT11MAXDWELLTIME , ASN_INTEGER , RONLY , var_dot11PhyFHSSTable, 4, { 4,4,1,3 } },
++#define DOT11CURRENTDWELLTIME 113
++ { DOT11CURRENTDWELLTIME, ASN_INTEGER , RWRITE, var_dot11PhyFHSSTable, 4, { 4,4,1,4 } },
++#define DOT11CURRENTSET 114
++ { DOT11CURRENTSET , ASN_INTEGER , RWRITE, var_dot11PhyFHSSTable, 4, { 4,4,1,5 } },
++#define DOT11CURRENTPATTERN 115
++ { DOT11CURRENTPATTERN , ASN_INTEGER , RWRITE, var_dot11PhyFHSSTable, 4, { 4,4,1,6 } },
++#define DOT11CURRENTINDEX 116
++ { DOT11CURRENTINDEX , ASN_INTEGER , RWRITE, var_dot11PhyFHSSTable, 4, { 4,4,1,7 } },
++
++#define DOT11CURRENTCHANNEL 119
++ { DOT11CURRENTCHANNEL , ASN_INTEGER , RWRITE, var_dot11PhyDSSSTable, 4, { 4,5,1,1 } },
++#define DOT11CCAMODESUPPORTED 120
++ { DOT11CCAMODESUPPORTED, ASN_INTEGER , RONLY , var_dot11PhyDSSSTable, 4, { 4,5,1,2 } },
++#define DOT11CURRENTCCAMODE 121
++ { DOT11CURRENTCCAMODE , ASN_INTEGER , RWRITE, var_dot11PhyDSSSTable, 4, { 4,5,1,3 } },
++#define DOT11EDTHRESHOLD 122
++ { DOT11EDTHRESHOLD , ASN_INTEGER , RWRITE, var_dot11PhyDSSSTable, 4, { 4,5,1,4 } },
++
++#define DOT11CCAWATCHDOGTIMERMAX 125
++ { DOT11CCAWATCHDOGTIMERMAX, ASN_INTEGER , RWRITE, var_dot11PhyIRTable, 4, { 4,6,1,1 } },
++#define DOT11CCAWATCHDOGCOUNTMAX 126
++ { DOT11CCAWATCHDOGCOUNTMAX, ASN_INTEGER , RWRITE, var_dot11PhyIRTable, 4, { 4,6,1,2 } },
++#define DOT11CCAWATCHDOGTIMERMIN 127
++ { DOT11CCAWATCHDOGTIMERMIN, ASN_INTEGER , RWRITE, var_dot11PhyIRTable, 4, { 4,6,1,3 } },
++#define DOT11CCAWATCHDOGCOUNTMIN 128
++ { DOT11CCAWATCHDOGCOUNTMIN, ASN_INTEGER , RWRITE, var_dot11PhyIRTable, 4, { 4,6,1,4 } },
++
++#define DOT11REGDOMAINSSUPPORTVALUE 132
++ { DOT11REGDOMAINSSUPPORTVALUE, ASN_INTEGER , RONLY , var_dot11RegDomainsSupportedTable, 4, { 4,7,1,2 } },
++
++#define DOT11SUPPORTEDTXANTENNA 136
++ { DOT11SUPPORTEDTXANTENNA, ASN_INTEGER , RWRITE, var_dot11AntennasListTable, 4, { 4,8,1,2 } },
++#define DOT11SUPPORTEDRXANTENNA 137
++ { DOT11SUPPORTEDRXANTENNA, ASN_INTEGER , RWRITE, var_dot11AntennasListTable, 4, { 4,8,1,3 } },
++#define DOT11DIVERSITYSELECTIONRX 138
++ { DOT11DIVERSITYSELECTIONRX, ASN_INTEGER , RWRITE, var_dot11AntennasListTable, 4, { 4,8,1,4 } },
++
++#define DOT11SUPPORTEDDATARATESTXVALUE 142
++ { DOT11SUPPORTEDDATARATESTXVALUE, ASN_INTEGER , RONLY , var_dot11SupportedDataRatesTxTable, 4, { 4,9,1,2 } },
++
++#define DOT11SUPPORTEDDATARATESRXVALUE 146
++ { DOT11SUPPORTEDDATARATESRXVALUE, ASN_INTEGER , RONLY , var_dot11SupportedDataRatesRxTable, 4, { 4,10,1,2 } },
++};
++// ( L = length of the oidsuffix )
++
++/****************************************************************************
++* *
++* init_ieee802dot11() - perform any required initialization *
++* *
++****************************************************************************/
++void init_ieee802dot11 ( void ) {
++
++ /* register ourselves with the agent to handle our mib tree */
++ REGISTER_MIB("ieee802dot11", ieee802dot11_variables, variable7,
++ ieee802dot11_variables_oid);
++
++ initLists();
++}
++
++/****************************************************************************
++* *
++* shutdown_ieee802dot11() - perform any required cleanup @ shutdown *
++* *
++****************************************************************************/
++void shutdown_ieee802dot11 ( void )
++{
++ flushLists();
++}
++
++/****************************************************************************
++* *
++* var_ieee802dot11() - *
++* *
++****************************************************************************/
++unsigned char *
++var_ieee802dot11 ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ loadTables();
++
++ if ( header_generic ( vp, name, length, exact,var_len,write_method )
++ == MATCH_FAILED )
++ return NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11RESOURCETYPEIDNAME:
++ if ( !haveResourceTypeIDName )
++ return NULL;
++ *var_len = strlen ( resourceTypeIDName );
++ return ( UCHAR * ) resourceTypeIDName;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11StationConfigTable() - return a variable value from the table *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11StationConfigTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++ static char MACWork[17];
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &scList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ sc = ( struct scTbl_data * ) np->data;
++ rName[vp->namelen] = sc->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++
++ switch ( vp->magic ) { // found requested OID, now check for requested variable
++ case DOT11STATIONID:
++ if ( sc->haveStationID ) found = TRUE; break;
++ case DOT11MEDIUMOCCUPANCYLIMIT:
++ if ( sc->haveMediumOccupancyLimit ) found = TRUE; break;
++ case DOT11CFPOLLABLE:
++ if ( sc->haveCFPPollable ) found = TRUE; break;
++ case DOT11CFPPERIOD:
++ if ( sc->haveCFPPeriod ) found = TRUE; break;
++ case DOT11CFPMAXDURATION:
++ if ( sc->haveMaxDuration ) found = TRUE; break;
++ case DOT11AUTHENTICATIONRESPONSETIMEOUT:
++ if ( sc->haveAuthenticationResponseTimeOut ) found = TRUE; break;
++ case DOT11PRIVACYOPTIONIMPLEMENTED:
++ if ( sc->havePrivacyOptionImplemented ) found = TRUE; break;
++ case DOT11POWERMANAGEMENTMODE:
++ if ( sc->havePowerManagementMode ) found = TRUE; break;
++ case DOT11DESIREDSSID:
++ if ( sc->haveDesiredSSID ) found = TRUE; break;
++ case DOT11DESIREDBSSTYPE:
++ if ( sc->haveDesiredBSSType ) found = TRUE; break;
++ case DOT11OPERATIONALRATESET:
++ if ( sc->haveOperationalRateSet ) found = TRUE; break;
++ case DOT11BEACONPERIOD:
++ if ( sc->haveBeaconPeriod ) found = TRUE; break;
++ case DOT11DTIMPERIOD:
++ if ( sc->haveDTIMPeriod ) found = TRUE; break;
++ case DOT11ASSOCIATIONRESPONSETIMEOUT:
++ if ( sc->haveAssociationResponseTimeOut ) found = TRUE; break;
++ case DOT11DISASSOCIATEREASON:
++ if ( sc->disAssociationReason ) found = TRUE; break;
++ case DOT11DISASSOCIATESTATION:
++ if ( sc->haveDisAssociationStation ) found = TRUE; break;
++ case DOT11DEAUTHENTICATEREASON:
++ if ( sc->deAuthenticationReason ) found = TRUE; break;
++ case DOT11DEAUTHENTICATESTATION:
++ if ( sc->haveDeAuthenticationStation ) found = TRUE; break;
++ case DOT11AUTHENTICATEFAILSTATUS:
++ if ( sc->authenticateFailStatus ) found = TRUE; break;
++ case DOT11AUTHENTICATEFAILSTATION:
++ if ( sc->haveAuthenticateFailStation ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11STATIONID:
++// *write_method = write_dot11StationID;
++ MACWork[ 0] = sc->stationID [ 0];
++ MACWork[ 1] = sc->stationID [ 1];
++ MACWork[ 2] = sc->stationID [ 3];
++ MACWork[ 3] = sc->stationID [ 4];
++ MACWork[ 4] = sc->stationID [ 6];
++ MACWork[ 5] = sc->stationID [ 7];
++ MACWork[ 6] = sc->stationID [ 9];
++ MACWork[ 7] = sc->stationID [10];
++ MACWork[ 8] = sc->stationID [12];
++ MACWork[ 9] = sc->stationID [13];
++ MACWork[10] = sc->stationID [15];
++ MACWork[11] = sc->stationID [16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11MEDIUMOCCUPANCYLIMIT:
++// *write_method = write_dot11MediumOccupancyLimit;
++ sc->mediumOccupancyLimit = 5;
++ return ( UCHAR * ) &sc->mediumOccupancyLimit;
++
++ case DOT11CFPOLLABLE:
++ return ( UCHAR * ) &sc->CFPPollable;
++
++ case DOT11CFPPERIOD:
++// *write_method = write_dot11CFPPeriod;
++ return ( UCHAR * ) &sc->CFPPeriod;
++
++ case DOT11CFPMAXDURATION:
++// *write_method = write_dot11CFPMaxDuration;
++ return ( UCHAR * ) &sc->maxDuration;
++
++ case DOT11AUTHENTICATIONRESPONSETIMEOUT:
++// *write_method = write_dot11AuthenticationResponseTimeOut;
++ return ( UCHAR * ) &sc->authenticationResponseTimeOut;
++
++ case DOT11PRIVACYOPTIONIMPLEMENTED:
++ return ( UCHAR * ) &sc->privacyOptionImplemented;
++
++ case DOT11POWERMANAGEMENTMODE:
++// *write_method = write_dot11PowerManagementMode;
++ return ( UCHAR * ) &sc->powerManagementMode;
++
++ case DOT11DESIREDSSID:
++// *write_method = write_dot11DesiredSSID;
++ *var_len = strlen ( sc->desiredSSID );
++ return ( UCHAR * ) sc->desiredSSID;
++
++ case DOT11DESIREDBSSTYPE:
++// *write_method = write_dot11DesiredBSSType;
++ return ( UCHAR * ) &sc->desiredBSSType;
++
++ case DOT11OPERATIONALRATESET:
++// *write_method = write_dot11OperationalRateSet;
++ *var_len = strlen ( sc->operationalRateSet );
++ return ( UCHAR * ) sc->operationalRateSet;
++
++ case DOT11BEACONPERIOD:
++// *write_method = write_dot11BeaconPeriod;
++ return ( UCHAR * ) &sc->beaconPeriod;
++
++ case DOT11DTIMPERIOD:
++// *write_method = write_dot11DTIMPeriod;
++ return ( UCHAR * ) &sc->DTIMPeriod;
++
++ case DOT11ASSOCIATIONRESPONSETIMEOUT:
++// *write_method = write_dot11AssociationResponseTimeOut;
++ return ( UCHAR * ) &sc->associationResponseTimeOut;
++
++ case DOT11DISASSOCIATEREASON:
++ return ( UCHAR * ) &sc->disAssociationReason;
++
++ case DOT11DISASSOCIATESTATION:
++ MACWork[ 0] = sc->disAssociationStation[ 0];
++ MACWork[ 1] = sc->disAssociationStation[ 1];
++ MACWork[ 2] = sc->disAssociationStation[ 3];
++ MACWork[ 3] = sc->disAssociationStation[ 4];
++ MACWork[ 4] = sc->disAssociationStation[ 6];
++ MACWork[ 5] = sc->disAssociationStation[ 7];
++ MACWork[ 6] = sc->disAssociationStation[ 9];
++ MACWork[ 7] = sc->disAssociationStation[10];
++ MACWork[ 8] = sc->disAssociationStation[12];
++ MACWork[ 9] = sc->disAssociationStation[13];
++ MACWork[10] = sc->disAssociationStation[15];
++ MACWork[11] = sc->disAssociationStation[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11DEAUTHENTICATEREASON:
++ return ( UCHAR * ) &sc->deAuthenticationReason;
++
++ case DOT11DEAUTHENTICATESTATION:
++ MACWork[ 0] = sc->deAuthenticationStation[ 0];
++ MACWork[ 1] = sc->deAuthenticationStation[ 1];
++ MACWork[ 2] = sc->deAuthenticationStation[ 3];
++ MACWork[ 3] = sc->deAuthenticationStation[ 4];
++ MACWork[ 4] = sc->deAuthenticationStation[ 6];
++ MACWork[ 5] = sc->deAuthenticationStation[ 7];
++ MACWork[ 6] = sc->deAuthenticationStation[ 9];
++ MACWork[ 7] = sc->deAuthenticationStation[10];
++ MACWork[ 8] = sc->deAuthenticationStation[12];
++ MACWork[ 9] = sc->deAuthenticationStation[13];
++ MACWork[10] = sc->deAuthenticationStation[15];
++ MACWork[11] = sc->deAuthenticationStation[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11AUTHENTICATEFAILSTATUS:
++ return ( UCHAR * ) &sc->authenticateFailStatus;
++
++ case DOT11AUTHENTICATEFAILSTATION:
++ MACWork[ 0] = sc->authenticateFailStation[ 0];
++ MACWork[ 1] = sc->authenticateFailStation[ 1];
++ MACWork[ 2] = sc->authenticateFailStation[ 3];
++ MACWork[ 3] = sc->authenticateFailStation[ 4];
++ MACWork[ 4] = sc->authenticateFailStation[ 6];
++ MACWork[ 5] = sc->authenticateFailStation[ 7];
++ MACWork[ 6] = sc->authenticateFailStation[ 9];
++ MACWork[ 7] = sc->authenticateFailStation[10];
++ MACWork[ 8] = sc->authenticateFailStation[12];
++ MACWork[ 9] = sc->authenticateFailStation[13];
++ MACWork[10] = sc->authenticateFailStation[15];
++ MACWork[11] = sc->authenticateFailStation[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11AuthenticationAlgorithmsTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11AuthenticationAlgorithmsTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &aaList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ aa = ( struct aaTbl_data * ) np->data;
++ rName[vp->namelen + 0] = aa->ifIndex;
++ rName[vp->namelen + 1] = aa->authenticationAlgorithmsIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11AUTHENTICATIONALGORITHM:
++ if ( aa->haveAuthenticationAlgorithm ) found = TRUE; break;
++ case DOT11AUTHENTICATIONALGORITHMSENABLE:
++ if ( aa->authenticationAlgorithmsEnable ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11AUTHENTICATIONALGORITHM:
++ return ( UCHAR * ) &aa->authenticationAlgorithm;
++
++ case DOT11AUTHENTICATIONALGORITHMSENABLE:
++// *write_method = write_dot11AuthenticationAlgorithmsEnable;
++ return ( UCHAR * ) &aa->authenticationAlgorithmsEnable;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11WEPDefaultKeysTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11WEPDefaultKeysTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &dfList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ df = ( struct dfTbl_data * ) np->data;
++ rName[vp->namelen + 0] = df->ifIndex;
++ rName[vp->namelen + 1] = df->WEPDefaultKeyIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11WEPDEFAULTKEYVALUE:
++ if ( df->haveWEPDefaultKeyValue ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11WEPDEFAULTKEYVALUE:
++// *write_method = write_dot11WEPDefaultKeyValue;
++ *var_len = strlen ( df->WEPDefaultKeyValue );
++ return ( UCHAR * ) df->WEPDefaultKeyValue;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11WEPKeyMappingsTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11WEPKeyMappingsTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ static char MACWork[17];
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &kmList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ km = ( struct kmTbl_data * ) np->data;
++ rName[vp->namelen + 0] = km->ifIndex;
++ rName[vp->namelen + 1] = km->WEPKeyMappingIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11WEPKEYMAPPINGADDRESS:
++ if ( km->haveWEPKeyMappingAddress ) found = TRUE; break;
++ case DOT11WEPKEYMAPPINGWEPON:
++ if ( km->haveWEPKeyMappingWEPOn ) found = TRUE; break;
++ case DOT11WEPKEYMAPPINGVALUE:
++ if ( km->haveWEPKeyMappingValue ) found = TRUE; break;
++ case DOT11WEPKEYMAPPINGSTATUS:
++ if ( km->haveWEPKeyMappingStatus ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11WEPKEYMAPPINGADDRESS:
++// *write_method = write_dot11WEPKeyMappingAddress;
++ MACWork[ 0] = km->WEPKeyMappingAddress[ 0];
++ MACWork[ 1] = km->WEPKeyMappingAddress[ 1];
++ MACWork[ 2] = km->WEPKeyMappingAddress[ 3];
++ MACWork[ 3] = km->WEPKeyMappingAddress[ 4];
++ MACWork[ 4] = km->WEPKeyMappingAddress[ 6];
++ MACWork[ 5] = km->WEPKeyMappingAddress[ 7];
++ MACWork[ 6] = km->WEPKeyMappingAddress[ 9];
++ MACWork[ 7] = km->WEPKeyMappingAddress[10];
++ MACWork[ 8] = km->WEPKeyMappingAddress[12];
++ MACWork[ 9] = km->WEPKeyMappingAddress[13];
++ MACWork[10] = km->WEPKeyMappingAddress[15];
++ MACWork[11] = km->WEPKeyMappingAddress[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11WEPKEYMAPPINGWEPON:
++// *write_method = write_dot11WEPKeyMappingWEPOn;
++ return ( UCHAR * ) &km->WEPKeyMappingWEPOn;
++
++ case DOT11WEPKEYMAPPINGVALUE:
++// *write_method = write_dot11WEPKeyMappingValue;
++ *var_len = strlen ( km->WEPKeyMappingValue );
++ return ( UCHAR * ) km->WEPKeyMappingValue;
++
++ case DOT11WEPKEYMAPPINGSTATUS:
++// *write_method = write_dot11WEPKeyMappingStatus;
++ return ( UCHAR * ) &km->WEPKeyMappingStatus;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PrivacyTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PrivacyTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &prList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pr = ( struct prTbl_data * ) np->data;
++ rName[vp->namelen] = pr->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11PRIVACYINVOKED:
++ if ( pr->havePrivacyInvoked ) found = TRUE; break;
++ case DOT11WEPDEFAULTKEYID:
++ if ( pr->haveWEPDefaultKeyID ) found = TRUE; break;
++ case DOT11WEPKEYMAPPINGLENGTH:
++ if ( pr->haveWEPKeyMappingLength ) found = TRUE; break;
++ case DOT11EXCLUDEUNENCRYPTED:
++ if ( pr->haveExcludeUnencrypted ) found = TRUE; break;
++ case DOT11WEPICVERRORCOUNT:
++ if ( pr->haveWEPICVErrorCount ) found = TRUE; break;
++ case DOT11WEPEXCLUDEDCOUNT:
++ if ( pr->haveWEPExcludedCount ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11PRIVACYINVOKED:
++// *write_method = write_dot11PrivacyInvoked;
++ return ( UCHAR * ) &pr->privacyInvoked;
++
++ case DOT11WEPDEFAULTKEYID:
++// *write_method = write_dot11WEPDefaultKeyID;
++ return ( UCHAR * ) &pr->WEPDefaultKeyID;
++
++ case DOT11WEPKEYMAPPINGLENGTH:
++// *write_method = write_dot11WEPKeyMappingLength;
++ return ( UCHAR * ) &pr->WEPKeyMappingLength;
++
++ case DOT11EXCLUDEUNENCRYPTED:
++// *write_method = write_dot11ExcludeUnencrypted;
++ return ( UCHAR * ) &pr->excludeUnencrypted;
++
++ case DOT11WEPICVERRORCOUNT:
++ return ( UCHAR * ) &pr->WEPICVErrorCount;
++
++ case DOT11WEPEXCLUDEDCOUNT:
++ return ( UCHAR * ) &pr->WEPExcludedCount;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11OperationTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11OperationTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++ static char MACWork[17];
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &opList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ op = ( struct opTbl_data * ) np->data;
++ rName[vp->namelen] = op->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++
++ switch ( vp->magic ) { // found requested OID, now check for requested variable
++ case DOT11MACADDRESS:
++ if ( op->haveMACAddress ) found = TRUE; break;
++ case DOT11RTSTHRESHOLD:
++ if ( op->haveRTSThreshold ) found = TRUE; break;
++ case DOT11SHORTRETRYLIMIT:
++ if ( op->haveShortRetryLimit ) found = TRUE; break;
++ case DOT11LONGRETRYLIMIT:
++ if ( op->haveLongRetryLimit ) found = TRUE; break;
++ case DOT11FRAGMENTATIONTHRESHOLD:
++ if ( op->haveFragmentationThreshold ) found = TRUE; break;
++ case DOT11MAXTRANSMITMSDULIFETIME:
++ if ( op->haveMaxTransmitMSDULifetime ) found = TRUE; break;
++ case DOT11MAXRECEIVELIFETIME:
++ if ( op->haveMaxReceiveLifetime ) found = TRUE; break;
++ case DOT11MANUFACTURERID:
++ if ( op->haveManufacturerID ) found = TRUE; break;
++ case DOT11PRODUCTID:
++ if ( op->haveProductID ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11MACADDRESS:
++ MACWork[ 0] = op->MACAddress[ 0];
++ MACWork[ 1] = op->MACAddress[ 1];
++ MACWork[ 2] = op->MACAddress[ 3];
++ MACWork[ 3] = op->MACAddress[ 4];
++ MACWork[ 4] = op->MACAddress[ 6];
++ MACWork[ 5] = op->MACAddress[ 7];
++ MACWork[ 6] = op->MACAddress[ 9];
++ MACWork[ 7] = op->MACAddress[10];
++ MACWork[ 8] = op->MACAddress[12];
++ MACWork[ 9] = op->MACAddress[13];
++ MACWork[10] = op->MACAddress[15];
++ MACWork[11] = op->MACAddress[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11RTSTHRESHOLD:
++// *write_method = write_dot11RTSThreshold;
++ return ( UCHAR * ) &op->RTSThreshold;
++
++ case DOT11SHORTRETRYLIMIT:
++// *write_method = write_dot11ShortRetryLimit;
++ return ( UCHAR * ) &op->shortRetryLimit;
++
++ case DOT11LONGRETRYLIMIT:
++// *write_method = write_dot11LongRetryLimit;
++ return ( UCHAR * ) &op->longRetryLimit;
++
++ case DOT11FRAGMENTATIONTHRESHOLD:
++// *write_method = write_dot11FragmentationThreshold;
++ return ( UCHAR * ) &op->fragmentationThreshold;
++
++ case DOT11MAXTRANSMITMSDULIFETIME:
++// *write_method = write_dot11MaxTransmitMSDULifetime;
++ return ( UCHAR * ) &op->maxTransmitMSDULifetime;
++
++ case DOT11MAXRECEIVELIFETIME:
++// *write_method = write_dot11MaxReceiveLifetime;
++ return ( UCHAR * ) &op->maxReceiveLifetime;
++
++ case DOT11MANUFACTURERID:
++ *var_len = strlen ( op->manufacturerID );
++ return ( UCHAR * ) op->manufacturerID;
++
++ case DOT11PRODUCTID:
++ *var_len = strlen ( op->productID );
++ return ( UCHAR * ) op->productID;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11CountersTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11CountersTable(struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &coList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ co = ( struct coTbl_data * ) np->data;
++ rName[vp->namelen] = co->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11TRANSMITTEDFRAGMENTCOUNT:
++ if ( co->haveTransmittedFragmentCount ) found = TRUE; break;
++ case DOT11MULTICASTTRANSMITTEDFRAMECOUNT:
++ if ( co->haveTransmittedFrameCount ) found = TRUE; break;
++ case DOT11FAILEDCOUNT:
++ if ( co->haveFailedCount ) found = TRUE; break;
++ case DOT11RETRYCOUNT:
++ if ( co->haveRetryCount ) found = TRUE; break;
++ case DOT11MULTIPLERETRYCOUNT:
++ if ( co->haveMultipleRetryCount ) found = TRUE; break;
++ case DOT11FRAMEDUPLICATECOUNT:
++ if ( co->haveFrameDuplicateCount ) found = TRUE; break;
++ case DOT11RTSSUCCESSCOUNT:
++ if ( co->haveRTSSuccessCount ) found = TRUE; break;
++ case DOT11RTSFAILURECOUNT:
++ if ( co->haveRTSFailureCount ) found = TRUE; break;
++ case DOT11ACKFAILURECOUNT:
++ if ( co->haveACKFailureCount ) found = TRUE; break;
++ case DOT11RECEIVEDFRAGMENTCOUNT:
++ if ( co->haveReceivedFragmentCount ) found = TRUE; break;
++ case DOT11MULTICASTRECEIVEDFRAMECOUNT:
++ if ( co->haveMulticastReceivedFrameCount ) found = TRUE; break;
++ case DOT11FCSERRORCOUNT:
++ if ( co->haveFCSErrorCount ) found = TRUE; break;
++ case DOT11TRANSMITTEDFRAMECOUNT:
++ if ( co->haveTransmittedFrameCount ) found = TRUE; break;
++ case DOT11WEPUNDECRYPTABLECOUNT:
++ if ( co->haveWEPUndecryptableCount ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11TRANSMITTEDFRAGMENTCOUNT: return ( UCHAR * ) &co->transmittedFragmentCount;
++ case DOT11MULTICASTTRANSMITTEDFRAMECOUNT: return ( UCHAR * ) &co->transmittedFrameCount;
++ case DOT11FAILEDCOUNT: return ( UCHAR * ) &co->failedCount;
++ case DOT11RETRYCOUNT: return ( UCHAR * ) &co->retryCount;
++ case DOT11MULTIPLERETRYCOUNT: return ( UCHAR * ) &co->multipleRetryCount;
++ case DOT11FRAMEDUPLICATECOUNT: return ( UCHAR * ) &co->frameDuplicateCount;
++ case DOT11RTSSUCCESSCOUNT: return ( UCHAR * ) &co->RTSSuccessCount;
++ case DOT11RTSFAILURECOUNT: return ( UCHAR * ) &co->RTSFailureCount;
++ case DOT11ACKFAILURECOUNT: return ( UCHAR * ) &co->ACKFailureCount;
++ case DOT11RECEIVEDFRAGMENTCOUNT: return ( UCHAR * ) &co->receivedFragmentCount;
++ case DOT11MULTICASTRECEIVEDFRAMECOUNT: return ( UCHAR * ) &co->multicastReceivedFrameCount;
++ case DOT11FCSERRORCOUNT: return ( UCHAR * ) &co->FCSErrorCount;
++ case DOT11TRANSMITTEDFRAMECOUNT: return ( UCHAR * ) &co->transmittedFrameCount;
++ case DOT11WEPUNDECRYPTABLECOUNT: return ( UCHAR * ) &co->WEPUndecryptableCount;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11GroupAddressesTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11GroupAddressesTable(struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ static char MACWork[17];
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &gaList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ ga = ( struct gaTbl_data * ) np->data;
++ rName[vp->namelen + 0] = ga->ifIndex;
++ rName[vp->namelen + 1] = ga->groupAddressesIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11ADDRESS:
++ if ( ga->haveAddress ) found = TRUE; break;
++ case DOT11GROUPADDRESSESSTATUS:
++ if ( ga->haveGroupAddressesStatus ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11ADDRESS:
++// *write_method = write_dot11Address;
++ MACWork[ 0] = ga->address[ 0];
++ MACWork[ 1] = ga->address[ 1];
++ MACWork[ 2] = ga->address[ 3];
++ MACWork[ 3] = ga->address[ 4];
++ MACWork[ 4] = ga->address[ 6];
++ MACWork[ 5] = ga->address[ 7];
++ MACWork[ 6] = ga->address[ 9];
++ MACWork[ 7] = ga->address[10];
++ MACWork[ 8] = ga->address[12];
++ MACWork[ 9] = ga->address[13];
++ MACWork[10] = ga->address[15];
++ MACWork[11] = ga->address[16];
++ MACWork[12] = '\0';
++ *var_len = 6;
++ return ( UCHAR * ) htob ( MACWork );
++
++ case DOT11GROUPADDRESSESSTATUS:
++// *write_method = write_dot11GroupAddressesStatus;
++ return ( UCHAR * ) &ga->groupAddressesStatus;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11ResourceInfoTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11ResourceInfoTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &riList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ ri = ( struct riTbl_data * ) np->data;
++ rName[vp->namelen] = ri->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11MANUFACTUREROUI:
++ if ( ri->haveManufacturerOUI ) found = TRUE; break;
++ case DOT11MANUFACTURERNAME:
++ if ( ri->haveManufacturerName ) found = TRUE; break;
++ case DOT11MANUFACTURERPRODUCTNAME:
++ if ( ri->haveManufacturerProductName ) found = TRUE; break;
++ case DOT11MANUFACTURERPRODUCTVERSION:
++ if ( ri->haveManufacturerProductVersion ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11MANUFACTUREROUI:
++ *var_len = strlen ( ri->manufacturerOUI );
++ return ( UCHAR * ) ri->manufacturerOUI;
++
++ case DOT11MANUFACTURERNAME:
++ *var_len = strlen ( ri->manufacturerName );
++ return ( UCHAR * ) ri->manufacturerName;
++
++ case DOT11MANUFACTURERPRODUCTNAME:
++ *var_len = strlen ( ri->manufacturerProductName );
++ return ( UCHAR * ) ri->manufacturerProductName;
++
++ case DOT11MANUFACTURERPRODUCTVERSION:
++ *var_len = strlen ( ri->manufacturerProductVersion );
++ return ( UCHAR * ) ri->manufacturerProductVersion;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyOperationTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyOperationTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &poList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ po = ( struct poTbl_data * ) np->data;
++ rName[vp->namelen] = po->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11PHYTYPE:
++ if ( po->havePHYType ) found = TRUE; break;
++ case DOT11CURRENTREGDOMAIN:
++ if ( po->haveCurrentRegDomain ) found = TRUE; break;
++ case DOT11TEMPTYPE:
++ if ( po->haveTempType ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11PHYTYPE:
++ return ( UCHAR * ) &po->PHYType;
++
++ case DOT11CURRENTREGDOMAIN:
++// *write_method = write_dot11CurrentRegDomain;
++ return ( UCHAR * ) &po->currentRegDomain;
++
++ case DOT11TEMPTYPE:
++ return ( UCHAR * ) &po->tempType;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyAntennaTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyAntennaTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &paList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pa = ( struct paTbl_data * ) np->data;
++ rName[vp->namelen] = pa->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11CURRENTTXANTENNA:
++ if ( pa->haveCurrentTxAntenna ) found = TRUE; break;
++ case DOT11DIVERSITYSUPPORT:
++ if ( pa->haveDiversitySupport ) found = TRUE; break;
++ case DOT11CURRENTRXANTENNA:
++ if ( pa->haveCurrentRxAntenna ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11CURRENTTXANTENNA:
++// *write_method = write_dot11CurrentTxAntenna;
++ return ( UCHAR * ) &pa->currentTxAntenna;
++
++ case DOT11DIVERSITYSUPPORT:
++ return ( UCHAR * ) &pa->diversitySupport;
++
++ case DOT11CURRENTRXANTENNA:
++// *write_method = write_dot11CurrentRxAntenna;
++ return ( UCHAR * ) &pa->currentRxAntenna;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyTxPowerTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyTxPowerTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &ptList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pt = ( struct ptTbl_data * ) np->data;
++ rName[vp->namelen] = pt->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11NUMBERSUPPORTEDPOWERLEVELS:
++ if ( pt->haveNumberSupportedPowerLevels ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL1:
++ if ( pt->haveTxPowerLevel1 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL2:
++ if ( pt->haveTxPowerLevel2 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL3:
++ if ( pt->haveTxPowerLevel3 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL4:
++ if ( pt->haveTxPowerLevel4 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL5:
++ if ( pt->haveTxPowerLevel5 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL6:
++ if ( pt->haveTxPowerLevel6 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL7:
++ if ( pt->haveTxPowerLevel7 ) found = TRUE; break;
++ case DOT11TXPOWERLEVEL8:
++ if ( pt->haveTxPowerLevel8 ) found = TRUE; break;
++ case DOT11CURRENTTXPOWERLEVEL:
++ if ( pt->currentTxPowerLevel ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11NUMBERSUPPORTEDPOWERLEVELS:
++ return ( UCHAR * ) &pt->numberSupportedPowerLevels;
++
++ case DOT11TXPOWERLEVEL1: return ( UCHAR * ) &pt->TxPowerLevel1;
++ case DOT11TXPOWERLEVEL2: return ( UCHAR * ) &pt->TxPowerLevel2;
++ case DOT11TXPOWERLEVEL3: return ( UCHAR * ) &pt->TxPowerLevel3;
++ case DOT11TXPOWERLEVEL4: return ( UCHAR * ) &pt->TxPowerLevel4;
++ case DOT11TXPOWERLEVEL5: return ( UCHAR * ) &pt->TxPowerLevel5;
++ case DOT11TXPOWERLEVEL6: return ( UCHAR * ) &pt->TxPowerLevel6;
++ case DOT11TXPOWERLEVEL7: return ( UCHAR * ) &pt->TxPowerLevel7;
++ case DOT11TXPOWERLEVEL8: return ( UCHAR * ) &pt->TxPowerLevel8;
++
++ case DOT11CURRENTTXPOWERLEVEL:
++// *write_method = write_dot11CurrentTxPowerLevel;
++ return ( UCHAR * ) &pt->currentTxPowerLevel;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyFHSSTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyFHSSTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &pfList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pf = ( struct pfTbl_data * ) np->data;
++ rName[vp->namelen] = pf->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11HOPTIME:
++ if ( pf->haveHopTime ) found = TRUE; break;
++ case DOT11CURRENTCHANNELNUMBER:
++ if ( pf->haveCurrentChannelNumber ) found = TRUE; break;
++ case DOT11MAXDWELLTIME:
++ if ( pf->haveMaxDwellTime ) found = TRUE; break;
++ case DOT11CURRENTDWELLTIME:
++ if ( pf->haveCurrentDwellTime ) found = TRUE; break;
++ case DOT11CURRENTSET:
++ if ( pf->haveCurrentSet ) found = TRUE; break;
++ case DOT11CURRENTPATTERN:
++ if ( pf->haveCurrentPattern ) found = TRUE; break;
++ case DOT11CURRENTINDEX:
++ if ( pf->haveCurrentIndex ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11HOPTIME:
++ return ( UCHAR * ) &pf->hopTime;
++
++ case DOT11CURRENTCHANNELNUMBER:
++// *write_method = write_dot11CurrentChannelNumber;
++ return ( UCHAR * ) &pf->currentChannelNumber;
++
++ case DOT11MAXDWELLTIME:
++ return ( UCHAR * ) &pf->maxDwellTime;
++
++ case DOT11CURRENTDWELLTIME:
++// *write_method = write_dot11CurrentDwellTime;
++ return ( UCHAR * ) &pf->currentDwellTime;
++
++ case DOT11CURRENTSET:
++// *write_method = write_dot11CurrentSet;
++ return ( UCHAR * ) &pf->currentSet;
++
++ case DOT11CURRENTPATTERN:
++// *write_method = write_dot11CurrentPattern;
++ return ( UCHAR * ) &pf->currentPattern;
++
++ case DOT11CURRENTINDEX:
++// *write_method = write_dot11CurrentIndex;
++ return ( UCHAR * ) &pf->currentIndex;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyDSSSTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyDSSSTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &pdList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pd = ( struct pdTbl_data * ) np->data;
++ rName[vp->namelen] = pd->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11CURRENTCHANNEL:
++ if ( pd->haveCurrentChannel ) found = TRUE; break;
++ case DOT11CCAMODESUPPORTED:
++ if ( pd->haveCCAModeSupported ) found = TRUE; break;
++ case DOT11CURRENTCCAMODE:
++ if ( pd->haveCurrentCCAMode ) found = TRUE; break;
++ case DOT11EDTHRESHOLD:
++ if ( pd->haveEDThreshold ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11CURRENTCHANNEL:
++// *write_method = write_dot11CurrentChannel;
++ return ( UCHAR * ) &pd->currentChannel;
++
++ case DOT11CCAMODESUPPORTED:
++ return ( UCHAR * ) &pd->CCAModeSupported;
++
++ case DOT11CURRENTCCAMODE:
++// *write_method = write_dot11CurrentCCAMode;
++ return ( UCHAR * ) &pd->currentCCAMode;
++
++ case DOT11EDTHRESHOLD:
++// *write_method = write_dot11EDThreshold;
++ return ( UCHAR * ) &pd->EDThreshold;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11PhyIRTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11PhyIRTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &piList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ pi = ( struct piTbl_data * ) np->data;
++ rName[vp->namelen] = pi->ifIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 1, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11CCAWATCHDOGTIMERMAX:
++ if ( pi->CCAWatchdogTimerMax ) found = TRUE; break;
++ case DOT11CCAWATCHDOGCOUNTMAX:
++ if ( pi->CCAWatchdogCountMax ) found = TRUE; break;
++ case DOT11CCAWATCHDOGTIMERMIN:
++ if ( pi->CCAWatchdogTimerMin ) found = TRUE; break;
++ case DOT11CCAWATCHDOGCOUNTMIN:
++ if ( pi->CCAWatchdogCountMin ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 1 ) * sizeof ( oid ));
++ *length = vp->namelen + 1;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11CCAWATCHDOGTIMERMAX:
++// *write_method = write_dot11CCAWatchdogTimerMax;
++ return ( UCHAR * ) &pi->CCAWatchdogTimerMax;
++
++ case DOT11CCAWATCHDOGCOUNTMAX:
++// *write_method = write_dot11CCAWatchdogCountMax;
++ return ( UCHAR * ) &pi->CCAWatchdogCountMax;
++
++ case DOT11CCAWATCHDOGTIMERMIN:
++// *write_method = write_dot11CCAWatchdogTimerMin;
++ return ( UCHAR * ) &pi->CCAWatchdogTimerMin;
++
++ case DOT11CCAWATCHDOGCOUNTMIN:
++// *write_method = write_dot11CCAWatchdogCountMin;
++ return ( UCHAR * ) &pi->CCAWatchdogCountMin;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11RegDomainsSupportedTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11RegDomainsSupportedTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &rdList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ rd = ( struct rdTbl_data * ) np->data;
++ rName[vp->namelen + 0] = rd->ifIndex;
++ rName[vp->namelen + 1] = rd->regDomainsSupportIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11REGDOMAINSSUPPORTVALUE:
++ if ( rd->haveRegDomainsSupportValue ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11REGDOMAINSSUPPORTVALUE:
++ return ( UCHAR * ) &rd->regDomainsSupportValue;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11AntennasListTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11AntennasListTable(struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method)
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &alList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ al = ( struct alTbl_data * ) np->data;
++ rName[vp->namelen + 0] = al->ifIndex;
++ rName[vp->namelen + 1] = al->antennaListIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11SUPPORTEDTXANTENNA:
++ if ( al->haveSupportedTxAntenna ) found = TRUE; break;
++ case DOT11SUPPORTEDRXANTENNA:
++ if ( al->haveSupportedRxAntenna ) found = TRUE; break;
++ case DOT11DIVERSITYSELECTIONRX:
++ if ( al->haveDiversitySelectionRx ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11SUPPORTEDTXANTENNA:
++// *write_method = write_dot11SupportedTxAntenna;
++ return ( UCHAR * ) &al->supportedTxAntenna;
++
++ case DOT11SUPPORTEDRXANTENNA:
++// *write_method = write_dot11SupportedRxAntenna;
++ return ( UCHAR * ) &al->supportedRxAntenna;
++
++ case DOT11DIVERSITYSELECTIONRX:
++// *write_method = write_dot11DiversitySelectionRx;
++ return ( UCHAR * ) &al->diversitySelectionRx;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11SupportedDataRatesTxTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11SupportedDataRatesTxTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &rtList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ rt = ( struct rtTbl_data * ) np->data;
++ rName[vp->namelen + 0] = rt->ifIndex;
++ rName[vp->namelen + 1] = rt->supportedDataRatesTxIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11SUPPORTEDDATARATESTXVALUE:
++ if ( rt->haveSupportedDataRatesTxValue ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11SUPPORTEDDATARATESTXVALUE:
++ return ( UCHAR * ) &rt->supportedDataRatesTxValue;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++* var_dot11SupportedDataRatesRxTable() - *
++* *
++****************************************************************************/
++unsigned char *
++var_dot11SupportedDataRatesRxTable ( struct variable *vp,
++ oid *name,
++ size_t *length,
++ int exact,
++ size_t *var_len,
++ WriteMethod **write_method )
++{
++ int found = FALSE;
++ oid rName [ MAX_OID_LEN ]; // OID to be returned
++
++ loadTables();
++ memcpy (( char * ) rName, ( char * ) vp->name, ( int ) vp->namelen * sizeof ( oid ));
++ for ( np = LIST_FIRST ( &rrList ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ rr = ( struct rrTbl_data * ) np->data;
++ rName[vp->namelen + 0] = rr->ifIndex;
++ rName[vp->namelen + 1] = rr->supportedDataRatesRxIndex;
++ if (( exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) == 0 )) ||
++ ( !exact && ( snmp_oid_compare ( rName, vp->namelen + 2, name, *length ) > 0 ))) {
++ switch ( vp->magic ) {
++ case DOT11SUPPORTEDDATARATESRXVALUE:
++ if ( rr->haveSupportedDataRatesRxValue ) found = TRUE; break;
++ }
++ }
++ if ( found )
++ break;
++ }
++
++ if ( !found )
++ return NULL;
++
++ memcpy (( char * ) name, ( char * ) rName, ( vp->namelen + 2 ) * sizeof ( oid ));
++ *length = vp->namelen + 2;
++ *var_len = sizeof ( long );
++ *write_method = NULL;
++
++ switch ( vp->magic ) {
++
++ case DOT11SUPPORTEDDATARATESRXVALUE:
++ return ( UCHAR * ) &rr->supportedDataRatesRxValue;
++
++ default:
++ ERROR_MSG ( "" );
++ }
++
++ return NULL;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11StationID(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11StationID not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )) {
++ fprintf ( stderr,"write to dot11StationID: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11MediumOccupancyLimit(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11MediumOccupancyLimit not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11MediumOccupancyLimit: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CFPPeriod(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CFPPeriod not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CFPPeriod: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CFPMaxDuration(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CFPMaxDuration not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CFPMaxDuration: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11AuthenticationResponseTimeOut(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11AuthenticationResponseTimeOut not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11AuthenticationResponseTimeOut: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11PowerManagementMode(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11PowerManagementMode not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )) {
++ fprintf ( stderr, "write to dot11PowerManagementMode: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11DesiredSSID(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11DesiredSSID not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )){
++ fprintf ( stderr, "write to dot11DesiredSSID: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11DesiredBSSType(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11DesiredBSSType not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11DesiredBSSType: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11OperationalRateSet(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11OperationalRateSet not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )){
++ fprintf ( stderr, "write to dot11OperationalRateSet: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11BeaconPeriod(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11BeaconPeriod not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11BeaconPeriod: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11DTIMPeriod(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11DTIMPeriod not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11DTIMPeriod: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11AssociationResponseTimeOut(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11AssociationResponseTimeOut not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )) {
++ fprintf ( stderr,"write to dot11AssociationResponseTimeOut: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11AuthenticationAlgorithmsEnable(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11AuthenticationAlgorithmsEnable not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11AuthenticationAlgorithmsEnable: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPDefaultKeyValue(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11WEPDefaultKeyValue not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )){
++ fprintf ( stderr,"write to dot11WEPDefaultKeyValue: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPKeyMappingAddress(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingAddress not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )) {
++ fprintf ( stderr,"write to dot11WEPKeyMappingAddress: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPKeyMappingWEPOn(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingWEPOn not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11WEPKeyMappingWEPOn: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPKeyMappingValue(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingValue not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingValue: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPKeyMappingStatus(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingStatus not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11WEPKeyMappingStatus: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11PrivacyInvoked(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11PrivacyInvoked not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11PrivacyInvoked: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPDefaultKeyID(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11WEPDefaultKeyID not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11WEPDefaultKeyID: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11WEPKeyMappingLength(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11WEPKeyMappingLength not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11WEPKeyMappingLength: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11ExcludeUnencrypted(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11ExcludeUnencrypted not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11ExcludeUnencrypted: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11RTSThreshold(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ){
++ fprintf ( stderr, "write to dot11RTSThreshold not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11RTSThreshold: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11ShortRetryLimit(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11ShortRetryLimit not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11ShortRetryLimit: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11LongRetryLimit(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11LongRetryLimit not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11LongRetryLimit: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11FragmentationThreshold(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11FragmentationThreshold not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11FragmentationThreshold: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11MaxTransmitMSDULifetime(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11MaxTransmitMSDULifetime not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11MaxTransmitMSDULifetime: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11MaxReceiveLifetime(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11MaxReceiveLifetime not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11MaxReceiveLifetime: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11Address(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static unsigned char string[SPRINT_MAX_LEN];
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_OCTET_STR ) {
++ fprintf ( stderr, "write to dot11Address not ASN_OCTET_STR\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( string )){
++ fprintf ( stderr, "write to dot11Address: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11GroupAddressesStatus(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11GroupAddressesStatus not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11GroupAddressesStatus: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentRegDomain(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentRegDomain not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentRegDomain: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentTxAntenna(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentTxAntenna not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentTxAntenna: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentRxAntenna(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentRxAntenna not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11CurrentRxAntenna: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentTxPowerLevel(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentTxPowerLevel not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentTxPowerLevel: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentChannelNumber(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentChannelNumber not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11CurrentChannelNumber: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentDwellTime(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentDwellTime not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentDwellTime: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentSet(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentSet not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentSet: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentPattern(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentPattern not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentPattern: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentIndex(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentIndex not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentIndex: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentChannel(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentChannel not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CurrentChannel: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CurrentCCAMode(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CurrentCCAMode not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11CurrentCCAMode: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11EDThreshold(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11EDThreshold not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11EDThreshold: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CCAWatchdogTimerMax(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CCAWatchdogTimerMax not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CCAWatchdogTimerMax: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CCAWatchdogCountMax(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CCAWatchdogCountMax not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CCAWatchdogCountMax: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CCAWatchdogTimerMin(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CCAWatchdogTimerMin not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CCAWatchdogTimerMin: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11CCAWatchdogCountMin(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11CCAWatchdogCountMin not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11CCAWatchdogCountMin: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11SupportedTxAntenna(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11SupportedTxAntenna not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11SupportedTxAntenna: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11SupportedRxAntenna(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11SupportedRxAntenna not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr,"write to dot11SupportedRxAntenna: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++****************************************************************************/
++int
++write_dot11DiversitySelectionRx(int action,
++ u_char *var_val,
++ u_char var_val_type,
++ size_t var_val_len,
++ u_char *statP,
++ oid *name,
++ size_t name_len)
++{
++ static long *long_ret;
++ int size;
++
++ switch ( action ) {
++
++ case RESERVE1:
++ if ( var_val_type != ASN_INTEGER ) {
++ fprintf ( stderr, "write to dot11DiversitySelectionRx not ASN_INTEGER\n" );
++ return SNMP_ERR_WRONGTYPE;
++ }
++ if ( var_val_len > sizeof ( long_ret )){
++ fprintf ( stderr, "write to dot11DiversitySelectionRx: bad length\n" );
++ return SNMP_ERR_WRONGLENGTH;
++ }
++ break;
++
++ case RESERVE2:
++ case FREE:
++ case ACTION:
++ case UNDO:
++ break;
++
++ case COMMIT:
++ break;
++ }
++
++ return SNMP_ERR_NOERROR;
++}
++
++/****************************************************************************
++* *
++* loadTables() - Load the Tables *
++* *
++****************************************************************************/
++static void loadTables()
++{
++ int skfd; // generic raw socket desc
++ struct iwreq wrq; // ioctl request structure
++ struct ifreq ifr;
++ struct timeval et; // elapsed time
++ struct wireless_info info; // workarea for wireless ioctl information
++ FILE *fp;
++ char bfr[1024], ifName[1024];
++ char *s, *t;
++
++ gettimeofday ( &et, ( struct timezone * ) 0 ); // get time-of-day
++ if ( et.tv_sec < lastLoad + MINLOADFREQ ) // only reload so often
++ return;
++ lastLoad = et.tv_sec;
++
++ skfd = openSocket(); // open socket
++ if ( skfd < 0 ) {
++ syslog ( LOG_ERR, "SNMP ieee802dot11.loadTables() - %s\n", "socket open failure" );
++ return;
++ }
++
++ flushLists();
++
++ // find interfaces in /proc/net/dev and find the wireless interfaces
++ fp = fopen ( PROC_NET_DEV, "r" );
++ if ( fp ) {
++ while ( fgets ( bfr, sizeof ( bfr ), fp )) {
++ if ( strstr ( bfr, ":" )) {
++ s = bfr; t = ifName;
++ while ( isspace ( *s )) // discard white space
++ *s++;
++ while ( *s != ':' ) // get interface name
++ *t++ = *s++;
++ *t = '\0';
++
++ // verify as a wireless device
++ memset (( char * ) &info, 0, sizeof ( struct wireless_info ));
++ strncpy ( wrq.ifr_name, ifName, IFNAMSIZ );
++ if ( ioctl ( skfd, SIOCGIWNAME, &wrq ) >= 0 ) {
++ printf ( "%s ifName: %s\n", "loadTables() -", ifName );
++ initStructs();
++ loadWiExt( skfd, ifName, &info );
++ displayWiExt ( info );
++ load80211Structs ( skfd, ifName, &info );
++ }
++ }
++ }
++ fclose ( fp );
++ }
++
++ close ( skfd );
++}
++
++/****************************************************************************
++* *
++* load80211Structs() - load the 802.11 structures *
++* *
++****************************************************************************/
++static void
++load80211Structs ( int skfd, char *ifName, struct wireless_info *wi )
++{
++ int rc, ifIndex = 0;
++ struct ifreq ifr;
++ char MACAddress [ MACADDR_LEN + 1 ];
++
++ strcpy ( ifr.ifr_name, ifName );
++ rc = ioctl ( skfd, SIOCGIFHWADDR, &ifr );
++ if ( rc >= 0 ) {
++
++ sprintf ( MACAddress, "%02X:%02X:%02X:%02X:%02X:%02X\0",
++ ( UCHAR ) ifr.ifr_hwaddr.sa_data[0], ( UCHAR ) ifr.ifr_hwaddr.sa_data[1],
++ ( UCHAR ) ifr.ifr_hwaddr.sa_data[2], ( UCHAR ) ifr.ifr_hwaddr.sa_data[3],
++ ( UCHAR ) ifr.ifr_hwaddr.sa_data[4], ( UCHAR ) ifr.ifr_hwaddr.sa_data[5] );
++
++ nSc.haveStationID = TRUE;
++ strcpy ( nSc.stationID, MACAddress );
++ nOp.haveMACAddress = TRUE;
++ strcpy ( nOp.MACAddress, MACAddress );
++ nRi.haveManufacturerOUI = TRUE;
++ strncpy ( nRi.manufacturerOUI, MACAddress, MAN_OUI_LEN );
++
++ ifIndex = if_nametoindex ( ifName );
++ if ( !ifIndex ) {
++ syslog ( LOG_ERR, "SNMP %s - %s %s\n",
++ "ieee802dot11.load80211Structs()", ifName, "has no ifIndex" );
++ return;
++ }
++
++ loadWiExtTo80211Structs ( ifIndex, ifName, wi );
++
++ if ( hasChanged (( char * ) &nSc, sizeof ( nSc ))) {
++ nSc.ifIndex = ifIndex;
++ sprintf ( nSc.UID, "%04d\0", nSc.ifIndex );
++ strcpy ( nSc.ifName, ifName );
++ addList (( char * ) &scList, ( char * ) &nSc, sizeof ( nSc ));
++ }
++
++ if ( hasChanged (( char * ) &nPr, sizeof ( nPr ))) {
++ nPr.ifIndex = ifIndex;
++ sprintf ( nPr.UID, "%04d\0", nPr.ifIndex );
++ strcpy ( nPr.ifName, ifName );
++ addList (( char * ) &prList, ( char * ) &nPr, sizeof ( nPr ));
++ }
++
++ if ( hasChanged (( char * ) &nOp, sizeof ( nOp ))) {
++ nOp.ifIndex = ifIndex;
++ sprintf ( nOp.UID, "%04d\0", nOp.ifIndex );
++ strcpy ( nOp.ifName, ifName );
++ addList (( char * ) &opList, ( char * ) &nOp, sizeof ( nOp ));
++ }
++
++ if ( hasChanged (( char * ) &nCo, sizeof ( nCo ))) {
++ nCo.ifIndex = ifIndex;
++ sprintf ( nCo.UID, "%04d\0", nCo.ifIndex );
++ strcpy ( nCo.ifName, ifName );
++ addList (( char * ) &coList, ( char * ) &nCo, sizeof ( nCo ));
++ }
++
++ if ( hasChanged (( char * ) &nRi, sizeof ( nRi ))) {
++ nRi.ifIndex = ifIndex;
++ sprintf ( nRi.UID, "%04d\0", nRi.ifIndex );
++ strcpy ( nRi.ifName, ifName );
++ addList (( char * ) &riList, ( char * ) &nRi, sizeof ( nRi ));
++ }
++
++ if ( hasChanged (( char * ) &nPo, sizeof ( nPo ))) {
++ nPo.ifIndex = ifIndex;
++ sprintf ( nPo.UID, "%04d\0", nPo.ifIndex );
++ strcpy ( nPo.ifName, ifName );
++ addList (( char * ) &poList, ( char * ) &nPo, sizeof ( nPo ));
++ }
++
++ if ( hasChanged (( char * ) &nPa, sizeof ( nPa ))) {
++ nPa.ifIndex = ifIndex;
++ sprintf ( nPa.UID, "%04d\0", nPa.ifIndex );
++ strcpy ( nPa.ifName, ifName );
++ addList (( char * ) &paList, ( char * ) &nPa, sizeof ( nPa ));
++ }
++
++ if ( hasChanged (( char * ) &nPt, sizeof ( nPt ))) {
++ nPt.ifIndex = ifIndex;
++ sprintf ( nPt.UID, "%04d\0", nPt.ifIndex );
++ strcpy ( nPt.ifName, ifName );
++ addList (( char * ) &ptList, ( char * ) &nPt, sizeof ( nPt ));
++ }
++
++ if ( hasChanged (( char * ) &nPf, sizeof ( nPf ))) {
++ nPf.ifIndex = ifIndex;
++ sprintf ( nPf.UID, "%04d\0", nPf.ifIndex );
++ strcpy ( nPf.ifName, ifName );
++ addList (( char * ) &pfList, ( char * ) &nPf, sizeof ( nPf ));
++ }
++
++ if ( hasChanged (( char * ) &nPd, sizeof ( nPd ))) {
++ nPd.ifIndex = ifIndex;
++ sprintf ( nPd.UID, "%04d\0", nPd.ifIndex );
++ strcpy ( nPd.ifName, ifName );
++ addList (( char * ) &pdList, ( char * ) &nPd, sizeof ( nPd ));
++ }
++
++ if ( hasChanged (( char * ) &nPi, sizeof ( nPi ))) {
++ nPi.ifIndex = ifIndex;
++ sprintf ( nPi.UID, "%04d\0", nPi.ifIndex );
++ strcpy ( nPi.ifName, ifName );
++ addList (( char * ) &piList, ( char * ) &nPi, sizeof ( nPi ));
++ }
++ }
++
++//printf ( "%s - ifIndex: %d ifName: %s UID: %s\n",
++// "load80211Structs() - HASCHANGED", ifIndex, ifName, nSc.UID );
++}
++
++/****************************************************************************
++* *
++* initStructs() - initialize structures *
++* *
++****************************************************************************/
++static void initStructs()
++{
++ int i;
++
++ // 802.11 MIB Stuctures
++ memset (( char * ) &nSc, 0, sizeof ( nSc )); memset (( char * ) &nAa, 0, sizeof ( nAa ));
++ memset (( char * ) &nDf, 0, sizeof ( nDf )); memset (( char * ) &nKm, 0, sizeof ( nKm ));
++ memset (( char * ) &nPr, 0, sizeof ( nPr )); memset (( char * ) &nOp, 0, sizeof ( nOp ));
++ memset (( char * ) &nCo, 0, sizeof ( nCo )); memset (( char * ) &nGa, 0, sizeof ( nGa ));
++ memset (( char * ) &nRi, 0, sizeof ( nRi )); memset (( char * ) &nPo, 0, sizeof ( nPo ));
++ memset (( char * ) &nPa, 0, sizeof ( nPa )); memset (( char * ) &nPt, 0, sizeof ( nPt ));
++ memset (( char * ) &nPf, 0, sizeof ( nPf )); memset (( char * ) &nPd, 0, sizeof ( nPd ));
++ memset (( char * ) &nPi, 0, sizeof ( nPi )); memset (( char * ) &nRd, 0, sizeof ( nRd ));
++ memset (( char * ) &nAl, 0, sizeof ( nAl )); memset (( char * ) &nRt, 0, sizeof ( nRt ));
++ memset (( char * ) &nRr, 0, sizeof ( nRr ));
++
++ // Wireless Extensions
++ wepCurrentKey = 0;
++ haveWepCurrentKey = FALSE;
++ for ( i = 0; i < MAX_WEP_KEYS; i++ ) {
++ wep[i].len = 0;
++ wep[i].key[0] = '\0';
++ wep[i].haveKey = FALSE;
++ }
++}
++
++/****************************************************************************
++* *
++* Wireless Extensions Specific Functions *
++* *
++****************************************************************************/
++/****************************************************************************
++* *
++* loadWiExtTo80211Structs() - load wireless extensions to 802.11 structures *
++* *
++****************************************************************************/
++static void
++loadWiExtTo80211Structs ( int ifIndex, char *ifName, struct wireless_info *wi )
++{
++ int i, j = 0;
++
++ // dot11Smt Group
++ // dot11StationConfigTable
++ nSc.havePrivacyOptionImplemented = TRUE;
++ nSc.privacyOptionImplemented = 1; // assume we support WEP
++
++ if ( wi->has_power ) {
++ nSc.havePowerManagementMode = TRUE;
++ nSc.powerManagementMode = 1; // assume power is active
++ if ( !wi->power.disabled &&
++ wi->power.flags & IW_POWER_MIN )
++ nSc.powerManagementMode = 2; // power save mode
++ }
++
++ if ( wi->has_essid && strlen ( wi->essid )) {
++ nSc.haveDesiredSSID = TRUE;
++ strcpy ( nSc.desiredSSID, wi->essid );
++ }
++
++ if ( wi->has_mode ) {
++ nSc.haveDesiredBSSType = TRUE;
++ if ( wi->mode == IW_MODE_ADHOC )
++ nSc.desiredBSSType = 2; // independent
++ else if ( wi->has_ap_addr )
++ nSc.desiredBSSType = 1; // infrastructure
++ else
++ nSc.desiredBSSType = 3; // any
++ }
++
++ if ( wi->has_range ) {
++ for ( i = 0; i < wi->range.num_bitrates && j < 126; i++ ) {
++ nSc.haveOperationalRateSet = TRUE;
++ nSc.operationalRateSet[j++] = ( char ) ( wi->range.bitrate[i] / 500000L );
++ }
++ }
++
++ // dot11AuthenticationAlgorithmsTable
++ nAa.haveAuthenticationAlgorithm = TRUE; // it's a rule to always have
++ nAa.haveAuthenticationAlgorithmsEnable = TRUE; // 'open' supported
++ nAa.ifIndex = ifIndex;
++ nAa.authenticationAlgorithmsIndex = 1; // index number one
++ nAa.authenticationAlgorithm = 1; // 1 => open key
++ sprintf ( nAa.UID, "%04d%04d\0", nAa.ifIndex, nAa.authenticationAlgorithmsIndex );
++ nAa.authenticationAlgorithmsEnable = 1; // enabled by default
++ if ( ( wi->has_key ) &&
++ ( wi->key_size != 0 ) &&
++ !( wi->key_flags & IW_ENCODE_DISABLED ))
++ nAa.authenticationAlgorithmsEnable = 2;
++ addList (( char * ) &aaList, ( char * ) &nAa, sizeof ( nAa ));
++
++ nAa.haveAuthenticationAlgorithm = TRUE; // I'm gonna assume we always support WEP
++ nAa.haveAuthenticationAlgorithmsEnable = TRUE;
++ nAa.ifIndex = ifIndex;
++ nAa.authenticationAlgorithmsIndex = 2; // index number 2
++ nAa.authenticationAlgorithm = 2; // 2 => shared key
++ sprintf ( nAa.UID, "%04d%04d\0", nAa.ifIndex, nAa.authenticationAlgorithmsIndex );
++ nAa.authenticationAlgorithmsEnable = 2;
++ if ( ( wi->has_key ) &&
++ ( wi->key_size != 0 ) &&
++ !( wi->key_flags & IW_ENCODE_DISABLED ))
++ nAa.authenticationAlgorithmsEnable = 1; // disabled by default
++ addList (( char * ) &aaList, ( char * ) &nAa, sizeof ( nAa ));
++
++ //dot11WEPDefaultKeysTable
++ if ( wi->has_range ) {
++ for ( i = 0; i < MAX_WEP_KEYS; i++ ) {
++ nDf.haveWEPDefaultKeyValue = TRUE;
++ nDf.ifIndex = ifIndex;
++ nDf.WEPDefaultKeyIndex = i + 1; // index number
++ sprintf ( nDf.UID, "%04d%04d\0", nDf.ifIndex, nDf.WEPDefaultKeyIndex );
++ if ( wep[i].haveKey )
++ strcpy ( nDf.WEPDefaultKeyValue, "*****" );
++ else
++ nDf.WEPDefaultKeyValue[0] = '\0';
++ addList (( char * ) &dfList, ( char * ) &nDf, sizeof ( nDf ));
++ }
++ }
++
++ // dot11PrivacyTable
++ nPr.havePrivacyInvoked = TRUE;
++ nPr.privacyInvoked = 2; // 2 => FALSE
++ nPr.haveWEPDefaultKeyID = TRUE;
++ nPr.WEPDefaultKeyID = 0;
++ nPr.haveExcludeUnencrypted = TRUE;
++ nPr.excludeUnencrypted = 2; // 2 => FALSE
++ if ( wi->has_range ) {
++ if ( ( wi->key_size != 0 ) &&
++ !( wi->key_flags & IW_ENCODE_DISABLED )) {
++ nPr.privacyInvoked = 1;
++ if ( wi->key_flags & IW_ENCODE_RESTRICTED )
++ nPr.excludeUnencrypted = 1;
++ nPr.WEPDefaultKeyID = wepCurrentKey;
++ }
++ }
++
++ // dot11Mac Group
++ // dot11OperationTable
++ if ( wi->has_range ) {
++ nOp.haveRTSThreshold = TRUE;
++ nOp.RTSThreshold = wi->range.max_rts;
++ }
++
++ if ( wi->has_frag && wi->frag.value ) {
++ nOp.haveFragmentationThreshold = TRUE;
++ nOp.fragmentationThreshold = wi->frag.value;
++ }
++
++ // dot11Phy Group
++ // dot11PhyOperationTable
++ if ( strstr ( wi->name, "IEEE 802.11-FS" )) nPo.PHYType = 1; // So what if I
++ if ( strstr ( wi->name, "IEEE 802.11-DS" )) nPo.PHYType = 2; // made up a couple?
++ if ( strstr ( wi->name, "IEEE 802.11-IR" )) nPo.PHYType = 3;
++ if ( strstr ( wi->name, "IEEE 802.11-OFDM" )) nPo.PHYType = 4; // 802.11a
++ if ( strstr ( wi->name, "IEEE 802.11-OFDM/DS" )) nPo.PHYType = 5; // 802.11g
++ if ( strstr ( wi->name, "IEEE 802.11-TURBO" )) nPo.PHYType = 6; // Atheros TURBO mode
++ if ( nPo.PHYType ) nPo.havePHYType = TRUE;
++
++ // dot11PhyDSSSTable
++ if ( wi->has_range ) { // && wi->freq <= ( double ) 2483000000 ) { // DSSS frequencies only
++ for ( i = 0; i < wi->range.num_frequency; i++ ) {
++ if ((( double ) ( wi->range.freq[i].e * 10 ) * ( double ) wi->range.freq[i].m ) == wi->freq ) {
++ nPd.haveCurrentChannel = TRUE;
++ nPd.currentChannel = wi->range.freq[i].i;
++ }
++ }
++ }
++
++ // dot11SupportedDataRatesTxTable
++ if ( wi->has_range ) {
++ for ( i = 0; i < wi->range.num_bitrates; i++ ) {
++ nRt.ifIndex = ifIndex;
++ nRt.supportedDataRatesTxIndex = i + 1;
++ nRt.supportedDataRatesTxValue = wi->range.bitrate[i] / 500000L;
++ nRt.haveSupportedDataRatesTxValue = TRUE;
++ sprintf ( nRt.UID, "%04d%04d\0", nRt.ifIndex, nRt.supportedDataRatesTxIndex );
++ strcpy ( nRt.ifName, ifName );
++ addList (( char * ) &rtList, ( char * ) &nRt, sizeof ( nRt ));
++ }
++ }
++
++ // dot11SupportedDataRatesRxTable
++ if ( wi->has_range ) {
++ for ( i = 0; i < wi->range.num_bitrates; i++ ) {
++ nRr.ifIndex = ifIndex;
++ nRr.supportedDataRatesRxIndex = i + 1;
++ nRr.supportedDataRatesRxValue = wi->range.bitrate[i] / 500000L;
++ nRr.haveSupportedDataRatesRxValue = TRUE;
++ sprintf ( nRr.UID, "%04d%04d\0", nRr.ifIndex, nRr.supportedDataRatesRxIndex );
++ strcpy ( nRr.ifName, ifName );
++ addList (( char * ) &rrList, ( char * ) &nRr, sizeof ( nRr ));
++ }
++ }
++
++//printf ( "%s max_encoding_tokens: %d\n",
++// "loadWiExtTo80211Structs() - ", wi->range.max_encoding_tokens );
++}
++
++/****************************************************************************
++* *
++* loadWiExt() - load wireless extensions structures; *
++* use ioctl calls and read /proc/net/wireless *
++* *
++****************************************************************************/
++static void loadWiExt ( int skfd, char *ifname, struct wireless_info *wi )
++{
++ struct iwreq wrq; // ioctl request structure
++ FILE *fp;
++ char bfr[1024];
++ char buffer[sizeof ( iwrange ) * 2]; /* Large enough */
++ char *s, *t;
++ int i, j;
++
++ strncpy ( wrq.ifr_name, ifname, IFNAMSIZ );
++
++ /* Get wireless name */
++ if ( ioctl ( skfd, SIOCGIWNAME, &wrq ) >= 0 ) {
++ strncpy ( wi->name, wrq.u.name, IFNAMSIZ );
++ wi->name[IFNAMSIZ] = '\0';
++ }
++
++ /* Get ranges */ // NOTE: some version checking in iwlib.c
++ memset ( buffer, 0, sizeof ( buffer ));
++ wrq.u.data.pointer = ( caddr_t ) &buffer;
++ wrq.u.data.length = sizeof ( buffer );
++ wrq.u.data.flags = 0;
++ if ( ioctl ( skfd, SIOCGIWRANGE, &wrq ) >= 0 ) {
++ memcpy (( char * ) &wi->range, buffer, sizeof ( iwrange ));
++ wi->has_range = 1;
++ }
++
++ /* Get network ID */
++ if ( ioctl ( skfd, SIOCGIWNWID, &wrq ) >= 0 ) {
++ memcpy ( &wi->nwid, &wrq.u.nwid, sizeof ( iwparam ));
++ wi->has_nwid = 1;
++ }
++
++ /* Get frequency / channel */ // THIS NUMBER LOOKS FUNNY
++ if ( ioctl ( skfd, SIOCGIWFREQ, &wrq ) >= 0 ) {
++ wi->has_freq = 1;
++ wi->freq = (( double ) wrq.u.freq.m ) * pow ( 10, wrq.u.freq.e );
++ }
++
++ /* Get sensitivity */
++ if ( ioctl ( skfd, SIOCGIWSENS, &wrq ) >= 0 ) {
++ wi->has_sens = 1;
++ memcpy ( &wi->sens, &wrq.u.sens, sizeof ( iwparam ));
++ }
++
++ /* Get encryption information */
++ wrq.u.data.pointer = ( caddr_t ) &wi->key;
++ wrq.u.data.length = IW_ENCODING_TOKEN_MAX;
++ wrq.u.data.flags = 0;
++ if ( ioctl ( skfd, SIOCGIWENCODE, &wrq ) >= 0 ) {
++ wi->has_key = 1;
++ wi->key_size = wrq.u.data.length;
++ wi->key_flags = wrq.u.data.flags;
++ wepCurrentKey = wrq.u.data.flags & IW_ENCODE_INDEX;
++ }
++
++ for ( i = 0; i < wi->range.max_encoding_tokens; i++ ) {
++ wrq.u.data.pointer = ( caddr_t ) &wi->key;
++ wrq.u.data.length = IW_ENCODING_TOKEN_MAX;
++ wrq.u.data.flags = i;
++ if ( ioctl ( skfd, SIOCGIWENCODE, &wrq ) >= 0 ) {
++ if ( ( wrq.u.data.length != 0 ) &&
++ !( wrq.u.data.flags & IW_ENCODE_DISABLED )) {
++ wep[i].len = wrq.u.data.length;
++ wep[i].haveKey = TRUE;
++ t = wep[i].key;
++ for ( j = 0; j < wrq.u.data.length; j++ ) {
++ if (( j & 0x1 ) == 0 && j != 0 )
++ strcpy ( t++, "-");
++ sprintf ( t, "%.2X", wi->key[j] );
++ t += 2;
++ }
++ t = '\0';
++ }
++ }
++ }
++
++ /* Get ESSID */
++ wrq.u.essid.pointer = ( caddr_t ) &wi->essid;
++ wrq.u.essid.length = IW_ESSID_MAX_SIZE + 1;
++ wrq.u.essid.flags = 0;
++ if ( ioctl ( skfd, SIOCGIWESSID, &wrq ) >= 0 ) {
++ wi->has_essid = 1;
++ wi->essid_on = wrq.u.data.flags;
++ }
++
++ /* Get AP address */
++ if ( ioctl ( skfd, SIOCGIWAP, &wrq ) >= 0 ) {
++ wi->has_ap_addr = 1;
++ memcpy ( &wi->ap_addr, &wrq.u.ap_addr, sizeof ( sockaddr ));
++ }
++
++ /* Get NickName */
++ wrq.u.essid.pointer = ( caddr_t ) &wi->nickname;
++ wrq.u.essid.length = IW_ESSID_MAX_SIZE + 1;
++ wrq.u.essid.flags = 0;
++ if ( ioctl ( skfd, SIOCGIWNICKN, &wrq ) >= 0 ) {
++ if ( wrq.u.data.length > 1 )
++ wi->has_nickname = 1;
++ }
++
++ /* Get bit rate */
++ if ( ioctl ( skfd, SIOCGIWRATE, &wrq ) >= 0 ) {
++ wi->has_bitrate = 1;
++ memcpy ( &wi->bitrate, &wrq.u.bitrate, sizeof ( iwparam ));
++ }
++
++ /* Get RTS threshold */
++ if ( ioctl ( skfd, SIOCGIWRTS, &wrq ) >= 0 ) {
++ wi->has_rts = 1;
++ memcpy ( &wi->rts, &wrq.u.rts, sizeof ( iwparam ));
++ }
++
++ /* Get fragmentation threshold */
++ if ( ioctl ( skfd, SIOCGIWFRAG, &wrq ) >= 0 ) {
++ wi->has_frag = 1;
++ memcpy ( &wi->frag, &wrq.u.frag, sizeof ( iwparam ));
++ }
++
++ /* Get operation mode */
++ if ( ioctl ( skfd, SIOCGIWMODE, &wrq ) >= 0 ) {
++ wi->mode = wrq.u.mode;
++ if ( wi->mode < IW_NUM_OPER_MODE && wi->mode >= 0 )
++ wi->has_mode = 1;
++ }
++
++ /* Get Power Management settings */ // #if WIRELESS_EXT > 9
++ wrq.u.power.flags = 0;
++ if ( ioctl ( skfd, SIOCGIWPOWER, &wrq ) >= 0 ) {
++ wi->has_power = 1;
++ memcpy ( &wi->power, &wrq.u.power, sizeof ( iwparam ));
++ }
++
++ /* Get retry limit/lifetime */ // #if WIRELESS_EXT > 10
++ if ( ioctl ( skfd, SIOCGIWRETRY, &wrq ) >= 0 ) {
++ wi->has_retry = 1;
++ memcpy ( &wi->retry, &wrq.u.retry, sizeof ( iwparam ));
++ }
++
++ /* Get stats */ // #if WIRELESS_EXT > 11
++ wrq.u.data.pointer = ( caddr_t ) &wi->stats;
++ wrq.u.data.length = 0;
++ wrq.u.data.flags = 1; /* Clear updated flag */
++ if ( ioctl ( skfd, SIOCGIWSTATS, &wrq ) < 0 )
++ wi->has_stats = 1;
++
++ if ( !wi->has_stats ) { // no ioctl support, go to file
++ fp = fopen ( PROC_NET_WIRELESS, "r" );
++ if ( fp ) {
++ while ( fgets ( bfr, sizeof ( bfr ), fp )) {
++ bfr [ sizeof ( bfr ) - 1 ] = '\0'; // no buffer overruns here!
++ strtok (( char * ) &bfr, "\n" ); // '\n' => '\0'
++ if ( strstr ( bfr, ifname ) && strstr ( bfr, ":" )) {
++ wi->has_stats = 1;
++ s = bfr;
++ s = strchr ( s, ':' ); s++; /* Skip ethX: */
++ s = strtok ( s, " " ); /* ' ' => '\0' */
++ sscanf ( s, "%X", &wi->stats.status ); // status
++
++ s = strtok ( NULL, " " ); // link quality
++ if ( strchr ( s, '.' ) != NULL )
++ wi->stats.qual.updated |= 1;
++ sscanf ( s, "%d", &wi->stats.qual.qual );
++
++ s = strtok ( NULL, " " ); // signal level
++ if ( strchr ( s,'.' ) != NULL )
++ wi->stats.qual.updated |= 2;
++ sscanf ( s, "%d", &wi->stats.qual.level );
++
++ s = strtok ( NULL, " " ); // noise level
++ if ( strchr ( s, '.' ) != NULL )
++ wi->stats.qual.updated += 4;
++ sscanf ( s, "%d", &wi->stats.qual.noise );
++
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.discard.nwid );
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.discard.code );
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.discard.fragment );
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.discard.retries );
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.discard.misc );
++ s = strtok ( NULL, " " ); sscanf ( s, "%d", &wi->stats.miss.beacon );
++ }
++ }
++ fclose ( fp );
++ }
++ }
++
++// printf ( "%s bfr: %s\n", "loadTables()", bfr );
++}
++
++/****************************************************************************
++* *
++* displayWiExt() - show what I got from Wireless Extensions *
++* *
++****************************************************************************/
++static void displayWiExt ( struct wireless_info info )
++{
++#ifdef DISPLAYWIEXT
++ int i;
++ char title[] = "displayWiExt() -";
++
++ printf ( "========================================\n" );
++ printf ( "===> Wireless Extension IOCTL calls <===\n" );
++ printf ( "========================================\n" );
++
++ if ( strlen ( info.name ))
++ printf ( "%s name: %s\n", "SIOCGIWNAME", info.name );
++ else
++ printf ( "%s\n", "no info.name support" );
++
++ if ( info.has_nickname = 1 )
++ printf ( "%s nickname: %s\n", "SIOCGIWNICKN", info.nickname );
++ else
++ printf ( "%s %s\n", "SIOCGIWNICKN", " ===> no info.nickname support" );
++
++ if ( info.has_essid )
++ printf ( "%s essid_on: %d essid: %s\n", "SIOCGIWESSID", info.essid_on, info.essid );
++ else
++ printf ( "%s %s\n", "SIOCGIWESSID", " ===> no info.essid support" );
++
++ if ( info.has_range ) {
++ printf ( "%s throughput: %d\n", "SIOCGIWRANGE", info.range.throughput );
++ printf ( "%s min_nwid: %d\n", "SIOCGIWRANGE", info.range.min_nwid );
++ printf ( "%s max_nwid: %d\n", "SIOCGIWRANGE", info.range.max_nwid );
++ printf ( "%s sensitivity: %d\n", "SIOCGIWRANGE", info.range.sensitivity );
++ printf ( "%s num_bitrates: %d\n", "SIOCGIWRANGE", info.range.num_bitrates );
++ for ( i = 0; i < info.range.num_bitrates; i++ )
++ printf ( "%s bitrate[%d]: %d\n", "SIOCGIWRANGE", i, info.range.bitrate[i] );
++ printf ( "%s min_rts: %d\n", "SIOCGIWRANGE", info.range.min_rts );
++ printf ( "%s max_rts: %d\n", "SIOCGIWRANGE", info.range.max_rts );
++ printf ( "%s min_frag: %d\n", "SIOCGIWRANGE", info.range.min_frag );
++ printf ( "%s max_frag: %d\n", "SIOCGIWRANGE", info.range.max_frag );
++ printf ( "%s min_pmp: %d\n", "SIOCGIWRANGE", info.range.min_pmp );
++ printf ( "%s max_pmp: %d\n", "SIOCGIWRANGE", info.range.max_pmp );
++ printf ( "%s min_pmt: %d\n", "SIOCGIWRANGE", info.range.min_pmt );
++ printf ( "%s max_pmt: %d\n", "SIOCGIWRANGE", info.range.max_pmt );
++ printf ( "%s pmp_flags: %d\n", "SIOCGIWRANGE", info.range.pmp_flags );
++ printf ( "%s pmt_flags: %d\n", "SIOCGIWRANGE", info.range.pmt_flags );
++ printf ( "%s pm_capa: %d\n", "SIOCGIWRANGE", info.range.pm_capa );
++ printf ( "%s num_encoding_sizes: %d\n", "SIOCGIWRANGE", info.range.num_encoding_sizes );
++ for ( i = 0; i < info.range.num_encoding_sizes; i++ )
++ printf ( "%s encoding_size[%d]: %d\n", "SIOCGIWRANGE", i, info.range.encoding_size[i] );
++ printf ( "%s max_encoding_tokens: %d\n", "SIOCGIWRANGE", info.range.max_encoding_tokens );
++// printf ( "%s encoding_login_index: %d\n", "SIOCGIWRANGE", info.range.encoding_login_index );
++ printf ( "%s txpower_capa: %d\n", "SIOCGIWRANGE", info.range.txpower_capa );
++ printf ( "%s num_txpower: %d dBm\n", "SIOCGIWRANGE", info.range.num_txpower );
++ for ( i = 0; i < info.range.num_txpower; i++ )
++ printf ( "%s txpower[%d]: %d\n", "SIOCGIWRANGE", i, info.range.txpower[i] );
++ printf ( "%s we_version_compiled: %d\n", "SIOCGIWRANGE", info.range.we_version_compiled );
++ printf ( "%s we_version_source: %d\n", "SIOCGIWRANGE", info.range.we_version_source );
++ printf ( "%s retry_capa: %d\n", "SIOCGIWRANGE", info.range.retry_capa );
++ printf ( "%s retry_flags: %d\n", "SIOCGIWRANGE", info.range.retry_flags );
++ printf ( "%s r_time_flags: %d\n", "SIOCGIWRANGE", info.range.r_time_flags );
++ printf ( "%s min_retry: %d\n", "SIOCGIWRANGE", info.range.min_retry );
++ printf ( "%s max_retry: %d\n", "SIOCGIWRANGE", info.range.max_retry );
++ printf ( "%s min_r_time: %d\n", "SIOCGIWRANGE", info.range.min_r_time );
++ printf ( "%s max_r_time: %d\n", "SIOCGIWRANGE", info.range.max_r_time );
++ printf ( "%s num_channels: %d\n", "SIOCGIWRANGE", info.range.num_channels );
++ printf ( "%s num_frequency: %d\n", "SIOCGIWRANGE", info.range.num_frequency );
++ for ( i = 0; i < info.range.num_frequency; i++ )
++ printf ( "%s freq[%d].i: %d freq[%d].e: %d freq[%d].m: %d\n", "SIOCGIWRANGE",
++ i, info.range.freq[i].i, i, info.range.freq[i].e, i, info.range.freq[i].m );
++ }
++ else
++ printf ( "%s %s\n", "SIOCGIWRANGE", " ===> no info.range support" );
++
++ if ( info.has_nwid )
++ printf ( "%s nwid - disabled: %d value: %X\n", "SIOCGIWNWID", info.nwid.disabled, info.nwid.value );
++ else
++ printf ( "%s %s\n", "SIOCGIWNWID", " ===> no info.nwid support" );
++
++ if ( info.has_freq ) {
++// printf ( "%s freq: %g\n", "SIOCGIWFREQ", info.freq / GIGA );
++ printf ( "%s freq: %g\n", "SIOCGIWFREQ", info.freq );
++ }
++ else
++ printf ( "%s %s\n", "SIOCGIWFREQ", " ===> no info.freq support" );
++
++ if ( info.has_sens )
++ printf ( "%s sens: %d\n", "SIOCGIWSENS", info.sens );
++ else
++ printf ( "%s %s\n", "SIOCGIWSENS", " ===> no info.sens support" );
++
++ if ( info.has_key ) {
++ printf ( "%s key_size: %d key_flags: %d wepCurrentKey: %d\n",
++ "SIOCGIWENCODE", info.key_size, info.key_flags, wepCurrentKey );
++ printf ( "%s MODE: %d DISABLED: %d INDEX: %d OPEN: %d RESTRICTED: %d NOKEY: %d TEMP: %d\n",
++ "SIOCGIWENCODE", info.key_flags & IW_ENCODE_MODE,
++ info.key_flags & IW_ENCODE_DISABLED ? 1:0, info.key_flags & IW_ENCODE_INDEX,
++ info.key_flags & IW_ENCODE_OPEN ? 1:0, info.key_flags & IW_ENCODE_RESTRICTED ? 1:0,
++ info.key_flags & IW_ENCODE_NOKEY ? 1:0, info.key_flags & IW_ENCODE_TEMP ? 1:0 );
++ }
++ else
++ printf ( "%s %s\n", "SIOCGIWENCODE", " ===> no info.key support" );
++
++ for ( i = 0; i < MAX_WEP_KEYS; i++ ) {
++ if ( wep[i].haveKey )
++ printf ( "%s wep[%d].len: %d wep[%d].key: %s\n",
++ "SIOCGIWENCODE", i, wep[i].len, i, wep[i].key );
++ }
++
++ if ( info.has_ap_addr )
++ printf ( "%s ap_addr.sa_data: %02X:%02X:%02X:%02X:%02X:%02X ap_addr.sa_family: %d\n",
++ "SIOCGIWAP", ( UCHAR ) info.ap_addr.sa_data[0], ( UCHAR ) info.ap_addr.sa_data[1],
++ ( UCHAR ) info.ap_addr.sa_data[2], ( UCHAR ) info.ap_addr.sa_data[3],
++ ( UCHAR ) info.ap_addr.sa_data[4], ( UCHAR ) info.ap_addr.sa_data[5],
++ info.ap_addr.sa_family );
++ else
++ printf ( "%s %s\n", "SIOCGIWAP", " ===> no ap_addr information" );
++
++ if ( info.has_bitrate )
++ printf ( "%s bitrate: %d value: %d fixed: %d disabled: %d flags: %d\n",
++ "SIOCGIWRATE", info.bitrate, info.bitrate.value, info.bitrate.fixed,
++ info.bitrate.disabled, info.bitrate.flags );
++ else
++ printf ( "%s %s\n", "SIOCGIWRATE", " ===> no info.bitrate support" );
++
++ if ( info.has_rts )
++ printf ( "%s rts: %d\n", "SIOCGIWRTS", info.rts );
++ else
++ printf ( "%s %s\n", "SIOCGIWRTS", " ===> no info.rts support" );
++
++ if ( info.has_frag )
++ printf ( "%s frag: %d\n", "SIOCGIWFRAG", info.frag );
++ else
++ printf ( "%s %s\n", "SIOCGIWFRAG", " ===> no info.frag support" );
++
++ if ( info.has_mode )
++ printf ( "%s mode: %d\n", "SIOCGIWMODE", info.mode );
++ else
++ printf ( "%s %s\n", "SIOCGIWMODE", " ===> no info.mode support" );
++
++ if ( info.has_power ) {
++ printf ( "%s power: %d\n", "SIOCGIWPOWER", info.power );
++ printf ( "%s disabled: %d MIN: %d MAX: %d TIMEOUT: %d RELATIVE: %d\n",
++ "SIOCGIWPOWER",
++ info.power.disabled ? 1:0,
++ info.power.flags & IW_POWER_MIN ? 1:0,
++ info.power.flags & IW_POWER_MAX ? 1:0,
++ info.power.flags & IW_POWER_TIMEOUT ? 1:0,
++ info.power.flags & IW_POWER_RELATIVE ? 1:0 );
++ printf ( "%s UNICAST: %d MULTICAST: %d ALL: %d FORCE: %d REPEATER: %d\n",
++ "SIOCGIWPOWER",
++ info.power.flags & IW_POWER_UNICAST_R ? 1:0,
++ info.power.flags & IW_POWER_MULTICAST_R ? 1:0,
++ info.power.flags & IW_POWER_ALL_R ? 1:0,
++ info.power.flags & IW_POWER_FORCE_S ? 1:0,
++ info.power.flags & IW_POWER_REPEATER ? 1:0 );
++ }
++ else
++ printf ( "%s %s\n", "SIOCGIWPOWER", " ===> no info.power support" );
++
++ if ( info.has_retry )
++ printf ( "%s retry: %d\n", "SIOCGIWRETRY", info.retry );
++ else
++ printf ( "%s %s\n", "SIOCGIWRETRY", " ===> no info.retry support" );
++
++ if ( info.has_stats ) {
++ printf ( "%s status: %d\n", "SIOCGIWSTATS", info.stats.status );
++ printf ( "%s qual.level: %d\n", "SIOCGIWSTATS", info.stats.qual.level );
++ printf ( "%s qual.noise: %d\n", "SIOCGIWSTATS", info.stats.qual.noise );
++ printf ( "%s qual.qual: %d\n", "SIOCGIWSTATS", info.stats.qual.qual );
++ printf ( "%s qual.updated: %d\n", "SIOCGIWSTATS", info.stats.qual.updated );
++ printf ( "%s discard.code: %d\n", "SIOCGIWSTATS", info.stats.discard.code );
++ printf ( "%s discard.fragment: %d\n", "SIOCGIWSTATS", info.stats.discard.fragment );
++ printf ( "%s discard.misc: %d\n", "SIOCGIWSTATS", info.stats.discard.misc );
++ printf ( "%s discard.nwid: %d\n", "SIOCGIWSTATS", info.stats.discard.nwid );
++ printf ( "%s discard.retries: %d\n", "SIOCGIWSTATS", info.stats.discard.retries );
++ printf ( "%s miss.beacon: %d\n", "SIOCGIWSTATS", info.stats.miss.beacon );
++ }
++ else
++ printf ( "%s %s\n", "SIOCGIWSTATS", " ===> no info.stats support" );
++
++ if ( info.txpower.flags & IW_TXPOW_MWATT )
++ printf ( "%s txpower1: %d dBm disabled: %d fixed: %d flags: %d\n", "SIOCGIWRANGE",
++ mWatt2dbm ( info.txpower.value ), info.txpower.disabled, info.txpower.fixed, info.txpower.flags);
++ else
++ printf ( "%s txpower2: %d dBm disabled: %d fixed: %d flags: %d\n", "SIOCGIWRANGE", info.txpower.value, info.txpower.disabled, info.txpower.fixed, info.txpower.flags );
++
++ if ( info.has_range )
++ if ( info.sens.value < 0 )
++ printf ( "%s sens: %d dBm\n", "SIOCGIWRANGE", info.sens.value );
++ else
++ printf ( "%s sens: %d/%d\n", "SIOCGIWRANGE", info.sens.value, info.range.sensitivity );
++
++ if ( info.has_range && ( info.stats.qual.level != 0 ))
++ if ( info.stats.qual.level > info.range.max_qual.level )
++ /* Statistics are in dBm (absolute power measurement) */
++ printf ( "%s Quality: %d/%d Signal level: %d dBm Noise level: %d dBm\n",
++ "SIOCGIWRANGE",
++ info.stats.qual.qual, info.range.max_qual.qual,
++ info.stats.qual.level - 0x100,
++ info.stats.qual.noise - 0x100 );
++ else
++ printf ( "%s Quality: %d/%d Signal level: %d/%d Noise level: %d/%d",
++ "SIOCGIWRANGE",
++ info.stats.qual.qual, info.range.max_qual.qual,
++ info.stats.qual.level, info.range.max_qual.level,
++ info.stats.qual.noise, info.range.max_qual.noise );
++
++#endif // #ifdef DISPLAYWIEXT
++}
++
++/****************************************************************************
++* *
++* Linked List Functions *
++* *
++****************************************************************************/
++/****************************************************************************
++* *
++* addList() - add an entry to a linked list *
++* *
++****************************************************************************/
++static void
++addList ( char *l, char *data, int len )
++{
++ char uid[256];
++ LIST_HEAD ( , avNode ) *list;
++
++ // NOTE: this assumes the UID is at the begining of the
++ // data structure and that UIDs are strings
++
++ list = ( LIST_HEAD ( , avNode ) * ) l; // NOTE: don't know how to get
++ strcpy ( uid, data ); // rid of compiler warning on
++ // LISTHEAD typecast
++ // create a new node and the data that goes in it
++ newNode = malloc ( sizeof ( struct avNode ));
++ newNode->data = malloc ( len );
++ memcpy ( newNode->data, data, len );
++
++ // this deals with an empty list
++ if ( LIST_EMPTY ( list )) {
++ LIST_INSERT_HEAD ( list, newNode, nodes );
++ return;
++ }
++
++ // this deals with UIDs that match
++ for ( np = LIST_FIRST ( list ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ if ( strncmp ( uid, np->data, strlen ( uid )) == 0 ) { // found matching UID
++ LIST_INSERT_AFTER ( np, newNode, nodes );
++ if ( np->data )
++ free ( np->data );
++ LIST_REMOVE ( np, nodes );
++ free ( np );
++ return;
++ }
++ }
++
++ // this deals with inserting a new UID in the list
++ for ( np = LIST_FIRST ( list ); np != NULL; np = LIST_NEXT ( np, nodes )) {
++ lastNode = np;
++ if ( strncmp ( np->data, uid, strlen ( uid )) > 0 ) { // old ID > new ID AND
++ LIST_INSERT_BEFORE ( np, newNode, nodes );
++ return;
++ }
++ }
++
++ // this deals with a UID that needs to go on the end of the list
++ LIST_INSERT_AFTER ( lastNode, newNode, nodes );
++
++ return;
++}
++
++/****************************************************************************
++* *
++* initLists() - initialize all the linked lists *
++* *
++****************************************************************************/
++static void initLists()
++{
++ LIST_INIT ( &scList ); LIST_INIT ( &aaList ); LIST_INIT ( &dfList );
++ LIST_INIT ( &kmList ); LIST_INIT ( &prList );
++ LIST_INIT ( &opList ); LIST_INIT ( &coList );
++ LIST_INIT ( &gaList ); LIST_INIT ( &riList ); LIST_INIT ( &poList );
++ LIST_INIT ( &paList ); LIST_INIT ( &ptList ); LIST_INIT ( &pfList );
++ LIST_INIT ( &pdList ); LIST_INIT ( &piList ); LIST_INIT ( &rdList );
++ LIST_INIT ( &alList ); LIST_INIT ( &rtList ); LIST_INIT ( &rrList );
++}
++/****************************************************************************
++* *
++* flushLists() - flush all linked lists *
++* *
++****************************************************************************/
++static void flushLists()
++{
++ flushList (( char * ) &scList ); flushList (( char * ) &aaList );
++ flushList (( char * ) &dfList ); flushList (( char * ) &kmList );
++ flushList (( char * ) &prList );
++ flushList (( char * ) &opList ); flushList (( char * ) &coList );
++ flushList (( char * ) &gaList ); flushList (( char * ) &riList );
++ flushList (( char * ) &poList ); flushList (( char * ) &paList );
++ flushList (( char * ) &ptList ); flushList (( char * ) &pfList );
++ flushList (( char * ) &pdList ); flushList (( char * ) &piList );
++ flushList (( char * ) &rdList ); flushList (( char * ) &alList );
++ flushList (( char * ) &rtList ); flushList (( char * ) &rrList );
++}
++
++/****************************************************************************
++* *
++* flushList() - flush a linked list *
++* *
++****************************************************************************/
++static void flushList ( char *l )
++{
++ LIST_HEAD ( , avNode ) *list;
++
++ list = ( LIST_HEAD ( , avNode ) * ) l; // NOTE: don't know how to get
++ while ( !LIST_EMPTY ( list )) { // rid of compiler warning on
++ np = LIST_FIRST ( list ); // LISTHEAD typecast
++ if ( np->data )
++ free ( np->data );
++ LIST_REMOVE ( np, nodes );
++ free ( np );
++ }
++}
++
++/****************************************************************************
++* *
++* Utility Functions *
++* *
++****************************************************************************/
++/****************************************************************************
++* *
++* The following two routines were taken directly from iwlib.c *
++* *
++****************************************************************************/
++ /*
++ * Open a socket.
++ * Depending on the protocol present, open the right socket. The socket
++ * will allow us to talk to the driver.
++ */
++static int openSocket ( void )
++{
++ static const int families[] = {
++ AF_INET, AF_IPX, AF_AX25, AF_APPLETALK
++ };
++ unsigned int i;
++ int sock;
++
++ /*
++ * Now pick any (exisiting) useful socket family for generic queries
++ * Note : don't open all the socket, only returns when one matches,
++ * all protocols might not be valid.
++ * Workaround by Jim Kaba <jkaba@sarnoff.com>
++ * Note : in 99% of the case, we will just open the inet_sock.
++ * The remaining 1% case are not fully correct...
++ */
++
++ /* Try all families we support */
++ for(i = 0; i < sizeof(families)/sizeof(int); ++i) {
++ /* Try to open the socket, if success returns it */
++ sock = socket(families[i], SOCK_DGRAM, 0);
++ if(sock >= 0)
++ return sock;
++ }
++
++ return -1;
++}
++
++/*------------------------------------------------------------------*/
++/*
++ * Convert a value in milliWatt to a value in dBm.
++ */
++static int mWatt2dbm ( int in )
++{
++#ifdef WE_NOLIBM
++ /* Version without libm : slower */
++ double fin = (double) in;
++ int res = 0;
++
++ /* Split integral and floating part to avoid accumulating rounding errors */
++ while(fin > 10.0)
++ {
++ res += 10;
++ fin /= 10.0;
++ }
++ while(fin > 1.000001) /* Eliminate rounding errors, take ceil */
++ {
++ res += 1;
++ fin /= LOG10_MAGIC;
++ }
++ return(res);
++#else /* WE_NOLIBM */
++ /* Version with libm : faster */
++ return((int) (ceil(10.0 * log10((double) in))));
++#endif /* WE_NOLIBM */
++}
++
++/****************************************************************************
++* *
++* htob - converts hex string to binary *
++* *
++****************************************************************************/
++static char *htob ( char *s )
++{
++ char nibl, *byt;
++ static char bin[20];
++
++ byt = bin;
++
++ while ((nibl = *s++) && nibl != ' ') { /* While not end of string. */
++ nibl -= ( nibl > '9') ? ('A' - 10): '0';
++ *byt = nibl << 4; /* place high nibble */
++ if((nibl = *s++) && nibl != ' ') {
++ nibl -= ( nibl > '9') ? ('A' - 10): '0';
++ *byt |= nibl; /* place low nibble */
++ }
++ else break;
++ ++byt;
++ }
++ *++byt = '\0';
++ return ( bin );
++}
++
++/****************************************************************************
++* *
++* hasChanged() - see if area has been changed from NULLs *
++* *
++****************************************************************************/
++static int hasChanged ( char *loc, int len )
++{
++ char *wrk;
++ int changed = TRUE;
++
++ wrk = malloc ( len );
++ memset ( wrk, 0, len );
++ if ( memcmp ( loc, wrk, len ) == 0 )
++ changed = FALSE;
++ free ( wrk );
++
++ return ( changed );
++}
++
+--- net-snmp-5.1.2-orig/agent/mibgroup/ieee802dot11.h 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/agent/mibgroup/ieee802dot11.h 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,730 @@
++/****************************************************************************
++* *
++* File Name: ieee802dot11.h *
++* Used By: *
++* *
++* Operating System: *
++* Purpose: *
++* *
++* Comments: *
++* *
++* Author: Larry Simmons *
++* lsimmons@avantcom.com *
++* www.avantcom.com *
++* *
++* Creation Date: 09/02/03 *
++* *
++* Ver Date Inits Modification *
++* ----- -------- ----- ------------ *
++* 0.0.1 09/02/03 LRS created *
++* 0.0.2 09/24/03 LRS wouldn't build after fresh ./configure *
++****************************************************************************/
++/* This file was generated by mib2c and is intended for use as a mib module
++ for the ucd-snmp snmpd agent. */
++#ifndef _MIBGROUP_IEEE802DOT11_H
++#define _MIBGROUP_IEEE802DOT11_H
++/* we may use header_generic and header_simple_table from the util_funcs module */
++
++/****************************************************************************
++* Includes *
++****************************************************************************/
++#include <sys/queue.h>
++
++/****************************************************************************
++* Linked List Defines *
++****************************************************************************/
++// here are some Linked List MACROS I wanted to use,
++// but curiously were not in /usr/includes/sys/queue.h
++
++#ifndef LIST_EMPTY
++ #define LIST_EMPTY(head) ((head)->lh_first == NULL)
++#endif
++
++#ifndef LIST_NEXT
++ #define LIST_NEXT(elm, field) ((elm)->field.le_next)
++#endif
++
++#ifndef LIST_INSERT_BEFORE
++ #define LIST_INSERT_BEFORE(listelm, elm, field) do { \
++ (elm)->field.le_prev = (listelm)->field.le_prev; \
++ LIST_NEXT((elm), field) = (listelm); \
++ *(listelm)->field.le_prev = (elm); \
++ (listelm)->field.le_prev = &LIST_NEXT((elm), field); \
++ } while (0)
++#endif
++
++#ifndef LIST_FIRST
++ #define LIST_FIRST(head) ((head)->lh_first)
++#endif
++
++/****************************************************************************
++* 802.11 MIB Defines *
++****************************************************************************/
++#define SYS_STRING_LEN 256
++#define MACADDR_LEN ( 6 * 2 ) + 5
++#define OPER_RATE_SET_LEN 126
++#define MAN_OUI_LEN ( 3 * 2 ) + 2
++#define WEP_STR_LEN 64
++#define SNMP_STR_LEN 128
++#define TEXT_LEN 80
++#define IFINDEX_LEN 4
++#define IFNAME_LEN 16
++#define MAX_WEP_KEYS 4
++
++#define AUTHENICATION_ALGORITHMS_INDEX_LEN 4
++#define WEP_DEFAULT_KEY_INDEX_LEN 4
++#define WEP_KEY_MAPPING_INDEX_LEN 4
++#define GROUP_ADDRESS_INDEX_LEN 4
++#define REG_DOMAIN_SUPPORT_INDEX_LEN 4
++#define ANTENNA_LIST_INDEX_LEN 4
++#define SUPPORTED_DATA_RATES_TX_INDEX_LEN 4
++#define SUPPORTED_DATA_RATES_RX_INDEX_LEN 4
++
++#define SC_UID_LEN IFINDEX_LEN
++#define AA_UID_LEN IFINDEX_LEN + AUTHENICATION_ALGORITHMS_INDEX_LEN
++#define DF_UID_LEN IFINDEX_LEN + WEP_DEFAULT_KEY_INDEX_LEN
++#define KM_UID_LEN IFINDEX_LEN + WEP_KEY_MAPPING_INDEX_LEN
++#define PR_UID_LEN IFINDEX_LEN
++#define OP_UID_LEN IFINDEX_LEN
++#define CO_UID_LEN IFINDEX_LEN
++#define GA_UID_LEN IFINDEX_LEN + GROUP_ADDRESS_INDEX_LEN
++#define RI_UID_LEN IFINDEX_LEN
++#define PO_UID_LEN IFINDEX_LEN
++#define PA_UID_LEN IFINDEX_LEN
++#define PT_UID_LEN IFINDEX_LEN
++#define PF_UID_LEN IFINDEX_LEN
++#define PD_UID_LEN IFINDEX_LEN
++#define PI_UID_LEN IFINDEX_LEN
++#define RD_UID_LEN IFINDEX_LEN + REG_DOMAIN_SUPPORT_INDEX_LEN
++#define AL_UID_LEN IFINDEX_LEN + ANTENNA_LIST_INDEX_LEN
++#define RT_UID_LEN IFINDEX_LEN + SUPPORTED_DATA_RATES_TX_INDEX_LEN
++#define RR_UID_LEN IFINDEX_LEN + SUPPORTED_DATA_RATES_RX_INDEX_LEN
++
++/****************************************************************************
++* Linked List Structure *
++****************************************************************************/
++static struct avNode {
++ LIST_ENTRY ( avNode ) nodes;
++ char *data; // pointer to data
++};
++
++typedef LIST_HEAD ( , avNode ) avList_t;
++
++/****************************************************************************
++* 802.11 MIB structures *
++****************************************************************************/
++/****************************************************************************
++* dot11Smt Group *
++****************************************************************************/
++/****************************************************************************
++* dot11StationConfigTable *
++****************************************************************************/
++static struct scTbl_data {
++
++ char UID [ SC_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ char stationID [ MACADDR_LEN + 1 ]; // Default actual MacAddr
++ long mediumOccupancyLimit;
++ long CFPPollable;
++ long CFPPeriod;
++ long maxDuration;
++ long authenticationResponseTimeOut;
++ long privacyOptionImplemented;
++ long powerManagementMode;
++ char desiredSSID [ SNMP_STR_LEN + 1 ];
++ long desiredBSSType;
++ char operationalRateSet [ OPER_RATE_SET_LEN + 1];
++ long beaconPeriod;
++ long DTIMPeriod;
++ long associationResponseTimeOut;
++ long disAssociationReason;
++ char disAssociationStation [ MACADDR_LEN + 1 ];
++ long deAuthenticationReason;
++ char deAuthenticationStation [ MACADDR_LEN + 1 ];
++ long authenticateFailStatus;
++ char authenticateFailStation [ MACADDR_LEN + 1 ];
++
++ long haveStationID;
++ long haveMediumOccupancyLimit;
++ long haveCFPPollable;
++ long haveCFPPeriod;
++ long haveMaxDuration;
++ long haveAuthenticationResponseTimeOut;
++ long havePrivacyOptionImplemented;
++ long havePowerManagementMode;
++ long haveDesiredSSID;
++ long haveDesiredBSSType;
++ long haveOperationalRateSet;
++ long haveBeaconPeriod;
++ long haveDTIMPeriod;
++ long haveAssociationResponseTimeOut;
++ long haveDisAssociationReason;
++ long haveDisAssociationStation;
++ long haveDeAuthenticationReason;
++ long haveDeAuthenticationStation;
++ long haveAuthenticateFailStatus;
++ long haveAuthenticateFailStation;
++
++} nSc, *sc = &nSc;
++
++static avList_t scList;
++
++/****************************************************************************
++* dot11AuthenticationAlgorithmsTable *
++****************************************************************************/
++static struct aaTbl_data {
++
++ char UID [ AA_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++ long authenticationAlgorithmsIndex;
++
++ long authenticationAlgorithm;
++ long authenticationAlgorithmsEnable;
++
++ long haveAuthenticationAlgorithm;
++ long haveAuthenticationAlgorithmsEnable;
++
++} nAa, *aa = &nAa;
++
++static avList_t aaList;
++
++/****************************************************************************
++* dot11WEPDefaultKeysTable *
++****************************************************************************/
++static struct dfTbl_data {
++
++ char UID [ DF_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long WEPDefaultKeyIndex;
++
++ char WEPDefaultKeyValue [ WEP_STR_LEN + 1 ];
++ long haveWEPDefaultKeyValue;
++
++} nDf, *df = &nDf;
++
++static avList_t dfList;
++
++/****************************************************************************
++* dot11WEPKeyMappingsTable *
++****************************************************************************/
++static struct kmTbl_data {
++
++ char UID [ KM_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex;
++ long WEPKeyMappingIndex;
++
++ char WEPKeyMappingAddress [ MACADDR_LEN + 1 ];
++ long WEPKeyMappingWEPOn;
++ char WEPKeyMappingValue [ WEP_STR_LEN + 1 ];
++ long WEPKeyMappingStatus;
++
++ long haveWEPKeyMappingIndex;
++ long haveWEPKeyMappingAddress;
++ long haveWEPKeyMappingWEPOn;
++ long haveWEPKeyMappingValue;
++ long haveWEPKeyMappingStatus;
++
++} nKm, *km = &nKm;
++
++static avList_t kmList;
++
++/****************************************************************************
++* dot11PrivacyTable *
++****************************************************************************/
++static struct prTbl_data {
++
++ char UID [ PR_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex;
++
++ long privacyInvoked;
++ long WEPDefaultKeyID;
++ long WEPKeyMappingLength;
++ long excludeUnencrypted;
++ unsigned long WEPICVErrorCount;
++ unsigned long WEPExcludedCount;
++
++ long havePrivacyInvoked;
++ long haveWEPDefaultKeyID;
++ long haveWEPKeyMappingLength;
++ long haveExcludeUnencrypted;
++ long haveWEPICVErrorCount;
++ long haveWEPExcludedCount;
++
++} nPr, *pr = &nPr;
++
++static avList_t prList;
++
++/****************************************************************************
++* dot11Mac Group *
++****************************************************************************/
++/****************************************************************************
++* dot11OperationTable *
++****************************************************************************/
++static struct opTbl_data {
++
++ char UID [ OP_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ char MACAddress [ MACADDR_LEN + 1 ];
++ long RTSThreshold;
++ long shortRetryLimit;
++ long longRetryLimit;
++ long fragmentationThreshold;
++ long maxTransmitMSDULifetime;
++ long maxReceiveLifetime;
++ char manufacturerID [ SNMP_STR_LEN + 1 ];
++ char productID [ SNMP_STR_LEN + 1 ];
++
++ long haveMACAddress;
++ long haveRTSThreshold;
++ long haveShortRetryLimit;
++ long haveLongRetryLimit;
++ long haveFragmentationThreshold;
++ long haveMaxTransmitMSDULifetime;
++ long haveMaxReceiveLifetime;
++ long haveManufacturerID;
++ long haveProductID;
++
++} nOp, *op = &nOp;
++
++static avList_t opList;
++
++/****************************************************************************
++* dot11CountersTable *
++****************************************************************************/
++static struct coTbl_data {
++
++ char UID [ CO_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ unsigned long transmittedFragmentCount;
++ unsigned long multicastTransmittedFrameCount;
++ unsigned long failedCount;
++ unsigned long retryCount;
++ unsigned long multipleRetryCount;
++ unsigned long frameDuplicateCount;
++ unsigned long RTSSuccessCount;
++ unsigned long RTSFailureCount;
++ unsigned long ACKFailureCount;
++ unsigned long receivedFragmentCount;
++ unsigned long multicastReceivedFrameCount;
++ unsigned long FCSErrorCount;
++ unsigned long transmittedFrameCount;
++ unsigned long WEPUndecryptableCount;
++
++ long haveTransmittedFragmentCount;
++ long haveMulticastTransmittedFrameCount;
++ long haveFailedCount;
++ long haveRetryCount;
++ long haveMultipleRetryCount;
++ long haveFrameDuplicateCount;
++ long haveRTSSuccessCount;
++ long haveRTSFailureCount;
++ long haveACKFailureCount;
++ long haveReceivedFragmentCount;
++ long haveMulticastReceivedFrameCount;
++ long haveFCSErrorCount;
++ long haveTransmittedFrameCount;
++ long haveWEPUndecryptableCount;
++
++} nCo, *co = &nCo;
++
++static avList_t coList;
++
++/****************************************************************************
++* dot11GroupAddressesTable *
++****************************************************************************/
++static struct gaTbl_data {
++
++ char UID [ GA_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long groupAddressesIndex;
++
++ char address [ MACADDR_LEN + 1 ];
++ long groupAddressesStatus;
++
++ long haveAddress;
++ long haveGroupAddressesStatus;
++
++} nGa, *ga = &nGa;
++
++static avList_t gaList;
++
++/****************************************************************************
++* dot11Res Group *
++****************************************************************************/
++static char resourceTypeIDName[] = "RTID";
++static long haveResourceTypeIDName = 1;
++
++/****************************************************************************
++* dot11ResourceInfoTable *
++****************************************************************************/
++static struct riTbl_data {
++
++ char UID [ RI_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ char manufacturerOUI [ MAN_OUI_LEN + 1 ];
++ char manufacturerName [ SYS_STRING_LEN + 1 ];
++ char manufacturerProductName [ SYS_STRING_LEN + 1 ];
++ char manufacturerProductVersion [ SYS_STRING_LEN + 1 ];
++
++ char haveManufacturerOUI;
++ char haveManufacturerName;
++ char haveManufacturerProductName;
++ char haveManufacturerProductVersion;
++
++} nRi, *ri = &nRi;
++
++static avList_t riList;
++
++/****************************************************************************
++* dot11Phy Group *
++****************************************************************************/
++/****************************************************************************
++* dot11PhyOperationTable *
++****************************************************************************/
++static struct poTbl_data {
++
++ char UID [ PO_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long PHYType;
++ long currentRegDomain;
++ long tempType;
++
++ long havePHYType;
++ long haveCurrentRegDomain;
++ long haveTempType;
++
++} nPo, *po = &nPo;
++
++static avList_t poList;
++
++/****************************************************************************
++* dot11PhyAntennaEntry *
++****************************************************************************/
++static struct paTbl_data {
++
++ char UID [ PA_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long currentTxAntenna;
++ long diversitySupport;
++ long currentRxAntenna;
++
++ long haveCurrentTxAntenna;
++ long haveDiversitySupport;
++ long haveCurrentRxAntenna;
++
++} nPa, *pa = &nPa;
++
++static avList_t paList;
++
++/****************************************************************************
++* dot11PhyTxPowerTable *
++****************************************************************************/
++static struct ptTbl_data {
++
++ char UID [ PT_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long numberSupportedPowerLevels;
++ long TxPowerLevel1;
++ long TxPowerLevel2;
++ long TxPowerLevel3;
++ long TxPowerLevel4;
++ long TxPowerLevel5;
++ long TxPowerLevel6;
++ long TxPowerLevel7;
++ long TxPowerLevel8;
++ long currentTxPowerLevel;
++
++ long haveNumberSupportedPowerLevels;
++ long haveTxPowerLevel1;
++ long haveTxPowerLevel2;
++ long haveTxPowerLevel3;
++ long haveTxPowerLevel4;
++ long haveTxPowerLevel5;
++ long haveTxPowerLevel6;
++ long haveTxPowerLevel7;
++ long haveTxPowerLevel8;
++ long haveCurrentTxPowerLevel ;
++
++} nPt, *pt = &nPt;
++
++static avList_t ptList;
++
++/****************************************************************************
++* dot11PhyFHSSTable *
++****************************************************************************/
++static struct pfTbl_data {
++
++ char UID [ PF_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long hopTime;
++ long currentChannelNumber;
++ long maxDwellTime;
++ long currentDwellTime;
++ long currentSet;
++ long currentPattern;
++ long currentIndex;
++
++ long haveHopTime;
++ long haveCurrentChannelNumber;
++ long haveMaxDwellTime;
++ long haveCurrentDwellTime;
++ long haveCurrentSet;
++ long haveCurrentPattern;
++ long haveCurrentIndex;
++
++} nPf, *pf = &nPf;
++
++static avList_t pfList;
++
++/****************************************************************************
++* dot11PhyDSSSTable *
++****************************************************************************/
++static struct pdTbl_data {
++
++ char UID [ PD_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long currentChannel;
++ long CCAModeSupported;
++ long currentCCAMode;
++ long EDThreshold;
++
++ long haveCurrentChannel;
++ long haveCCAModeSupported ;
++ long haveCurrentCCAMode;
++ long haveEDThreshold;
++
++} nPd, *pd = &nPd;
++
++static avList_t pdList;
++
++/****************************************************************************
++* dot11PhyIRTable *
++****************************************************************************/
++static struct piTbl_data {
++
++ char UID [ PI_UID_LEN + 1 ]; // unique ID
++ char ifName [ IFNAME_LEN + 1 ]; // ifName of card
++
++ long ifIndex; // ifindex of card
++
++ long CCAWatchdogTimerMax;
++ long CCAWatchdogCountMax;
++ long CCAWatchdogTimerMin;
++ long CCAWatchdogCountMin;
++
++ long haveCCAWatchdogTimerMax;
++ long haveCCAWatchdogCountMax;
++ long haveCCAWatchdogTimerMin;
++ long haveCCAWatchdogCountMin;
++
++} nPi, *pi = &nPi;
++
++static avList_t piList;
++
++/****************************************************************************
++* dot11RegDomainsSupportedTable *
++****************************************************************************/
++static struct rdTbl_data {
++
++ char UID [ RD_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long regDomainsSupportIndex;
++
++ long regDomainsSupportValue;
++ long haveRegDomainsSupportValue;
++
++} nRd, *rd = &nRd;
++
++static avList_t rdList;
++
++/****************************************************************************
++* dot11AntennasListTable *
++****************************************************************************/
++static struct alTbl_data {
++
++ char UID [ AL_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long antennaListIndex;
++
++ long supportedTxAntenna;
++ long supportedRxAntenna;
++ long diversitySelectionRx ;
++
++ long haveSupportedTxAntenna;
++ long haveSupportedRxAntenna;
++ long haveDiversitySelectionRx ;
++
++} nAl, *al = &nAl;
++
++static avList_t alList;
++
++/****************************************************************************
++* dot11SupportedDataRatesTxTable *
++****************************************************************************/
++static struct rtTbl_data {
++
++ char UID [ RT_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long supportedDataRatesTxIndex;
++
++ long supportedDataRatesTxValue;
++ long haveSupportedDataRatesTxValue;
++
++} nRt, *rt = &nRt;
++
++static avList_t rtList;
++
++/****************************************************************************
++* dot11SupportedDataRatesRxTable *
++****************************************************************************/
++static struct rrTbl_data {
++
++ char UID [ RR_UID_LEN + 1 ];
++ char ifName [ IFNAME_LEN + 1 ];
++
++ long ifIndex; // ifindex of card
++ long supportedDataRatesRxIndex;
++
++ long supportedDataRatesRxValue;
++ long haveSupportedDataRatesRxValue;
++
++} nRr, *rr = &nRr;
++
++static avList_t rrList;
++
++/****************************************************************************
++* Wireless Extensions Structures *
++****************************************************************************/
++static long wepCurrentKey;
++static long haveWepCurrentKey;
++static struct wepTbl_data {
++
++ long len;
++ char key [ WEP_STR_LEN + 1 ];
++ long haveKey;
++
++} wep[4];
++
++/****************************************************************************
++* *
++****************************************************************************/
++config_require(util_funcs)
++
++/* function prototypes */
++
++void init_ieee802dot11 ( void );
++FindVarMethod var_ieee802dot11;
++FindVarMethod var_dot11StationConfigTable;
++FindVarMethod var_dot11AuthenticationAlgorithmsTable;
++FindVarMethod var_dot11WEPDefaultKeysTable;
++FindVarMethod var_dot11WEPKeyMappingsTable;
++FindVarMethod var_dot11PrivacyTable;
++FindVarMethod var_dot11OperationTable;
++FindVarMethod var_dot11CountersTable;
++FindVarMethod var_dot11GroupAddressesTable;
++FindVarMethod var_dot11ResourceInfoTable;
++FindVarMethod var_dot11PhyOperationTable;
++FindVarMethod var_dot11PhyAntennaTable;
++FindVarMethod var_dot11PhyTxPowerTable;
++FindVarMethod var_dot11PhyFHSSTable;
++FindVarMethod var_dot11PhyDSSSTable;
++FindVarMethod var_dot11PhyIRTable;
++FindVarMethod var_dot11RegDomainsSupportedTable;
++FindVarMethod var_dot11AntennasListTable;
++FindVarMethod var_dot11SupportedDataRatesTxTable;
++FindVarMethod var_dot11SupportedDataRatesRxTable;
++
++WriteMethod write_dot11StationID;
++WriteMethod write_dot11MediumOccupancyLimit;
++WriteMethod write_dot11CFPPeriod;
++WriteMethod write_dot11CFPMaxDuration;
++WriteMethod write_dot11AuthenticationResponseTimeOut;
++WriteMethod write_dot11PowerManagementMode;
++WriteMethod write_dot11DesiredSSID;
++WriteMethod write_dot11DesiredBSSType;
++WriteMethod write_dot11OperationalRateSet;
++WriteMethod write_dot11BeaconPeriod;
++WriteMethod write_dot11DTIMPeriod;
++WriteMethod write_dot11AssociationResponseTimeOut;
++WriteMethod write_dot11AuthenticationAlgorithmsEnable;
++WriteMethod write_dot11WEPDefaultKeyValue;
++WriteMethod write_dot11WEPKeyMappingAddress;
++WriteMethod write_dot11WEPKeyMappingWEPOn;
++WriteMethod write_dot11WEPKeyMappingValue;
++WriteMethod write_dot11WEPKeyMappingStatus;
++WriteMethod write_dot11PrivacyInvoked;
++WriteMethod write_dot11WEPDefaultKeyID;
++WriteMethod write_dot11WEPKeyMappingLength;
++WriteMethod write_dot11ExcludeUnencrypted;
++WriteMethod write_dot11RTSThreshold;
++WriteMethod write_dot11ShortRetryLimit;
++WriteMethod write_dot11LongRetryLimit;
++WriteMethod write_dot11FragmentationThreshold;
++WriteMethod write_dot11MaxTransmitMSDULifetime;
++WriteMethod write_dot11MaxReceiveLifetime;
++WriteMethod write_dot11Address;
++WriteMethod write_dot11GroupAddressesStatus;
++WriteMethod write_dot11CurrentRegDomain;
++WriteMethod write_dot11CurrentTxAntenna;
++WriteMethod write_dot11CurrentRxAntenna;
++WriteMethod write_dot11CurrentTxPowerLevel;
++WriteMethod write_dot11CurrentChannelNumber;
++WriteMethod write_dot11CurrentDwellTime;
++WriteMethod write_dot11CurrentSet;
++WriteMethod write_dot11CurrentPattern;
++WriteMethod write_dot11CurrentIndex;
++WriteMethod write_dot11CurrentChannel;
++WriteMethod write_dot11CurrentCCAMode;
++WriteMethod write_dot11EDThreshold;
++WriteMethod write_dot11CCAWatchdogTimerMax;
++WriteMethod write_dot11CCAWatchdogCountMax;
++WriteMethod write_dot11CCAWatchdogTimerMin;
++WriteMethod write_dot11CCAWatchdogCountMin;
++WriteMethod write_dot11SupportedTxAntenna;
++WriteMethod write_dot11SupportedRxAntenna;
++WriteMethod write_dot11DiversitySelectionRx;
++
++#endif /* _MIBGROUP_IEEE802DOT11_H */
+--- net-snmp-5.1.2-orig/agent/mibgroup/iwlib.h 1970-01-01 01:00:00.000000000 +0100
++++ net-snmp-5.1.2-5/agent/mibgroup/iwlib.h 2005-03-13 16:17:21.000000000 +0100
+@@ -0,0 +1,502 @@
++/*
++ * Wireless Tools
++ *
++ * Jean II - HPLB 97->99 - HPL 99->02
++ *
++ * Common header for the Wireless Extension library...
++ *
++ * This file is released under the GPL license.
++ * Copyright (c) 1997-2002 Jean Tourrilhes <jt@hpl.hp.com>
++ */
++
++#ifndef IWLIB_H
++#define IWLIB_H
++
++/*#include "CHANGELOG.h"*/
++
++/***************************** INCLUDES *****************************/
++
++/* Standard headers */
++#include <sys/types.h>
++#include <sys/ioctl.h>
++#include <stdio.h>
++#include <math.h>
++#include <errno.h>
++#include <fcntl.h>
++#include <ctype.h>
++#include <stdlib.h>
++#include <string.h>
++#include <unistd.h>
++#include <netdb.h> /* gethostbyname, getnetbyname */
++#include <net/ethernet.h> /* struct ether_addr */
++#include <sys/time.h> /* struct timeval */
++#include <unistd.h>
++
++/* This is our header selection. Try to hide the mess and the misery :-(
++ * Don't look, you would go blind ;-) */
++
++#ifndef LINUX_VERSION_CODE
++#include <linux/version.h>
++#endif
++
++/* Kernel headers 2.4.X + Glibc 2.2 - Mandrake 8.0, Debian 2.3, RH 7.1
++ * Kernel headers 2.2.X + Glibc 2.2 - Slackware 8.0 */
++#if defined(__GLIBC__) \
++ && __GLIBC__ == 2 \
++ && __GLIBC_MINOR__ >= 2 \
++ && LINUX_VERSION_CODE >= KERNEL_VERSION(2,2,0)
++//#define GLIBC22_HEADERS
++#define GENERIC_HEADERS
++
++/* Kernel headers 2.4.X + Glibc 2.1 - Debian 2.2 upgraded, RH 7.0
++ * Kernel headers 2.2.X + Glibc 2.1 - Debian 2.2, RH 6.1 */
++#elif defined(__GLIBC__) \
++ && __GLIBC__ == 2 \
++ && __GLIBC_MINOR__ == 1 \
++ && LINUX_VERSION_CODE >= KERNEL_VERSION(2,2,0)
++//#define GLIBC_HEADERS
++#define GENERIC_HEADERS
++
++/* Kernel headers 2.2.X + Glibc 2.0 - Debian 2.1 */
++#elif defined(__GLIBC__) \
++ && __GLIBC__ == 2 \
++ && __GLIBC_MINOR__ == 0 \
++ && LINUX_VERSION_CODE >= KERNEL_VERSION(2,0,0) \
++ && LINUX_VERSION_CODE < KERNEL_VERSION(2,1,0)
++#define GLIBC_HEADERS
++#define KLUDGE_HEADERS
++
++/* Note : is it really worth supporting kernel 2.0.X, knowing that
++ * we require WE v9, which is only available in 2.2.X and higher ?
++ * I guess one could use 2.0.x with an upgraded wireless.h... */
++
++/* Kernel headers 2.0.X + Glibc 2.0 - Debian 2.0, RH 5 */
++#elif defined(__GLIBC__) \
++ && __GLIBC__ == 2 \
++ && __GLIBC_MINOR__ == 0 \
++ && LINUX_VERSION_CODE < KERNEL_VERSION(2,1,0) \
++ && LINUX_VERSION_CODE >= KERNEL_VERSION(2,0,0)
++#define GLIBC_HEADERS
++
++/* Kernel headers 2.0.X + libc5 - old systems */
++#elif defined(_LINUX_C_LIB_VERSION_MAJOR) \
++ && _LINUX_C_LIB_VERSION_MAJOR == 5 \
++ && LINUX_VERSION_CODE >= KERNEL_VERSION(2,0,0) \
++ && LINUX_VERSION_CODE < KERNEL_VERSION(2,1,0)
++#define LIBC5_HEADERS
++
++/* Unsupported combination */
++#else
++#error "Your kernel/libc combination is not supported"
++#endif
++
++#ifdef GENERIC_HEADERS
++/* Proposed by Dr. Michael Rietz <rietz@mail.amps.de>, 27.3.2 */
++/* If this works for all, it might be more stable on the long term - Jean II */
++#include <net/if_arp.h> /* For ARPHRD_ETHER */
++#include <sys/socket.h> /* For AF_INET & struct sockaddr */
++#include <netinet/in.h> /* For struct sockaddr_in */
++#include <netinet/if_ether.h>
++#endif /* GENERIC_HEADERS */
++
++#ifdef GLIBC22_HEADERS
++/* Added by Ross G. Miller <Ross_Miller@baylor.edu>, 3/28/01 */
++#include <linux/if_arp.h> /* For ARPHRD_ETHER */
++#include <linux/socket.h> /* For AF_INET & struct sockaddr */
++#include <sys/socket.h>
++#endif /* GLIBC22_HEADERS */
++
++#ifdef KLUDGE_HEADERS
++#include <socketbits.h>
++#endif /* KLUDGE_HEADERS */
++
++#ifdef GLIBC_HEADERS
++#include <linux/if_arp.h> /* For ARPHRD_ETHER */
++#include <linux/socket.h> /* For AF_INET & struct sockaddr */
++#include <linux/in.h> /* For struct sockaddr_in */
++#endif /* KLUDGE_HEADERS || GLIBC_HEADERS */
++
++#ifdef LIBC5_HEADERS
++#include <sys/socket.h> /* For AF_INET & struct sockaddr & socket() */
++#include <linux/if_arp.h> /* For ARPHRD_ETHER */
++#include <linux/in.h> /* For struct sockaddr_in */
++#endif /* LIBC5_HEADERS */
++
++/* Those 3 headers were previously included in wireless.h */
++#include <linux/types.h> /* for "caddr_t" et al */
++#include <linux/socket.h> /* for "struct sockaddr" et al */
++#include <linux/if.h> /* for IFNAMSIZ and co... */
++
++#ifdef WEXT_HEADER
++/* Private copy of Wireless extensions */
++#include WEXT_HEADER
++#else /* !WEXT_HEADER */
++/* System wide Wireless extensions */
++#include <linux/wireless.h>
++#endif /* !WEXT_HEADER */
++
++#ifdef __cplusplus
++extern "C" {
++#endif
++
++/****************************** DEBUG ******************************/
++
++
++/************************ CONSTANTS & MACROS ************************/
++
++/* Paths */
++#define PROC_NET_WIRELESS "/proc/net/wireless"
++#define PROC_NET_DEV "/proc/net/dev"
++
++/* Some usefull constants */
++#define KILO 1e3
++#define MEGA 1e6
++#define GIGA 1e9
++/* For doing log10/exp10 without libm */
++#define LOG10_MAGIC 1.25892541179
++
++/* Backward compatibility for Wireless Extension 9 */
++#ifndef IW_POWER_MODIFIER
++#define IW_POWER_MODIFIER 0x000F /* Modify a parameter */
++#define IW_POWER_MIN 0x0001 /* Value is a minimum */
++#define IW_POWER_MAX 0x0002 /* Value is a maximum */
++#define IW_POWER_RELATIVE 0x0004 /* Value is not in seconds/ms/us */
++#endif /* IW_POWER_MODIFIER */
++
++#ifndef IW_ENCODE_NOKEY
++#define IW_ENCODE_NOKEY 0x0800 /* Key is write only, so not here */
++#define IW_ENCODE_MODE 0xF000 /* Modes defined below */
++#endif /* IW_ENCODE_NOKEY */
++#ifndef IW_ENCODE_TEMP
++#define IW_ENCODE_TEMP 0x0400 /* Temporary key */
++#endif /* IW_ENCODE_TEMP */
++
++/* More backward compatibility */
++#ifndef SIOCSIWCOMMIT
++#define SIOCSIWCOMMIT SIOCSIWNAME
++#endif /* SIOCSIWCOMMIT */
++
++/****************************** TYPES ******************************/
++
++/* Shortcuts */
++typedef struct iw_statistics iwstats;
++typedef struct iw_range iwrange;
++typedef struct iw_param iwparam;
++typedef struct iw_freq iwfreq;
++typedef struct iw_quality iwqual;
++typedef struct iw_priv_args iwprivargs;
++typedef struct sockaddr sockaddr;
++
++/* Structure for storing all wireless information for each device
++ * This is pretty exhaustive... */
++typedef struct wireless_info
++{
++ char name[IFNAMSIZ + 1]; /* Wireless/protocol name */
++ int has_nwid;
++ iwparam nwid; /* Network ID */
++ int has_freq;
++ double freq; /* Frequency/channel */
++ int has_sens;
++ iwparam sens; /* sensitivity */
++ int has_key;
++ unsigned char key[IW_ENCODING_TOKEN_MAX]; /* Encoding key used */
++ int key_size; /* Number of bytes */
++ int key_flags; /* Various flags */
++ int has_essid;
++ int essid_on;
++ char essid[IW_ESSID_MAX_SIZE + 1]; /* ESSID (extended network) */
++ int has_nickname;
++ char nickname[IW_ESSID_MAX_SIZE + 1]; /* NickName */
++ int has_ap_addr;
++ sockaddr ap_addr; /* Access point address */
++ int has_bitrate;
++ iwparam bitrate; /* Bit rate in bps */
++ int has_rts;
++ iwparam rts; /* RTS threshold in bytes */
++ int has_frag;
++ iwparam frag; /* Fragmentation threshold in bytes */
++ int has_mode;
++ int mode; /* Operation mode */
++ int has_power;
++ iwparam power; /* Power management parameters */
++ int has_txpower;
++ iwparam txpower; /* Transmit Power in dBm */
++ int has_retry;
++ iwparam retry; /* Retry limit or lifetime */
++
++ /* Stats */
++ iwstats stats;
++ int has_stats;
++ iwrange range;
++ int has_range;
++} wireless_info;
++
++/* Structure for storing all wireless information for each device
++ * This is a cut down version of the one above, containing only
++ * the things *truly* needed to configure a card.
++ * Don't add other junk, I'll remove it... */
++typedef struct wireless_config
++{
++ char name[IFNAMSIZ + 1]; /* Wireless/protocol name */
++ int has_nwid;
++ iwparam nwid; /* Network ID */
++ int has_freq;
++ double freq; /* Frequency/channel */
++ int has_key;
++ unsigned char key[IW_ENCODING_TOKEN_MAX]; /* Encoding key used */
++ int key_size; /* Number of bytes */
++ int key_flags; /* Various flags */
++ int has_essid;
++ int essid_on;
++ char essid[IW_ESSID_MAX_SIZE + 1]; /* ESSID (extended network) */
++ int has_mode;
++ int mode; /* Operation mode */
++} wireless_config;
++
++typedef struct stream_descr
++{
++ char * end; /* End of the stream */
++ char * current; /* Current event in stream of events */
++ char * value; /* Current value in event */
++} stream_descr;
++
++/* Prototype for handling display of each single interface on the
++ * system - see iw_enum_devices() */
++typedef int (*iw_enum_handler)(int skfd,
++ char * ifname,
++ char * args[],
++ int count);
++
++/**************************** PROTOTYPES ****************************/
++/*
++ * All the functions in iwcommon.c
++ */
++
++/* ---------------------- SOCKET SUBROUTINES -----------------------*/
++int
++ iw_sockets_open(void);
++void
++ iw_enum_devices(int skfd,
++ iw_enum_handler fn,
++ char * args[],
++ int count);
++/* --------------------- WIRELESS SUBROUTINES ----------------------*/
++int
++ iw_get_range_info(int skfd,
++ char * ifname,
++ iwrange * range);
++int
++ iw_print_version_info(char * toolname);
++int
++ iw_get_priv_info(int skfd,
++ char * ifname,
++ iwprivargs * priv,
++ int maxpriv);
++int
++ iw_get_basic_config(int skfd,
++ char * ifname,
++ wireless_config * info);
++int
++ iw_set_basic_config(int skfd,
++ char * ifname,
++ wireless_config * info);
++/* --------------------- PROTOCOL SUBROUTINES --------------------- */
++int
++ iw_protocol_compare(char * protocol1,
++ char * protocol2);
++/* -------------------- FREQUENCY SUBROUTINES --------------------- */
++void
++ iw_float2freq(double in,
++ iwfreq * out);
++double
++ iw_freq2float(iwfreq * in);
++void
++ iw_print_freq(char * buffer,
++ double freq);
++int
++ iw_freq_to_channel(double freq,
++ struct iw_range * range);
++void
++ iw_print_bitrate(char * buffer,
++ int bitrate);
++/* ---------------------- POWER SUBROUTINES ----------------------- */
++int
++ iw_dbm2mwatt(int in);
++int
++ iw_mwatt2dbm(int in);
++/* -------------------- STATISTICS SUBROUTINES -------------------- */
++int
++ iw_get_stats(int skfd,
++ char * ifname,
++ iwstats * stats);
++void
++ iw_print_stats(char * buffer,
++ iwqual * qual,
++ iwrange * range,
++ int has_range);
++/* --------------------- ENCODING SUBROUTINES --------------------- */
++void
++ iw_print_key(char * buffer,
++ unsigned char * key,
++ int key_size,
++ int key_flags);
++int
++ iw_in_key(char * input,
++ unsigned char * key);
++int
++ iw_in_key_full(int skfd,
++ char * ifname,
++ char * input,
++ unsigned char * key,
++ __u16 * flags);
++/* ----------------- POWER MANAGEMENT SUBROUTINES ----------------- */
++void
++ iw_print_pm_value(char * buffer,
++ int value,
++ int flags);
++void
++ iw_print_pm_mode(char * buffer,
++ int flags);
++/* --------------- RETRY LIMIT/LIFETIME SUBROUTINES --------------- */
++#if WIRELESS_EXT > 10
++void
++ iw_print_retry_value(char * buffer,
++ int value,
++ int flags);
++#endif
++/* ----------------------- TIME SUBROUTINES ----------------------- */
++void
++ iw_print_timeval(char * buffer,
++ const struct timeval * time);
++/* --------------------- ADDRESS SUBROUTINES ---------------------- */
++int
++ iw_check_mac_addr_type(int skfd,
++ char * ifname);
++int
++ iw_check_if_addr_type(int skfd,
++ char * ifname);
++#if 0
++int
++ iw_check_addr_type(int skfd,
++ char * ifname);
++#endif
++void
++ iw_ether_ntop(const struct ether_addr* eth, char* buf);
++char*
++ iw_ether_ntoa(const struct ether_addr* eth);
++int
++ iw_ether_aton(const char* bufp, struct ether_addr* eth);
++int
++ iw_in_inet(char *bufp, struct sockaddr *sap);
++int
++ iw_in_addr(int skfd,
++ char * ifname,
++ char * bufp,
++ struct sockaddr * sap);
++/* ----------------------- MISC SUBROUTINES ------------------------ */
++int
++ iw_get_priv_size(int args);
++
++#if WIRELESS_EXT > 13
++/* ---------------------- EVENT SUBROUTINES ---------------------- */
++void
++ iw_init_event_stream(struct stream_descr * stream,
++ char * data,
++ int len);
++int
++ iw_extract_event_stream(struct stream_descr * stream,
++ struct iw_event * iwe);
++#endif /* WIRELESS_EXT > 13 */
++
++/**************************** VARIABLES ****************************/
++
++extern const char * const iw_operation_mode[];
++#define IW_NUM_OPER_MODE 7
++
++/************************* INLINE FUNTIONS *************************/
++/*
++ * Functions that are so simple that it's more efficient inlining them
++ */
++
++/*
++ * Note : I've defined wrapper for the ioctl request so that
++ * it will be easier to migrate to other kernel API if needed
++ */
++
++/*------------------------------------------------------------------*/
++/*
++ * Wrapper to push some Wireless Parameter in the driver
++ */
++static inline int
++iw_set_ext(int skfd, /* Socket to the kernel */
++ char * ifname, /* Device name */
++ int request, /* WE ID */
++ struct iwreq * pwrq) /* Fixed part of the request */
++{
++ /* Set device name */
++ strncpy(pwrq->ifr_name, ifname, IFNAMSIZ);
++ /* Do the request */
++ return(ioctl(skfd, request, pwrq));
++}
++
++/*------------------------------------------------------------------*/
++/*
++ * Wrapper to extract some Wireless Parameter out of the driver
++ */
++static inline int
++iw_get_ext(int skfd, /* Socket to the kernel */
++ char * ifname, /* Device name */
++ int request, /* WE ID */
++ struct iwreq * pwrq) /* Fixed part of the request */
++{
++ /* Set device name */
++ strncpy(pwrq->ifr_name, ifname, IFNAMSIZ);
++ /* Do the request */
++ return(ioctl(skfd, request, pwrq));
++}
++
++/*------------------------------------------------------------------*/
++/* Backwards compatability
++ * Actually, those form are much easier to use when dealing with
++ * struct sockaddr... */
++static inline char*
++iw_pr_ether(char* bufp, const unsigned char* addr)
++{
++ iw_ether_ntop((const struct ether_addr *) addr, bufp);
++ return bufp;
++}
++/* Backwards compatability */
++static inline int
++iw_in_ether(const char *bufp, struct sockaddr *sap)
++{
++ sap->sa_family = ARPHRD_ETHER;
++ return iw_ether_aton(bufp, (struct ether_addr *) sap->sa_data) ? 0 : -1;
++}
++
++/*------------------------------------------------------------------*/
++/*
++ * Create an Ethernet broadcast address
++ */
++static inline void
++iw_broad_ether(struct sockaddr *sap)
++{
++ sap->sa_family = ARPHRD_ETHER;
++ memset((char *) sap->sa_data, 0xFF, ETH_ALEN);
++}
++
++/*------------------------------------------------------------------*/
++/*
++ * Create an Ethernet NULL address
++ */
++static inline void
++iw_null_ether(struct sockaddr *sap)
++{
++ sap->sa_family = ARPHRD_ETHER;
++ memset((char *) sap->sa_data, 0x00, ETH_ALEN);
++}
++
++#ifdef __cplusplus
++}
++#endif
++
++#endif /* IWLIB_H */