svn commit: r316268 - in projects/bsnmp-ipv6-mib: etc usr.sbin/bsnmpd/modules/snmp_ipv6

Ngie Cooper ngie at FreeBSD.org
Thu Mar 30 08:17:29 UTC 2017


Author: ngie
Date: Thu Mar 30 08:17:27 2017
New Revision: 316268
URL: https://svnweb.freebsd.org/changeset/base/316268

Log:
  Revert r316267 to unbreak the module again due to missing symbols
  
  Reminder to self: renaming things for the sake of renaming
  things when they conflict with RFC embedded symbol names is a
  PITA

Added:
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def
     - copied unchanged from r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3
     - copied unchanged from r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3
Deleted:
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6mib_tree.def
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6mib.3
Modified:
  projects/bsnmp-ipv6-mib/etc/bsnmpd.config
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/Makefile
  projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6.c

Modified: projects/bsnmp-ipv6-mib/etc/bsnmpd.config
==============================================================================
--- projects/bsnmp-ipv6-mib/etc/bsnmpd.config	Thu Mar 30 08:08:56 2017	(r316267)
+++ projects/bsnmp-ipv6-mib/etc/bsnmpd.config	Thu Mar 30 08:17:27 2017	(r316268)
@@ -147,7 +147,7 @@ begemotSnmpdModulePath."mibII"	= "/usr/l
 # IPv6 module
 #  This requires the mibII module.
 #
-#begemotSnmpdModulePath."ipv6mib" = "/usr/lib/snmp_ipv6mib.so"
+#begemotSnmpdModulePath."ipv6MIB" = "/usr/lib/snmp_ipv6MIB.so"
 
 #
 # LM75 Sensor module

Modified: projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/Makefile
==============================================================================
--- projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/Makefile	Thu Mar 30 08:08:56 2017	(r316267)
+++ projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/Makefile	Thu Mar 30 08:17:27 2017	(r316268)
@@ -1,7 +1,7 @@
 # $FreeBSD$
 #
 
-MOD=	ipv6mib
+MOD=	ipv6MIB
 
 SRCS+=	ipv6.c
 SRCS+=	ipv6_addrPrefixTable.c
@@ -12,7 +12,7 @@ SRCS+=	ipv6_netToMediaTable.c
 SRCS+=	ipv6_routeTable.c
 SRCS+=	ipv6_sys.c
 
-XSYM=	ipv6MIB
+XSYM=	${MOD}
 
 MAN=	snmp_${MOD}.3
 

Modified: projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6.c
==============================================================================
--- projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6.c	Thu Mar 30 08:08:56 2017	(r316267)
+++ projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6.c	Thu Mar 30 08:17:27 2017	(r316268)
@@ -34,11 +34,11 @@ __FBSDID("$FreeBSD$");
 
 #include "ipv6.h"
 #include "ipv6_sys.h"
-#include "ipv6MIB_oid.h"
+#include "ipv6mib_oid.h"
 
 static struct lmodule *module;
 
-static const struct asn_oid oid_ipv6MIB = OIDX_ipv6MIB;
+static const struct asn_oid oid_ipv6mib = OIDX_ipv6MIB;
 
 uint32_t mib_ipv6_ipv6Interfaces;
 
@@ -112,15 +112,15 @@ op_ipv6MIBObjects(struct snmp_context *c
 }
 
 static void
-ipv6MIB_start(void)
+ipv6mib_start(void)
 {
 
-	ipv6_reg = or_register(&oid_ipv6MIB,
+	ipv6_reg = or_register(&oid_ipv6mib,
 	    "The (incomplete) MIB module for RFC 2465.", module);
 }
 
 static int
-ipv6MIB_init(struct lmodule *mod, int argc __unused, char *argv[] __unused)
+ipv6mib_init(struct lmodule *mod, int argc __unused, char *argv[] __unused)
 {
 	module = mod;
 
@@ -128,7 +128,7 @@ ipv6MIB_init(struct lmodule *mod, int ar
 }
 
 static int
-ipv6MIB_fini(void)
+ipv6mib_fini(void)
 {
 
 	or_unregister(ipv6_reg);
@@ -138,12 +138,12 @@ ipv6MIB_fini(void)
 
 const struct snmp_module config = {
 	"This module implements RFC 2465.",
-	ipv6MIB_init,
-	ipv6MIB_fini,
+	ipv6mib_init,
+	ipv6mib_fini,
 	NULL,
 	NULL,
 	NULL,
-	ipv6MIB_start,
+	ipv6mib_start,
 	NULL,
 	ipv6MIB_ctree,
 	ipv6MIB_CTREE_SIZE,

Copied: projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def (from r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def	Thu Mar 30 08:17:27 2017	(r316268, copy of r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/ipv6MIB_tree.def)
@@ -0,0 +1,143 @@
+#-
+# Copyright (C) 2010 The FreeBSD Foundation
+# All rights reserved.
+#
+# This software was developed by Shteryana Sotirova Shopova under
+# sponsorship from the FreeBSD Foundation.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+#    notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+#    notice, this list of conditions and the following disclaimer in the
+#   documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED.  IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+#
+
+(1 internet
+  (2 mgmt
+    (1 mib_2
+      (55 ipv6MIB
+        (1 ipv6MIBObjects
+          (1 ipv6Forwarding ENUM ( 1 forwarding 2 notForwarding ) op_ipv6MIBObjects GET SET)
+          (2 ipv6DefaultHopLimit INTEGER op_ipv6MIBObjects GET SET)
+          (3 ipv6Interfaces UNSIGNED32 op_ipv6MIBObjects GET)
+          (4 ipv6IfTableLastChange UNSIGNED32 op_ipv6MIBObjects GET)
+          (5 ipv6IfTable
+            (1 ipv6IfEntry : INTEGER op_ipv6IfTable
+              (1 ipv6IfIndex INTEGER)
+              (2 ipv6IfDescr OCTETSTRING | DisplayString GET SET)
+              (3 ipv6IfLowerLayer OID GET)
+              (4 ipv6IfEffectiveMtu UNSIGNED32 GET)
+              (5 ipv6IfReasmMaxSize UNSIGNED32 GET)
+              (6 ipv6IfIdentifier OCTETSTRING | Ipv6AddressIfIdentifier GET SET)
+              (7 ipv6IfIdentifierLength INTEGER GET SET)
+              (8 ipv6IfPhysicalAddress OCTETSTRING | PhysAddress GET)
+              (9 ipv6IfAdminStatus ENUM ( 1 up 2 down ) GET SET)
+              (10 ipv6IfOperStatus ENUM ( 1 up 2 down 3 noIfIdentifier 4 unknown 5 notPresent ) GET)
+              (11 ipv6IfLastChange UNSIGNED32 GET)
+            )
+          )
+          (6 ipv6IfStatsTable
+            (1 ipv6IfStatsEntry : INTEGER op_ipv6IfStatsTable
+              (1 ipv6IfStatsInReceives COUNTER GET)
+              (2 ipv6IfStatsInHdrErrors COUNTER GET)
+              (3 ipv6IfStatsInTooBigErrors COUNTER GET)
+              (4 ipv6IfStatsInNoRoutes COUNTER GET)
+              (5 ipv6IfStatsInAddrErrors COUNTER GET)
+              (6 ipv6IfStatsInUnknownProtos COUNTER GET)
+              (7 ipv6IfStatsInTruncatedPkts COUNTER GET)
+              (8 ipv6IfStatsInDiscards COUNTER GET)
+              (9 ipv6IfStatsInDelivers COUNTER GET)
+              (10 ipv6IfStatsOutForwDatagrams COUNTER GET)
+              (11 ipv6IfStatsOutRequests COUNTER GET)
+              (12 ipv6IfStatsOutDiscards COUNTER GET)
+              (13 ipv6IfStatsOutFragOKs COUNTER GET)
+              (14 ipv6IfStatsOutFragFails COUNTER GET)
+              (15 ipv6IfStatsOutFragCreates COUNTER GET)
+              (16 ipv6IfStatsReasmReqds COUNTER GET)
+              (17 ipv6IfStatsReasmOKs COUNTER GET)
+              (18 ipv6IfStatsReasmFails COUNTER GET)
+              (19 ipv6IfStatsInMcastPkts COUNTER GET)
+              (20 ipv6IfStatsOutMcastPkts COUNTER GET)
+            )
+          )
+          (7 ipv6AddrPrefixTable
+            (1 ipv6AddrPrefixEntry : INTEGER OCTETSTRING | Ipv6AddressPrefix INTEGER op_ipv6AddrPrefixTable
+              (1 ipv6AddrPrefix OCTETSTRING | Ipv6AddressPrefix)
+              (2 ipv6AddrPrefixLength INTEGER)
+              (3 ipv6AddrPrefixOnLinkFlag ENUM ( 1 true 2 false ) GET)
+              (4 ipv6AddrPrefixAutonomousFlag ENUM ( 1 true 2 false ) GET)
+              (5 ipv6AddrPrefixAdvPreferredLifetime UNSIGNED32 GET)
+              (6 ipv6AddrPrefixAdvValidLifetime UNSIGNED32 GET)
+            )
+          )
+          (8 ipv6AddrTable
+            (1 ipv6AddrEntry : INTEGER OCTETSTRING | Ipv6Address op_ipv6AddrTable
+              (1 ipv6AddrAddress OCTETSTRING | Ipv6Address)
+              (2 ipv6AddrPfxLength INTEGER GET)
+              (3 ipv6AddrType ENUM ( 1 stateless 2 stateful 3 unknown ) GET)
+              (4 ipv6AddrAnycastFlag ENUM ( 1 true 2 false ) GET)
+              (5 ipv6AddrStatus ENUM ( 1 preferred 2 deprecated 3 invalid 4 inaccessible 5 unknown ) GET)
+            )
+          )
+          (9 ipv6RouteNumber GAUGE op_ipv6MIBObjects GET)
+          (10 ipv6DiscardedRoutes COUNTER op_ipv6MIBObjects GET)
+          (11 ipv6RouteTable
+            (1 ipv6RouteEntry : OCTETSTRING | Ipv6Address INTEGER UNSIGNED32 op_ipv6RouteTable
+              (1 ipv6RouteDest OCTETSTRING | Ipv6Address)
+              (2 ipv6RoutePfxLength INTEGER)
+              (3 ipv6RouteIndex UNSIGNED32)
+              (4 ipv6RouteIfIndex INTEGER GET)
+              (5 ipv6RouteNextHop OCTETSTRING | Ipv6Address GET)
+              (6 ipv6RouteType ENUM ( 1 other 2 discard 3 local 4 remote ) GET)
+              (7 ipv6RouteProtocol ENUM ( 1 other 2 local 3 netmgmt 4 ndisc 5 rip 6 ospf 7 bgp 8 idrp 9 igrp ) GET)
+              (8 ipv6RoutePolicy INTEGER32 GET)
+              (9 ipv6RouteAge UNSIGNED32 GET)
+              (10 ipv6RouteNextHopRDI UNSIGNED32 GET)
+              (11 ipv6RouteMetric UNSIGNED32 GET)
+              (12 ipv6RouteWeight UNSIGNED32 GET)
+              (13 ipv6RouteInfo OID GET)
+              (14 ipv6RouteValid ENUM ( 1 true 2 false ) GET SET)
+            )
+          )
+          (12 ipv6NetToMediaTable
+            (1 ipv6NetToMediaEntry : INTEGER OCTETSTRING | Ipv6Address op_ipv6NetToMediaTable
+              (1 ipv6NetToMediaNetAddress OCTETSTRING | Ipv6Address)
+              (2 ipv6NetToMediaPhysAddress OCTETSTRING | PhysAddress GET)
+              (3 ipv6NetToMediaType ENUM ( 1 other 2 dynamic 3 static 4 local ) GET)
+              (4 ipv6IfNetToMediaState ENUM ( 1 reachable 2 stale 3 delay 4 probe 5 invalid 6 unknown ) GET)
+              (5 ipv6IfNetToMediaLastUpdated UNSIGNED32 GET)
+              (6 ipv6NetToMediaValid ENUM ( 1 true 2 false ) GET SET)
+            )
+          )
+        )
+        (2 ipv6Notifications
+          (0 ipv6NotificationPrefix
+            (1 ipv6IfStateChange OID op_ipv6IfStateChange)
+          )
+        )
+        (3 ipv6Conformance
+          (1 ipv6Compliances
+          )
+          (2 ipv6Groups
+          )
+        )
+      )
+    )
+  )
+)

Copied: projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3 (from r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3	Thu Mar 30 08:17:27 2017	(r316268, copy of r316266, projects/bsnmp-ipv6-mib/usr.sbin/bsnmpd/modules/snmp_ipv6/snmp_ipv6MIB.3)
@@ -0,0 +1,62 @@
+.\"-
+.\" Copyright (C) Dell EMC Isilon
+.\" All rights reserved.
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\" 1. Redistributions of source code must retain the above copyright
+.\"    notice, this list of conditions and the following disclaimer.
+.\" 2. Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in the
+.\"    documentation and/or other materials provided with the distribution.
+.\"
+.\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED.  IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
+.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+.\" SUCH DAMAGE.
+.\"
+.\" $FreeBSD$
+.\"
+.Dd December 28, 2016
+.Dt SNMP_IPV6MIB 3
+.Os
+.Sh NAME
+.Nm snmp_ipv6MIB
+.Nd "ipv6 module for snmpd"
+.Sh LIBRARY
+.Pq begemotSnmpdModulePath."ipv6MIB" = "/usr/lib/snmp_ipv6MIB.so"
+.Sh DESCRIPTION
+The
+.Nm snmp_ipv6
+module implements the IPV6-MIB as standardized in RFC 2465.
+.Sh FILES
+.Bl -tag -width "XXXXXXXXX"
+.It Pa /usr/share/snmp/defs/ipv6MIB_tree.def
+The description of the MIB tree implemented by
+.Nm .
+.It Pa /usr/share/snmp/mibs/IPV6-MIB.txt
+The MIB that is implemented by this module.
+.El
+.Sh STANDARDS
+This module does not completely implement IPV6-MIB as standardized in
+RFC 2465 and RFC 4293.
+.Sh SEE ALSO
+.Xr bsnmpd 1 ,
+.Xr gensnmptree 1 ,
+.Xr inet6 4 ,
+.Xr snmpmod 3 ,
+.Sh AUTHORS
+The module was written by
+.An Thor Steingrimsson Aq Mt thor.steingrimsson at isilon.com
+and ported to FreeBSD by
+.An Ngie Cooper Aq Mt ngie at FreeBSD.org
+This manual page was written by
+.An Ngie Cooper Aq Mt ngie at FreeBSD.org


More information about the svn-src-projects mailing list