FreeBSD Bugzilla – Attachment 202692 Details for
Bug 232025
net-mgmt/net-snmp: update 5.7.3 -> 5.8
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch-v4
snmp.diff (text/plain), 48.65 KB, created by
Kurt Jaeger
on 2019-03-07 17:06:20 UTC
(
hide
)
Description:
patch-v4
Filename:
MIME Type:
Creator:
Kurt Jaeger
Created:
2019-03-07 17:06:20 UTC
Size:
48.65 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 494874) >+++ Makefile (working copy) >@@ -2,8 +2,7 @@ > # $FreeBSD$ > > PORTNAME= snmp >-PORTVERSION= 5.7.3 >-PORTREVISION= 19 >+PORTVERSION= 5.8 > CATEGORIES= net-mgmt ipv6 > MASTER_SITES= SF/net-${PORTNAME}/net-${PORTNAME}/${PORTVERSION} \ > ZI >@@ -16,14 +15,22 @@ > LICENSE= BSD3CLAUSE > LICENSE_FILE= ${WRKSRC}/COPYING > >-BROKEN_SSL= openssl111 >- >-LIB_DEPENDS= libpkg.so:ports-mgmt/pkg >- > NOT_FOR_ARCHS= mips mips64 > NOT_FOR_ARCHS_REASON= SSP is currently broken on MIPS > >-OPTIONS_DEFINE= IPV6 MFD_REWRITES PERL PERL_EMBEDDED PYTHON DUMMY TKMIB \ >+LIB_DEPENDS= libpkg.so:ports-mgmt/pkg \ >+ libpcre.so:devel/pcre >+ >+USES= cpe libtool perl5 ssl >+USE_RC_SUBR= snmpd snmptrapd >+USE_LDCONFIG= yes >+USE_PERL5= build run >+USE_CSTD= c99 >+ >+CPE_VENDOR= net-snmp >+GNU_CONFIGURE= yes >+ >+OPTIONS_DEFINE= MFD_REWRITES PERL PERL_EMBEDDED PYTHON DUMMY TKMIB \ > MYSQL AX_SOCKONLY UNPRIVILEGED SMUX DOCS JAIL AX_DISABLE_TRAP \ > TLS NEWSYSLOG > OPTIONS_DEFAULT=PERL PERL_EMBEDDED DUMMY SMUX NEWSYSLOG >@@ -44,14 +51,6 @@ > > PORTSCOUT= skipv:5.7.2.1 > >-GNU_CONFIGURE= yes >-USE_RC_SUBR= snmpd snmptrapd >-USE_LDCONFIG= yes >-USES= cpe libtool perl5 ssl >-CPE_VENDOR= net-snmp >-USE_PERL5= build run >-USE_CSTD= c99 >- > CFLAGS+= -I${LOCALBASE}/include -I${PKG_PREFIX}/include > LDFLAGS+= -L${LOCALBASE}/lib > CONFIGURE_ENV+= PERLPROG="${PERL}" PSPROG="${PS_CMD}" SED="${SED}" >@@ -77,10 +76,6 @@ > > .include <bsd.port.options.mk> > >-.if ${OSVERSION} >= 1200085 >-EXTRA_PATCHES= ${PATCHDIR}/extra-patch-openssl11 >-.endif >- > .if ${PORT_OPTIONS:MPYTHON} > PYDISTUTILS_PKGNAME?= netsnmp-python > PYDISTUTILS_PKGVERSION?= 1.0a1 >@@ -141,20 +136,12 @@ > CONFIGURE_ARGS+=--enable-agentx-dom-sock-only > .endif > >-.if ${PORT_OPTIONS:MIPV6} >-CONFIGURE_ARGS+=--enable-ipv6 >-# --with-transport="UDPIPv6 TCPIPv6" --with-modules=mibII/ipv6" >-PLIST_SUB+= WITH_IPV6="" >-.else >-PLIST_SUB+= WITH_IPV6="@comment " >-.endif >- > .if ${PORT_OPTIONS:MUNPRIVILEGED} > CONFIGURE_ARGS+=--without-root-access > .endif > >-SHLIB_VERSION= 30 >-SHLIB_VERSION2= .0.3 >+SHLIB_VERSION= 35 >+SHLIB_VERSION2= .0.0 > PLIST_SUB+= SHLIB_VERSION=${SHLIB_VERSION} SHLIB_VERSION2=${SHLIB_VERSION2} > SCRIPTS_SUB= PREFIX=${PREFIX} PERL=${PERL} > >@@ -199,7 +186,12 @@ > BIN_FILES= snmpbulkwalk snmpget snmpgetnext snmpset \ > snmpstatus snmptest snmptranslate snmptrap snmpwalk \ > snmptable snmpbulkget snmpdelta snmpdf agentxtrap \ >- snmpvacm snmpusm encode_keychange snmpnetstat >+ snmpvacm snmpusm encode_keychange snmpnetstat \ >+ snmppcap snmpping snmpps >+.if ${PORT_OPTIONS:MTLS} >+BIN_FILES+= snmptls >+.endif >+ > LIB_FILES= libnetsnmp.so.${SHLIB_VERSION}${SHLIB_VERSION2} \ > libnetsnmpagent.so.${SHLIB_VERSION}${SHLIB_VERSION2} \ > libnetsnmpmibs.so.${SHLIB_VERSION}${SHLIB_VERSION2} \ >@@ -246,13 +238,13 @@ > > post-patch: > .for filename in ${SCRIPT_FILES} >- @${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|' ${WRKSRC}/local/${filename} >+ ${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|' ${WRKSRC}/local/${filename} > .endfor >- @${REINPLACE_CMD} -e 's!utmp_p->ut_name!utmp_p->ut_user!' \ >+ ${REINPLACE_CMD} -e 's!utmp_p->ut_name!utmp_p->ut_user!' \ > ${WRKSRC}/agent/mibgroup/host/hr_system.c >- @${REINPLACE_CMD} -E -e 's|return pci_lookup_name|disabled broken|g' \ >+ ${REINPLACE_CMD} -E -e 's|return pci_lookup_name|disabled broken|g' \ > ${WRKSRC}/configure >- @${CP} ${WRKSRC}/include/net-snmp/system/freebsd12.h \ >+ ${CP} ${WRKSRC}/include/net-snmp/system/freebsd12.h \ > ${WRKSRC}/include/net-snmp/system/freebsd13.h > > post-configure: >@@ -306,7 +298,7 @@ > > install-doc-files: > .if ${PORT_OPTIONS:MDOCS} >- @${MKDIR} ${STAGEDIR}${DOCSDIR} >+ ${MKDIR} ${STAGEDIR}${DOCSDIR} > . for filename in ${DOC_FILES} > ${INSTALL_DATA} ${WRKSRC}/${filename} ${STAGEDIR}${DOCSDIR} > . endfor >Index: distinfo >=================================================================== >--- distinfo (revision 494874) >+++ distinfo (working copy) >@@ -1,2 +1,3 @@ >-SHA256 (net-snmp-5.7.3.tar.gz) = 12ef89613c7707dc96d13335f153c1921efc9d61d3708ef09f3fc4a7014fb4f0 >-SIZE (net-snmp-5.7.3.tar.gz) = 6382428 >+TIMESTAMP = 1538855962 >+SHA256 (net-snmp-5.8.tar.gz) = b2fc3500840ebe532734c4786b0da4ef0a5f67e51ef4c86b3345d697e4976adf >+SIZE (net-snmp-5.8.tar.gz) = 6591680 >Index: files/extra-patch-local_Makefile.in >=================================================================== >--- files/extra-patch-local_Makefile.in (revision 494874) >+++ files/extra-patch-local_Makefile.in (working copy) >@@ -1,11 +1,11 @@ >---- local/Makefile.in.orig 2015-01-19 14:37:56 UTC >+--- local/Makefile.in.orig 2018-07-16 14:33:40 UTC > +++ local/Makefile.in >-@@ -16,7 +16,7 @@ OTHERUNINSTALL=localuninstall >+@@ -14,7 +14,7 @@ OTHERUNINSTALL=localuninstall > # > SNMPCONFPATH=@SNMPCONFPATH@ > PERSISTENT_DIRECTORY=@PERSISTENT_DIRECTORY@ >--PERLSCRIPTS=snmpcheck tkmib mib2c fixproc ipf-mod.pl snmpconf traptoemail snmp-bridge-mib net-snmp-cert >-+PERLSCRIPTS=snmpcheck mib2c fixproc ipf-mod.pl snmpconf traptoemail snmp-bridge-mib net-snmp-cert >+-PERLSCRIPTS=snmpcheck tkmib mib2c fixproc ipf-mod.pl snmpconf traptoemail snmp-bridge-mib net-snmp-cert checkbandwidth >++PERLSCRIPTS=snmpcheck mib2c fixproc ipf-mod.pl snmpconf traptoemail snmp-bridge-mib net-snmp-cert checkbandwidth > SHELLSCRIPTS=mib2c-update > SCRIPTSMADEFORPERL=snmpcheck.made tkmib.made mib2c.made fixproc.made \ > ipf-mod.pl.made snmpconf.made traptoemail.made snmp-bridge-mib.made \ >Index: files/patch-Makefile.in >=================================================================== >--- files/patch-Makefile.in (revision 494874) >+++ files/patch-Makefile.in (working copy) >@@ -1,19 +1,19 @@ >---- Makefile.in.orig 2014-12-08 20:23:22 UTC >+--- Makefile.in.orig 2018-07-16 14:33:40 UTC > +++ Makefile.in >-@@ -21,7 +21,7 @@ INCLUDESUBDIRHEADERS= aix.h bsd.h bsdi3.h bsdi4.h bsdi >- darwin.h darwin7.h darwin8.h darwin9.h darwin10.h dragonfly.h dynix.h \ >+@@ -22,7 +22,7 @@ INCLUDESUBDIRHEADERS= aix.h bsd.h bsdi3.h bsdi4.h bsdi >+ dragonfly.h dynix.h \ > freebsd2.h freebsd3.h freebsd4.h freebsd5.h freebsd6.h \ > freebsd7.h freebsd8.h freebsd9.h freebsd10.h freebsd11.h \ >-- freebsd12.h freebsd.h \ >-+ freebsd12.h freebsd13.h freebsd.h \ >- generic.h \ >- hpux.h irix.h linux.h mingw32.h mips.h netbsd.h osf5.h \ >- openbsd.h openbsd5.h openbsd4.h \ >-@@ -230,7 +230,7 @@ pythonmodules: subdirs >+- freebsd12.h freebsd.h kfreebsd.h \ >++ freebsd12.h freebsd13.h freebsd.h kfreebsd.h \ >+ generic.h \ >+ hpux.h irix.h linux.h mingw32.h mingw32msvc.h mips.h \ >+ netbsd.h nto-qnx6.h osf5.h \ >+@@ -234,7 +234,7 @@ pythonmodules: subdirs > fi > > pythoninstall: >-- @(dir=`pwd`; cd python; $(PYMAKE) install --basedir=$$dir) ; \ >+- @(dir=`pwd`; cd python; $(PYMAKE) install --basedir=$$dir --root=$(DESTDIR) --prefix=$(prefix)) ; \ > + @(dir=`pwd`; cd python; $(PYMAKE) install --root=${STAGEDIR} --basedir=$$dir ${PYDISTUTILS_INSTALLARGS}) ; \ > if test $$? != 0 ; then \ > exit 1 ; \ > >Property changes on: files/patch-Makefile.in >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-agent_mibgroup_hardware_cpu_cpu__sysctl.c >=================================================================== >--- files/patch-agent_mibgroup_hardware_cpu_cpu__sysctl.c (revision 494874) >+++ files/patch-agent_mibgroup_hardware_cpu_cpu__sysctl.c (working copy) >@@ -1,6 +1,6 @@ >---- agent/mibgroup/hardware/cpu/cpu_sysctl.c.orig 2014-12-08 12:23:22.000000000 -0800 >-+++ agent/mibgroup/hardware/cpu/cpu_sysctl.c 2017-04-20 15:05:11.607496000 -0700 >-@@ -130,8 +130,21 @@ >+--- agent/mibgroup/hardware/cpu/cpu_sysctl.c.orig 2018-07-16 14:33:40 UTC >++++ agent/mibgroup/hardware/cpu/cpu_sysctl.c >+@@ -133,8 +133,21 @@ void init_cpu_sysctl( void ) { > #endif /* VM_UVMEXP2 || VM_UVMEXP */ > > #elif defined(__FreeBSD__) /* FreeBSD */ >@@ -23,7 +23,7 @@ > #define NS_VM_INTR v_intr > #define NS_VM_SWTCH v_swtch > #define NS_VM_PAGEIN v_swappgsin >-@@ -206,7 +219,23 @@ >+@@ -209,7 +222,23 @@ int netsnmp_cpu_arch_load( netsnmp_cache *cache, void > * Interrupt/Context Switch statistics > * XXX - Do these really belong here ? > */ >Index: files/patch-agent_mibgroup_hardware_cpu_cpu_sysctl.c >=================================================================== >--- files/patch-agent_mibgroup_hardware_cpu_cpu_sysctl.c (revision 494874) >+++ files/patch-agent_mibgroup_hardware_cpu_cpu_sysctl.c (nonexistent) >@@ -1,49 +0,0 @@ >---- agent/mibgroup/hardware/cpu/cpu_sysctl.c.orig 2014-12-08 12:23:22.000000000 -0800 >-+++ agent/mibgroup/hardware/cpu/cpu_sysctl.c 2017-04-20 15:05:11.607496000 -0700 >-@@ -130,8 +130,21 @@ >- #endif /* VM_UVMEXP2 || VM_UVMEXP */ >- >- #elif defined(__FreeBSD__) /* FreeBSD */ >-+#if __FreeBSD_version >= 1200028 >-+#define VMMETER_TYPE uint64_t >-+#else >-+#define VMMETER_TYPE u_int >-+#endif >-+struct __vmmeter { >-+ VMMETER_TYPE v_intr; >-+ VMMETER_TYPE v_swtch; >-+ VMMETER_TYPE v_swappgsin; >-+ VMMETER_TYPE v_swappgsout; >-+ VMMETER_TYPE v_swapin; >-+ VMMETER_TYPE v_swapout; >-+}; >- #define NETSNMP_VM_STATS VM_METER >--#define NETSNMP_VM_STATS_TYPE struct vmmeter >-+#define NETSNMP_VM_STATS_TYPE struct __vmmeter >- #define NS_VM_INTR v_intr >- #define NS_VM_SWTCH v_swtch >- #define NS_VM_PAGEIN v_swappgsin >-@@ -206,7 +219,23 @@ >- * Interrupt/Context Switch statistics >- * XXX - Do these really belong here ? >- */ >-+#ifdef __FreeBSD__ >-+#define GET_VM_STATS(space, name) sysctlbyname("vm.stats." #space "." #name, &mem_stats.name, &len, NULL, 0) >-+ { >-+ size_t len; >-+ >-+ len = sizeof(VMMETER_TYPE); >-+ GET_VM_STATS(sys, v_intr); >-+ GET_VM_STATS(sys, v_swtch); >-+ GET_VM_STATS(vm, v_swappgsin); >-+ GET_VM_STATS(vm, v_swappgsout); >-+ GET_VM_STATS(vm, v_swapin); >-+ GET_VM_STATS(vm, v_swapout); >-+ } >-+#undef GET_VM_STATS >-+#else >- sysctl(mem_mib, 2, &mem_stats, &mem_size, NULL, 0); >-+#endif >- cpu->nInterrupts = mem_stats.NS_VM_INTR; >- cpu->nCtxSwitches = mem_stats.NS_VM_SWTCH; >- cpu->swapIn = mem_stats.NS_VM_SWAPIN; > >Property changes on: files/patch-agent_mibgroup_hardware_cpu_cpu_sysctl.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-agent_mibgroup_hardware_fsys_fsys__getfsstats.c >=================================================================== >--- files/patch-agent_mibgroup_hardware_fsys_fsys__getfsstats.c (revision 494874) >+++ files/patch-agent_mibgroup_hardware_fsys_fsys__getfsstats.c (nonexistent) >@@ -1,11 +0,0 @@ >---- agent/mibgroup/hardware/fsys/fsys_getfsstats.c.orig 2017-03-22 16:28:29 UTC >-+++ agent/mibgroup/hardware/fsys/fsys_getfsstats.c >-@@ -116,7 +116,7 @@ netsnmp_fsys_arch_load( void ) >- /* >- * Retrieve information about the currently mounted filesystems... >- */ >-- n = NSFS_GETFSSTAT( NULL, 0, 0 ); >-+ n = NSFS_GETFSSTAT( NULL, 0, MNT_NOWAIT ); >- if ( n==0 ) >- return; >- stats = (struct NSFS_STATFS *)malloc( n * sizeof( struct NSFS_STATFS )); > >Property changes on: files/patch-agent_mibgroup_hardware_fsys_fsys__getfsstats.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-agent_mibgroup_hardware_memory_memory__freebsd.c >=================================================================== >--- files/patch-agent_mibgroup_hardware_memory_memory__freebsd.c (revision 494874) >+++ files/patch-agent_mibgroup_hardware_memory_memory__freebsd.c (working copy) >@@ -1,6 +1,6 @@ >---- agent/mibgroup/hardware/memory/memory_freebsd.c.orig 2015-02-20 14:44:47 UTC >+--- agent/mibgroup/hardware/memory/memory_freebsd.c.orig 2018-07-16 14:33:40 UTC > +++ agent/mibgroup/hardware/memory/memory_freebsd.c >-@@ -163,7 +163,7 @@ int netsnmp_mem_arch_load( netsnmp_cache >+@@ -163,7 +163,7 @@ int netsnmp_mem_arch_load( netsnmp_cache *cache, void > if (!mem->descr) > mem->descr = strdup("Cached memory"); > mem->units = pagesize; >Index: files/patch-agent_mibgroup_mibII_icmp.h >=================================================================== >--- files/patch-agent_mibgroup_mibII_icmp.h (revision 494874) >+++ files/patch-agent_mibgroup_mibII_icmp.h (nonexistent) >@@ -1,12 +0,0 @@ >---- agent/mibgroup/mibII/icmp.h.orig 2014-12-08 20:23:22 UTC >-+++ agent/mibgroup/mibII/icmp.h >-@@ -14,6 +14,9 @@ config_arch_require(freebsd7, mibII/ker >- config_arch_require(freebsd8, mibII/kernel_sysctl) >- config_arch_require(freebsd9, mibII/kernel_sysctl) >- config_arch_require(freebsd10, mibII/kernel_sysctl) >-+config_arch_require(freebsd11, mibII/kernel_sysctl) >-+config_arch_require(freebsd12, mibII/kernel_sysctl) >-+config_arch_require(freebsd13, mibII/kernel_sysctl) >- config_arch_require(netbsd, mibII/kernel_netbsd) >- config_arch_require(netbsdelf, mibII/kernel_netbsd) >- config_arch_require(openbsd4, mibII/kernel_sysctl) > >Property changes on: files/patch-agent_mibgroup_mibII_icmp.h >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-agent_mibgroup_mibII_tcpTable.c >=================================================================== >--- files/patch-agent_mibgroup_mibII_tcpTable.c (revision 494874) >+++ files/patch-agent_mibgroup_mibII_tcpTable.c (working copy) >@@ -1,6 +1,6 @@ >---- agent/mibgroup/mibII/tcpTable.c.orig 2017-03-15 17:46:37.000000000 +0000 >-+++ agent/mibgroup/mibII/tcpTable.c 2017-03-15 17:46:37.000000000 +0000 >-@@ -96,7 +96,11 @@ >+--- agent/mibgroup/mibII/tcpTable.c.orig 2018-07-16 14:33:40 UTC >++++ agent/mibgroup/mibII/tcpTable.c >+@@ -120,7 +120,11 @@ struct netsnmp_tcpConnEntry_s { > > typedef struct netsnmp_inpcb_s netsnmp_inpcb; > struct netsnmp_inpcb_s { >@@ -12,7 +12,7 @@ > int state; > netsnmp_inpcb *inp_next; > }; >-@@ -301,8 +305,10 @@ >+@@ -330,8 +334,10 @@ tcpTable_handler(netsnmp_mib_handler *handler > #ifndef NETSNMP_FEATURE_REMOVE_TCP_COUNT_CONNECTIONS > int > TCP_Count_Connections( void ) { >@@ -23,7 +23,7 @@ > } > #endif /* NETSNMP_FEATURE_REMOVE_TCP_COUNT_CONNECTIONS */ > >-@@ -923,12 +929,20 @@ >+@@ -988,12 +994,20 @@ tcpTable_load(netsnmp_cache *cache, void *vmagic) > nnew = SNMP_MALLOC_TYPEDEF(netsnmp_inpcb); > if (!nnew) > break; >@@ -42,5 +42,5 @@ > sizeof(struct inpcb)); > +#endif > >- if (nnew->pcb.inp_vflag & INP_IPV6) >- free(nnew); >+ #ifdef INP_ISIPV6 >+ if (INP_ISIPV6(&nnew->pcb)) >Index: files/patch-agent_mibgroup_mibII_udpTable.c >=================================================================== >--- files/patch-agent_mibgroup_mibII_udpTable.c (revision 494874) >+++ files/patch-agent_mibgroup_mibII_udpTable.c (working copy) >@@ -1,6 +1,6 @@ >---- agent/mibgroup/mibII/udpTable.c.orig 2017-03-15 18:08:43.000000000 +0000 >-+++ agent/mibgroup/mibII/udpTable.c 2017-03-15 18:08:43.000000000 +0000 >-@@ -71,7 +71,11 @@ >+--- agent/mibgroup/mibII/udpTable.c.orig 2018-07-16 14:33:40 UTC >++++ agent/mibgroup/mibII/udpTable.c >+@@ -97,7 +97,11 @@ struct netsnmp_udpEntry_s { > #if defined(freebsd4) || defined(darwin) || defined(osf5) > typedef struct netsnmp_inpcb_s netsnmp_inpcb; > struct netsnmp_inpcb_s { >@@ -12,7 +12,7 @@ > int state; > netsnmp_inpcb *inp_next; > }; >-@@ -670,7 +674,11 @@ >+@@ -708,7 +712,11 @@ udpTable_load(netsnmp_cache *cache, void *vmagic) > nnew = SNMP_MALLOC_TYPEDEF(UDPTABLE_ENTRY_TYPE); > if (!nnew) > break; >Index: files/patch-agent_mibgroup_tcp-mib_data__access_tcpConn__freebsd4.c >=================================================================== >--- files/patch-agent_mibgroup_tcp-mib_data__access_tcpConn__freebsd4.c (revision 494874) >+++ files/patch-agent_mibgroup_tcp-mib_data__access_tcpConn__freebsd4.c (working copy) >@@ -1,6 +1,6 @@ >---- agent/mibgroup/tcp-mib/data_access/tcpConn_freebsd4.c.orig 2017-03-15 18:15:07.000000000 +0000 >-+++ agent/mibgroup/tcp-mib/data_access/tcpConn_freebsd4.c 2017-03-15 18:15:07.000000000 +0000 >-@@ -163,7 +163,11 @@ >+--- agent/mibgroup/tcp-mib/data_access/tcpConn_freebsd4.c.orig 2018-07-16 14:33:40 UTC >++++ agent/mibgroup/tcp-mib/data_access/tcpConn_freebsd4.c >+@@ -163,7 +163,11 @@ _load(netsnmp_container *container, u_int load_flags) > #else > xig = (struct xinpgen *) ((char *) xig + xig->xig_len); > #endif >@@ -12,7 +12,7 @@ > > if (load_flags) { > if (state == TCPCONNECTIONSTATE_LISTEN) { >-@@ -215,6 +219,8 @@ >+@@ -223,6 +227,8 @@ _load(netsnmp_container *container, u_int load_flags) > entry->arbitrary_index = CONTAINER_SIZE(container) + 1; > CONTAINER_INSERT(container, entry); > } >@@ -19,5 +19,5 @@ > + > + free(tcpcb_buf); > >- if(rc<0) >- return rc; >+ free(tcpcb_buf); >+ >Index: files/patch-agent_mibgroup_ucd-snmp_diskio.c >=================================================================== >--- files/patch-agent_mibgroup_ucd-snmp_diskio.c (revision 494874) >+++ files/patch-agent_mibgroup_ucd-snmp_diskio.c (nonexistent) >@@ -1,54 +0,0 @@ >---- agent/mibgroup/ucd-snmp/diskio.c.orig 2014-12-08 20:23:22 UTC >-+++ agent/mibgroup/ucd-snmp/diskio.c >-@@ -944,14 +944,14 @@ var_diskio(struct variable * vp, >- return (u_char *) stat->dinfo->devices[indx].device_name; >- case DISKIO_NREAD: >- #if HAVE_DEVSTAT_GETDEVS >-- long_ret = (signed long) stat->dinfo->devices[indx].bytes[DEVSTAT_READ]; >-+ long_ret = (signed long) stat->dinfo->devices[indx].bytes[DEVSTAT_READ] & 0xFFFFFFFF; >- #else >- long_ret = (signed long) stat->dinfo->devices[indx].bytes_read; >- #endif >- return (u_char *) & long_ret; >- case DISKIO_NWRITTEN: >- #if HAVE_DEVSTAT_GETDEVS >-- long_ret = (signed long) stat->dinfo->devices[indx].bytes[DEVSTAT_WRITE]; >-+ long_ret = (signed long) stat->dinfo->devices[indx].bytes[DEVSTAT_WRITE] & 0xFFFFFFFF; >- #else >- long_ret = (signed long) stat->dinfo->devices[indx].bytes_written; >- #endif >-@@ -959,7 +959,7 @@ var_diskio(struct variable * vp, >- case DISKIO_NREADX: >- *var_len = sizeof(struct counter64); >- #if HAVE_DEVSTAT_GETDEVS >-- longlong_ret = stat->dinfo->devices[indx].bytes[DEVSTAT_READ]; >-+ longlong_ret = stat->dinfo->devices[indx].bytes[DEVSTAT_READ] & 0xFFFFFFFF; >- #else >- longlong_ret = stat->dinfo->devices[indx].bytes_read; >- #endif >-@@ -969,7 +969,7 @@ var_diskio(struct variable * vp, >- case DISKIO_NWRITTENX: >- *var_len = sizeof(struct counter64); >- #if HAVE_DEVSTAT_GETDEVS >-- longlong_ret = stat->dinfo->devices[indx].bytes[DEVSTAT_WRITE]; >-+ longlong_ret = stat->dinfo->devices[indx].bytes[DEVSTAT_WRITE] & 0xFFFFFFFF; >- #else >- longlong_ret = stat->dinfo->devices[indx].bytes_written; >- #endif >-@@ -978,14 +978,14 @@ var_diskio(struct variable * vp, >- return (u_char *) & c64_ret; >- case DISKIO_READS: >- #if HAVE_DEVSTAT_GETDEVS >-- long_ret = (signed long) stat->dinfo->devices[indx].operations[DEVSTAT_READ]; >-+ long_ret = (signed long) stat->dinfo->devices[indx].operations[DEVSTAT_READ] & 0xFFFFFFFF; >- #else >- long_ret = (signed long) stat->dinfo->devices[indx].num_reads; >- #endif >- return (u_char *) & long_ret; >- case DISKIO_WRITES: >- #if HAVE_DEVSTAT_GETDEVS >-- long_ret = (signed long) stat->dinfo->devices[indx].operations[DEVSTAT_WRITE]; >-+ long_ret = (signed long) stat->dinfo->devices[indx].operations[DEVSTAT_WRITE] & 0xFFFFFFFF; >- #else >- long_ret = (signed long) stat->dinfo->devices[indx].num_writes; >- #endif > >Property changes on: files/patch-agent_mibgroup_ucd-snmp_diskio.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-agent_mibgroup_udp-mib_data__access_udp__endpoint__freebsd4.c >=================================================================== >--- files/patch-agent_mibgroup_udp-mib_data__access_udp__endpoint__freebsd4.c (revision 494874) >+++ files/patch-agent_mibgroup_udp-mib_data__access_udp__endpoint__freebsd4.c (working copy) >@@ -1,18 +1,6 @@ >---- agent/mibgroup/udp-mib/data_access/udp_endpoint_freebsd4.c.orig 2014-12-08 12:23:22.000000000 -0800 >-+++ agent/mibgroup/udp-mib/data_access/udp_endpoint_freebsd4.c 2017-04-07 16:05:05.752849000 -0700 >-@@ -153,7 +153,11 @@ >- #endif >- >- #if !defined(NETSNMP_ENABLE_IPV6) >-+#if __FreeBSD_version >= 1200026 >-+ if (pcb.inp_vflag & INP_IPV6) >-+#else >- if (pcb.xi_inp.inp_vflag & INP_IPV6) >-+#endif >- continue; >- #endif >- >-@@ -164,9 +168,24 @@ >+--- agent/mibgroup/udp-mib/data_access/udp_endpoint_freebsd4.c.orig 2018-07-16 14:33:40 UTC >++++ agent/mibgroup/udp-mib/data_access/udp_endpoint_freebsd4.c >+@@ -168,9 +168,24 @@ _load(netsnmp_container *container, u_int load_flags) > } > > /** oddly enough, these appear to already be in network order */ >@@ -37,8 +25,8 @@ > - entry->pid = 0; > > /** the addr string may need work */ >- if (pcb.xi_inp.inp_vflag & INP_IPV6) { >-@@ -179,6 +198,8 @@ >+ #ifdef INP_ISIPV6 >+@@ -187,6 +202,8 @@ _load(netsnmp_container *container, u_int load_flags) > memcpy(entry->loc_addr, &pcb.xi_inp.inp_laddr, 4); > memcpy(entry->rmt_addr, &pcb.xi_inp.inp_faddr, 4); > } >@@ -47,12 +35,12 @@ > > /* > * add entry to container >-@@ -187,6 +208,8 @@ >+@@ -194,6 +211,8 @@ _load(netsnmp_container *container, u_int load_flags) >+ entry->index = CONTAINER_SIZE(container) + 1; > CONTAINER_INSERT(container, entry); > } >- >++ > + free(udpcb_buf); >-+ >- if(rc<0) >- return rc; > >+ free(udpcb_buf); >+ >Index: files/patch-include__net-snmp__net-snmp-config.h.in >=================================================================== >--- files/patch-include__net-snmp__net-snmp-config.h.in (revision 494874) >+++ files/patch-include__net-snmp__net-snmp-config.h.in (nonexistent) >@@ -1,11 +0,0 @@ >---- ./include/net-snmp/net-snmp-config.h.in.orig 2012-10-09 18:28:58.000000000 -0400 >-+++ ./include/net-snmp/net-snmp-config.h.in 2012-10-14 11:37:35.000000000 -0400 >-@@ -2106,7 +2106,7 @@ >- #define UCD_SNMP_LIBRARY 1 >- >- /* final conclusion on nlist usage */ >--#if defined(HAVE_NLIST) && defined(HAVE_STRUCT_NLIST_N_VALUE) && !defined(NETSNMP_DONT_USE_NLIST) && defined(HAVE_KMEM) && !defined(NETSNMP_NO_KMEM_USAGE) >-+#if defined(HAVE_NLIST) && defined(HAVE_STRUCT_NLIST_N_VALUE) && !defined(NETSNMP_DONT_USE_NLIST) && !defined(NETSNMP_NO_KMEM_USAGE) >- #define NETSNMP_CAN_USE_NLIST >- #endif >- > >Property changes on: files/patch-include__net-snmp__net-snmp-config.h.in >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-include_net-snmp_library_transform__oids.h >=================================================================== >--- files/patch-include_net-snmp_library_transform__oids.h (revision 494874) >+++ files/patch-include_net-snmp_library_transform__oids.h (working copy) >@@ -1,11 +1,11 @@ >---- include/net-snmp/library/transform_oids.h.orig 2006-10-28 05:19:44.000000000 +0900 >-+++ include/net-snmp/library/transform_oids.h 2008-03-26 07:50:45.393507729 +0900 >-@@ -23,6 +23,8 @@ >- /* XXX: OIDs not defined yet */ >- NETSNMP_IMPORT oid usmAESPrivProtocol[10]; /* == { 1,3,6,1,6,3,10,1,2,4 }; */ >+--- include/net-snmp/library/transform_oids.h.orig 2018-07-16 14:33:40 UTC >++++ include/net-snmp/library/transform_oids.h >+@@ -48,6 +48,8 @@ NETSNMP_IMPORT oid usmDESPrivProtocol[10]; >+ >+ NETSNMP_IMPORT oid usmAESPrivProtocol[10]; > NETSNMP_IMPORT oid *usmAES128PrivProtocol; /* backwards compat */ > +NETSNMP_IMPORT oid *usmAES192PrivProtocol; /* backwards compat */ > +NETSNMP_IMPORT oid *usmAES256PrivProtocol; /* backwards compat */ > >- #define USM_AUTH_PROTO_NOAUTH_LEN 10 >- #define USM_AUTH_PROTO_MD5_LEN 10 >+ /* >+ * backwards compatibility. should not be used in internal code. >Index: files/patch-include_net-snmp_system_freebsd13.h >=================================================================== >--- files/patch-include_net-snmp_system_freebsd13.h (revision 494874) >+++ files/patch-include_net-snmp_system_freebsd13.h (working copy) >@@ -1,6 +1,6 @@ >---- include/net-snmp/system/freebsd13.h.orig 2018-12-25 15:35:28 UTC >+--- include/net-snmp/system/freebsd13.h.orig 2019-03-07 15:59:25 UTC > +++ include/net-snmp/system/freebsd13.h > @@ -0,0 +1,3 @@ >-+/* freebsd13 is a superset of freebsd12 */ >-+#include "freebsd12.h" >-+#define freebsd13 freebsd13 >++/* freebsd12 is a superset of freebsd11 */ >++#include "freebsd11.h" >++#define freebsd11 freebsd11 >Index: files/patch-kthreads >=================================================================== >--- files/patch-kthreads (revision 494874) >+++ files/patch-kthreads (nonexistent) >@@ -1,96 +0,0 @@ >-diff --git a/agent/mibgroup/host/data_access/swrun.c b/agent/mibgroup/host/data_access/swrun.c >-index d18ea5f..60ad5b4 100644 >---- agent/mibgroup/host/data_access/swrun.c >-+++ agent/mibgroup/host/data_access/swrun.c >-@@ -75,10 +75,27 @@ shutdown_swrun(void) >- } >- >- int >--swrun_count_processes( void ) >-+swrun_count_processes(int include_kthreads) >- { >-+ netsnmp_swrun_entry *entry; >-+ netsnmp_iterator *it; >-+ int i = 0; >-+ >- netsnmp_cache_check_and_reload(swrun_cache); >-- return ( swrun_container ? CONTAINER_SIZE(swrun_container) : 0 ); >-+ if ( !swrun_container ) >-+ return 0; /* or -1 */ >-+ >-+ if (include_kthreads) >-+ return ( swrun_container ? CONTAINER_SIZE(swrun_container) : 0 ); >-+ >-+ it = CONTAINER_ITERATOR( swrun_container ); >-+ while ((entry = (netsnmp_swrun_entry*)ITERATOR_NEXT( it )) != NULL) { >-+ if (4 == entry->hrSWRunType) >-+ i++; >-+ } >-+ ITERATOR_RELEASE( it ); >-+ >-+ return i; >- } >- >- #ifndef NETSNMP_FEATURE_REMOVE_SWRUN_MAX_PROCESSES >-diff --git a/agent/mibgroup/host/hr_system.c b/agent/mibgroup/host/hr_system.c >-index d99cc7d..e853779 100644 >---- agent/mibgroup/host/hr_system.c >-+++ agent/mibgroup/host/hr_system.c >-@@ -24,6 +24,7 @@ >- >- #include <net-snmp/net-snmp-includes.h> >- #include <net-snmp/agent/net-snmp-agent-includes.h> >-+#include <net-snmp/data_access/swrun.h> >- >- #include "host.h" >- #include "host_res.h" >-@@ -114,7 +115,14 @@ static long get_max_solaris_processes(void); >- static int get_load_dev(void); >- static int count_users(void); >- extern int count_processes(void); >--extern int swrun_count_processes(void); >-+#if USING_HOST_DATA_ACCESS_SWRUN_MODULE >-+static int count_kthreads = 0; >-+ >-+static void parse_count_kthreads(const char *token, const char *line) >-+{ >-+ count_kthreads = atoi(line); >-+} >-+#endif >- >- /********************* >- * >-@@ -194,6 +202,11 @@ init_hr_system(void) >- #ifdef NPROC_SYMBOL >- auto_nlist(NPROC_SYMBOL, 0, 0); >- #endif >-+#if USING_HOST_DATA_ACCESS_SWRUN_MODULE >-+ snmpd_register_const_config_handler("count_kthreads", >-+ parse_count_kthreads, NULL, >-+ "0|1 0 to exclude kernel threads from hrSystemProcesses.0"); >-+#endif >- >- REGISTER_MIB("host/hr_system", hrsystem_variables, variable2, >- hrsystem_variables_oid); >-@@ -317,7 +330,7 @@ var_hrsys(struct variable * vp, >- return (u_char *) & long_return; >- case HRSYS_PROCS: >- #if USING_HOST_DATA_ACCESS_SWRUN_MODULE >-- long_return = swrun_count_processes(); >-+ long_return = swrun_count_processes(count_kthreads); >- #elif USING_HOST_HR_SWRUN_MODULE >- long_return = count_processes(); >- #else >-diff --git a/include/net-snmp/data_access/swrun.h b/include/net-snmp/data_access/swrun.h >-index 3e15c41..4f768ac 100644 >---- include/net-snmp/data_access/swrun.h >-+++ include/net-snmp/data_access/swrun.h >-@@ -85,7 +85,7 @@ extern "C" { >- >- void netsnmp_swrun_entry_free(netsnmp_swrun_entry *entry); >- >-- int swrun_count_processes( void ); >-+ int swrun_count_processes( int include_kthreads ); >- int swrun_max_processes( void ); >- int swrun_count_processes_by_name( char *name ); >- > >Property changes on: files/patch-kthreads >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-perl5.23 >=================================================================== >--- files/patch-perl5.23 (revision 494874) >+++ files/patch-perl5.23 (nonexistent) >@@ -1,135 +0,0 @@ >---- agent/snmp_perl.c.orig 2015-08-11 13:07:06 UTC >-+++ agent/snmp_perl.c >-@@ -5,6 +5,10 @@ >- #include <EXTERN.h> >- #include "perl.h" >- >-+#ifdef U64TYPE >-+#define U64 U64pairU32 >-+#endif >-+ >- #include <net-snmp/net-snmp-config.h> >- #include <net-snmp/net-snmp-includes.h> >- #include <net-snmp/agent/net-snmp-agent-includes.h> >---- perl/OID/OID.xs.orig 2015-08-11 13:07:28 UTC >-+++ perl/OID/OID.xs >-@@ -7,6 +7,10 @@ >- #include "perl.h" >- #include "XSUB.h" >- >-+#ifdef U64TYPE >-+#define U64 U64pairU32 >-+#endif >-+ >- #include <net-snmp/net-snmp-config.h> >- #include <net-snmp/net-snmp-includes.h> >- >---- perl/SNMP/SNMP.xs.orig 2015-08-11 13:07:54 UTC >-+++ perl/SNMP/SNMP.xs >-@@ -16,6 +16,10 @@ >- #include "perl.h" >- #include "XSUB.h" >- >-+#ifdef U64TYPE >-+#define U64 U64pairU32 >-+#endif >-+ >- #include <net-snmp/net-snmp-config.h> >- #include <net-snmp/net-snmp-includes.h> >- #include <sys/types.h> >---- perl/TrapReceiver/TrapReceiver.xs.orig 2015-08-11 13:08:02 UTC >-+++ perl/TrapReceiver/TrapReceiver.xs >-@@ -9,6 +9,10 @@ >- >- #include "ppport.h" >- >-+#ifdef U64TYPE >-+#define U64 U64pairU32 >-+#endif >-+ >- #include <net-snmp/net-snmp-config.h> >- #include <net-snmp/net-snmp-includes.h> >- #include <net-snmp/agent/net-snmp-agent-includes.h> >---- perl/agent/agent.xs.orig 2015-08-11 13:07:48 UTC >-+++ perl/agent/agent.xs >-@@ -9,6 +9,10 @@ >- #include <netdb.h> >- #include <sys/socket.h> >- >-+#ifdef U64TYPE >-+#define U64 U64pairU32 >-+#endif >-+ >- #include <net-snmp/net-snmp-config.h> >- #include <net-snmp/net-snmp-includes.h> >- #include <net-snmp/agent/net-snmp-agent-includes.h> >---- perl/ASN/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/ASN/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package ASN; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/AnyData_SNMP/Makefile.PL.orig 2015-09-03 22:27:45 UTC >-+++ perl/AnyData_SNMP/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package AnyData_SNMP; >- use ExtUtils::MakeMaker; >- # See lib/ExtUtils/MakeMaker.pm for details of how to influence >- # the contents of the Makefile that is written. >---- perl/OID/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/OID/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package OID; >- # See lib/ExtUtils/MakeMaker.pm for details of how to influence >- # the contents of the Makefile that is written. >- >---- perl/SNMP/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/SNMP/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package SNMP; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/TrapReceiver/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/TrapReceiver/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package TrapReceiver; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/agent/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/agent/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package agent; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/agent/Support/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/agent/Support/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package agent_Support; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/agent/default_store/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/agent/default_store/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package agent_default_store; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/default_store/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/default_store/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package default_store; >- use ExtUtils::MakeMaker; >- require 5; >- use Config; >---- perl/manager/Makefile.PL.orig 2014-12-08 20:23:22 UTC >-+++ perl/manager/Makefile.PL >-@@ -1,3 +1,4 @@ >-+package manager; >- use ExtUtils::MakeMaker; >- # See lib/ExtUtils/MakeMaker.pm for details of how to influence >- # the contents of the Makefile that is written. > >Property changes on: files/patch-perl5.23 >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-snmplib_snmp__api.c >=================================================================== >--- files/patch-snmplib_snmp__api.c (revision 494874) >+++ files/patch-snmplib_snmp__api.c (nonexistent) >@@ -1,117 +0,0 @@ >---- snmplib/snmp_api.c.orig 2014-12-08 20:23:22 UTC >-+++ snmplib/snmp_api.c >-@@ -4350,10 +4350,9 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- u_char type; >- u_char msg_type; >- u_char *var_val; >-- int badtype = 0; >- size_t len; >- size_t four; >-- netsnmp_variable_list *vp = NULL; >-+ netsnmp_variable_list *vp = NULL, *vplast = NULL; >- oid objid[MAX_OID_LEN]; >- u_char *p; >- >-@@ -4493,38 +4492,24 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- (ASN_SEQUENCE | ASN_CONSTRUCTOR), >- "varbinds"); >- if (data == NULL) >-- return -1; >-+ goto fail; >- >- /* >- * get each varBind sequence >- */ >- while ((int) *length > 0) { >-- netsnmp_variable_list *vptemp; >-- vptemp = (netsnmp_variable_list *) malloc(sizeof(*vptemp)); >-- if (NULL == vptemp) { >-- return -1; >-- } >-- if (NULL == vp) { >-- pdu->variables = vptemp; >-- } else { >-- vp->next_variable = vptemp; >-- } >-- vp = vptemp; >-+ vp = SNMP_MALLOC_TYPEDEF(netsnmp_variable_list); >-+ if (NULL == vp) >-+ goto fail; >- >-- vp->next_variable = NULL; >-- vp->val.string = NULL; >- vp->name_length = MAX_OID_LEN; >-- vp->name = NULL; >-- vp->index = 0; >-- vp->data = NULL; >-- vp->dataFreeHook = NULL; >- DEBUGDUMPSECTION("recv", "VarBind"); >- data = snmp_parse_var_op(data, objid, &vp->name_length, &vp->type, >- &vp->val_len, &var_val, length); >- if (data == NULL) >-- return -1; >-+ goto fail; >- if (snmp_set_var_objid(vp, objid, vp->name_length)) >-- return -1; >-+ goto fail; >- >- len = MAX_PACKET_LENGTH; >- DEBUGDUMPHEADER("recv", "Value"); >-@@ -4604,7 +4589,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- vp->val.string = (u_char *) malloc(vp->val_len); >- } >- if (vp->val.string == NULL) { >-- return -1; >-+ goto fail; >- } >- p = asn_parse_string(var_val, &len, &vp->type, vp->val.string, >- &vp->val_len); >-@@ -4619,7 +4604,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- vp->val_len *= sizeof(oid); >- vp->val.objid = (oid *) malloc(vp->val_len); >- if (vp->val.objid == NULL) { >-- return -1; >-+ goto fail; >- } >- memmove(vp->val.objid, objid, vp->val_len); >- break; >-@@ -4631,7 +4616,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- case ASN_BIT_STR: >- vp->val.bitstring = (u_char *) malloc(vp->val_len); >- if (vp->val.bitstring == NULL) { >-- return -1; >-+ goto fail; >- } >- p = asn_parse_bitstring(var_val, &len, &vp->type, >- vp->val.bitstring, &vp->val_len); >-@@ -4640,12 +4625,28 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char >- break; >- default: >- snmp_log(LOG_ERR, "bad type returned (%x)\n", vp->type); >-- badtype = -1; >-+ goto fail; >- break; >- } >- DEBUGINDENTADD(-4); >-+ >-+ if (NULL == vplast) { >-+ pdu->variables = vp; >-+ } else { >-+ vplast->next_variable = vp; >-+ } >-+ vplast = vp; >-+ vp = NULL; >- } >-- return badtype; >-+ return 0; >-+ >-+ fail: >-+ DEBUGMSGTL(("recv", "error while parsing VarBindList\n")); >-+ /** if we were parsing a var, remove it from the pdu and free it */ >-+ if (vp) >-+ snmp_free_var(vp); >-+ >-+ return -1; >- } >- >- /* > >Property changes on: files/patch-snmplib_snmp__api.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-snmplib_snmpusm.c >=================================================================== >--- files/patch-snmplib_snmpusm.c (revision 494874) >+++ files/patch-snmplib_snmpusm.c (working copy) >@@ -1,11 +1,11 @@ >---- snmplib/snmpusm.c.orig 2011-07-27 09:58:24.000000000 -0300 >-+++ snmplib/snmpusm.c 2011-07-27 09:57:48.000000000 -0300 >-@@ -91,6 +91,8 @@ >- oid usmAESPrivProtocol[10] = { 1, 3, 6, 1, 6, 3, 10, 1, 2, 4 }; >+--- snmplib/snmpusm.c.orig 2018-07-16 14:33:40 UTC >++++ snmplib/snmpusm.c >+@@ -117,6 +117,8 @@ oid usmDESPrivProtocol[10] = { 1, 3, 6, 1, >+ oid usmAESPrivProtocol[10] = { 1, 3, 6, 1, 6, 3, 10, 1, 2, 4 }; > /* backwards compat */ >- oid *usmAES128PrivProtocol = usmAESPrivProtocol; >-+oid *usmAES192PrivProtocol = usmAESPrivProtocol; >-+oid *usmAES256PrivProtocol = usmAESPrivProtocol; >+ oid *usmAES128PrivProtocol = usmAESPrivProtocol; >++oid *usmAES192PrivProtocol = usmAESPrivProtocol; >++oid *usmAES256PrivProtocol = usmAESPrivProtocol; > >- static u_int dummy_etime, dummy_eboot; /* For ISENGINEKNOWN(). */ >- >+ #ifdef NETSNMP_DRAFT_BLUMENTHAL_AES_04 >+ /* OIDs from http://www.snmp.com/eso/esoConsortiumMIB.txt */ >Index: files/patch-snmpusm.c >=================================================================== >--- files/patch-snmpusm.c (revision 494874) >+++ files/patch-snmpusm.c (nonexistent) >@@ -1,11 +0,0 @@ >---- snmplib/snmpusm.c.orig 2011-07-27 09:58:24.000000000 -0300 >-+++ snmplib/snmpusm.c 2011-07-27 09:57:48.000000000 -0300 >-@@ -91,6 +91,8 @@ >- oid usmAESPrivProtocol[10] = { 1, 3, 6, 1, 6, 3, 10, 1, 2, 4 }; >- /* backwards compat */ >- oid *usmAES128PrivProtocol = usmAESPrivProtocol; >-+oid *usmAES192PrivProtocol = usmAESPrivProtocol; >-+oid *usmAES256PrivProtocol = usmAESPrivProtocol; >- >- static u_int dummy_etime, dummy_eboot; /* For ISENGINEKNOWN(). */ >- > >Property changes on: files/patch-snmpusm.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-tcpTable.c >=================================================================== >--- files/patch-tcpTable.c (revision 494874) >+++ files/patch-tcpTable.c (nonexistent) >@@ -1,46 +0,0 @@ >---- agent/mibgroup/mibII/tcpTable.c.orig 2017-03-15 17:46:37.000000000 +0000 >-+++ agent/mibgroup/mibII/tcpTable.c 2017-03-15 17:46:37.000000000 +0000 >-@@ -96,7 +96,11 @@ >- >- typedef struct netsnmp_inpcb_s netsnmp_inpcb; >- struct netsnmp_inpcb_s { >-+#if __FreeBSD_version >= 1200026 >-+ struct xinpcb pcb; >-+#else >- struct inpcb pcb; >-+#endif >- int state; >- netsnmp_inpcb *inp_next; >- }; >-@@ -301,8 +305,10 @@ >- #ifndef NETSNMP_FEATURE_REMOVE_TCP_COUNT_CONNECTIONS >- int >- TCP_Count_Connections( void ) { >-+#if (defined(CAN_USE_SYSCTL) && defined(TCPCTL_PCBLIST)) >- tcpTable_load(NULL, NULL); >- return tcp_estab; >-+#endif >- } >- #endif /* NETSNMP_FEATURE_REMOVE_TCP_COUNT_CONNECTIONS */ >- >-@@ -923,12 +929,20 @@ >- nnew = SNMP_MALLOC_TYPEDEF(netsnmp_inpcb); >- if (!nnew) >- break; >-+#if __FreeBSD_version >= 1200026 >-+ nnew->state = StateMap[((NS_ELEM *) xig)->t_state]; >-+#else >- nnew->state = StateMap[((NS_ELEM *) xig)->xt_tp.t_state]; >-+#endif >- if (nnew->state == 5 /* established */ || >- nnew->state == 8 /* closeWait */ ) >- tcp_estab++; >- memcpy(&(nnew->pcb), &(((NS_ELEM *) xig)->xt_inp), >-+#if __FreeBSD_version >= 1200026 >-+ sizeof(struct xinpcb)); >-+#else >- sizeof(struct inpcb)); >-+#endif >- >- if (nnew->pcb.inp_vflag & INP_IPV6) >- free(nnew); > >Property changes on: files/patch-tcpTable.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-transform_oids.h >=================================================================== >--- files/patch-transform_oids.h (revision 494874) >+++ files/patch-transform_oids.h (nonexistent) >@@ -1,11 +0,0 @@ >---- include/net-snmp/library/transform_oids.h.orig 2006-10-28 05:19:44.000000000 +0900 >-+++ include/net-snmp/library/transform_oids.h 2008-03-26 07:50:45.393507729 +0900 >-@@ -23,6 +23,8 @@ >- /* XXX: OIDs not defined yet */ >- NETSNMP_IMPORT oid usmAESPrivProtocol[10]; /* == { 1,3,6,1,6,3,10,1,2,4 }; */ >- NETSNMP_IMPORT oid *usmAES128PrivProtocol; /* backwards compat */ >-+NETSNMP_IMPORT oid *usmAES192PrivProtocol; /* backwards compat */ >-+NETSNMP_IMPORT oid *usmAES256PrivProtocol; /* backwards compat */ >- >- #define USM_AUTH_PROTO_NOAUTH_LEN 10 >- #define USM_AUTH_PROTO_MD5_LEN 10 > >Property changes on: files/patch-transform_oids.h >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: files/patch-udpTable.c >=================================================================== >--- files/patch-udpTable.c (revision 494874) >+++ files/patch-udpTable.c (nonexistent) >@@ -1,26 +0,0 @@ >---- agent/mibgroup/mibII/udpTable.c.orig 2017-03-15 18:08:43.000000000 +0000 >-+++ agent/mibgroup/mibII/udpTable.c 2017-03-15 18:08:43.000000000 +0000 >-@@ -71,7 +71,11 @@ >- #if defined(freebsd4) || defined(darwin) || defined(osf5) >- typedef struct netsnmp_inpcb_s netsnmp_inpcb; >- struct netsnmp_inpcb_s { >-+#if __FreeBSD_version >= 1200026 >-+ struct xinpcb pcb; >-+#else >- struct inpcb pcb; >-+#endif >- int state; >- netsnmp_inpcb *inp_next; >- }; >-@@ -670,7 +674,11 @@ >- nnew = SNMP_MALLOC_TYPEDEF(UDPTABLE_ENTRY_TYPE); >- if (!nnew) >- break; >-+#if __FreeBSD_version >= 1200026 >-+ memcpy(&nnew->pcb, xig, sizeof(struct xinpcb)); >-+#else >- memcpy(&nnew->pcb, &((struct xinpcb *) xig)->xi_inp, sizeof(struct inpcb)); >-+#endif >- nnew->inp_next = udp_head; >- udp_head = nnew; >- #if defined(dragonfly) > >Property changes on: files/patch-udpTable.c >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property >Index: pkg-plist >=================================================================== >--- pkg-plist (revision 494874) >+++ pkg-plist (working copy) >@@ -1,4 +1,5 @@ > bin/agentxtrap >+bin/checkbandwidth > bin/encode_keychange > bin/fixproc > bin/ipf-mod.pl >@@ -18,11 +19,15 @@ > bin/snmpgetnext > bin/snmpinform > bin/snmpnetstat >+bin/snmppcap >+bin/snmpping >+bin/snmpps > bin/snmpset > bin/snmpstatus > bin/snmptable > bin/snmptest > %%TLS%%bin/snmptls >+bin/snmptop > bin/snmptranslate > bin/snmptrap > bin/snmpusm >@@ -54,6 +59,7 @@ > include/net-snmp/agent/mode_end_call.h > include/net-snmp/agent/multiplexer.h > include/net-snmp/agent/net-snmp-agent-includes.h >+include/net-snmp/agent/netsnmp_close_fds.h > include/net-snmp/agent/null.h > include/net-snmp/agent/old_api.h > include/net-snmp/agent/read_only.h >@@ -110,6 +116,7 @@ > include/net-snmp/library/md5.h > include/net-snmp/library/mib.h > include/net-snmp/library/mt_support.h >+include/net-snmp/library/netsnmp-attribute-format.h > include/net-snmp/library/oid_stash.h > include/net-snmp/library/parse.h > include/net-snmp/library/read_config.h >@@ -120,11 +127,11 @@ > include/net-snmp/library/snmpCallbackDomain.h > %%TLS%%include/net-snmp/library/snmpDTLSUDPDomain.h > include/net-snmp/library/snmpTCPDomain.h >-%%WITH_IPV6%%include/net-snmp/library/snmpTCPIPv6Domain.h >+include/net-snmp/library/snmpTCPIPv6Domain.h > %%TLS%%include/net-snmp/library/snmpTLSBaseDomain.h > %%TLS%%include/net-snmp/library/snmpTLSTCPDomain.h > include/net-snmp/library/snmpUDPDomain.h >-%%WITH_IPV6%%include/net-snmp/library/snmpUDPIPv6Domain.h >+include/net-snmp/library/snmpUDPIPv6Domain.h > include/net-snmp/library/snmpUnixDomain.h > include/net-snmp/library/snmp_alarm.h > include/net-snmp/library/snmp_api.h >@@ -142,7 +149,7 @@ > include/net-snmp/library/snmpusm.h > include/net-snmp/library/snmpv3-security-includes.h > include/net-snmp/library/snmpv3.h >-%%WITH_IPV6%%include/net-snmp/library/snmpIPv6BaseDomain.h >+include/net-snmp/library/snmpIPv6BaseDomain.h > include/net-snmp/library/snmpUDPBaseDomain.h > include/net-snmp/library/snmpUDPIPv4BaseDomain.h > include/net-snmp/library/snmpTCPBaseDomain.h >@@ -177,6 +184,13 @@ > include/net-snmp/system/darwin8.h > include/net-snmp/system/darwin9.h > include/net-snmp/system/darwin10.h >+include/net-snmp/system/darwin11.h >+include/net-snmp/system/darwin12.h >+include/net-snmp/system/darwin13.h >+include/net-snmp/system/darwin14.h >+include/net-snmp/system/darwin15.h >+include/net-snmp/system/darwin16.h >+include/net-snmp/system/darwin17.h > include/net-snmp/system/dragonfly.h > include/net-snmp/system/dynix.h > include/net-snmp/system/freebsd.h >@@ -195,13 +209,17 @@ > include/net-snmp/system/generic.h > include/net-snmp/system/hpux.h > include/net-snmp/system/irix.h >+include/net-snmp/system/kfreebsd.h > include/net-snmp/system/linux.h > include/net-snmp/system/mingw32.h >+include/net-snmp/system/mingw32msvc.h > include/net-snmp/system/mips.h > include/net-snmp/system/netbsd.h >+include/net-snmp/system/nto-qnx6.h > include/net-snmp/system/openbsd.h > include/net-snmp/system/openbsd4.h > include/net-snmp/system/openbsd5.h >+include/net-snmp/system/openbsd6.h > include/net-snmp/system/osf5.h > include/net-snmp/system/solaris.h > include/net-snmp/system/solaris2.3.h >@@ -254,6 +272,8 @@ > man/man1/snmpgetnext.1.gz > man/man1/snmpinform.1.gz > man/man1/snmpnetstat.1.gz >+man/man1/snmpps.1.gz >+man/man1/snmptop.1.gz > man/man1/snmpset.1.gz > man/man1/snmpstatus.1.gz > man/man1/snmptable.1.gz >@@ -376,7 +396,7 @@ > %%WITH_PERL%%man/man3/NetSNMP::default_store.3.gz > %%WITH_PERL%%man/man3/NetSNMP::netsnmp_request_infoPtr.3.gz > %%WITH_PERL%%man/man3/SNMP.3.gz >-%%WITH_PERL%%%%SITE_ARCH%%/Bundle/Makefile.subs.pl >+%%WITH_PERL%%%%SITE_ARCH%%/Bundle/MakefileSubs.pm > %%WITH_PERL%%%%SITE_ARCH%%/NetSNMP/ASN.pm > %%WITH_PERL%%%%SITE_ARCH%%/NetSNMP/OID.pm > %%WITH_PERL%%%%SITE_ARCH%%/NetSNMP/TrapReceiver.pm >@@ -431,6 +451,7 @@ > %%DATADIR%%/mib2c.mfd.conf > %%DATADIR%%/mib2c.notify.conf > %%DATADIR%%/mib2c.old-api.conf >+%%DATADIR%%/mib2c.org-mode.conf > %%DATADIR%%/mib2c.perl.conf > %%DATADIR%%/mib2c.raw-table.conf > %%DATADIR%%/mib2c.scalar.conf >@@ -553,6 +574,7 @@ > %%DATADIR%%/mibs/SNMP-USER-BASED-SM-MIB.txt > %%DATADIR%%/mibs/SNMP-USM-AES-MIB.txt > %%DATADIR%%/mibs/SNMP-USM-DH-OBJECTS-MIB.txt >+%%DATADIR%%/mibs/SNMP-USM-HMAC-SHA2-MIB.txt > %%DATADIR%%/mibs/SNMP-VIEW-BASED-ACM-MIB.txt > %%DATADIR%%/mibs/SNMPv2-CONF.txt > %%DATADIR%%/mibs/SNMPv2-MIB.txt >@@ -568,7 +590,7 @@ > %%DATADIR%%/mibs/UCD-IPFWACC-MIB.txt > %%DATADIR%%/mibs/UCD-SNMP-MIB.txt > %%DATADIR%%/mibs/UDP-MIB.txt >-@unexec rm -f %D/%%DATADIR%%/mibs/.index 2>/dev/null || true >+@preunexec rm -f %D/%%DATADIR%%/mibs/.index 2>/dev/null || true > %%WITH_PERL_EMBEDDED%%%%DATADIR%%/snmp_perl.pl > %%DATADIR%%/snmpconf-data/snmp-data/authopts > %%DATADIR%%/snmpconf-data/snmp-data/debugging
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 232025
:
197865
|
202563
|
202690
|
202692
|
205132
|
205592
|
207965
|
207967