# -*- text -*- ---------------------------------------------------------------------- Changes: V5.9.5.1 -> V5.9.5.2 commit ca81dd88ec95021ab466ef7ab877314473b7b086 Author: Wes Hardaker Date: Tue Dec 23 08:49:00 2025 -0800 autoconf 2.72 commit 13f217faec21afa741054ff631197490b8a38927 Author: Wes Hardaker Date: Tue Dec 23 08:48:54 2025 -0800 update autoconf version to 2.72 commit 0ea9eb90b2e3eb4ca43018b75ef5b780b3dd136c Author: Wes Hardaker Date: Tue Dec 23 07:47:30 2025 -0800 autoconf commit 4d6831c19f73470b7e271133c53316bc45d046e5 Author: Wes Hardaker Date: Tue Dec 23 07:45:51 2025 -0800 Version number update: 5.9.5.2 commit cd87c89a87b5900a2c32f480eb3b9dca4803403c Author: Wes Hardaker Date: Tue Dec 23 07:42:14 2025 -0800 system -> informational commit a25c3828dbfa50c631811427fa3af318d72a4ecb Author: Wes Hardaker Date: Tue Dec 23 07:37:26 2025 -0800 don't force firefox use commit adf2b5298833f6438fafb88e5318236d0dea4ce1 Author: Wes Hardaker Date: Tue Dec 23 07:36:25 2025 -0800 include limits.h for LONG_MAX ---------------------------------------------------------------------- Changes: V5.9.5 -> V5.9.5.1 commit 83d4a87b693697fd67d39f885d4c254525645858 Author: Wes Hardaker Date: Tue Dec 23 06:34:37 2025 -0800 fix broken version mismatch from older 5.9.4 to newer 5.9.5.1 commit 1a45f84238207ee52bec7c8cab083da33d5e2541 Author: Wes Hardaker Date: Tue Dec 23 06:32:10 2025 -0800 Version number update: 5.9.5.1 commit 9940489b8653061474551c9d6acce2f80ef21704 Author: Wes Hardaker Date: Mon Dec 22 15:29:28 2025 -0800 trimming and modifying commit 6e9c67ef7e1cca1216a54139c2781ef736a2fbaf Author: Wes Hardaker Date: Mon Dec 22 15:25:36 2025 -0800 news for 5.9.5 ---------------------------------------------------------------------- Changes: V5.9.4 -> V5.9.5 commit 917f17c0b363273c048b97279093b4470dac39a1 Author: Wes Hardaker Date: Sat Dec 20 06:37:43 2025 -0800 Version number update: 5.9.5 commit 43da3ad35ace5d28e71212dd31c18ef9b6ba4726 Author: Andreas Hasenkopf Date: Fri Nov 7 11:19:38 2025 +0100 Fix segfaults when `varbind` cannot be constructed For multiple reasons, `varbind` can be a null pointer, which causes segmentation faults. With this change, the value is checked and the segmentation fault avoided. Co-authored-by: kain88-de Co-authored-by: spt29 commit 67d0989141ff4697a57afe16aa99afee0588ebed Author: Kuzin Andrey Date: Tue Nov 11 16:26:24 2025 +0300 Fix: Unused variable warning in cpu_linux.c mibgroup/hardware/cpu/cpu_linux.c: In function 'init_cpu_linux': mibgroup/hardware/cpu/cpu_linux.c:40:22: warning: unused variable 'cp' [-Wunused-variable] 40 | char buf[1024], *cp; | ^~ Move it to local scope. commit 49210f5e2df6b11865b3cc5e52329b93f6df4901 Author: Kuzin Andrey Date: Tue Nov 11 16:23:42 2025 +0300 Fix: Possible unix socket path overflow with strncpy() Compilation warning: sd-daemon.c: In function 'netsnmp_sd_notify': sd-daemon.c:316:9: warning: '__builtin_strncpy' specified bound 108 equals destination size [-Wstringop-truncation] 316 | strncpy(sockaddr.un.sun_path, e, sizeof(sockaddr.un.sun_path)); | ^ commit 8a0608a37aaacfeb22faf5097d3bf227831990ec Author: Kuzin Andrey Date: Tue Nov 11 16:22:56 2025 +0300 Fix: Add wrapers on const values to use in hosts_ctl() To prevent compilation warnings in snmp_agent.c and snmptrapd.c about discard 'const' qualifier: snmp_agent.c:1082:29: warning: passing argument 2 of 'hosts_ctl' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers] 1082 | if (hosts_ctl(name, STRING_UNKNOWN, sbuf, STRING_UNKNOWN)) { | ^~~~~~~~~~~~~~ In file included from snmp_agent.c:94: /usr/include/tcpd.h:131:42: note: expected 'char *' but argument is of type 'const char *' 131 | extern int hosts_ctl(char *daemon, char *client_name, char *client_addr, | ~~~~~~^~~~~~~~~~~ snmp_agent.c:1082:51: warning: passing argument 4 of 'hosts_ctl' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers] 1082 | if (hosts_ctl(name, STRING_UNKNOWN, sbuf, STRING_UNKNOWN)) { | ^~~~~~~~~~~~~~ /usr/include/tcpd.h:132:23: note: expected 'char *' but argument is of type 'const char *' 132 | char *client_user); | ~~~~~~^~~~~~~~~~~ commit 311171416e4da6a1561bbab6e8cbe5291ad1b7ea Author: Anton Moryakov Date: Tue Nov 4 21:38:52 2025 +0300 fix prevent buffer overflow in ASN_OCTET_STR index allocation In register_index(), when generating sequential string indices from 'prev_idx_ptr', the code used a flawed algorithm that could lead to buffer overflow by writing beyond the end of new_index->varbind->buf. The loop condition relied on buf[i] without proper bounds checking, and the fallback logic for growing the string wrote to buf[i+1] without validating available space. Rewrite the octet string increment logic to: - Properly check array bounds using i >= 0 - Use memmove to shift string left when growing - Validate buffer capacity before extending - Update val_len correctly Now returns NULL if buffer is full, preventing memor Signed-off-by: Anton Moryakov commit 201f8198c60b716c7c9dee6fe63cbbbc3838295b Author: Bart Van Assche Date: Sun Nov 9 06:18:18 2025 -0800 snmptrapd: Fix an integer overflow Do not add one to the trap type if doing this would cause an integer overflow. Fixes: https://issues.oss-fuzz.com/issues/459029273 commit b4e6f826d9ddcc2d72eac432746807e1234266db Author: Bart Van Assche Date: Sun Nov 2 14:48:55 2025 -0800 snmptrapd: Fix out-of-bounds trapOid[] accesses Fixes: https://issues.oss-fuzz.com/issues/457106694 Fixes: https://issues.oss-fuzz.com/issues/458668421 Fixes: https://issues.oss-fuzz.com/issues/458876071 commit d49392bb982954aa3d31516f04b2d9784b5f204a Author: Anton Moryakov Date: Tue Nov 4 14:40:09 2025 +0300 libsnmp: Reject invalid input in asn_realloc_rbuild_string() Return error if str == NULL && strlength != 0 in asn_realloc_rbuild_string to prevent potential NULL dereference and enforce valid input. Signed-off-by: Anton Moryakov [ bvanassche: modified patch description ] commit fc35391bb9d774d2ffa221df934a8ffdac91994b Author: Bart Van Assche Date: Sun Nov 2 15:17:48 2025 -0800 snmplib/snmpksm: Free memory when exiting commit 35d216b57ea2e9abf1cc42077bcf60a4bae0b29e Author: Bart Van Assche Date: Sat Nov 1 13:47:37 2025 -0700 snmptrapd: Do not write outside the bounds of trapOid[] commit b1f75132b1ed51743c862564065792fe20819b84 Author: wangxiaomeng Date: Fri Oct 31 11:18:53 2025 +0800 libsnmp: Need check env_var before read mib commit 1ef83cd90c65fae94debaed124d431d090813a1c Author: wangxiaomeng Date: Thu Oct 30 14:27:52 2025 +0800 snmp_agent.c: Fix crash caused by buf being a null pointer commit 8683cca83726ca0159ff9450f4673e0e0fc4d2d2 Author: Wes Hardaker Date: Fri Dec 19 05:56:16 2025 -0800 check trap variable type to ensure it's an OID commit e3c550b890b249c3512063ee471b8a3067ec3d24 Author: Bart Van Assche Date: Tue Oct 14 20:28:16 2025 -0700 ci, Windows: Bump the OpenSSL version number commit 6592b9b64950ef2d38af0d7de4cff81d571b0b18 Author: Ryan Steinmetz Date: Sat Sep 27 09:42:09 2025 +0200 Fix build for FreeBSD 15. Patch taken from FreeBSD ports collection. commit c8332ca8cce7e49189981066010b9e80e215aa0e Author: GenericRikka Date: Thu Sep 11 02:50:40 2025 +0200 Added include/net-snmp/system/freebsd16.h (cherry picked from commit 106cac2f04fc40c7f7a0f813b4bee88693dd9402) commit f3a3e9fb98e428c2d974cf4b6ad7ec15bc188340 Author: Moshe Kaplan Date: Thu Jul 24 13:27:50 2025 -0400 tunnel.c: Avoid leaking tunnel->ifname Fixes coverity 454603 (cherry picked from commit afd81d3965b9feb8f24e1e02c4e8e3b334693c58) commit 79c453845aabb99bf2278db9c95633e35a6cc6d9 Author: Bart Van Assche Date: Sun Jun 22 16:10:58 2025 -0700 Perl: add the compiler flag -Wno-old-style-definition (cherry picked from commit 02bee0fe32a4136ade3de137eef6c5acdfeed508) commit e5e1f96ded3d4f30d1ca223a80b9b0df6dc27115 Author: Bart Van Assche Date: Sun Jun 22 16:00:51 2025 -0700 snmpd, testing: Fix a few MinGW compiler warnings (cherry picked from commit dcabf00b29245249b717309957c0db6e232f1a0c) commit ad4537a2af54d85772496c3f542f60c1a8eb7e69 Author: AntonMoryakov Date: Tue Jun 10 13:54:26 2025 +0300 loadave.c: fix out-of-bounds access in loadave_parse_config Static analysis reported a potential buffer overflow when accessing maxload[i - 1] for i = 0. The issue was fixed by: - Adding a check to ensure i > 0 before accessing maxload[i - 1] - Using NETSNMP_DEFMAXLOADAVE as a default value for the first element (i == 0) - Ensuring that the code does not attempt to access memory outside of the maxload array This change makes the code more robust and avoids undefined behavior. Signed-off-by: Anton Moryakov (cherry picked from commit be3f27119346acbcc2e200bb6e33e98677a47b2d) commit 604ebdc0b3f841f613572dc4e9cc161b2d3d587c Author: Bart Van Assche Date: Thu Jun 5 09:00:45 2025 +0800 testing: Add a registration handler test with context name (cherry picked from commit 7a55b3332037302c4fd7d5378d435318704834a4) commit bd5539a5757f172adcb5b504ec069b8f5ad396ee Author: Bart Van Assche Date: Mon Jun 9 16:07:51 2025 -0700 snmpd: Fix a use-after-free in unregister_mib_context() See also https://github.com/net-snmp/net-snmp/issues/983. (cherry picked from commit b64bde54177ff2ed3110febcef189b5fdccb47ff) commit fbc1b7f94ea4fa8d1853df9ab08f4a21fa125f2b Author: Demon Date: Tue Jun 3 21:26:43 2025 +0800 win32: add build support for Windows on ARM (cherry picked from commit 23cfd15bf05aad242af958831b2b472e24e0ce04) commit 1a6aab4c913a505905ba8de1f2f4943e2f561d84 Author: Bart Van Assche Date: Sat Sep 13 15:29:08 2025 -0700 ci: Switch to the latest version of the Android SDK commit bcc2cccf6ecf0ebf2ec684c3854da9cfb6f8fc3b Author: Bart Van Assche Date: Fri Jun 20 10:59:29 2025 -0700 MinGW64: ci/build.sh: Switch from pkg-config to pkgconf pkgconf is the preferred and modern choice for MinGW64. commit e71597f537eeefe9c585be40262759e61cb9b4ce Author: Bart Van Assche Date: Mon Jun 2 15:48:35 2025 +0800 Revert "snmpd: Exclude certain MIBs if the Netlink library is not available" This reverts commit a6042e0f08e3b70cc0e3d810ba120d86758f27d8. On the V5-9-patches branch, fewer MIBs depend on libnl than on the master branch. Hence this revert. Fixes: https://github.com/net-snmp/net-snmp/issues/980 commit b88a7334a1468daebff0d1d763a0a7d26e7e701d Author: Bart Van Assche Date: Sat May 31 12:18:48 2025 -0700 snmpd, Perl: Fix most compiler warnings for MODE=read-only This patch includes only one functional change, namely in the Perl function snmp_set(). This patch prevents that in read-only mode snmp_set() passes an uninitialized pointer to Safefree(). commit 0687955e879d916f8edd567763e088d2e7c37603 Author: Bart Van Assche Date: Wed May 28 08:36:12 2025 -0700 ci/build.sh: Dump config.log if configure fails commit d4af272b3f3d7119c7ffa305fc2de6e8b7333c9b Author: Niels Baggesen Date: Wed May 28 16:48:10 2025 +0200 Fix warning when compiling with --disable-ipv6 commit 573e3215057cfbc7bff22a13c72a0b8979434830 Author: Bart Van Assche Date: Sun May 25 14:52:56 2025 -0700 ci: Add MODE=without-nl commit a6042e0f08e3b70cc0e3d810ba120d86758f27d8 Author: Bart Van Assche Date: Fri May 23 15:08:12 2025 -0700 snmpd: Exclude certain MIBs if the Netlink library is not available On Linux a significant number of MIB implementations depends on the Netlink library. Exclude these MIBs if the Netlink library is not available. commit e185504a84fff20fbc31ebbc24f8fbc15ae44eb1 Author: Bart Van Assche Date: Sat May 24 15:46:00 2025 -0700 configure: Test earlier for the Netlink library Prepare for making the MIB choice dependent on the presence of the Netlink library. commit 29faa0ccb8d93f561af878da3e7baf0979fcf3b1 Author: Bart Van Assche Date: Fri May 23 14:11:45 2025 -0700 configure: Exit with exit code 1 if MIB module debugging is enabled No Makefile is generated if MIB module debugging is enabled. Hence exit with exit code 1. commit 7182fb805a38910a85b0810e569ae19bf3786fbf Author: Bart Van Assche Date: Sun May 25 14:27:24 2025 -0700 ci/build.sh: Query the branch name instead of hard-coding it commit 628ccedea713287484dbed91fe698e313ec6d812 Author: Bart Van Assche Date: Sat May 17 14:45:18 2025 +0000 apps, snmpd: Move declarations in front of statements (cherry picked from commit 4473ead5cdecaa6df23a10062a701acaef61c299) commit 2588df7628d423558afec54296b3d419e48dfac5 Author: Bart Van Assche Date: Thu May 22 08:58:56 2025 -0700 configure: Fix the -Wdeclaration-after-statement test commit af34dcbe34fc5a825787a2157aed47d8e2e8bd8c Author: Bart Van Assche Date: Wed May 21 16:18:40 2025 -0700 ci: Add MODE=disable-ipv6 commit 0c0e19346e57287367e5baa3c60f1617c91a9819 Author: Bart Van Assche Date: Wed May 21 16:42:12 2025 -0700 testing: Skip IPv6 tests if IPv6 support is disabled commit a1ec55476213f92915d8186e6cb793d562e9a733 Author: Bart Van Assche Date: Wed May 21 16:27:18 2025 -0700 libsnmp: Fix --disable-ipv6 support commit 7536a8d6d363898e0f511aa81cf2dc000c452b89 Author: Bart Van Assche Date: Thu May 15 13:25:09 2025 -0700 configure: Enable -Wdeclaration-after-statement commit d9aad5695ed8964c142867a6d7888c9dd90c7361 Author: Bart Van Assche Date: Thu May 15 15:03:04 2025 -0700 libsnmp, perl, apps: Fix -Wdeclaration-after-statement warnings commit 5e2e029b262a3cba48ae801c259b85c5c749b013 Author: Bart Van Assche Date: Thu May 15 08:47:53 2025 -0700 ci/build.sh: Only build fuzz-tests on the master branch commit d896cdd5d554ba06e09ae5a8777b917be9fd113e Author: Bart Van Assche Date: Thu May 15 08:38:30 2025 -0700 ci/net-snmp-configure: Add missing package names commit 414394bddea52eafcae65e7bd7b0563c295b614d Author: Bart Van Assche Date: Sat Mar 8 13:48:16 2025 -0800 ci/build.sh: Fix the CI build Only build the fuzz tests in regular mode. Fix the name of the Makefile target. Fixes: 8c9ec0108c24 ("move fuzz-test target to just inside testing") commit c0cb4ef50ef2eff6006de47218f1d0db345e808e Author: Niels Baggesen Date: Thu May 15 16:09:54 2025 +0200 testing: Fix OpenBSD warnings about strcpy(), sprintf() when running tests [ bvanassche: modified patch description / added parentheses around sizeof arguments ] commit ed24f12728587737f5f8c08da1f171901cf9709b Author: Niels Baggesen Date: Thu May 15 16:07:39 2025 +0200 libsnmp: Use libssh2_session_handshake() when available libssh2 v1.2.8 deprecated libssh2_session_startup, use libssh2_session_handshake when available. [ bvanassche: modified patch description ] commit 741eb2dcfecf560a39454c7b93d56dff9a89a7c4 Author: Bart Van Assche Date: Thu Apr 3 19:57:37 2025 -0700 libsnmp: Do not truncate AGENT-CAPABILITIES descriptions Fixes: https://github.com/net-snmp/net-snmp/issues/957 (cherry picked from commit 36e0bdd1a0e6c9073c2da6c837ecfc38c4854586) commit c6ad7dffd7d81e5d603722a5053a3aed51cf5512 Author: Bart Van Assche Date: Tue Apr 1 09:48:26 2025 -0700 Perl: Revert "fix resource leaks in the SNMP::Session destructor and SNMP::NODE::FETCH" Revert commit 581698a162b47b08f8571c7e1b8991df0764e5d3 because it introduced the following crash: __snmp_xs_cb (SNMP.so + 0xab9c) snmp_sess_close (libnetsnmp.so.40 + 0x39419) XS_SnmpSessionPtr_DESTROY (SNMP.so + 0x16dc0) Perl_pp_entersub (libperl.so.5.32 + 0x108437) Perl_call_sv (libperl.so.5.32 + 0x7b18a) S_curse.lto_priv.0 (libperl.so.5.32 + 0x110920) Perl_sv_clear (libperl.so.5.32 + 0x111068) Perl_sv_free2 (libperl.so.5.32 + 0x10ff52) Perl_free_tmps (libperl.so.5.32 + 0x13a66f) XS_SNMP__main_loop (SNMP.so + 0x17e97) Perl_pp_entersub (libperl.so.5.32 + 0x108437) Perl_runops_standard (libperl.so.5.32 + 0x1001a0) perl_run (libperl.so.5.32 + 0x7e90c) main (perl + 0x134a) __libc_start_call_main (libc.so.6 + 0x295d0) __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x29680) _start (perl + 0x1385) Fixes: https://github.com/net-snmp/net-snmp/issues/955 (cherry picked from commit 823b8d2eca1916ae80295959d2704b546d6a0006) commit 656e39a2fe7125bf8c37a24e78427d5a373a8f7d Author: Klaus Holst Jacobsen Date: Fri Mar 28 10:01:07 2025 +0100 Better testing for syslog.h presence (cherry picked from commit 695ac0e1f8964e441d17282d9c475cc548f56f5d) commit 9870561812c4f15e7ca63ea1b5e5db7d25b66708 Author: Bart Van Assche Date: Mon Mar 31 09:58:35 2025 -0700 Perl: Suppress a warning message Suppress the following warning message: Attempt to call undefined import method with arguments ("AF_INET6" ...) via package "Socket6" (Perhaps you forgot to load the package?) at (eval 5) line 1. Fixes: https://github.com/net-snmp/net-snmp/issues/954 commit 19f0bb03152c2449b59663376958496edffe1531 Author: Niels Baggesen Date: Mon Mar 17 16:36:04 2025 +0100 Add error checking to schedConf.c. This fixes issue #864 (Out-of-bounds access in _sched_convert_bits function due to invalid cron_spec input) commit 49ee547aad51dc716aca6b2390f8fe430a0a7723 Author: Bart Van Assche Date: Sat Mar 8 13:49:16 2025 -0800 libsnmp: Fix a memory leak in an error path of parse_enumlist() Fixes: https://issues.oss-fuzz.com/issues/401658592 (cherry picked from commit 4618b65571b44591418d2080b2b4aa6ba43e2291) commit 48aaf0905d7fcafbc6ccc7f227958e08260e2ce3 Author: Anton Moryakov Date: Tue Feb 4 00:04:16 2025 +0300 agent: mibgroup: mibII: fix prevent use-after-free in write_vacmAccessStatus (cherry picked from commit 96faf0eb33e647916b6c3817ddda6dd02c7c4f25) commit 595f9af35731461c276b716d21414fad50370056 Author: Maxim Korotkov Date: Wed Mar 5 12:36:15 2025 +0300 snmplib: add deallocation of container name The function netsnmp_binary_array_release() does not deallocate dynamic char array. (cherry picked from commit dc2842c37a2ffbd26433c55c0de103251564944b) commit b2802e60ee381a774ff85ea59000f432b9621353 Author: Stuart Henderson Date: Sat Mar 8 13:10:11 2025 +0000 support openbsd8 (cherry picked from commit 7ffa1ced101b45fd2d45ea7ffb6a6353b9ab5186) commit 98c1925cb1221f25c5fc53960fa122c5ed314239 Author: Bart Van Assche Date: Wed Mar 5 19:33:33 2025 -0800 Perl: Disable -Wmaybe-uninitialized for .xs files (cherry picked from commit d5254345f45f0c15e961e37b5f6a8194b004183d) commit 9ae0e684c050c06fe0426bf821677a11d234dd05 Author: Bart Van Assche Date: Tue Mar 4 06:18:57 2025 -0800 libsnmp: Fix a memory leak in the MIB parser Fixes: https://issues.oss-fuzz.com/issues/383154227 (cherry picked from commit 2ee581b2ece557069e0f5a2e5cd65e3e6bf415c1) commit 0532cb5af7f2460fd14d697ccd3ddf987aaa63ab Author: Bart Van Assche Date: Mon Mar 3 12:18:50 2025 -0800 testing/fulltests/unit-tests/T004snmp_enum_clib: Add more checks (cherry picked from commit 2e98a911a994e7ce18c9a0f0051549a9dbd64842) commit 237a8377c8ee8af3e59b3cef96cfeb68f08dba4f Author: Bart Van Assche Date: Mon Mar 3 12:18:34 2025 -0800 libsnmp: Make clear_snmp_enum() free all lists Fixes: 2da22610f90b ("libsnmp: Make init_snmp_enum() faster") (cherry picked from commit 1d0895eaf1b919ea63da2e6d51e9fd138b38b8dc) commit 22c70efcc08f0da2525bc5d8f922ff99dfa4777b Author: Bart Van Assche Date: Mon Mar 3 09:42:50 2025 -0800 libsnmp: Rework se_add_pair_to_slist() Call se_add_pair_to_list() after having inserted 'sptr' into 'sliststorage' instead of before. (cherry picked from commit 080bcc445b67cd9dfc5c9f579182529aedbdf968) commit 31546ccaad857e28dcc7f214f363a2a3efaba145 Author: Bart Van Assche Date: Mon Mar 3 09:24:02 2025 -0800 libsnmp: Fix a memory leak in se_add_pair_to_list() Fixes: https://issues.oss-fuzz.com/issues/398401924 (cherry picked from commit 2ed9186eb0473c6d4b72503d764f7b13ab1573ff) commit 8a5d51e627173dfde092f2a32aca6fe2ebf602f6 Author: Bart Van Assche Date: Sun Mar 2 15:36:04 2025 -0800 libsnmp: Fix a NULL pointer dereference in snmp_config_when() (cherry picked from commit 87bd1ec3620c37ff4e7602c13966d65371378244) commit 9f6de1c98e04ddb4f254fc25f3cd7779d001a274 Author: Bart Van Assche Date: Sun Mar 2 15:23:07 2025 -0800 libsnmp: Fix a buffer overflow Fixes: https://issues.oss-fuzz.com/issues/399458050 (cherry picked from commit 4082593d733e2e03aaac74c62801f76449402651) commit 69b6025ab60ea67e0cfc7f37938d343149dedd63 Author: Bart Van Assche Date: Sun Mar 2 15:12:24 2025 -0800 libsnmp: Use netsnmp_memdup() instead of open-coding it (cherry picked from commit e49ee4990168e9aa02a2aeb02857385f868ff948) commit b7d5bbbb84239f0c22b5c227344b0a6a535cfd69 Author: Bart Van Assche Date: Tue Feb 25 13:04:11 2025 -0800 libsnmp: Make init_snmp_enum() faster Call calloc() once instead of 5 * 32 + 1 = 161 times. (cherry picked from commit 2da22610f90b8a64c930af02d88f07f3a596905f) commit 781e1bc319d23c61a00e62297b8926a866aaa6fd Author: Bart Van Assche Date: Tue Feb 25 09:20:34 2025 -0800 libsnmp: Fix a buffer overflow in setup_engineID() The following code triggers a buffer overflow if an oldEngineID has been specified that is shorter than 4 bytes: if (localEngineIDType == ENGINEID_TYPE_NETSNMP_RND) memcpy(bufp, &netsnmpoid, sizeof(netsnmpoid)); /* XXX Must be 4 bytes! */ else memcpy(bufp, &enterpriseid, sizeof(enterpriseid)); /* XXX Must be 4 bytes! */ Fix this by rejecting oldEngineID's shorter than four bytes. (cherry picked from commit 0b49a5de9ad4c3875e42ea223ff61de7d3e26963) commit 2985da1608f6731906944c4018fefe73b91997b7 Author: Bart Van Assche Date: Mon Feb 24 12:12:08 2025 -0800 libsnmp: Fix a heap buffer overflow in se_find_list() Fixes: https://issues.oss-fuzz.com/issues/398356443 Fixes: d7e6be1d59f7 ("generic snmp enum list support") (cherry picked from commit a147b834d49e656f6216701b8769b4b6261e72d5) commit 0b37269ca32393aeb314b2b726a345960701b464 Author: Bart Van Assche Date: Mon Feb 24 12:11:22 2025 -0800 libsnmp: Declare local variables 'static' (cherry picked from commit 8305b51e4d80158052b9cc279b798c227d81b9af) commit d845bdd100f454caf0bfd8ef28cf421d8fb26c16 Author: Bart Van Assche Date: Mon Feb 24 11:03:13 2025 -0800 libsnmp: Simplify se_add_pair() Introduce se_find_list_ptr(). Simplify se_add_pair(). Remove se_store_in_list() because this patch removes the last user of that function. No functionality has been changed. (cherry picked from commit 5f79b7f37febd7fafbddcc0f2aff3e81a3a439a2) commit 6a955cac13afa9ed9cdc778c7961756108259490 Author: Bart Van Assche Date: Sun Feb 23 10:10:15 2025 -0800 libsnmp: Simplify se_add_pair_to_list() Move the memory allocation code in front of an if-statement instead of duplicating it in each branch of that if-statement. (cherry picked from commit f23617df54f4d09d346bbc3452528abe3cc7947e) commit 61325b5cae0e5b2243fc078c6da71924dad0fa11 Author: Bart Van Assche Date: Sun Feb 23 10:01:12 2025 -0800 libsnmp: Make 'optind' handling more robust Fixes: https://issues.oss-fuzz.com/issues/398067543 (cherry picked from commit 2b3e0837830e14c7747ac1e175017c733d9d62b3) commit 90d06e589b77c3875595716700d69f6b6c4136f1 Author: Bart Van Assche Date: Fri Feb 21 15:04:30 2025 -0800 libsnmp: Fix another stack buffer overflow in se_read_conf() Additionally, make some recently modified code easier to read. Fixes: https://oss-fuzz.com/issue/6271135411142656 (cherry picked from commit b4d94476f02769a92be7d2122bc8926f39aa6980) commit 6af1dd2e6ab3820d949e24bc640bdcd75a05e48f Author: Bart Van Assche Date: Tue Feb 18 06:31:10 2025 -0800 libsnmp: Fix the code for resetting getopt() Although the getopt() man page mentions that 'optind' should be set to 1 to reset getopt(), the glibc implementation only resets the getopt() state if 'optind' is set to zero. Fixes: https://issues.oss-fuzz.com/issues/396777457 (cherry picked from commit cbedf0cba170b967ab312ebc794eabdd6f67c6d5) commit d1372b63fdf0d7fceb67c9527cf31d1219f84da0 Author: Bart Van Assche Date: Sun Feb 16 13:31:48 2025 -0800 Perl: SNMP: Suppress a compiler warning Suppress the following Clang compiler warning: SNMP.xs: In function ‘__snprint_value.isra’: SNMP.xs:449:21: warning: argument 1 is null but the corresponding size argument 3 value is [4095, 4096] [-Wnonnull] 449 | strlcpy(buf, ep->label, buf_len); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /usr/lib/x86_64-linux-gnu/perl/5.38/CORE/perl.h:1715, from SNMP.xs:12: /usr/include/string.h:506:15: note: in a call to function ‘strlcpy’ declared with attribute ‘access (write_only, 1, 3)’ 506 | extern size_t strlcpy (char *__restrict __dest, | ^~~~~~~ (cherry picked from commit 562a8bba9ebbc8621b8c299db6264c2d5685a721) commit c1ae498b04cdc43ebb6e5348dcf51fe061c1dec4 Author: Bart Van Assche Date: Sun Feb 16 08:45:02 2025 -0800 libsnmp: Fix a stack buffer overflow in se_read_conf() Fixes: https://issues.oss-fuzz.com/issues/396958482 (cherry picked from commit 2342de96b4968969e2f01f3970905963053b0504) commit 858157c225f8db6e41683a154b30f557a1501e5c Author: Bart Van Assche Date: Sun Feb 16 07:56:17 2025 -0800 libsnmp: Fix a NULL pointer dereference in netsnmp_ds_handle_config() This has been detected by fuzzing netsnmp_parse_args(). (cherry picked from commit 0a08ddf75e2234ea93aed1b2bccd9e387444e69b) commit e2712fe7e0d3dabb340c3770c27f233361fae6a1 Author: Bart Van Assche Date: Sun Feb 16 07:51:11 2025 -0800 libsnmp: Fix missing argument handling in netsnmp_parse_args() This may fix https://oss-fuzz.com/issue/4664325096931328 (not sure). (cherry picked from commit 578b1f50062677d6db1dc0e134226457b627ea11) commit 44c2edb218c303d0fc5f8e83483887246dfac749 Author: Bart Van Assche Date: Sat Feb 15 19:02:12 2025 -0800 libsnmp: Fix an out-of-bounds access in netsnmp_hex_to_binary() isxdigit() accepts arguments in the range -1..255. Make sure that the value passed to isxdigit() is in that range. This has been found by reading the source code. (cherry picked from commit ed6247a54085c13b1c327e46afe73d248e6afef0) commit 007b9c7e8a77c0b8b7e761895517923b00923304 Author: Bart Van Assche Date: Fri Feb 14 08:01:36 2025 -0800 libsnmp: Fix a memory leak in netsnmp_transport_filter_add() Fixes: https://issues.oss-fuzz.com/issues/396459485 (cherry picked from commit db989be9abc201d60691a0926e5a76f66f843fc3) commit 5c27b38d84cd480a0dc1dc09e93ce78e4663b99c Author: Bart Van Assche Date: Wed Feb 12 15:49:24 2025 -0800 libsnmp: Fix a NULL pointer dereference in netsnmp_ds_parse_boolean() Fixes: https://issues.oss-fuzz.com/issues/395969086 (cherry picked from commit 930f44e2ef4972047f3394c28c655fd15e04c706) commit e02bab233ca1ccff6b90eda7b644967c7b6917de Author: Bart Van Assche Date: Wed Feb 12 15:45:58 2025 -0800 libsnmp: Fix an out-of-bounds access in snmp_log_options() Fixes: https://issues.oss-fuzz.com/issues/395921931 (cherry picked from commit c90280f310aa8f9fd0442128244a8672bdfdb80e) commit 0b3d8eeba0df795676754ae7207726d3efb38a2e Author: Bart Van Assche Date: Wed Feb 12 15:41:35 2025 -0800 libsnmp: Fix a memory leak in netsnmp_parse_args() Fixes: https://issues.oss-fuzz.com/issues/395969087 (cherry picked from commit 0ab82d4c6cae3dd9f901ae292c2f60bbea32515a) commit 9c2aeb5cb12a75f366303623c522f6ed72afd944 Author: Bart Van Assche Date: Wed Feb 12 07:35:48 2025 -0800 libsnmp: Fix a heap buffer overflow Fixes: https://issues.oss-fuzz.com/issues/396102403 (cherry picked from commit 50d5c3d007cf9b4f56a29b79a8a2e736115eb6cb) commit c58525e2cfc4c18c8ccf51345f9b523b9507ad8a Author: Bart Van Assche Date: Wed Feb 12 07:30:44 2025 -0800 libsnmp: Declare local functions 'static' (cherry picked from commit 8cf375fb612dcaa635a063d92b962be260a6a0ea) commit 6644fd92260abedf52921101419bc3f341fddeb8 Author: Bart Van Assche Date: Wed Feb 12 09:13:27 2025 -0800 ci, Windows: Bump the OpenSSL version number commit bdb611307f1fa9336b9455409e748bf709f31677 Author: Egil Kvaleberg Date: Fri Jan 31 21:26:37 2025 +0100 Document that we are now using configure.ac (cherry picked from commit 1109b6fd408e1c8b03e6ccfdcbe70c2ad0412c13) commit 8d4f4d623f5f90ad7ca7227a1cacce23a0e52802 Author: Egil Kvaleberg Date: Fri Jan 31 21:24:20 2025 +0100 Avoid latest Rpi compiler complaining about possibly uninitialized variable. The code seems ok. (cherry picked from commit 5db02cfd10b4a198cfcd23658f17f0d8f737a8ab) commit 3d41fcf7eb0d4590a6583fa024d27cd7fc75f6fa Author: Yuan Date: Wed Jan 22 16:31:47 2025 +0800 Fix include stdint.h missing to get SIZE_MAX This fixes commit d33578d for ubuntu building. Signed-off-by: zodf0055980 (cherry picked from commit ba627e15aafd49341d94d35989b1b9703918dfa9) commit a043a06540dc595dc17a56504de969d3700264f6 Author: Bart Van Assche Date: Mon Jan 20 19:23:56 2025 -0800 libsnmp: Fix an integer overflow in asn_parse_signed_int64() This was detected by Coverity (ID 454617). (cherry picked from commit 33b25d6e181ba949791885109a5dadeaa9046865) commit eed6600c62ac18599cdf562db4cb0de1974b1f41 Author: Bart Van Assche Date: Sun Jan 19 19:06:38 2025 -0800 libsnmp: Simplify include/net-snmp/types.h (cherry picked from commit 6a95ad887b04758e5b76e5d3d0c8546257e5efd5) commit eb9a6282d8ef14902c8f7ed1c9c9da43d0640fdb Author: Bart Van Assche Date: Sun Jan 19 19:15:26 2025 -0800 libsnmp: Fix the netsnmp_gethomedir() declaration Fixes: 1c6e66b3122b ("libsnmp: Fix homedir lookup also for configuration") (cherry picked from commit 0e27a7d8c2f9c84fc641cc61cf24791da8a8198f) commit 8067e9ff12fbf706323f3faef5b9146e57158b58 Author: Klaus Holst Jacobsen Date: Fri Jan 17 10:12:23 2025 +0100 Added qnx support (cherry picked from commit 2145ebd07f5b6ec6c4eee505ffa2431f3c361087) commit a1d35a12cdb62aa7c71866715843a38f64e0eefc Author: Denis Kamenskii Date: Fri Oct 4 11:45:35 2024 +0300 notificationFilter: Fix mask data copying This change is fixing incorrect filterMask copying when adding a new snmpNotifyFilter (cherry picked from commit 571696608c260d81d1d686234fea02a132bbe65a) commit 0b940b98005498419d24d14fbdfb2137946d321c Author: Jon DeVree Date: Sat Jan 18 10:04:03 2025 -0500 Add missing 'diskio_exclude_md' to manpage Fixes: 2fc3de6b5 ("Added option to exclude *md* devices in diskio.") (cherry picked from commit bb21b69d75df050754efb5476e74eb4f630e5d11) commit e29c40dbddb827e4b9324c0105cfc9a35e7557ac Author: Jon DeVree Date: Sat Jan 18 10:03:18 2025 -0500 Fix typo in manpage: LInux => Linux Additionally, ending a line with a period seems to insert an extra space into the resulting text. Re-wrap the line to avoid having a period as the last character. (cherry picked from commit dc7f4d53afd687b3a70ec0d16b80b8ced0afbac7) commit e0fb35640459f62a7773cee09c34949b19d82a88 Author: Orgad Shaneh Date: Wed Dec 18 07:40:40 2024 +0200 libsnmp: Fix homedir lookup also for configuration (cherry picked from commit 1c6e66b3122b7fd878d17f40664adf831d1a2c7a) commit ef137dbd3c183db0acce4fcb60ab67245b092b26 Author: Niels Baggesen Date: Fri Jan 24 16:14:20 2025 +0100 Normalized line endings commit a17027209a0101b66dc7ab50670d0146677e2545 Author: Orgad Shaneh Date: Tue Dec 17 12:03:57 2024 +0200 Add gitattributes file to use eol=lf for almost all files This fixes autoreconf on MSYS2 and possibly other issues. (cherry picked from commit d17282ed842364d83be83d1a45ad95dd986cdb0a) commit 572661f8265516c397b7691aa4ae1b8cfa05a34b Author: Orgad Shaneh Date: Tue Dec 17 20:59:59 2024 +0200 libsnmp: Support $HOME in MIBDIRS also on Windows (cherry picked from commit 75829eb857f2468001050fda26af843bcb9475db) commit 5a94f2831e8b22ffd962af9db6f7d0959c0dde51 Author: Bart Van Assche Date: Wed Dec 11 07:56:25 2024 -0800 libsnmp: Use asprintf() in parse_trapDefinition() No functionality has been changed. (cherry picked from commit 46980afe4a4b5ce9820bd4419064d18e28fe215b) commit b7119b2d578e782300d372a2e5e1c6327977e2eb Author: Bart Van Assche Date: Wed Dec 11 07:21:17 2024 -0800 snmplib/parse.c: Make error handling more systematic No functionality has been changed. (cherry picked from commit b057efbf770fbd964a8f6fd1e27912f584a6a8ee) commit 078e165b17376e95c705341affad628e86d865ac Author: Bart Van Assche Date: Sat Dec 7 15:13:29 2024 -0800 libsnmp: Fix a memory leak in free_objgroup() Fixes: 84aba8f8f878 ("libsnmp: Fix a memory leak in the MIB parser") Fixes: https://issues.oss-fuzz.com/issues/380322456 (cherry picked from commit 9425b05b663c55e12bc4fccec45a520c333ee343) commit d6e918eadc41eb3a364ce946495e92151221b63c Author: Bart Van Assche Date: Sat Dec 7 15:09:09 2024 -0800 libsnmp: Clean up compliance_lookup() Convert an if-else statement into an early return. Remove a superfluous cast. (cherry picked from commit d1bf740f9d328c2264f7a0abfb1970f41ccf9c4e) commit 11169c7d027b61150cda413a48bae62a36364723 Author: Bart Van Assche Date: Tue Dec 3 09:26:40 2024 +0800 MIB-II: Suppress a Coverity warning about an uninitialized variable (cherry picked from commit e780c985bf74ab7cda1fc6f4cb57435e980ee255) commit db42a6041317853be0d91b525ba9b2efccf7dc4c Author: Bart Van Assche Date: Tue Dec 3 09:24:49 2024 +0800 snmptrapd: Suppress a Coverity warning about an uninitialized variable (cherry picked from commit 9100bf8550c7c0baebdb1fd31e89d5fcee628fc4) commit 4feaa89057bb0b17e05832f655d4b12281a8b761 Author: Bart Van Assche Date: Tue Dec 3 09:22:26 2024 +0800 libsnmp: Suppress Coverity warnings about time_t truncation (cherry picked from commit e81a0edac75e568cddf7a1f595c4d7108c0a0bca) commit 0f81e94dffe932c545d36dff6ddf9d14cb6297d7 Author: Bart Van Assche Date: Sat Nov 30 13:31:15 2024 -0800 snmpd: Fix a potential integer overflow Make sure that avgvarbind > 0. This was detected by Coverity. (cherry picked from commit 2c24c784e08d194f62d08beea77fd2bef275577f) commit 92aa03f0381bac095fce1698a72e174b845d590c Author: Bart Van Assche Date: Sat Nov 30 13:28:37 2024 -0800 IP-MIB: Suppress a Coverity complaint Suppress a Coverity complaint about assigning -1 to entry->index. (cherry picked from commit 9e92b038386a63c5731a4717248ab65fedc6ad9b) commit 185611aebabc9362a55cc55e05bbc16e32b87e1f Author: Bart Van Assche Date: Tue Nov 26 15:16:17 2024 -0800 libsnmp: Rework an integer overflow check Rework an integer overflow check such that it no longer triggers a Coverity complaint. Fixes: 993728c977d4 ("libsnmp: Handle integer overflows in asn_predict_length()") (cherry picked from commit d33578d0bd1675a6f3d2a9d6788994e8bb1e7cef) commit 11c79b623f49b88f9006a3f3630a18aa5fd85c87 Author: Bart Van Assche Date: Tue Nov 19 14:47:27 2024 -0800 libsnmp: Split read_module_internal() to make it easier to read (cherry picked from commit 65375083382a4cd8a3913628f32596139f8f9eb8) commit f2ff0be44cc2c646f852d5c669a20d44e048e473 Author: Bart Van Assche Date: Tue Nov 19 14:58:52 2024 -0800 libsnmp: Use asprintf() in netsnmp_init_mib() instead of open-coding it Additionally, combine two SNMP_FREE(env_var) statements into a single statement. (cherry picked from commit e0be85dca5e8ab3a16702b6c48d6a401052e3ec9) commit 2058b0ccf6f111d90c4434c3db337961285196e3 Author: Bart Van Assche Date: Tue Nov 19 14:34:22 2024 -0800 libsnmp: Declare variables with file scope 'static' Additionally, zero-initialize variables with file scope implicitly instead of explicitly. (cherry picked from commit e1897a0baaa36ef5ad73c5653960c2ab239a64dc) commit 402f4a00e68222b9558fb3d5fac1ac782e5b2ba3 Author: Bart Van Assche Date: Wed Nov 6 12:22:18 2024 -0800 DISMAN-MIB: Suppress a Coverity complaint about integer truncation (cherry picked from commit f91020b7b7ccef4746e61a62c1acd5e7f2ee73bf) commit 1d67d78bfe7bcb02ca195ca9abf2bbd733939875 Author: Bart Van Assche Date: Wed Nov 6 12:20:28 2024 -0800 DISMAN-MIB: Suppress a Coverity complaint about integer truncation (cherry picked from commit 4e327e5838b2f8a07023c591c773602e4d299e44) commit 1f22bab84f6104859488488b878097248d3c598d Author: Bart Van Assche Date: Wed Nov 6 12:16:30 2024 -0800 libsnmp: Rework an integer overflow check Rework an integer overflow check such that it no longer triggers a Coverity complaint. Fixes: 993728c977d4 ("libsnmp: Handle integer overflows in asn_predict_length()") (cherry picked from commit e500d823c1242d3859f671ec5dd51c9fc6b9eeb5) commit 8473bf2a7f3938c7089e53f17e04edf3f2fab418 Author: Bart Van Assche Date: Tue Nov 5 06:55:06 2024 -0800 snmplib: Make get_module_node() check the strdup() return value Fixes: https://github.com/net-snmp/net-snmp/issues/887 (cherry picked from commit 801955c017327d711bce51ac4535557b11a98e39) commit b78ba9198686a9ac7b0f2aa5c87c6904752350f0 Author: Bart Van Assche Date: Tue Nov 5 06:34:34 2024 -0800 snmplib/transports/snmpUnixDomain: Fix a socket leak in an error path Fixes: https://github.com/net-snmp/net-snmp/issues/888 (cherry picked from commit 973a14ae0101d2b5fde67732208a3949f9ae9667) commit b9eb7d242552319e0fc5495cf7d5ef89698ca412 Author: Bart Van Assche Date: Thu Sep 26 09:24:38 2024 -0700 libsnmp: Remove an incorrect assert statement See also https://github.com/net-snmp/net-snmp/issues/856. (cherry picked from commit d8c83ff96144f0bb0945a3640ce7ac5995b91c74) commit 56ce8ccab4b27c0799a88a580fde1ef788869c88 Author: Nathan Monfils Date: Fri Aug 9 17:00:55 2024 +0200 Update snmp-create-v3-user man date What a jump! (cherry picked from commit ec00e19d475a2aa49c73651e93bb524d0a55fe9f) commit 638501c2781e9ace83f27e790d7b4592adf6d57e Author: Nathan Monfils Date: Fri Aug 9 16:50:29 2024 +0200 Update man page for net-snmp-create-v3-user Missing option for authentication algorithm and missing parameters for encryption algorithms have been documented. Although case does not matter for `-A` and `-X` (which seems to be its own can of worms that needs to be kept for compatibility), I've switched them around to match the usage string of `net-snmp-create-v3-user --help`. (cherry picked from commit 7d0da6c40db63611648115ad8dc4e5f00485ba1d) commit 27912791e1128dc9cfed9e8e9209c46d4cc2cbc7 Author: Bart Van Assche Date: Sun Jul 5 12:53:25 2020 -0700 FreeBSD: Fix the sysctl() configure test This patch fixes the following compiler warnings: conftest.c:406:1: warning: type specifier missing, defaults to 'int' [-Wimplicit-int] main() { ^ conftest.c:415:41: warning: incompatible pointer to integer conversion passing 'void *' to parameter of type 'size_t' (aka 'unsigned long') [-Wint-conversion] sysctl(mib, 2, &boottime, &len, NULL, NULL); ^~~~ /usr/include/sys/_null.h:34:14: note: expanded from macro 'NULL' ^~~~~~~~~~~ /usr/include/sys/sysctl.h:1062:70: note: passing argument to parameter here int sysctl(const int *, u_int, void *, size_t *, const void *, size_t); ^ conftest.c:417:5: warning: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Wimplicit-function-declaration] exit(0); ^ conftest.c:417:5: note: include the header or explicitly provide a declaration for 'exit' 3 warnings generated. (cherry picked from commit 09e42bbc4efcffb44bf50f150447bd25077d133b) commit 5ae20aad09846149fb2a7affbb9b9af32f08752b Author: Ivan Antonyuck Date: Tue Jul 30 15:42:00 2024 +0300 Update net-snmp-create-v3-user.in net-snmp-create-v3-user has an ability to use AES128, but does not advertise it (cherry picked from commit 3fab3b3b9031e97b85954d9dd6b60c546ca7cb9c) commit 501cc8bd0e7143c8e1aeee5142f4fd865c759da5 Author: Maxim Korotkov Date: Tue Dec 19 17:05:55 2023 +0300 agent: mibgroup: avoid potential NULL dereference The "while" loop shifts the pointer, which can cause it to be NULL. Fixes: 8baf64d4ae616(Re-worked Schedule MIB implementation.) Found by RASU JSC Signed-off-by: Maxim Korotkov (cherry picked from commit 8ab403e1595d3eca3d922daeb69d2dc454c8f9ef) commit eac92fb1e34fb9413d4cadc45444a2a43290909b Author: Simon Aldrich Date: Mon Jul 8 22:49:36 2024 +0100 Correct uS to μs for microseconds (cherry picked from commit 90a70ebd82ae1b545e7a58c1b3eb10981cb85adc) commit 5977b47543202ff68977aae806ceca6cf42144c0 Author: Simon Aldrich Date: Mon Jul 8 22:31:49 2024 +0100 Correct misleading header comment about retry timeouts (cherry picked from commit d305715470ea8d0e6b1ae899a03f58939629d23e) commit 07a197022d0b1b597ff135352cd677eb25ea4c04 Author: Bart Van Assche Date: Sat Jun 29 15:05:03 2024 -0700 snmpd, snmptrapd: Fix Coverity complaints about integer overflows (cherry picked from commit c1a34f3cbc1bf33fb65b125852541b8336e977cf) commit 012cb784b1fa6cfa807c272c774d9357fc5bfa8e Author: Bart Van Assche Date: Sat Jun 29 15:01:26 2024 -0700 libsnmp: Handle integer overflows in asn_predict_length() (cherry picked from commit 993728c977d416b15ea74ae8b0b03ebdf1c07ec8) commit 2625be874235a1f8a2bc1bf070a23092ed903a6d Author: Bart Van Assche Date: Sat Jun 29 14:48:49 2024 -0700 UCD-SNMP-MIB: Fix a potential integer overflow This was detected by Coverity. (cherry picked from commit f4005f4b8da27dc88e2001fbc2a884c16cf5fc11) commit 08db791adcac3bb3fa7f5fa95ccdfcbc5b21cac7 Author: Bart Van Assche Date: Sat Jun 29 14:45:23 2024 -0700 snmptrapd: Fix an integer underflow This was detected by Coverity. (cherry picked from commit 449c27cf9f36306b906e1e282a832f6545c4f532) commit f2ce30e252b3f63fc28097da99c9f92823329cd2 Author: Bart Van Assche Date: Sat Jun 29 14:43:43 2024 -0700 snmpd, apps: Handle mktime() failures This was detected by Coverity. (cherry picked from commit 3a4c6307086207eb5a69f88823063c934c02a692) commit dfab20a13e27eed063226c038008342855344640 Author: Maxim Korotkov Date: Tue Dec 19 17:44:45 2023 +0300 agent: helpers: added allocation fail check Fixes: e2ea345fa783(Agent helper module for support of scalar objects.) Found by RASU JSC Signed-off-by: Maxim Korotkov (cherry picked from commit 600b37a14105f73c2414b83b66297933cebbdec7) commit c9ac9f1c92600c1a568493f4a69c462e7fb115a7 Author: Wei Xing <2112860871@qq.com> Date: Fri May 24 01:53:59 2024 +0800 dump space around the "=" (cherry picked from commit 0aac3305b43f5eed38bd9aa53e44fdfc828d7cb3) commit 753bd7b6182aaa2326f3bad7d7aa8227bfe51b77 Author: Niels Baggesen Date: Sat Nov 30 20:29:14 2024 +0100 Update LM-SENSORS-MIB to support negative temperatures This fixes #752 commit 7949884b3fcab6da8c70b5e7c056da184c701195 Author: Bart Van Assche Date: Tue Nov 26 15:34:05 2024 -0800 CHANGES: Remove -Wredundant-decls from the developer options Revert commit ad80e335b8af because this option causes a lot of noise for the Perl header files. commit e39d80bc5b2ef01afc8b6872546cba61ce6a8538 Author: Bart Van Assche Date: Sat Nov 23 17:06:00 2024 -0800 libsnmp: Clean up parse_enumlist() Fix code formatting and indentation. Remove a superfluous cast. No functionality has been changed. commit b8ec69597c9031d75f5b1602be350833fda882de Author: Maxim Korotkov Date: Wed Dec 14 12:46:49 2022 +0300 snmplib: Fix memory leaks in the parse_enumlist() error path Found by RASU JSC with ISP RAS Svace Signed-off-by: Maxim Korotkov [ bvanassche: renamed error label, fixed indentation and a potential null pointer dereference ] commit 8f54853716dcb9447387931870341cf01d6b1bb8 Author: Bart Van Assche Date: Tue Nov 12 09:35:44 2024 -0800 libsnmp: Fix netsnmp_add_loghandler() Fixes: https://github.com/net-snmp/net-snmp/issues/696 Fixes: 00ef569e00d1 ("Fix 5.5.x branch structure (part 2)") commit cfc58d3e9cae01013a3baa70913681c31876c6e6 Author: Bart Van Assche Date: Mon Nov 11 17:13:18 2024 -0800 libsnmp: Declare local variables 'static' Additionally, switch from explicit to implicit zero-initializing of variables with file scope. commit fbdf2ed2e0bb06050d314e008a34d9ecdb84be17 Author: Bart Van Assche Date: Mon Oct 28 09:21:45 2024 -0700 libsnmp: Fix a buffer overflow in setup_engineID() See also https://github.com/net-snmp/net-snmp/issues/732. commit 88199e67c5f9ac2f5e72fc3f28b6b19d3321eb60 Author: Bart Van Assche Date: Thu Oct 24 09:40:27 2024 -0700 apps: Restore support for systems where tv_sec does not have the time_t type commit 0fcc15cca99a400b9beac47ee32d49e90ceca517 Author: Bart Van Assche Date: Wed Oct 23 11:18:05 2024 -0700 apps, libsnmp, snmpd: Check the localtime() return value See also https://github.com/net-snmp/net-snmp/issues/867. commit dc3884fd3a4cb2f915df73dbcfc25267f69a790b Author: Bart Van Assche Date: Wed Oct 23 10:07:28 2024 -0700 apps/snmpdelta: Prevent that a localtime() triggers a crash See also https://github.com/net-snmp/net-snmp/issues/867. commit fc847a802d7600adfc9ad2ebb29fe485a19c920b Author: Bart Van Assche Date: Wed Oct 23 10:00:19 2024 -0700 ci, Windows: Bump the OpenSSL version number commit 512ed48b8c35191b97e3bdcd7f3dab21200a0ba9 Author: Niels Baggesen Date: Mon Oct 7 09:30:47 2024 +0200 Port sshtosnmp to FreeBSD. Completes 3346619 (libsnmp: Port the SSH domain transport to FreeBSD) commit f2b6880b1bb30332aec48986799f659e6e6690ed Author: Niels Baggesen Date: Thu Aug 22 08:23:54 2024 +0200 Fix ipv6.c for DragonflyBSD (#841) Fixes: ebb758e3 (x Fix var_udp6 and var_tcp6 on FreeBSD) commit 34ec1fafd562292d8f511901c38009c8a3031625 Author: Bart Van Assche Date: Thu Jul 11 13:05:52 2024 -0700 DISMAN-EXPRESSION-MIB, DISMAN-EVENT-MIB: Simplify the security name duplication code Use netsnnmp_memdup() instead of calloc() + memcpy(). commit d1e107882230cbf53b19e6af1dc2d1878017e6e4 Author: Bart Van Assche Date: Wed Jul 10 13:31:09 2024 -0700 snmpd: Terminate security names with NUL Some code, e.g. netsnmp_iquery_session(), assumes that security names are NUL-terminated. Guarantee that this is the case. This patch fixes an address sanitizer error. commit bd6b09460ec268115cdd6f269f1cab8c69759c33 Author: Bart Van Assche Date: Tue Jun 18 13:12:38 2024 -0700 ci/install.sh: Install libmariadb-dev-compat for mysql_config commit 7c94ff08aacddae8dd5c068652b70288e84a152d Author: Mark Johnston Date: Tue Jun 11 10:04:06 2024 -0400 snmpd: Always open libkvm in "safe mode" on FreeBSD By specifying /dev/null as the path to kvm_openfiles(), we can get a libkvm descriptor which does not hold /dev/kmem open. None of the code shipped with net-snmp needs a /dev/kmem handle. Make this change for both the NETSNMP_NO_KMEM_USAGE and !NETSNMP_NO_KMEM_USAGE cases, per a suggestion from Bart Van Assche . commit 21bd3a00cf3efc1ef5b72d1e60d631ecfce3608f Author: Bart Van Assche Date: Fri Jun 14 14:52:47 2024 -0700 ci/perl.bat: Bump the Perl version commit 7ab06fdcb5d6066d0243af6203c54c24d5dcd795 Author: Niels Baggesen Date: Tue Jun 11 10:08:08 2024 +0200 Better test and info for libnl-3 presence commit 10e4846eebb20f4d58dca3d8e6c80e5c19bd2b83 Author: Bart Van Assche Date: Mon Jun 10 17:29:44 2024 -0700 ci, Windows: Bump the OpenSSL version number commit 98b8a5698594c0389dd66170aeb09425ae720852 Author: Bart Van Assche Date: Mon Jun 10 15:43:39 2024 -0700 Darwin: MIB-II: Fix the build for OS/X versions prior to 10.6.0 Fix compilation of Net-SNMP 5.9.4 on older versions of Mac OS X (prior to 10.6.0). This patch fixes the following build errors: mibgroup/mibII/kernel_sysctl.c: In function ‘sysctl_read_icmp6_stat’: mibgroup/mibII/kernel_sysctl.c:108: error: ‘MLD_LISTENER_QUERY’ undeclared (first use in this function) mibgroup/mibII/kernel_sysctl.c:108: error: (Each undeclared identifier is reported only once mibgroup/mibII/kernel_sysctl.c:108: error: for each function it appears in.) mibgroup/mibII/kernel_sysctl.c:109: error: ‘MLD_LISTENER_REPORT’ undeclared (first use in this function) mibgroup/mibII/kernel_sysctl.c:131: error: ‘MLD_LISTENER_DONE’ undeclared (first use in this function) make[1]: *** [mibgroup/mibII/kernel_sysctl.lo] Error 1 Fixes: https://github.com/net-snmp/net-snmp/issues/822 commit e11dadfb5fa3798cad4de3222ba04378728beefd Author: Bart Van Assche Date: Tue May 21 16:11:31 2024 -0700 libsnmp: Reduce code duplication Merge netsnmp_tcpbase_session_init() and netsnmp_udpbase_session_init() into a single function. commit ed917bfdb0e07f41c817b3f5efc255a6ce538df2 Author: Teus Benschop Date: Tue May 21 16:04:10 2024 -0700 libsnmp: Copy the listening port number into snmp_session.local_port [ bvanassche: removed trailing whitespace ] commit d30d63523bfd9ccc85175e484fea821815273237 Author: Bart Van Assche Date: Wed May 15 10:08:04 2024 -0600 snmptrapd: Fix compilation against recent versions of the MySQL library Fix the following build error: snmptrapd_sql.c:541:50: error: assignment to ‘_Bool *’ from incompatible pointer type ‘char *’ [-Wincompatible-pointer-types] 541 | _tbind[TBIND_v3_SECURITY_ENGINE].is_null = &_no_v3; Fixes: https://github.com/net-snmp/net-snmp/issues/815 commit e73c892e51dbbf3b75a9a19a2e7bbc269eeb05be Author: Bart Van Assche Date: Wed May 15 14:54:52 2024 -0600 CHANGES: Win32: winExtDLL: Fix the build Fix the following build error: mibgroup/winExtDLL.c:360:14: error: implicit declaration of function 'should_init' [-Wimplicit-function-declaration] 360 | if (!should_init(dll_basename)) { | ^~~~~~~~~~~ commit 3d6b7457ee34be30fe51b5e303521ece5d28feda Author: Bart Van Assche Date: Wed May 15 10:20:09 2024 -0600 ci/install.sh: Add the libmariadb-dev package In recent Debian distributions the MariaDB client library has been moved from libmariadbclient-dev to libmariadb-dev. commit 8f3cedfa723cfe1df5264cf174e9a3c279d9266e Author: Teus Benschop Date: Wed May 8 10:21:10 2024 -0700 libsnmp: Copy the listening port number into snmp_session.local_port This is useful if the MIB behavior should depend on the listening port. Listening port information can be retrieved as follows in a MIB implementation: reqinfo->asp->session->local_port. [ bvanassche: added IPv6 support and added a patch description ] commit 771966122e2fa7beca54febdd223464676c72fd3 Author: Bart Van Assche Date: Tue May 7 11:30:47 2024 -0700 EtherLike-MIB: Fail compilation on Linux if libnl-3 has not been found Commit 5b89350912eb ("EtherLike-MIB: Optimize the Linux implementation") made libnl-3 a dependency of the EtherLike-MIB implementation on Linux. Hence fail the build on Linux if libnl-3 has not been found. commit 9a8583119350b5db74163621acf11650e1187d79 Author: Bart Van Assche Date: Tue May 7 11:03:59 2024 -0700 configure: Fix a source code comment commit ebb758e337a52c75a06b2448ebb44a6c78a8600e Author: Mark Johnston Date: Tue Apr 30 13:53:57 2024 -0400 Fix var_udp6 and var_tcp6 on FreeBSD commit 3fa4c3157bb866c97876cc6ae236a5e122f228ef Author: Bart Van Assche Date: Thu Apr 25 07:00:48 2024 +0200 ci/install.sh: Minor improvements commit db30d3a47bc11429fbff5374af6da3601a493f4d Author: Niels Baggesen Date: Mon Apr 8 21:32:26 2024 +0200 Fix apparently transposed arguments to calloc. Detected by gcc 14 on Fedora 40 (BETA) commit 84f819c815d6644a5e916a3b8f56cd4d0b6f151d Author: Niels Baggesen Date: Mon Apr 8 21:09:55 2024 +0200 snmp_openssl.c: reorder some declaration to avoid warnings about redundant declarations. commit 1a10dbc83c0a2e5622943d65d46ef0a0c7048831 Author: Niels Baggesen Date: Mon Apr 8 20:57:59 2024 +0200 For the ARM architecture, char is unsigned. Repair the detected bad comparisons between char and -1. commit 148dd13682e8e0218c39778d433a8ff073fc78a3 Author: Niels Baggesen Date: Mon Apr 8 20:53:12 2024 +0200 Remove some duplicated declarations. commit c728c3cd64ad10c2b73dc3e284b0b2f6dfdd2502 Author: Niels Baggesen Date: Mon Apr 8 20:50:43 2024 +0200 EtherLike-MIB: remove a now unused variable. commit be35c9dd9af9582a1c40dff9c6994dc2743a2ff2 Author: Niels Baggesen Date: Mon Apr 8 20:47:43 2024 +0200 Fix commit 5b89350 (EtherLike-MIB: Optimize the Linux implementation) for *BSD by adding an "#if defined(linux)" that was lost during backport. commit 5cabd6f570aa6b0d741250b157c5a5d886c8b3b5 Author: Bart Van Assche Date: Fri Feb 2 07:26:59 2024 -0800 EtherLike-MIB: Declare local variables and functions static commit 05f56d3ec9e6c07dab12241ce3aa048d3dccd839 Author: Martin Rys Date: Sun Mar 3 01:19:51 2024 +0100 snmpd/snmptrapd.service: Remove dead syslog.target (cherry picked from commit 99237462ace151c3d706aa31f6060b491dacd2fa) commit 1268bc0dbcfa598fe67c3781f6c854b54d828490 Author: Thomas Egerer Date: Thu Feb 29 21:18:32 2024 +0100 libsnmp: Reassign timeout value for select(2) As select may update the timeout value, the code may not sleep for 100 ms. If timeout is updated, the code will only sleep for 1 ms once and the immediately return from select(2). Reassign the timeout value in the loop shouldn't be harmful even on systems that don't update the timeout value. Signed-off-by: Thomas Egerer (cherry picked from commit 741f066026e8bb97bac6bd3f43ed2cc1cdfd14b6) commit 468c5b2b40b0fbb9a47b21ec82eae51eee9dae27 Author: ashamedbit Date: Tue Feb 27 00:33:00 2024 -0500 Fix leak in snmpusm.c (cherry picked from commit c691ab06862bc2d83bba851c65321f60aad5f0b3) commit 08d557ff094d01b511ec67efa2d5fc3d51a5a566 Author: ashamedbit Date: Mon Feb 26 02:34:58 2024 -0500 Fix leaks in snmpv3.c (cherry picked from commit 70c4d95873b161768d08c0fd4d42f3a47ef1d002) commit 5b89350912ebd52e978d65c7a697d2183f509d51 Author: Bart Van Assche Date: Sun Feb 4 16:58:24 2024 -0800 EtherLike-MIB: Optimize the Linux implementation Query netlink statistics once instead of one time per network interface. This should fix https://github.com/net-snmp/net-snmp/issues/780. (cherry picked from commit ac6cd58ff9e0bf2ec5f336e50f79338455e21b91) commit 4609cd24c5d65ed41f14bee1d95d5381c02bbfda Author: Bart Van Assche Date: Sun Aug 1 20:34:02 2021 -0700 configure: Detect libnl-route-3 commit f1b9e4b0849e0c0a81232459a24137adbc946054 Author: Bart Van Assche Date: Sun Feb 4 16:22:13 2024 -0800 ci: Only replace /etc/hosts on Darwin commit 26f52c35c1c29acbc0a60a0b6ba5783b6f719985 Author: Bart Van Assche Date: Sat Feb 3 14:26:29 2024 -0800 ci, Windows: Bump the OpenSSL version number commit 7fc7edf676c527a0cfb661f9000a3d22738cf8e6 Author: Philippe Troin Date: Sat Feb 3 10:30:30 2024 -0800 Add Linux 6.7 compatibility parsing /proc/net/snmp Linux 6.7 adds a new OutTransmits field to Ip in /proc/net/snmp. This breaks the hard-coded assumptions about the Ip line length. Add compatibility to parse Linux 6.7 Ip header while keep support for previous versions. commit 934a7649eddfed2905f2fd43d2acd0a57365bde2 Author: Bart Van Assche Date: Tue Jan 30 09:54:32 2024 -0800 EtherLike-MIB: Optimize interface_dot3stats_get_errorcounters() This patch may fix an infinite loop. See also https://github.com/net-snmp/net-snmp/issues/780. commit f6500b2ed87236b7a2a4c10a891aae2ae4317b0b Author: Bart Van Assche Date: Mon Jan 29 15:33:58 2024 -0800 EtherLike-MIB: Simplify dot3stats_interface_name_list_free() Change the return type from 'int' into 'void'. commit ad80e335b8afab15e5aa2bb1fbf8af8c539138fd Author: Bart Van Assche Date: Mon Jan 29 14:32:41 2024 -0800 CHANGES: Add -Wredundant-decls to the developer options commit da5728052f7f1a4ca6764fdf1f740f222175d60a Author: Bart Van Assche Date: Mon Jan 29 14:57:24 2024 -0800 CHANGES: Remove more redundant redeclarations Prepare for enabling -Wredundant-decls. commit 4963dd110f7cf41d28a66624b7ac84c8c90296ed Author: Jaap Keuter Date: Sun Jan 28 22:03:02 2024 +0100 CHANGES: Remove redundant declarations These changes aim to remove redundant declarations from the Net-SNMP source code. They are most easily exposed with adding -Wredundant-decls to CPPFLAGS for the gcc compiler. Redundant declarations in other used modules and mib2c generated code are left in place. The changes consist of: - Removal of duplicate declarations in header files, other or the same. - Removal of duplicate declarations in source files, where the prototype already exists in the appropriate header file. - Fixing declaration of register log handler functions. - Use of forward declared struct, rather than extern function or char. [ bvanassche: added "CHANGES: " prefix to subject and ran autoreconf ] commit 7f90a81c778c5a50f72b0f4d7e9551cd4a04fedf Author: Bart Van Assche Date: Wed Jan 10 11:01:10 2024 -0800 libsnmp: Fix authorization protocol parsing Fixes: 09ac3f2f68b2 ("more sha2 support changes") Fixes: https://github.com/net-snmp/net-snmp/issues/771 commit abb479727a0911f00080680a62521396275a1a06 Author: Bart Van Assche Date: Wed Jan 10 07:29:49 2024 -0800 Revert "SIGHUP for handling agent port change" Reverts commit da96150d1eb85e6a4a995dab04eaaabd15c7d8c9 because of the issues mentioned in the description of this commit. See also https://github.com/net-snmp/net-snmp/pull/769. commit da96150d1eb85e6a4a995dab04eaaabd15c7d8c9 Author: Vivekaditya98 <49593894+Vivekaditya98@users.noreply.github.com> Date: Tue Jan 9 08:03:29 2024 +0000 SIGHUP for handling agent port change Fix - When the reconfig flag is set, we "shudown master agent" which closes the socket listening on 161 and "init_master_agent" would establish the socket on new port without changing the PID of "snmpd". Use-case where its failing - Though this change works for most of the cases, its failing in a peculiar case where when we send SIGHUP while parallely the snmpwalk is in progress. When we send SIGHUP in this usecase, the socket is closed by "shutdown_master_agent" but a new socket is never re-established by "init_master_agent" no matter how many sighups we sent, the snmp-server is down permanently. Going to the root of the problem, I see that the bind is successful as kernel returns 0 but netstat(-nlpu) never reports that socket. commit dfde22f5d955eb4b96ccce5c70dc838fe3406322 Author: Niels Baggesen Date: Tue Jan 9 20:22:53 2024 +0100 Fix complaints about using unsafe functions (OpenBSD, NetBSD) sprintf => snprintf, strcpy => strlcpy, strcat => strlcat commit 18134035cc099774d6a811da64265b18f2159575 Author: Niels Baggesen Date: Tue Jan 9 20:13:05 2024 +0100 Check for netgroup.h, required for OpenBSD. commit dce25f15577a96301481ad6df8855c7d871571a8 Author: Niels Baggesen Date: Tue Jan 9 20:09:53 2024 +0100 Protect variable declaration same as the use of it. commit 2258b6b49cac729063045f585cbebdd5214fc117 Author: Bart Van Assche Date: Fri Jan 5 12:51:28 2024 -0800 ci: Upgrade Github checkout action commit 0077eaadfe6cc4d3f93ce03c93db452b1a32988c Author: Bart Van Assche Date: Fri Jan 5 09:12:21 2024 -0800 ci: Add an Android build target commit c50900fc1076d691453cca648169c176b14761a7 Author: Bart Van Assche Date: Fri Jan 5 10:55:33 2024 -0800 ci: Fix shellcheck warnings commit afae87ba742831c9348177b83cf7728c6871afdc Author: Bart Van Assche Date: Fri Jan 5 10:44:58 2024 -0800 snmplib/openssl: Fix compiler warnings about function pointer casts commit 99d8377ff34963540659a4f43c7522f3607d8d42 Author: Bart Van Assche Date: Fri Jan 5 10:43:52 2024 -0800 apps/snmpusm: Fix a compiler warning Do not define usmDHParameters nor usmDHParameters_len if these symbols won't be used. commit 8df53c47975f262e0bfc378c70f058fc73d9d926 Author: Bart Van Assche Date: Thu Jan 4 13:19:33 2024 -0800 ci: Disable the Python modules if MODE=wolfssl commit 7edcdd265cb99a4e77200afe4ce2edff4905eef7 Author: Bart Van Assche Date: Thu Jan 4 11:38:16 2024 -0800 ci/net-snmp-configure: Restrict the TLSTM-MIB to OpenSSL commit cadcb0ca78cf0ea9db3a3c6d69ed0ad11b9d4751 Author: Bart Van Assche Date: Sun Jul 31 16:33:57 2022 -0700 libsnmp: Fix the wolfSSL build Use the ASN_* definitions from the wolfSSL headers when building with wolfSSL. Remove #ifdefs that refer to OpenSSL header file guard macros. Add missing include directives. Add support for EVP_MD_CTX_init() returning void. Enable logging of wolfSSL error messages. Disable OpenSSL code that has no wolfSSL equivalent. commit 28c00ab9454b499f6e66863c7db7efb6662af3b9 Author: Bart Van Assche Date: Thu Jan 4 10:54:56 2024 -0800 ci: Improve the test for DTLS support commit 7c2ac00e03bfaae6047712bb840d8bdb7eb9ffb2 Author: Bart Van Assche Date: Thu Jan 4 10:44:29 2024 -0800 Windows: Suppress a compiler warning related to ERR_get_error_all() This patch fixes the following warning when building with MSVC: ..\..\snmplib\transports\snmpTLSBaseDomain.c(70): warning C4996: 'ERR_get_error_line_data': Since OpenSSL 3.0 commit 39e7514ad7b3ccd4f2dcd1e1302ed72eeaf962e7 Author: Bart Van Assche Date: Thu Jan 4 10:38:04 2024 -0800 libsnmp: Improve the ERR_get_error_all() backport commit 392a06265a7bf6ee45f5a65faf0feebfea502828 Author: Bart Van Assche Date: Thu Jan 4 09:50:49 2024 -0800 configure: Check explicitly for the presence of openssl/{err,ssl}.h Additionally, remove the check for the header file. commit 3592dbf1dea3866b651c7e5097bdc81abc0bd0e7 Author: Bart Van Assche Date: Thu Jan 4 06:59:59 2024 -0800 ci/net-snmp-configure: Remove support for branches that are no longer supported commit cf5c36c4f57fe299eb378ffe32edbe67b5c43b7d Author: Bart Van Assche Date: Fri Jul 29 19:43:55 2022 -0700 NEWS: configure: Add --with-wolfssl Add support for building and linking with the wolfSSL library instead of OpenSSL. Other changes that have been included in this patch are: - Only enable AES support if EVP_aes_128_cfb() is available. - Add support for detecting SSL functions if these have been defined as macros. commit 2f0cb7a8895d206d73cbf2b96d20e4ca98e151a5 Author: Bart Van Assche Date: Sun Jul 31 07:18:04 2022 -0700 CHANGES: configure: Change the default OpenSSL path into /usr Change the default OpenSSL path from /usr/local/ssl into /usr since that is the default location for all current Linux distributions. commit bac9c094578840ad3d6bd22369697ece2875bdd7 Author: Bart Van Assche Date: Fri Jul 29 19:43:52 2022 -0700 configure: Simplify the OpenSSL detection code Use a single variable to represent that EVP_md5 has been found in a library instead of two. commit f7fbfdbc8078d64d772e9e09684a75cab197e86e Author: Bart Van Assche Date: Mon Aug 1 21:14:58 2022 -0700 configure: Do not echo the security module list commit 57cc8100a534323b17679d3992090ca3beed62b3 Author: Bart Van Assche Date: Fri Dec 29 17:25:14 2023 -0800 win32/dist/build-binary.pl: Fix OpenSSL library paths commit 5fd4e1caffaca55d58fa1104168c3ab3c8637abf Author: Bart Van Assche Date: Fri Dec 29 15:59:47 2023 -0800 HOST-RESOURCES-MIB: Remove dead code This patch fixes the following Coverity warning: CID 379751 (#1 of 1): Logically dead code (DEADCODE)dead_error_begin: Execution cannot reach this statement: config_perror("Missing moun.... commit 1dfc114f6b5b01c7616becb4be623f8799064905 Author: Bart Van Assche Date: Fri Dec 29 15:57:35 2023 -0800 Python: Remove dead code This patch fixes the following Coverity warning: CID 379753 (#1 of 1): Logically dead code (DEADCODE)dead_error_line: Execution cannot reach the expression NULL inside this statement: (vars = (response ? respons.... commit 99332c80b68248cb60023d12297135dc9c6c8abf Author: Bart Van Assche Date: Wed Dec 27 14:58:15 2023 -0800 Windows: Update the OpenSSL library paths Apparently the paths in which OpenSSL binaries are installed have changed. Hence, also change these paths in Net-SNMP. commit 83fa8f661a050aff37fdcbf09f918360929ee8de Author: Bart Van Assche Date: Wed Dec 27 16:45:09 2023 -0800 ci: Remove MinGW32 Downloading the MinGW32 installer fails. Additionally, the most recent upload to https://sourceforge.net/projects/mingw/files/ happened in 2017, six years ago. Hence remove MinGW32 from .appveyor.yml. commit 9f6e94928458d93e12d0c69fdde0ec2606e75c72 Author: Bart Van Assche Date: Wed Dec 27 16:04:18 2023 -0800 ci/perl.bat: Bump the Perl version commit ecf028eb6d2b706607dd26a39beb27c17f475fc8 Author: Bart Van Assche Date: Sun Dec 17 16:11:06 2023 -0800 UCD-SNMP-MIB: Fix a memory leak in an error path of _expand_disk_array() commit 70601631a4eaa504b34e1d071138e626fe068e36 Author: Christophe Leroy Date: Sat Dec 23 19:36:27 2023 +0100 Add 'ubifs' to other_fs ubifs used to be automatically taken into account in UCD-SNMP-MIB::dskTable but commit e3fc76e0ae ("CHANGES: snmpd: Make UCD-SNMP::dskTable dynamic if includeAllDisks is set.") added a verification that drops all filesystems not present in other_fs[] table. So add 'ubifs' in other_fs[] to fix it. commit 47a550defd0209d57d34e50290942fb6b1c286f5 Author: Bart Van Assche Date: Thu Dec 21 18:52:35 2023 -0800 DISMAN-EVENT-MIB: Unbreak the MSVC build Fixes: e5d60f0c46c5 ("DISMAN-EVENT-MIB: Initialize 'name' and 'name_buf'") commit 9226f4f2aded71c64f4d9e3416b783457ee95695 Author: Bart Van Assche Date: Thu Dec 21 17:23:39 2023 -0800 ci, Windows: Bump the OpenSSL version commit b4598662a39ff6974119c900ea56a4d020eac366 Author: Bart Van Assche Date: Wed Dec 20 13:08:06 2023 -0800 Android: Fix the build Include for the fd_set type. In the configure script, check whether 'unsigned long' is the underlying type of fd_set. Use u_long instead of ulong. commit 7f5fb8083d31834fec8bc89603f3d02115516fed Author: Niels Baggesen Date: Wed Dec 13 21:04:39 2023 +0100 Update the parser to warn about duplicate OBJECTs, TEXTUAL-CONVENTIONs and values in enums Duplicate enum label 'byte' at line 550 in ...lwapp/CISCO-LWAPP-SI-MIB.my. First at line 549 Duplicate TEXTUAL-CONVENTION 'CucsStorageControllerId' at line 48175 in .../CISCO-UNIFIED-COMPUTING-TC-MIB.my. First at line 48117 commit 43f0e3fdc8de03a5e7a0f864694744558ca5da03 Author: Niels Baggesen Date: Wed Dec 13 21:00:48 2023 +0100 snmptest: plug a possible memory leak. commit bfc27f6182f41173834c97baacead26f116d6b79 Author: Niels Baggesen Date: Wed Dec 13 20:59:05 2023 +0100 Update SNMP-TLS-TM-MIB.txt to RFC 9456 version. commit 8570eb2b40dd342fb4e2e2f0a34fe0eef400079a Author: Niels Baggesen Date: Fri Nov 24 13:22:19 2023 +0100 Allow TLS protocols higher than TLS10. Modern TLS versions will not connect using these old versions. commit 694b3869e6a2514a7b1073e4b5f7a15ce0c8e668 Author: Niels Baggesen Date: Fri Nov 24 13:15:52 2023 +0100 Fix matching of certs by using SHA1 fingerprints. PR#278 changed default for certs to SHA512, but now matching certs fails. Change the fingerprint reuqests to use SHA1 explicit. commit e5d60f0c46c58b99130e8ae8098dc5b192091ef6 Author: Bart Van Assche Date: Thu Nov 23 14:12:28 2023 -0800 DISMAN-EVENT-MIB: Initialize 'name' and 'name_buf' This patch suppresses the following two Coverity reports: CID 407579: Uninitialized variables (UNINIT) Using uninitialized value "*name_buf" when calling "memcpy". [Note: The source code implementation of the function has been overridden by a builtin model.] CID 407578: Uninitialized variables (UNINIT) Using uninitialized value "name_buf_len". commit eacb48436f24daa2e33d91c36c17ff71e442557e Author: Bart Van Assche Date: Sat Nov 11 09:54:03 2023 -0800 configure: Run autoreconf Fixes: 7779e40f6e1d ("snmpd: Unbreak the build") commit 1755a85c648e497099d3278986dee37065d35e04 Author: Bart Van Assche Date: Sat Nov 11 09:51:30 2023 -0800 libsnmp: Optimize read_config_save_objid() Make this function slightly faster by eliminating a strlen() call. Declare the 'oid' input parameter const. Remove a superfluous cast. commit ea6c54f508ca8897961f4faa8d7b04793151db78 Author: Bart Van Assche Date: Sat Nov 4 16:32:22 2023 -0700 IF-MIB: Fix the test for skipping PCI bus scanning Reported-by: https://github.com/abutcher-gh Fixes: 8c301c1e0600 ("IF-MIB: Do not scan for PCI devices if no PCI bus is available") commit a59d03aa1ecec19eaf9515896f6095bfbe77fb7c Author: Moshe Kaplan Date: Mon Oct 16 22:04:22 2023 -0400 snmpusm.c: Improve error handling Check that line is not NULL before passing it to `atoi`. Fixes #734 commit ba844b797ce90cd00a8e28844f1090c5c37ac103 Author: Moshe Kaplan Date: Tue Oct 17 13:17:04 2023 -0400 snmp_transport.c: Remove redundant if statement Found with cppcheck commit 98d2c46a1087c6cec627b243f189b0f305c9cec2 Author: Moshe Kaplan Date: Tue Oct 17 11:55:18 2023 -0400 agent_global_vars.h: Remove redundant forward declaration Detected with SonarCloud commit 24e233bbb2fd9b7debf8cfcf775ccd9f63f3b845 Author: Moshe Kaplan Date: Sat Oct 14 22:55:13 2023 -0400 lookupCtlTable.c: Check mallocs commit a51a0f1685e7d3159736fa44aa470c821db076b5 Author: Moshe Kaplan Date: Thu Oct 12 14:44:41 2023 -0400 snmpusm.c: Fix segfault when parsing config file createUser line snmpusm.c: Fix segfault when parsing config file createUser line If no authentication profile is specified, use the default. Fixes #416 commit 73695f05d58f8c50c93e2eca62268087f743a261 Author: Moshe Kaplan Date: Thu Oct 12 10:17:17 2023 -0400 ucdDemoPublic.c: Fix memory leak (Coverity 85639) ucdDemoPublic.c: Fix memory leak (Coverity 85639) Avoid leaking engineID commit 11c075958db84e9382df0d24eabe63a6f4211fa8 Author: Tomas Klacko Date: Tue Oct 3 13:02:59 2023 -0700 libsnmp: Add support for IPV6_RECVPKTINFO Fixes: https://github.com/net-snmp/net-snmp/pull/718 [ bvanassche: combined three patches into one, inserted a blank line and removed superfluous parentheses ] commit 237370c9193700f0a60736c175a3c66d072058f9 Author: Moshe Kaplan Date: Mon Oct 9 00:05:38 2023 -0400 T011snmp_old_api_registration_cagentlib.c: Avoid leaking session object Avoid leaking session object, so another test passes with leak sanitizer enabled commit f263a62936f488c088bb5240fe634c9b671c4b41 Author: Moshe Kaplan Date: Mon Oct 9 00:45:03 2023 -0400 T102pdu_build_clib.c: Fix memory leaks T102pdu_build_clib.c: Fix memory leaks commit abc227f9867fba913822ffb3d399a8f7b9bfdf81 Author: Moshe Kaplan Date: Mon Sep 18 21:25:50 2023 -0400 snmpv3.c: Avoid leaking memory if -E or -e is repeated snmpv3.c: Avoid leaking memory if -E or -e is repeated Fixes #703 commit 8d7f09fff3057b8073f7fcda26565c0eb8b0c607 Author: Moshe Kaplan Date: Mon Sep 18 13:44:42 2023 -0400 snmpv3.c: Avoid leaking memory if -X or -A is repeated snmpv3.c: Avoid leaking memory if -X or -A is repeated commit 938ad6d934b99c2bcc49ddd72ac84894bebcb6a3 Author: Bart Van Assche Date: Mon Sep 18 12:14:09 2023 -0700 libsnmp: Fix a crash in netsnmp_parse_args() Prevent that the following command triggers a segmentation fault: apps/snmpget -LF0 See also https://github.com/net-snmp/net-snmp/issues/695. commit 929736d251213c3af1fd0806e3f872876d4c0dec Author: Bart Van Assche Date: Mon Sep 18 12:25:36 2023 -0700 libsnmp: Fix recently introduced compiler warnings Fixes: 8e8d56b7b947 ("libsnmp: Fix a crash in netsnmp_parse_args()") commit 9fed14fb19548160ed08573f68bb9d503b338362 Author: Moshe Kaplan Date: Mon Sep 18 12:21:15 2023 -0400 snmpv3.c: Avoid leaking memory if command-line arg is repeated snmpv3.c: Avoid leaking memory if command-line args are repeated Specifically, -n, -u, -K, and -k commit b9ca6975456fc3a7674fca47b24f9ad4cd99be61 Author: Niels Baggesen Date: Wed Oct 25 07:49:15 2023 +0200 Fix a backporting glitch commit e9c4e72b32951e30c303fb081703e18ac8d477ec Author: Michael Veksler Date: Mon Jun 12 09:14:21 2023 +0300 libsnmp: Fix SNMPv3 multithreading support for snmp_sess_open() Fixes: https://github.com/net-snmp/net-snmp/pull/586 [ bvanassche: Reduced the number of arguments of usm_build_probe_pdu() to two ] commit b5b2483fdd83c578c8cb0d9a72899c3b8bd5d70a Author: Bart Van Assche Date: Sat Oct 7 14:56:15 2023 -0700 apps: Remove the code again that clears netsnmp_session objects Removing this code is safe now that _sess_copy() duplicates all memory that is freed by netsnmp_cleanup_session(). commit 668baac9f54727bca9e1983cd328a4d4d2430c90 Author: Bart Van Assche Date: Sun Oct 8 07:34:06 2023 -0700 libsnmp: Make _sess_copy() duplicate all security related information commit 56795de0a9cd1987007ac9b90868c7972c77f57f Author: Bart Van Assche Date: Sun Oct 8 06:50:25 2023 -0700 MinGW: Unbreak the Perl module build commit 8aac5c1be01d4f91ce3c0da3afb5cebfbdc73538 Author: Bart Van Assche Date: Sat Oct 7 19:43:45 2023 -0700 configure: Enable -Wcast-function-type commit 2d396db5aac06cb870922b6ccf26d5d5e7e0b614 Author: Bart Van Assche Date: Sat Oct 7 15:00:57 2023 -0700 libsnmp, MIBs, snmpd: Remove function casts This patch resolves a number of undefined behavior complaints reported by the clang UndefinedBehaviorSanitizer. commit af1b7f77975bbb2fcbdb3f005f8cb010d1d33cd3 Author: Adam Gajda Date: Mon Oct 2 16:40:31 2023 +0200 Fix configuration of NETSNMP_FD_MASK_TYPE commit 21b612e1cb02350448568240dfce7d213820e081 Author: Bart Van Assche Date: Thu Sep 28 10:47:45 2023 -0700 UCD-SNMP proxy: Fix an uninitialized variable dereference Fixes: f975916a847d ("apps: Use netsnmp_cleanup_session()") commit 1c6105cb46e13d2218e701b13ca1bb1c0c73d102 Author: Moshe Kaplan Date: Tue Sep 26 19:49:00 2023 -0400 netsnmp_config_api.3.def: Spelling and grammar netsnmp_config_api.3.def: Spelling and grammar commit 07cccb8d940daf5b41f5783b9c460248ac5c21e7 Author: Moshe Kaplan Date: Tue Sep 26 17:14:05 2023 -0400 More spelling and grammar fixes commit 8e3d6ba0c7449b579abf0f3867a72990f07c1fda Author: Moshe Kaplan Date: Tue Sep 26 13:48:35 2023 -0400 Fix many typos commit 69ebaf36c9b5ab1938a4137c4c5ae85af706f85f Author: Bart Van Assche Date: Tue Sep 26 21:27:06 2023 -0700 DISMAN-MIB: Use u_char for bitmasks Additionally, change schedWeekDay into a one element array to suppress a Coverity complaint. commit b0a32da4b2ba7295ded1d7a6514e2d0a250787c1 Author: Moshe Kaplan Date: Tue Sep 26 13:23:07 2023 -0400 snmpusm.c: fix text phrasing "active" to "activate" commit 81bf153c9c84c79e87485772fd89891c4f445d4c Author: Bart Van Assche Date: Sun Sep 24 15:16:11 2023 -0700 apps: Use netsnmp_cleanup_session() The changes compared to an earlier attempt (commit 21b16eba6024 ("apps: Use netsnmp_cleanup_session()")) are as follows: - netsnmp_cleanup_session() is now called for all session objects allocated on the stack instead of only for a subset of these objects. - A copy of strings is assigned to netsnmp_session members. - If an snmp_close() call is followed by a netsnmp_cleanup_session() call, the netsnmp_session object is cleared to prevent a double free. This patch should not reintroduce https://github.com/net-snmp/net-snmp/issues/707. commit 84aba8f8f878b977e98c46af0584723885660a3e Author: Bart Van Assche Date: Sun Sep 17 16:06:57 2023 -0700 libsnmp: Fix a memory leak in the MIB parser Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62448 commit 62401c9c77d99ff2da2871e5a49e68b3cd21b87e Author: Emil Bartczak Date: Tue Dec 15 21:37:25 2020 +0100 Fix the crash of snmpd when snmptrapd terminates the TCP connection. See also: https://github.com/net-snmp/net-snmp/issues/187 Re-opening of TCP connection with snmptrapd is still not supported. commit b1a4288289ba2bc38b074a0c922178e5bf488411 Author: Bart Van Assche Date: Sun Dec 4 15:53:54 2022 -0800 testing/fulltests/unit-tests/T105trap_parse_clib: Fix a memory leak commit 65a9d0f29be11f3e6ca75eb228ab116d71f92aca Author: Bart Van Assche Date: Thu Sep 28 12:33:52 2023 -0700 ci, Windows: Bump the OpenSSL version number commit 803569fbfa22108eb4a1ab8314e39e642d97e28c Author: Bart Van Assche Date: Mon Sep 25 13:47:01 2023 -0700 libsnmp: Micro-optimize netsnmp_cleanup_session() Clear the entire netsnmp_session object at once instead of clearing this struct pointer by pointer. commit edce16ae77498a43b1937bb895ca79c761a6f616 Author: Bart Van Assche Date: Mon Sep 25 13:43:36 2023 -0700 libsnmp: Reduce the indentation level in snmp_free_session() commit 7779e40f6e1d31fa184a1e7423302408706f7bb3 Author: Bart Van Assche Date: Sun Sep 10 06:54:42 2023 -0700 snmpd: Unbreak the build malloc_trim() is defined by glibc but is not available on BSD systems. Fixes: 585d35cc51e3 ("agent: release memory back to the system after freeing cache data") Conflicts: configure.d/config_os_functions commit b5566290c92d8f83fde14b3f4bbfb18b025fc0c8 Author: Nicolae Busuioc Date: Tue Sep 19 12:31:48 2023 +0200 Adding by default server cipher order commit a56518ab60b2b86a2084374d9c3439b9a7e832e1 Author: Bart Van Assche Date: Mon Sep 18 08:21:50 2023 -0700 libsnmp: Fix a crash in netsnmp_parse_args() Prevent that netsnmp_parse_args() crashes if one of the following argument lists is passed: -IS or -Is. Fixes: https://github.com/net-snmp/net-snmp/issues/692 commit 0e82772dc55a26200d0d6c09c53d884d082596b8 Author: Bart Van Assche Date: Wed Sep 13 06:57:01 2023 -0700 libsnmp: Fix a memory leak in the MIB parser This patch should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62295 . commit 33466199a979765e8396245ed14a3a748eb3cd8c Author: Bart Van Assche Date: Mon Sep 11 23:00:14 2023 +0000 libsnmp: Port the SSH domain transport to FreeBSD commit 27cd9e0d0c2683059ebcc3b9e233b02531b77c72 Author: Bart Van Assche Date: Mon Sep 11 16:06:07 2023 -0700 configure: Fix the IFNET_NEEDS_KERNEL_STRUCTURES test commit e5b2bfe282b28c6a572251040ec509ffcbb5ff45 Author: Bart Van Assche Date: Mon Sep 11 16:03:54 2023 -0700 MIB-II: Declare functions that are used in multiple source files commit c567f34b566d5e5d2eb039a0731f80829550ba60 Author: Bart Van Assche Date: Mon Sep 11 16:03:18 2023 -0700 FreeBSD: Add a missing include directive commit 33be698855b6671e29a84fad22cdd9ee18baf003 Author: Bart Van Assche Date: Mon Sep 11 16:02:09 2023 -0700 snmpd: Suppress a compiler warning Prevent that the compiler complains about casting a pointer to an integer of a different size. commit 050782fc7fa8dc12185f898b9fde58958dba3dbc Author: Bart Van Assche Date: Sun Sep 10 16:39:10 2023 -0700 libsnmp: Fix memory leaks in MIB parsing code See also https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=60833 . commit 7d1733f9535f89183a31120ef5b4123ee3faa4b3 Author: Bart Van Assche Date: Sun Sep 10 16:33:49 2023 -0700 libsnmp: Simplify the code for parsing a MIB parse() only has one caller and that caller passes NULL as second argument. Hence, remove the second argument of parse() and remove the code that depends on the second argument being not NULL. Reduce the scope of the 'nnp' variable. commit 9e608f44ed645baa8f0721a08951dccfac6ac3a0 Author: Moshe Kaplan Date: Sat Sep 9 23:44:33 2023 -0400 snmpget.c: Avoid leak if parsing OID fails snmpget.c: Avoid leak if parsing OID fails. This leak would not normally cause any problems, but might make investigating other leaks more difficult commit 47ffd72dc8c5b0e8ba0aafa51c467f3bb62607bc Author: Moshe Kaplan Date: Sun Sep 10 01:08:26 2023 -0400 encode_keychange.1.def: Fix typo commit 4e7ce92fbdf1886cb09c9eea3edcb2f43cc91bb3 Author: Ilyes Ben Hamouda Date: Wed Jul 5 16:26:30 2023 +0200 agent: release memory back to the system after freeing cache data The heap memory increases, when retrieving IP-FORWARD MIB objects, in proportion to the number of entries in the routing table. It is not given back to the system when freed due to a glibc limitation (See the link below). The IP-FORWARD MIB implementation as well as other MIB implementations use data caching. Cache management depends on cache flags. For instance, based on NETSNMP_CACHE_AUTO_RELOAD flag, some caches are reloaded automatically, while others are reloaded on request. Each cache has also a timeout. The timeout is checked on cache access. If expired, the cache is reloaded. A garbage collector also checks the timeout expiry every minute to release cache resources. Call malloc_trim() to return freed memory to the system after the garbage collector has freed cache data only if the cache will not be automatically reloaded. In the best-case scenario, malloc_trim will only be called once after cache accesses have been completed. Worst-case, the GC detects the timeout expiry just before a request. Hence, there will be a wasteful trim, as the cache will be immediately loaded later. There is a way to avoid this behavior by introducing NETSNMP_CACHE_RESET_TIMER_ON_USE flag which will reset cache timeout on each cache access but this may lead to a stale cache if the polling happens too fast. Avoid introducing this flag since it depends on polling period. Note: malloc_trim has a linear complexity, it seems to be safe but it may softly degrade performance when frequently called. Link: https://sourceware.org/bugzilla/show_bug.cgi?id=15321 Signed-off-by: Ilyes Ben Hamouda commit 4f6e1a352a690c0a46012b39234c1479cbe81bfd Author: Ilyes Ben Hamouda Date: Mon Jul 3 17:09:13 2023 +0200 agent: keep cache flags unchanged Cache flags are managed by the MIB implementation. Do not clear/set NETSNMP_CACHE_AUTO_RELOAD flag to ensure scheduling auto-reload only once. This is already managed by netsnmp_cache_timer_start() via cache timer_id check. Instead, check the timer_id validity in the cache handler before calling netsnmp_cache_timer_start() to avoid warnings if auto-reload is already scheduled. Fixes: e6e11ebcc493 ("Only schedule automatic loading once for any given cache.") Signed-off-by: Ilyes Ben Hamouda commit e6a092041424b5f5fd5345602ce6f489a0409ace Author: Ilyes Ben Hamouda Date: Mon Jul 3 16:54:32 2023 +0200 agent: clear the timer_id on cache timer stop The timer_id is set when the cache timer is started. However, it is not cleared when the cache timer is stopped, preventing it from being restarted later. Clear the cache timer_id after unregistering the alarm in netsnmp_cache_timer_stop(). Fixes #588 Fixes: 543d4b22666c ("- always consider cache w/timeout of -1 as expired (load cache every request)") Signed-off-by: Ilyes Ben Hamouda commit adf8b254d08b330f89988a791e3b8f007f34c570 Author: Moshe Kaplan Date: Wed Aug 30 22:54:49 2023 -0400 pingCtlTable.c: Validate create_pingCtlTable_data() allocations Ensure all memory allocations within create_pingCtlTable_data() were successful commit b050271f6b0a78558627d7f17737248072ec85f8 Author: Bart Van Assche Date: Sat Apr 22 17:54:35 2023 -0700 libsnmp: Do not pass NULL to memcmp() commit f701087096dc337a9ff36a747f3a53e1aacef2f6 Author: Bart Van Assche Date: Thu Sep 21 07:43:31 2023 -0700 Revert "apps: Use netsnmp_cleanup_session()" This reverts commit 21b16eba60245bc84149d338a9700e5915bda292. Fixes: https://github.com/net-snmp/net-snmp/issues/707 commit 85c6aba35d96802a580ec88fe57b2813cc766e84 Author: Bart Van Assche Date: Thu Sep 21 07:43:26 2023 -0700 Revert "apps/snmpusm: fix a memory leak" Prepare for reverting patch "apps: Use netsnmp_cleanup_session()". This reverts commit d6a1af15777981a20778260c25245f36bf7c25a6. commit 2230933c7fab36875af219f2bddc31544efabda4 Author: Niels Baggesen Date: Mon Sep 11 19:26:43 2023 +0200 Prepare for FreeBSD 15 commit 57b0a196af58222b1877421a234a7638206a84c5 Author: Niels Baggesen Date: Mon Sep 11 19:24:33 2023 +0200 Restore the NEWS/CHANGES for 5.9.2 as released with 5.9.3 skipped due to a last minute library versioning found bug -- use 5.9.3 instead commit db0f7f83b820b6be91b25417d1e21fa32895f937 Author: Bart Van Assche Date: Sat Sep 9 15:00:43 2023 -0700 snmpd: Fix nsLogMaxLevel handling From the nsLogMaxLevel description in mibs/NET-SNMP-AGENT-MIB.txt: "The maximum priority level for which this logging entry should be applied." Make the implementation match the description. See also https://github.com/net-snmp/net-snmp/issues/681 . commit 8c18c7442b68cae57812b4e340bee257d664c841 Author: Bart Van Assche Date: Fri Sep 1 09:52:23 2023 -0700 configure: Fix the version number Fixes: 7d38b8299e26 ("version update for 5.9.4") commit 4034ce072d0398a204c3552525424bc4a2bdebcf Author: Niels Baggesen Date: Thu Aug 31 19:06:58 2023 +0200 Fix bad protypes in sctpScalars_freebsd.c commit f12d5668122c7ea59fce9f5818bd8787f9b9af39 Author: Niels Baggesen Date: Thu Aug 31 19:03:44 2023 +0200 Another stab at fixing -Op (issue #554) commit 889daaffcea38eeb0dc8c6d2a944a1a61fd2838e Author: Niels Baggesen Date: Thu Aug 31 18:55:35 2023 +0200 Fix T032snmpv3engineidchange_simple for non Linux-systems. FreeBSD (and other BSDs) need a value after "sed -i". BSDs getopt does not allow mixing options and other arguments. commit e59866aeba64463e71933f92d066f38145d4f2b6 Author: Niels Baggesen Date: Thu Aug 31 18:54:42 2023 +0200 FreeBSD 14 needs another header to compile ipv6.c commit 619aeb7ea461d69578121e50b8e481bbca35307a Author: Bart Van Assche Date: Wed Aug 16 17:07:39 2023 -0700 configure: Remove the rpmdbOpen() check Commit 8e08fc520246 ("Tweak RPM handling to work with library version 4.9") removed all rpmdbOpen() calls. Hence remove the rpmdbOpen() configure test. Conflicts: configure commit 8c4db403d24c979c03fd40133e150c7c4af7738a Author: Bart Van Assche Date: Wed Aug 16 17:05:15 2023 -0700 HOST-RESOURCES-MIB: Declare the pkg_directory[] arrays static commit d8c5227fb75c9bf5ec159a1f226daa8ed64b7f52 Author: Josef Řídký Date: Wed Aug 9 16:51:28 2023 +0200 Add support for RPM SQLite DB background. From RPM 4.16 the SQLite support is available for RPM DB. After https://fedoraproject.org/wiki/Changes/Sqlite_Rpmdb, rpm changed it's background DB from Berkeley to SQLite in Fedora. Net-SNMP is using hard coded paths to determine where RPM DB files are. This update is adding check for rpmdb.sqlite file in order to be able invalidate internal cache after system package change. Closes #596 Conflicts: agent/mibgroup/host/data_access/swinst_rpm.c commit fdf72da85b11f5cc7de5e237dd4ac79d8d0685dc Author: Josef Řídký Date: Wed Aug 30 20:33:42 2023 +0200 Fix regression of memory leak when using RPMDB macros. This change is fixing memory leak when using RPMDB macros. The fix was introduced in PR #49 but was overwritten over time. Fix is needed in agent/mibgroup/host/hr_swinst.c only as the regression in the agent/mibgroup/host/data_access/swinst_rpm.c was fixed few weeks ago. commit 44fc3ca6695b079aac12953d9a3112dfd46d241a Author: Moshe Kaplan Date: Wed Aug 30 16:16:46 2023 -0400 master_admin.c: Validate that init_agent_snmp_session() was successful master_admin.c: Validate that init_agent_snmp_session() was successful commit 010c79470d9f7cb569bff34d35235a4b721a3e59 Author: Moshe Kaplan Date: Wed Aug 30 16:41:06 2023 -0400 snmp_agent.c: Ensure init_agent_snmp_session() was successful commit d8fea848f2b076e4d3cb6f5e071a1c83a896bb5b Author: Moshe Kaplan Date: Wed Aug 30 21:25:49 2023 -0400 mib2c-update.1.def: Typos commit e74da2c26ae7f726b460604460b82f683d2e16e9 Author: Moshe Kaplan Date: Wed Aug 30 21:22:33 2023 -0400 agentxtrap.1.def: Typos and grammar commit d3e146daa7cd8d1de45f192686fcda481f3466e7 Author: Moshe Kaplan Date: Wed Aug 30 21:20:25 2023 -0400 snmpd.conf.5.def: Fix misspellings and grammar typos Conflicts: man/snmpd.conf.5.def commit cce21c09044d6166a8c96f197c2b039424e32ad2 Author: Moshe Kaplan Date: Wed Aug 30 17:43:57 2023 -0400 tools.c: Ensure memory allocations were successful Conflicts: snmplib/tools.c commit a29971a426c8c3b42f7f48217f100379d5855bed Author: Moshe Kaplan Date: Wed Aug 30 17:30:34 2023 -0400 snmp_transport.c: Validate memory allocations Ensure malloc() and strdup() were successful commit 7d509eeb4f13130f70b056b0e7a5fdd31e0cc284 Author: Moshe Kaplan Date: Wed Aug 30 17:24:20 2023 -0400 snmp_service.c: Validate that malloc() was successful commit f62068c24cddd15eed8c382fd01723decf30b0b3 Author: Moshe Kaplan Date: Wed Aug 30 17:09:03 2023 -0400 snmp_enum.c: Validate that strdup() was successful commit c074fcc2f694a1e69eae72fa04c09a2eda4d3416 Author: Moshe Kaplan Date: Wed Aug 30 17:02:54 2023 -0400 read_config.c: Validate that strdup() was successful commit df73ab4c9288e9e55985c9ad833337488ac421b9 Author: Moshe Kaplan Date: Wed Aug 30 16:52:48 2023 -0400 parse.c: Validate that strdup() was successful commit bc08d8f81af4a5316642dbfc36fd325052372ed7 Author: Moshe Kaplan Date: Wed Aug 30 16:46:20 2023 -0400 container_binary_array.c: Validate that netsnmp_binary_array_initialize() was successful commit 668c63277c9a63cc56aaeaff71bef5fe0e153e03 Author: Moshe Kaplan Date: Wed Aug 30 21:27:10 2023 -0400 mib2c.1.def: Hyphens, missing word commit b861ae4f2af5f97a6ebdedca70fd778d76f6c28f Author: Moshe Kaplan Date: Wed Aug 30 21:28:36 2023 -0400 mib2c.conf.5.in: Grammar commit 6edfda9d063b7d5680f7e8bb31d84c0d71f2c0ca Author: Moshe Kaplan Date: Wed Aug 30 21:30:06 2023 -0400 net-snmp-create-v3-user.1.def: Grammary commit 1c0450789808d08ada9af37d690053fa3fd96941 Author: Moshe Kaplan Date: Wed Aug 30 21:32:01 2023 -0400 netsnmp_agent_api.3.def: Spelling and grammar commit 3e2fefdd59ecb7b39105470ec82a338577bd8532 Author: Moshe Kaplan Date: Wed Aug 30 21:34:23 2023 -0400 netsnmp_mib_api.3.def: Spelling and grammar commit 64c30c268997b28c64e717d673e74ac336c8d08d Author: Moshe Kaplan Date: Wed Aug 30 15:41:41 2023 -0400 agent_registry.c: Avoid memory leak if strdup fails commit 76e05bb509e03cf61a4c57d82ec16d171835a7e3 Author: Moshe Kaplan Date: Wed Aug 30 16:10:46 2023 -0400 old_api.c: Check result of netsnmp_duplicate_variable() commit 105f0b6f9fa93ad678e0bf2fd6dc207fd2cf8e70 Author: Loïc Sang Date: Wed Aug 30 11:32:52 2023 +0200 snmplib: do not filter internal request sourceFilterType and sourceFilterAddress options in snmpd.conf. However, once activated, internal requests are also blocked. The filtering is based on IP in the string returned by the function "fmtaddr". Internal requests do not have a source IP, instead of an IP address, the function returns a string that starts with "callback" following a file descriptor numero. These internal requests are generated by alarms to define event triggers. If they are blocked, no traps will be sent. Therefore, do not filter internal requests by checking if the string returned by "fmtaddr" starts with "callback". Fixes: 9d28612ac03b ("add packet filtering by source ip") Signed-off-by: Loïc Sang commit 5205b5c485b1e1e7266e6281c03aef10a9239cfe Author: Moshe Kaplan Date: Sun Aug 27 23:40:59 2023 -0400 snmpTlstmCertToTSNTable.c: Fix memory leak (Coverity 85750) snmpTlstmCertToTSNTable.c: Fix memory leak (Coverity 85750) Avoid leaking memory referenced in watcher if netsnmp_create_handler_registration fails. commit d22037ee0289d8c86ccdf29c7c15df89842446e8 Author: Moshe Kaplan Date: Sun Aug 27 21:26:14 2023 -0400 read_config.c: Remove dead store Remove dead store detected by clang. read_config.c:1454:26: warning: Value stored to 'ctmp' during its initialization is never read [deadcode.DeadStores] struct config_files *ctmp = config_files; commit 02572006fce8650f2ddfb0feec24a12fd9ee6b69 Author: Moshe Kaplan Date: Sun Aug 27 21:54:16 2023 -0400 snmpNotifyTable_data.c: Fix memory leak (Coverity 266308) snmpNotifyTable_data.c: Fix memory leak (Coverity 266308) Avoid leaking memory referenced in nptr if netsnmp_memdup_nt fails. commit e2bc7ce863a49150843d7eb5371fbfde5a75df68 Author: Moshe Kaplan Date: Sun Aug 27 00:49:29 2023 -0400 lookupCtlTable.c: Fix memory leak (Coverity 85698-2) lookupCtlTable.c: Fix memory leak (Coverity 85698-2) Avoid leaking memory referenced in address if IPv4 DNS lookup fails. commit 935828c35b55ca563e8446c4463e910200410413 Author: Moshe Kaplan Date: Sun Aug 27 00:52:41 2023 -0400 lookupCtlTable.c: Fix memory leak (Coverity 85698-3) lookupCtlTable.c: Fix memory leak (Coverity 85698-3) Avoid leaking memory referenced in address if IPv6 DNS lookup fails. commit 2eb675f46d15f24bc9c244a038d98ec741008571 Author: Moshe Kaplan Date: Sun Aug 27 00:59:56 2023 -0400 lookupCtlTable.c: Fix memory leak (Coverity 85732) Avoid leaking memory referenced in StorageTmp if invalid data is passed in. commit 647c0c022f5917abbf2161a7fe8a727eb24413a7 Author: Moshe Kaplan Date: Sun Aug 27 10:16:10 2023 -0400 subagent.c: Fix memory leak (Coverity 357928) Avoid leaking memory referenced in smagic if snmp_clone_pdu fails. commit 18ceaa4610a71af1b4ece5b3a3f29f03b9e46d89 Author: Moshe Kaplan Date: Fri Aug 18 11:20:46 2023 -0400 mteTrigger.c: Fix copy-paste bug (Coverity 85524) mteTrigger.c: Fix copy-paste bug (Coverity 85524) Examine the proper variable when determining whether or not fire a fall event. commit 9fec75b95648d10435bc74c236850902f7bc8829 Author: Moshe Kaplan Date: Fri Aug 18 11:25:47 2023 -0400 mteTrigger.c: Fix copy-paste bug (Coverity 85536) mteTrigger.c: Fix copy-paste bug (Coverity 85524) Examine the proper variable when determining whether or not fire a fall event. commit 6257bf2ee570480c364d2af33bc014f56594c0f7 Author: Moshe Kaplan Date: Mon Aug 21 10:58:23 2023 -0400 expValue.c: Fix memory leak (Coverity 85691) expValue.c: Fix memory leak (Coverity 85691) Avoid leaking memory referenced in var if invalid parameters are passed in by only allocating memory if parameters are valid. commit bab2a8685d337a328f01d98e44ac204f3e8edb0b Author: Moshe Kaplan Date: Mon Aug 21 10:50:45 2023 -0400 nsDebug.c: Fix memory leak (Coverity 85684) nsDebug.c: Fix memory leak (Coverity 85684) Free memory allocation referenced in table_info that is not free()'d in the event of a failure commit 49edf5d413b6423b6080354e92a55d60264f1237 Author: Moshe Kaplan Date: Thu Aug 24 21:08:45 2023 -0400 snmpv3.c: Confirm snmpv3_generate_engineID() was successful before using data from it If snmpv3_generate_engineID() fails, it returns NULL, possibly without modifying the passed-in engineIDLen parameter. This change examines the return value from snmpv3_generate_engineID() before examining the possibly-uninitialized engineIDLen. commit cce53ea81b018959543ce997cc5f888285fea7c9 Author: Moshe Kaplan Date: Thu Aug 24 20:28:08 2023 -0400 snmpUnixDomain.c: Free memory if recvfrom fails Free memory if recvfrom() fails. commit 0a9e32e8a09b9ca9293d5e5306e3838371c6b058 Author: Moshe Kaplan Date: Thu Aug 24 16:53:44 2023 -0400 icmp.c: Avoid uninitialized variable error Set the variable msg_stats_table_info to a default value of NULL, to avoid potentially accessing the pointer when it's uninitialized commit afd94ebfbcaf94e752bc756cf7a525edd36fd1b8 Author: Bart Van Assche Date: Mon Aug 21 17:17:04 2023 -0700 apps/snmptrapd_handlers: Remove a superfluous pointer check Because the third argument passed to command_handler() is never NULL, remove a NULL check for that argument. This patch addresses the following Coverity report: CID 399166 (#1 of 1): Dereference before null check (REVERSE_INULL) check_after_deref: Null-checking handler suggests that it may be null, but it has already been dereferenced on all paths leading to the check. commit 3be30527999a6a0be08f618b3d055a6738dd6e49 Author: Moshe Kaplan Date: Mon Aug 21 12:12:17 2023 -0400 netSnmpHostsTable.c: Fix memory leak (Coverity 344583) netSnmpHostsTable.c: Fix memory leak (Coverity 344583) Free memory allocation referenced in my_handler that is not free()'d in the event of a failure. commit b9ef1a8cf115deb79cb1cb05e6604dd1c7e35361 Author: Moshe Kaplan Date: Mon Aug 21 12:07:12 2023 -0400 route_linux.c: Fix memory leak (Coverity 344582) route_linux.c: Fix memory leak (Coverity 344582) Avoid leaking memory referenced in entry if the IPv6 data is formatted incorrectly. commit 68b5cff8703bd575c39071e0486c1614ce494d98 Author: Moshe Kaplan Date: Mon Aug 21 12:01:36 2023 -0400 deliverByNotify.c: Fix memory leak (Coverity 144379) Avoid leaking memory referenced in vars if it fails to issue the query. commit 4554b2a8cbd8ed6229a90c885f650929aa3063cf Author: Moshe Kaplan Date: Mon Aug 21 11:45:51 2023 -0400 table_dataset.c: Fix memory leak (Coverity 144371) Free memory allocation referenced in table_info that is not free()'d in the event of a failure commit 7184031472d10d64e182ab136fa0c73b4253f0f6 Author: Moshe Kaplan Date: Mon Aug 21 11:27:58 2023 -0400 lookupCtlTable.c: Fix memory leak (Coverity 85698-4) Avoid leaking memory referenced in address if an invalid argument is passed in. commit 47e1d54e24b250aa7e8dac2de051a4dbcead81de Author: Moshe Kaplan Date: Mon Aug 21 09:43:15 2023 -0400 snmpNotifyFilterProfileTable_data.c: Fix memory leaks (Coverity 85636) snmpNotifyFilterProfileTable_data.c: Fix memory leaks (Coverity 85636) Free memory allocation referenced in StorageTmp that is not free()'d in the event of a failure commit 9566c0c3f15a04672dc4fd64e8e6a6f24520584c Author: Moshe Kaplan Date: Mon Aug 21 10:38:29 2023 -0400 icmp.c: Fix memory leaks (Coverity 85667) icmp.c: Fix memory leaks (Coverity 85667) Free memory allocation referenced in msg_stats_table_info that is not free()'d in the event of a failure commit 8acc1cfb80ff5a806ee8fa11c1e133fa1574bbdf Author: Bart Van Assche Date: Sun Aug 20 16:46:15 2023 -0700 SNMP-TLS-TM-MIB: Remove two superfluous assignments This patch addresses the following Coverity complaint: CID 399070 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to table_row here, but that stored value is overwritten before it can be used. commit d9fa80fb9ec9678cc7e155d6b913382fc0b52c78 Author: Bart Van Assche Date: Sun Aug 20 16:43:12 2023 -0700 SNMP-TLS-TM-MIB: Remove a superfluous assignment This patch addresses the following Coverity complaint: CID 399071 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to table_row here, but that stored value is overwritten before it can be used. commit d10463d533506bd8f2f7567c06976dc125f99f5a Author: Bart Van Assche Date: Sun Aug 20 16:37:08 2023 -0700 SNMP-TLS-TM-MIB: Remove a superfluous assignment This patch addresses the following Coverity complaint: CID 399073 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to row here, but that stored value is overwritten before it can be used. commit 1d4de81b9b9540888ee76ad80da6fc5a5fc5ccc2 Author: Bart Van Assche Date: Sun Aug 20 16:28:37 2023 -0700 DISMAN-MIB: traceRouteCtlTable: Remove a superfluous assignment This patch addresses an issue detected by Coverity. commit fe152211938a37bc30276f70cad0fec1f57f9792 Author: Bart Van Assche Date: Sun Aug 20 16:52:50 2023 -0700 deliverByNotify: Use 64 bits for time variables This patch addresses the following Coverity report: CID 380298 (#1 of 1): Use of 32-bit time_t (Y2K38_SAFETY)1. store_truncates_time_t: A time_t value is stored in an integer with too few bits to accommodate it. The expression time(NULL) is cast to int. commit 94cf9460142dbf6ec4db2cf4ce4c2a3963d7c5e1 Author: Bart Van Assche Date: Sun Aug 20 16:39:01 2023 -0700 apps: snmptable: Remove a superfluous assignment This patch addresses the following Coverity complaint: CID 399072 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to vars here, but that stored value is overwritten before it can be used. commit 876c71e81bd71387356b291d11c5780d08c2c71f Author: Bart Van Assche Date: Sun Aug 20 16:34:30 2023 -0700 snmpd: Remove a superfluous assignment This patch addresses the following Coverity complaint: CID 399074 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to last_loop_context here, but that stored value is overwritten before it can be used. commit b99ddb332fa941bf3fa3f60fb20aafd98dd6d75c Author: Bart Van Assche Date: Sun Aug 20 16:31:41 2023 -0700 snmpd: Remove a superfluous assignment This patch addresses the following Coverity complaint: CID 399075 (#1 of 1): Unused value (UNUSED_VALUE)assigned_pointer: Assigning value NULL to row here, but that stored value is overwritten before it can be used. commit d4529cd3f4de93ae137ee13fc90a14e29af6d415 Author: Bart Van Assche Date: Sun Aug 20 17:05:54 2023 -0700 libsnmp: TLS transport: Fix memory leaks in error paths This patch addresses the following Coverity complaint about 'the_ctx': CID 373922 (#2 of 2): Resource leak (RESOURCE_LEAK)6. leaked_storage: Variable the_ctx going out of scope leaks the storage it points to. commit eee541aa54bb35b2f18a7acd7f589fbae6c31bd0 Author: Moshe Kaplan Date: Fri Aug 18 13:43:27 2023 -0400 lookupResultsTable.c: Fix memory leaks lookupResultsTable.c: Fix memory leaks (coverity 85588) Free memory allocation referenced in StorageTmp that is not free()'d in the event of a failure commit efbd198d80193c6a1ca010d94394c785710abdc8 Author: Moshe Kaplan Date: Fri Aug 18 13:54:04 2023 -0400 pingCtlTable.c: Fix memory leaks (Coverity 85603) pingCtlTable.c: Fix memory leaks (Coverity 85603) Free allocated memory if an error occurs. Revert "pingCtlTable.c: Fix memory leaks (Coverity 85603)" This reverts commit 0d3cb33ca5841e620c99f33b6e7b2b1b5c0fff60. re-add commit e5712d3bb7db696493bc29cb7d292797659aa9f4 Author: Moshe Kaplan Date: Fri Aug 18 14:06:31 2023 -0400 pingResultsTable.c: Fix memory leaks (coverity 85662) commit 8f8d71e46e28410696263d50aaccabaf39de09a4 Author: minfrin Date: Thu Oct 13 22:29:37 2022 +0100 apps/sshtosnmp: Avoid EINVAL when passing credentials over SSH unix domain socket Attempts to connect on RHEL9 machines would fail on sendmsg(). Align the socket path with the SSH transport. [ bvanassche: edited patch description ] commit f8a5cfb4ecf8a52ee14f92d5a3fb9e966dde07bc Author: Bart Van Assche Date: Sun Aug 6 17:49:12 2023 -0700 libsnmp: Filter out non-ASCII characters from the output Fixes: https://github.com/net-snmp/net-snmp/pull/580 commit 397de4a963dc94d318bf3229d16725455d490947 Author: Bart Van Assche Date: Sat Jul 22 17:34:31 2023 -0700 libsnmp: Fix a memory leak in read_mib() Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39320 commit 28929671ed268b22f1c4b41dc597c1522a2a2f71 Author: Bart Van Assche Date: Sat Jul 22 17:28:59 2023 -0700 testing/T027read_mib_clib: Add a test case commit 47ca9e62d91249ee5f423b8477ee806b411f59e6 Author: Feroz Ahmed Date: Wed Aug 16 12:08:24 2023 +0000 Added tests to validate SIGHUP for exactEngineID change This test validates commit 45a6422 commit 999d9aa75bf830eaa28654a7cbf627c9497aae51 Author: Feroz Ahmed Date: Sat Aug 12 07:09:37 2023 +0000 Handle SIGHUP for engine-id change SNMP operations continue to work with old engine-id with SIGHUP. commit 726c8aeff776c4cd494815c8a16b50dc8ef2cf2a Author: Bart Van Assche Date: Sun Aug 6 18:36:41 2023 -0700 ci, Windows: Bump the OpenSSL version number ---------------------------------------------------------------------- Changes: V5.9.4.rc1 -> V5.9.4 commit 5289dca2699acb24e4ba92bc20fd1079484eb0fb Author: Wes Hardaker Date: Tue Aug 15 13:28:30 2023 -0700 added a note about TLS commit 54f9a73ebdcc7e038f1f9a2612115b3f909ec871 Author: Wes Hardaker Date: Tue Aug 15 13:18:19 2023 -0700 remove 5-9 patches commit 7e527d309934c8c28e55de4c1d856a9cae137a7e Author: Wes Hardaker Date: Tue Aug 15 13:17:47 2023 -0700 Version number update: 5.9.4 commit 04b98f6b3c939382e697a85a10569299eb74b46e Author: Wes Hardaker Date: Tue Aug 15 13:16:36 2023 -0700 better debug message commit 100c0d989079cd36954e3000591fd1ef9e6859a1 Author: Wes Hardaker Date: Tue Aug 15 13:16:09 2023 -0700 changes and news ---------------------------------------------------------------------- Changes: V5.9.4.pre3 -> V5.9.4.rc1 commit bb7eb41a74cb11a212cc7b69bde09d10290f7824 Author: Wes Hardaker Date: Thu Jun 22 08:00:33 2023 -0700 Release Candidate for V5-9-patches commit ab9840507a39b68fa7bf3ebc1b03b4725ceaea1a Author: Wes Hardaker Date: Thu Jun 22 08:00:31 2023 -0700 Version number update: 5.9.4.rc1 commit d4db247d68c868452d4fe876796e2cd1e8326239 Author: Bart Van Assche Date: Tue Jun 20 06:59:15 2023 -0700 configure: Remove -Wno-deprecated Remove this compiler option now that a better solution is available for suppressing warnings from the OpenSSL library about using deprecated functions. commit d9be7344eeec10d139789f2cbac9ab0a7791f24d Author: Niels Baggesen Date: Mon Jun 19 10:05:50 2023 +0200 libsnmp: Declare OpenSSL API version Add the include/net-snmp/library/openssl_config.h header file. This suppresses warnings from the OpenSSL 3.0+ library about using deprecated API functions. Fixes: https://github.com/net-snmp/net-snmp/pull/591 [ bvanassche: edited patch description ] commit d78add0cdb953775786e040f2a6e92b578e84699 Author: Bart Van Assche Date: Wed Jun 7 08:04:06 2023 -0700 ci: Upgrade Github checkout action This patch addresses the following warning: Node.js 12 actions are deprecated. Please update the following actions to use Node.js 16: actions/checkout@v2. For more information see: https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/. commit 83a42cbb2fafcb228795be561d4cda2b1357a18e Author: Bart Van Assche Date: Sat Jan 21 15:55:55 2023 -0800 ci: Drop support for Travis CI CI support for open source projects ceased on travis-ci.org in June 2021. Hence remove support for Travis CI. commit 45cca4ef4babd5ee32961f92d69027774fe0aa02 Author: Bart Van Assche Date: Wed Dec 21 17:08:52 2022 -0800 ci/perl.bat: Fix a syntax error commit 50b7683008534ed4201e2e7796bd6f584c746852 Author: Bart Van Assche Date: Tue Sep 13 13:43:02 2022 -0700 .cirrus.yml: Update to the current Cirrus CI syntax Additionally, do not install pkgconf since it breaks the Net-SNMP build. commit b6569d5af51d2d6d158621b8c8b4c04cbf1666a8 Author: Bart Van Assche Date: Sun Aug 7 15:34:32 2022 -0700 Make the shell scripts again compatible with the POSIX shell Although /bin/sh is a soft link to /bin/bash on many Linux systems, this is not always the case. Use the POSIX shell syntax in shell scripts instead of bash extensions. commit a7dbdfb70cd82a8bc5563aa5a97c579c0f42a714 Author: Bart Van Assche Date: Fri Aug 5 17:10:46 2022 -0700 ci/net-snmp-configure: Only apply Travis workarounds for Travis CI commit f120aa7d59c2b3554ab0c9f20da5424491c429d4 Author: Bart Van Assche Date: Sat Jul 30 20:06:29 2022 -0700 ci: Build with OpenSSL and wolfSSL commit f3b8e895ea273a08fd013c7a430844df8988c829 Author: Bart Van Assche Date: Sat Jul 30 20:49:34 2022 -0700 ci/net-snmp-configure: Remove the OpenSSL version querying code commit 6c7ec60055a2e35e34c69bd24ec5ac68bd16d68b Author: Bart Van Assche Date: Tue Jun 6 11:39:28 2023 -0700 ci: Improve .appveyor.yml Reduce the build time by excluding configurations that are skipped. Add the Ubuntu2004 image. Switch from Visual Studio 2019 to Visual Studio 2022. Switch from macos-mojave to macos-monterey. commit e1fdcba82e5d8dff9c22de4f8307cc262d537977 Author: Bart Van Assche Date: Tue Sep 13 13:39:42 2022 -0700 ci: Use /bin/sh instead of /bin/bash Use /bin/sh since /bin/bash is not installed by default in the Cirrus CI FreeBSD VMs. commit 79204e14f69ffb8b2f5204a3c9df8b5e79136366 Author: Bart Van Assche Date: Thu Aug 4 14:01:19 2022 -0700 ci/install.sh: Install packages quietly commit a0d72fb33567dcd9faaa44479a6501f1843efd9e Author: Florian Koehler Date: Mon Mar 6 15:45:30 2023 +0100 Added fix for TSM segfault. commit a99eee78c38b62567ab0ff55b8c04b2d8656bc54 Author: Bart Van Assche Date: Sun Jun 4 13:49:51 2023 -0700 testing/fulltests/unit-tests/T021netsnmp_sprint_integer_clib.c: Add this test Add a reproducer for https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=59491. commit a9fba9a2f23a06a4d01482ccdb96b8ba70c1b0de Author: Bart Van Assche Date: Sun Jun 4 14:33:14 2023 -0700 libsnmp: Reject invalid DISPLAY-HINT format characters Prevent that format characters like 'F' cause a buffer overflow. commit b5229a4ef4c6a3ab6d23482211c7607c54044f12 Author: Bart Van Assche Date: Thu Aug 11 19:53:30 2022 -0700 libsnmp: Fix a recently introduced potential integer overflow Fixes: d65925a9f8f6 ("libsnmp: Ignore invalid DISPLAY-HINT clauses") Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50063 commit 09c00e9ff2311f1a69a97a4e7b394ac91e6aa0fb Author: Bart Van Assche Date: Sun Aug 7 20:26:29 2022 -0700 libsnmp: Ignore invalid DISPLAY-HINT clauses This patch should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=48802. commit ed31ab4c83eb3c745e61222be0f4d06689a821a5 Author: Bart Van Assche Date: Thu Jun 1 14:36:12 2023 -0700 libsnmp: Fix a buffer overflow in sprint_realloc_hinted_integer() See also https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=59491. commit fb63c4cbf9abbe4b3b3e8b9475bb6b9aca596c1d Author: Bart Van Assche Date: Wed May 31 17:02:59 2023 -0700 agent/snmp_perl: Disable -Wcast-qual The Perl headers trigger many -Wcast-qual warnings. Hence disable -Wcast-qual around the Perl extension headers. commit 3cec57d8c042619b83e97a45fff34475d314e4b1 Author: Niels Baggesen Date: Thu Jun 1 11:13:19 2023 +0200 read_config.c: add missing newlines to DEBUGMSGTL calls commit 20879e824851a7a188eac50fd34aac04113d7432 Author: Niels Baggesen Date: Thu Jun 1 11:12:34 2023 +0200 snmplib: Handle two oldEngineID lines in snmpd.conf. Fixes #578 commit 055d3801e0b93c552d77645288b2422b2595e2f4 Author: Bart Van Assche Date: Wed May 31 15:49:05 2023 -0700 ci, Windows: Bump the OpenSSL version number commit b208ebecc9381718b801c9d9ddfc5cc7546633f5 Author: Bart Van Assche Date: Wed May 31 07:18:26 2023 -0700 snmpd: Move a comment block The preprocessor constant MIB_CLIENTS_ARE_EVIL is used in source file old_api.c but not in snmp_vars.c. Hence move the comment block that explains the role of that preprocessor constant. commit 2f95d30e632d2c2ab3add875f2eee1e186d8209f Author: Bart Van Assche Date: Wed May 31 07:07:30 2023 -0700 libsnmp: Clean up netsnmp_old_api_helper() Combine the initialization and declaration of variable 'vp' such that it can be declared const. Remove 'vp &&' because it causes some static checkers to report a "dereference before checked" warning. Fixes: https://github.com/net-snmp/net-snmp/pull/487 commit dc103aa62a6bee2b5cef6085af69d96b65c7a5f9 Author: Bart Van Assche Date: Fri May 26 19:21:55 2023 -0700 agent/mibgroup/util_funcs: Align netsnmp_get_link_settings() with master branch commit 7594e24375c26641c36a6272970579042c350de4 Author: Bart Van Assche Date: Fri May 26 14:43:04 2023 -0700 agent/mibgroup/util_funcs: Fix a compiler warning Fix the following clang compiler warning: mibgroup/util_funcs.c:1249:42: warning: field 'elinkset' with variable sized type 'struct ethtool_link_settings' not at the end of a struct or class is a GNU extension [-Wgnu-variable-sized-type-not-at-end] struct ethtool_link_settings elinkset; Additionally, increase mask_nwords from 4 to 8. commit 7a1220567ec68805713eb2dd782424537f1f0de4 Author: Bart Van Assche Date: Fri May 26 14:42:55 2023 -0700 libsnmp: Fix a compiler warning commit 5192261e49957438d6f18b4f3104cdac49fbd28f Author: Bart Van Assche Date: Tue Aug 30 20:39:32 2022 -0700 apps/snmptrap: Initialize the variable 'ss' Fixes: 21b16eba6024 ("apps: Use netsnmp_cleanup_session()") commit 7d5ad2312d849adbed63f23a781049024df8675b Author: Phil O Date: Wed May 25 10:58:23 2022 -0700 HOST-MIB: Add ignoremount config option Fixes: https://github.com/net-snmp/net-snmp/pull/424 [bvanassche: edited patch description; moved a declaration of a global variable from a .c into a .h file and renamed match_mount_config() into ignore_mount_point().] commit 8e02f6c2df8dc929a2f89b71be4de31003a79986 Author: Phil O Date: Wed May 25 11:21:40 2022 -0700 HOST-MIB: Add virtiofs to other_fs commit 298c8103db80b292791616af4fd497342a71867f Author: Josef Řídký Date: Wed May 24 10:49:41 2023 +0200 libsnmp, UDP transport: Fix sendmsg() error code handling This change has been made because of Linux kernel commit "ipv4: Return -ENETUNREACH if we can't create route but saddr is valid" (https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=595e0651d029) Fixes: https://github.com/net-snmp/net-snmp/issues/564 Fixes: https://github.com/net-snmp/net-snmp/pull/576 [ bvanassche: edited commit message ] commit 9df89dc4cf04d27c230736da7d66e3b43911864c Author: Niels Baggesen Date: Mon May 22 21:33:28 2023 +0200 interface_linux.c: defined dummy PCI_NONRET if needed (CentOS7) commit 8c930d7242b8121cf9f8646d4519aefd8956b30e Author: Niels Baggesen Date: Mon May 22 21:31:46 2023 +0200 apps/Makefile.in: snmpps compiles without libcurses (always have) commit 76fae1a91eb70ce8231e16e8323a9bf7d8ac62d3 Author: Niels Baggesen Date: Mon May 22 21:30:21 2023 +0200 etherStatsTable_interface.c: fix a compare of unsigned < 0 commit 47ea381e97ff551fd530b6a3eee59451905a864e Author: Niels Baggesen Date: Mon May 22 21:24:35 2023 +0200 mibII/ipv6.c: remove unused variables commit cee200127b43b2858454851390b69551c144bbd3 Author: Niels Baggesen Date: Mon May 22 21:23:26 2023 +0200 RUNFULLTESTS: correct a reference to srcdir to builddir commit 97df191ff8b16bdc53ba95d2a1c064d2a4666ae6 Author: Bart Van Assche Date: Sat Oct 8 19:26:01 2022 -0700 OS/X: Fix the build Apparently the __fd_mask type has been removed on OS/X. Hence this patch. commit 0d7022df5cffe44227ab228dcf1fbbc725348138 Author: Bart Van Assche Date: Fri Sep 16 15:06:14 2022 -0700 libsnmp: Fix undefined behavior in large_fd_set.c commit 08d6f301ba025caad18f2ce60f9bb2700b61c087 Author: Bart Van Assche Date: Fri May 12 09:59:57 2023 -0700 testing/fulltests/support/simple_TESTCONF.sh: Support disabling limits If NET-SNMP is built with address sanitizer support, the tests fail as follows if memory is limited: ==225838==ERROR: AddressSanitizer failed to allocate 0xdfff0001000 (15392894357504) bytes at address 2008fff7000 (errno: 12) ==225838==ReserveShadowMemoryRange failed while trying to map 0xdfff0001000 bytes. Perhaps you're using ulimit -v Hence add support for disabling runtime limits. commit 6fcef3ba7f9cfc9358553cee4e8121841e06278f Author: Niels Baggesen Date: Fri May 12 12:55:32 2023 +0200 snmpIPv4BaseDomain: fix a leak (shows up with agentx) commit a3caa31fc076edae80e6b78667baac92db3493a7 Author: Niels Baggesen Date: Fri May 12 09:41:51 2023 +0200 config_net_snmp_config_h: add missing defines for DragonFlyBSD commit 042deb1731edc311ef5dbc7f01a8ec045285fbe6 Author: Niels Baggesen Date: Fri May 12 09:40:38 2023 +0200 mibsY/rfclist: correct rfcs for DS1/DS3-mibs commit b23b7fc60ad668c4265a694ebd001504bc206829 Author: Niels Baggesen Date: Fri May 12 09:39:40 2023 +0200 traceRouteCtlTable: fix a possible simple return in a non-void function commit b14b5749892b48081c481dab1bb8ce998be0acdd Author: Niels Baggesen Date: Fri May 12 09:38:05 2023 +0200 Rmon/alarmTable: implement shutdown handler commit 2d710d2e3de9c81f60740eb7a965d7c8991474b5 Author: Niels Baggesen Date: Fri May 12 09:36:17 2023 +0200 agent/extend: fix cleanup at shutdown commit d6a1af15777981a20778260c25245f36bf7c25a6 Author: Niels Baggesen Date: Fri May 12 09:34:57 2023 +0200 apps/snmpusm: fix a memory leak commit 9e9da9d092eca13ef23570d3e78fc6bdfb456ae0 Author: Niels Baggesen Date: Wed May 10 10:06:31 2023 +0200 Yet another #if HAVE_xxx example commit 2c7bdeda7a54516f6bcb9b26a0bd5058bdb742ef Author: Niels Baggesen Date: Wed May 10 10:02:41 2023 +0200 Use configured [ef]grep to avoid warnings about deprecation commit ca2334a0cc4e684edcbf1094b19b376c147ee94a Author: Niels Baggesen Date: Wed May 10 09:58:08 2023 +0200 snmpps: add calls to netsnmp_cleanup_session commit c4f0619e9d1e26aaf1d8332386c296b109fc514f Author: Niels Baggesen Date: Wed May 10 09:57:12 2023 +0200 Fix leak in snmpTargetAddrTable commit 0a244ec94ea46a789bb3b867e632417f8781370b Author: Bart Van Assche Date: Sat Apr 22 18:20:54 2023 -0700 testhandler: Fix memory leaks at exit time commit e42be3a74eb83c270b91feac1e28e9f68f7e5c76 Author: Bart Van Assche Date: Thu Sep 15 14:18:17 2022 -0700 testhandler: Fix memory leaks commit d84ccab2377aaaa402be1e58f92d2543b577d9c5 Author: Bart Van Assche Date: Fri Sep 16 14:48:33 2022 -0700 testhandler: Declare a local variable static commit 0dc31dd059913f5d32c1fee3fb8f8a0987307eb2 Author: Bart Van Assche Date: Sat Apr 22 18:20:59 2023 -0700 SNMP-TLS-TM-MIB: Fix leaks at exit time commit 918a733bb8c4e03b042a5724cb194662d3924e7b Author: Bart Van Assche Date: Sun Apr 23 14:03:32 2023 -0700 SNMP-TLS-TM-MIB: Reorder function definitions commit 537c7a6f6fc80b42240781ce45a06febe0567bba Author: Bart Van Assche Date: Sat Apr 22 17:32:15 2023 -0700 LM-SENSORS-MIB: Fix memory leaks at exit time commit 18ed7614451b40db393da4e57dfbcb8b96fe5a01 Author: Bart Van Assche Date: Fri Apr 21 16:49:56 2023 -0700 LM-SENSORS-MIB: Reorder function definitions commit 57d8dcb825c30f6f20941760863a1c8d671a7e8d Author: Bart Van Assche Date: Fri Apr 21 16:17:01 2023 -0700 DISMAN-EXPRESSION-MIB: Fix memory leaks at exit time commit dbb52d271d6bee9f162b9c6abe16ddbd064107f3 Author: Niels Baggesen Date: Mon May 1 21:40:57 2023 +0200 Fix issue #554 "All commands crash when using -Op" commit 4d3cd42e6acf55e640abef68daf567ddad3107ae Author: Niels Baggesen Date: Mon May 1 21:38:18 2023 +0200 Another few #if HAVE_xxx and similar fixes commit 536a09f70b859676b420781f5c73448f7fe7e2b9 Author: Niels Baggesen Date: Mon May 1 21:36:53 2023 +0200 Fixes for DragonflyBSD TCP and UDP tables commit 575dc2129d5707e1f57fefd145dc0a3085018387 Author: Niels Baggesen Date: Mon May 1 21:35:15 2023 +0200 Additional fix for build outside source directgory commit 3eb9ba9f053ea9c8f23c468c77568e125641b745 Author: Niels Baggesen Date: Mon May 1 21:34:19 2023 +0200 Remove or hide unused variables commit 99763268d8e937360ecc618b771c236a8493ec15 Author: Wes Hardaker Date: Sat Apr 29 01:33:06 2023 -0700 version update for 5.9.4.pre3 commit de0217a7698bf9e9fbeaa927f3b0761cbb3a269d Author: Wes Hardaker Date: Sat Apr 29 01:26:11 2023 -0700 Version number update: 5.9.4.pre3 ---------------------------------------------------------------------- Changes: V5.9.4.pre2 -> V5.9.4.pre3 commit de0217a7698bf9e9fbeaa927f3b0761cbb3a269d Author: Wes Hardaker Date: Sat Apr 29 01:26:11 2023 -0700 Version number update: 5.9.4.pre3 commit 265127456b431b5547a873b8cf6e564938550a6b Author: Wes Hardaker Date: Sat Apr 29 01:23:09 2023 -0700 Revert "Set flags in MakefileSubs.pm at configure time" This reverts commit 7e7ce5a6567c47822410a4683be26d2c0fb8b6cc. commit b29c63d12f7298c0e2c31d8e35fc5c2d87d05b7b Author: Chris Adams Date: Mon Mar 13 17:34:17 2023 -0500 Set flags in MakefileSubs.pm at configure time Setting the flags at configure time instead of runtime allows use of the perl module without pulling in net-snmp-config (which in the Fedora/RHEL RPM setup also pulls in gcc and *-devel packages, not otherwise needed when just using the perl SNMP module). The in-tree module is updated with the rest of the net-snmp code anyway, so setting this at configure time should stay consistent. Signed-off-by: Chris Adams commit 50c53277b500c0ee18edb7994e73033ff8020f80 Author: Bart Van Assche Date: Tue May 5 10:30:32 2020 -0700 libsnmp: Fix handling of the -a and -x app command line options Since snmp_free_session() frees securityAuthProto and securityPrivProto, allocate these two session members dynamically. Fixes: 670d4234b519 ("First pass at an SNMPv3 "combined-option" command-line flag (-3x)"). commit 21b16eba60245bc84149d338a9700e5915bda292 Author: Bart Van Assche Date: Sun Aug 28 18:11:49 2022 -0700 apps: Use netsnmp_cleanup_session() Backport from master. Free the memory allocated by netsnmp_parse_args() before exiting. This reduces the number of memory leaks reported by tools like LeakSanitizer. Ensure that netsnmp_parse_args() only stores pointers to dynamically allocated memory in the session object. commit 72ec58d82b7ddf64b84da2c072f34800c4350fef Author: Bart Van Assche Date: Sun Aug 28 18:11:31 2022 -0700 libsnmp: Introduce netsnmp_cleanup_session() Free all memory owned by a session instead of only a subset of the memory owned by a session. Conflicts: include/net-snmp/library/snmp_api.h commit e8ea0cb1bcc9b96e37895951eb46f04719a10f96 Author: Niels Baggesen Date: Thu Apr 20 12:06:14 2023 +0200 Fix for OpenBSD 7.3 commit 461afde75ac0eb8cafbb523c00762ed96a8e15ea Author: Niels Baggesen Date: Thu Apr 20 12:02:58 2023 +0200 Not all make's honor VPATH srcdir. FreeBSD is the culprit here. commit add75e011eaebee9eca30dd1aac4b9ab282d1626 Author: Niels Baggesen Date: Thu Apr 20 11:54:59 2023 +0200 Fix missing free detected by -fsanitize=address commit cb88cd0809d6be22e7bfb41333c48a171ba91a8f Author: Andy Fiddaman Date: Fri Jul 29 15:39:13 2022 +0000 testing/fulltests/support/simple_eval_tools.sh: support non-GNU getopt Not all implementations of getopt() handle options appearing after operands. POSIX doesn't require that, it's a GNU extension. Running the testsuite from version 5.9.2+ on such a system results in even simple tests failing as the agent attempts to find to port "-f" commit 0ab769060f6cc12b3e3bcd4ad914b784bfb5cfb0 Author: Bart Van Assche Date: Sun Apr 16 15:05:47 2023 -0700 perl: Check the size of output buffers Use snprintf() instead of sprintf() for converting an OID into an ASCII string. commit d3f1271a7e5c7b1087c69b0e9fa3a6b16b0dc8b5 Author: Bart Van Assche Date: Sun Apr 16 14:12:47 2023 -0700 configure: Change AC_TRY_COMPILE() into AC_COMPILE_IFELSE() Make this change because the former macro is obsolete. This patch does not change the configure script. commit a2cb167514ac0c7e1b04e8f151e0b015501362e0 Author: Bart Van Assche Date: Sun Apr 16 14:09:24 2023 -0700 configure: Require that config_() macros are terminated with a semicolon commit 85cedab5a26f00b8e4a2f42d2e8e37cde546e22d Author: Bart Van Assche Date: Sat Apr 15 15:35:42 2023 -0700 Terminate all config_*() macro invocations with a semicolon This patch has been generated by running the following commands: replace-in-files '^\([[:blank:]]*config_[^,*]*)\)[[:blank:]]*$' '\1;' $(git grep -l '^config_') replace-in-files '^\([[:blank:]]*config_version_require.*)\)[[:blank:]]*$' '\1;' $(git grep -l '^config_') commit 4e593010ef224f3b91fb7c5966788530d9393547 Author: Bart Van Assche Date: Sun Apr 16 07:28:35 2023 -0700 libsnmp, agent, MIBs: Fix multiple buffer overflows commit 1d738930b09fa9ae651881ed38d94c61c3c88060 Author: Bart Van Assche Date: Sun Apr 16 07:28:35 2023 -0700 libsnmp: Fix a buffer overflow in the MIB parsing code Fix the following address sanitizer complaint: ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7f4e612001a0 at pc 0x7f4e63c0a654 bp 0x7ffc98f7bb80 sp 0x7ffc98f7bb78 WRITE of size 1 at 0x7f4e612001a0 thread T0 #0 0x7f4e63c0a653 in get_token snmplib/parse.c:4835:13 #1 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #2 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #3 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #4 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #5 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #6 0x7f4e63c0a4a2 in get_token snmplib/parse.c:4813:20 #7 0x7f4e63c2dbd2 in parse_ranges snmplib/parse.c:2282:20 #8 0x7f4e63c29ffa in parse_asntype snmplib/parse.c:2462:27 #9 0x7f4e63c1789f in parse snmplib/parse.c:4598:19 #10 0x7f4e63c0497b in read_module_internal snmplib/parse.c:3942:18 #11 0x7f4e63c0407b in netsnmp_read_module snmplib/parse.c:4041:14 #12 0x7f4e63c0d5e1 in read_mib snmplib/parse.c:5044:12 #13 0x55ec21ab37b1 in main testing/fulltests/unit-tests/T027read_mib_clib.c:35:1 Fixes: 34058af3990b ("*/*: replace horrible (char *)"string" with const specifiers in relevant functions.") commit f065858b75b7eb10a596a9e5ab0f638cf119209f Author: Bart Van Assche Date: Sun Apr 16 07:24:14 2023 -0700 libsnmp: Declare the get_token() input arguments const commit f503e1722960a3b75a86b96c9eb999c8cf5b7b19 Author: Bart Van Assche Date: Sun Apr 16 07:45:02 2023 -0700 libsnmp: Do not pass NULL pointers to memcmp() commit 3644e682f1ae4e0dc7ab0b33600ef0aead48a86a Author: Bart Van Assche Date: Sat Apr 15 16:26:09 2023 -0700 libsnmp: Make sure that the memcmp() arguments are not NULL commit 14150d3e4dbaccaeb347ca56200929735c6d7f51 Author: Bart Van Assche Date: Sat Apr 15 16:11:20 2023 -0700 testing/fulltests/unit-tests/T018read_config_capp.c: Fix a function declaration This patch fixes a clang compiler warning. commit fcb439310eb765c90f4a149116690a1e063a04ca Author: Niels Baggesen Date: Wed Apr 12 12:40:09 2023 +0200 Yet another round of #if HAVE_XXX fixes Some lines that did not follow my simplistic patterns for automatic patching. commit 2df051f3176c77eab6633fca87e0869e545d9945 Author: Bart Van Assche Date: Sat Apr 8 14:43:29 2023 -0700 Run autoreconf -ivf Autoconf version: 2.71 Automake version: 1.16 Libtool version: 2.4.6 commit e7a268a2ee453d2fa3a364a4bf605b0e6b2d3ae9 Author: Niels Baggesen Date: Thu Apr 6 13:39:58 2023 +0200 Update rfclist/Makefile.mib for new IP-TRAFFIC-FLOW-SECURITY-MIB and forgotten SNMP-SSH-TM-MIB ---------------------------------------------------------------------- Changes: V5.9.3 -> V5.9.4.pre2 commit cc275e9a0eaf639dbee2af934419cdcc3fd2881e Author: Wes Hardaker Date: Mon Apr 3 15:06:49 2023 -0700 autoconf update commit 428605d00fea8df9a7b8ca14d15ffbdc8b1d4c64 Author: Wes Hardaker Date: Mon Apr 3 14:54:04 2023 -0700 version bump and autoconf bump commit a739ce6740445d2d2991e2effa1f97c995f5ff0d Author: Wes Hardaker Date: Mon Apr 3 14:53:31 2023 -0700 version update for 5.9.4.pre2 commit fcd3b9c7e04398f2f3bfa686f8ff1141cbc1eaf9 Author: Wes Hardaker Date: Mon Apr 3 14:52:02 2023 -0700 new-key commit 9d1c6c02ef7db23e7e894436fcc5b25b758d88b9 Author: Wes Hardaker Date: Mon Apr 3 14:41:55 2023 -0700 changes commit 6c5bf52dac1ea53b302d523093572fea54cd5d16 Author: Wes Hardaker Date: Mon Apr 3 14:41:02 2023 -0700 autoconf update commit b4b5fa2f20d8d41f24e778aac0034678508ea71b Author: Wes Hardaker Date: Mon Apr 3 14:40:30 2023 -0700 changelog update commit 763e50c1ee89181b1337c2fbdae229884d9facc3 Author: Wes Hardaker Date: Mon Apr 3 13:53:02 2023 -0700 Version number update: 5.9.4.pre1 commit 5846d75426d79a4866411a8768e1effcc4aa808e Author: Wes Hardaker Date: Mon Apr 3 13:49:52 2023 -0700 revision bump commit 5840d13ad70607bce15b4ed5cf744a66fd8147c0 Author: Wes Hardaker Date: Mon Apr 3 13:46:24 2023 -0700 autoconf-update commit 3e918def0de65d5a70239df76588ef2d540c9fb0 Author: Wes Hardaker Date: Mon Apr 3 13:45:46 2023 -0700 bump autoconf version commit 1efe6dfbd1169550e0c4b625324b6de3702676b6 Author: Wes Hardaker Date: Mon Apr 3 13:40:49 2023 -0700 fix name from snmpbulkget -> snmpbulkwalk commit c4ed481ffcc64883f135578291c0c34f08415865 Author: Niels Baggesen Date: Thu Mar 30 12:25:21 2023 +0200 More "#if HAVE_xxx fixes. My original script did not consider blanks between # and if/elif commit 36c2d1dbbb3503614ed5e339ad365411535c6d24 Author: Niels Baggesen Date: Thu Mar 9 15:15:14 2023 +0100 Change "#if HAVE_XXX" into "#ifdef HAVE_XXX" This fixes a bunch of -Wundef warnings. [ bvanassche: changed patch subject / restored consistency of the MSVC config header files ] commit 28d127bc71b77220acd94d3cd8ae65f0580263f2 Author: Bart Van Assche Date: Wed Mar 8 16:28:04 2023 -0800 libsnmp: Remove the ERR_GET_FUNC() macro ERR_GET_FUNC() has been removed from the OpenSSL 3.0 headers. See also https://github.com/net-snmp/net-snmp/issues/539. See also https://github.com/net-snmp/net-snmp/issues/539. commit baaf82808833ea6eaf254590f9e5cfcc02ef1b39 Author: Niels Baggesen Date: Mon Feb 27 21:59:16 2023 +0100 Fixes for OpenBSD 7 commit 906a1e8b92029564341f0768390a02203459561f Author: Bart Van Assche Date: Sat Feb 25 16:47:19 2023 -0800 configure: Add support for FreeBSD jails See also https://github.com/net-snmp/net-snmp/issues/280. commit b0f82764f4ab0b8c6d93378a9b5c2927f2b09509 Author: Bart Van Assche Date: Sat Feb 25 16:34:39 2023 -0800 Spelling: Change 'demon' into 'daemon' From https://en.wikipedia.org/wiki/Daemon_(computing): Many people equate the word "daemon" with the word "demon", implying some kind of satanic connection between UNIX and the underworld. This is an egregious misunderstanding. "Daemon" is actually a much older form of "demon"; daemons have no particular bias towards good or evil, but rather serve to help define a person's character or personality. The ancient Greeks' concept of a "personal daemon" was similar to the modern concept of a "guardian angel"-eudaemonia is the state of being helped or protected by a kindly spirit. As a rule, UNIX systems seem to be infested with both daemons and demons. commit 24b587b2481acfb878ede6c08bfbd581a21ad1d3 Author: Bart Van Assche Date: Thu Feb 23 13:25:52 2023 -0800 ci, Windows: Bump the OpenSSL version number commit 91673b10bac84230d8e4964abfab39d31a4e736f Author: David Rothenberger Date: Sat Mar 10 21:37:06 2018 +0000 Cygwin: Use ':' for the path separator [ bvanassche: edited subject and regenerated the configure script ] commit 2d1ab96c6b46843c593b54a15ff286fcfe9711a5 Author: Niels Baggesen Date: Thu Feb 23 11:37:55 2023 +0100 Updates for NetBSD 10 (now in Beta) Some of these inspired by (taken from) gthe NetBSD pkgsrc patches. commit f3c859515e916cdee899255df372a9045b63a82a Author: Niels Baggesen Date: Tue Jan 31 12:47:09 2023 +0100 mibs: Add missing REVISION clause to UCS-DNMP-mib commit a97098802ae027eb798ab33c6e56b709a870a473 Author: Niels Baggesen Date: Tue Jan 31 12:09:16 2023 +0100 mibs: IANAifType-MIB, IANA-ADDRESS-FAMILY-NUMBERS-MIB Update IANAifType-MIB, IANA-ADDRESS-FAMILY-NUMBERS-MIB to current IANA versions. commit 7e9ec86c929033fc65dd531802ae987cdde04a2a Author: Bart Van Assche Date: Wed Dec 21 16:42:02 2022 -0800 win32/dist/build-binary.pl: Improve this script Use the MSYS gzip executable if gzip is not in the path. Change the OpenSSL path from the OpenSSL 1 path into the OpenSSL 3 path. commit 65709b0b201b6890446e50485a77f27696d285c4 Author: Bart Van Assche Date: Wed Dec 21 17:08:52 2022 -0800 ci/perl.bat: Fix a syntax error commit 49816b48332567d54e1e4d8ce4ac4c42e6c71582 Author: Peter Korsgaard Date: Tue Dec 13 15:03:37 2022 +0100 ipaddress_ioctl.c: unbreak builds with IPv6 but no rtnetlink netsnmp_access_other_info_get() is only available on setups with rtnetlink, so protect the caller with HAVE_LINUX_RTNETLINK_H as well to fix a linking issue: ipaddress_ioctl.c:(.text+0x3be): undefined reference to `netsnmp_access_other_info_get' Signed-off-by: Peter Korsgaard commit 1d4d3c7045a1ba6eab28a0aee47b604d62481b68 Author: Peter Korsgaard Date: Tue Dec 13 12:41:04 2022 +0100 ipaddress_linux.c: unbreak builds without HAVE_LINUX_RTNETLINK_H Commit 89a7860829fdc618ef (IP-MIB: Fix the --disable-ipv6 build) moved defines around to fix builds without IPv6 support, but accidently caused netsnmp_access_other_info_get() to be visible even if HAVE_LINUX_RTNETLINK_H isn't defined, leading to build issues: mibgroup/ip-mib/data_access/ipaddress_linux.c: In function ‘netsnmp_access_other_info_get’: mibgroup/ip-mib/data_access/ipaddress_linux.c:439:28: error: field ‘n’ has incomplete type struct nlmsghdr n; ^ mibgroup/ip-mib/data_access/ipaddress_linux.c:440:29: error: field ‘r’ has incomplete type struct ifaddrmsg r; ^ mibgroup/ip-mib/data_access/ipaddress_linux.c:454:40: error: ‘NETLINK_ROUTE’ undeclared (first use in this function) sd = socket(PF_NETLINK, SOCK_DGRAM, NETLINK_ROUTE); ^~~~~~~~~~~~~ mibgroup/ip-mib/data_access/ipaddress_linux.c:454:40: note: each undeclared identifier is reported only once for each function it appears in mibgroup/ip-mib/data_access/ipaddress_linux.c:461:22: warning: implicit declaration of function ‘NLMSG_LENGTH’; did you mean ‘CMSG_LEN’? [-Wimplicit-function-declaration] req.n.nlmsg_len = NLMSG_LENGTH(sizeof(struct ifaddrmsg)); ^~~~~~~~~~~~ CMSG_LEN mibgroup/ip-mib/data_access/ipaddress_linux.c:461:42: error: invalid application of ‘sizeof’ to incomplete type ‘struct ifaddrmsg’ req.n.nlmsg_len = NLMSG_LENGTH(sizeof(struct ifaddrmsg)); ^~~~~~ Fix it by also enclosing it within the RTNETLINK and IPV6 guards, similar to netsnmp_access_ipaddress_extra_prefix_info(). Given that are already inside an IPV6 conditional just above and below, simply reuse that for simplicity. Signed-off-by: Peter Korsgaard commit 15f9d7f7e5b90c9b419832ed8e6413feb6570d83 Author: Bill Fenner Date: Fri Nov 25 10:23:32 2022 -0800 Add test for NULL varbind set commit 7f4ac4051cc7fec6a5944661923acb95cec359c7 Author: Bill Fenner Date: Fri Nov 25 08:41:46 2022 -0800 apps: snmpset: allow SET with NULL varbind for testing commit 4589352dac3ae111c7621298cf231742209efd9b Author: Bill Fenner Date: Fri Nov 25 08:41:24 2022 -0800 snmp_agent: disallow SET with NULL varbind commit fd898757b47ba0eb0af204ae6f4283be82ab59b8 Author: Bart Van Assche Date: Wed Nov 16 19:54:38 2022 -0800 ci, Windows: Bump the OpenSSL version number commit f362b354ce993d7394bf77db41bb27cfe8d1e307 Author: Sam James Date: Thu Nov 17 00:20:04 2022 +0000 agent: fix -Wincompatible-function-pointer-types Clang 16 makes -Wincompatible-function-pointer-types an error by default. Fixes the following error: ``` mibgroup/if-mib/data_access/interface_linux.c:159:23: error: incompatible function pointer types assigning to 'void (*)(char *, ...) __attribute__((noreturn))' from 'void (char *, ...)' [-Wincompatible-function-pointer-types] pci_access->error = netsnmp_pci_error; ^ ~~~~~~~~~~~~~~~~~ 1 error generated. ``` Signed-off-by: Sam James commit fec0f9ee59d5d89c28d70bb35fad29a0013d048c Author: Sam James Date: Thu Nov 17 00:13:55 2022 +0000 agent/mibgroup: fix -Wstrict-prototypes Clang 16 warns on this. Fix it in preparation for C23. Signed-off-by: Sam James [ bvanassche: minor formatting changes ] commit ddec5fa0ed1c76fde5eea9b974442faeec008526 Author: Sam James Date: Thu Nov 17 00:10:09 2022 +0000 configure.d: fix compatibility with Clang 16 Clang 16 makes -Wimplicit-function-declaration and -Wimplicit-int an error by default. Unfortunately, this can lead to misconfiguration or miscompilation of software as configure tests may then return the wrong result. We also fix -Wstrict-prototypes while here as it's easy to do and it prepares us for C23. For more information, see LWN.net [0] or LLVM's Discourse [1], the Gentoo wiki [2], or the (new) c-std-porting mailing list [3]. [0] https://lwn.net/Articles/913505/ [1] https://discourse.llvm.org/t/configure-script-breakage-with-the-new-werror-implicit-function-declaration/65213 [2] https://wiki.gentoo.org/wiki/Modern_C_porting [3] hosted at lists.linux.dev. Bug: https://bugs.gentoo.org/879715 Signed-off-by: Sam James [ bvanassche: removed two header file guards ] commit d420ff6cd3a3bd8ae469fc2d6a0bafd523280794 Author: Bart Van Assche Date: Fri Nov 4 06:32:46 2022 -0700 CHANGES: libsnmp: Restore support for DNS names longer than 63 characters Fixes: 0b637fea62c7 ("libsnmp/transports: Introduce netsnmp_parse_ep_str()") Fixes: https://github.com/net-snmp/net-snmp/issues/476 commit 923cb442bbef360de227fbca565710518b5ee8e5 Author: Bart Van Assche Date: Fri Nov 4 06:38:06 2022 -0700 CHANGES: libsnmp: Make the snmpIPBaseDomain.h header file private Before making backwards-incompatible changes in snmpIPBaseDomain.h, make this header file private. This patch removes several symbols from the ABI. commit dffe26c0bd9a4f62dc9cd7b267fa7dded867ceee Author: Bart Van Assche Date: Thu Oct 6 11:14:01 2022 -0700 agent/mibgroup/ucd-snmp/pass_persist: Fix a regression in pass_persist SET handling Fixes: 9b9c0e287b4d ("MIBs: Use asprintf() instead of snprintf() to prevent truncation") Fixes: https://github.com/net-snmp/net-snmp/issues/461 commit f494348b8e352845db787ea4eef256c012caf99c Author: Bart Van Assche Date: Tue Sep 13 15:41:29 2022 -0700 FreeBSD: Introduce a function for querying the reassembly timeout commit 0b243e508c38c9d989e4df51adc526c390939087 Author: Gleb Smirnoff Date: Sat Aug 20 12:26:08 2022 -0700 configure: Fix the TCPTV_NEEDS_HZ test In configure search for existing defines, and actually those defines that we are later going to use in code - TCPTV_MIN, TCPTV_REXMTMAX. TCPTV_SRTTDFLT is not existing in FreeBSD for a long time, hence this check always failed, while it should not, and we were compiling wrong code in mibII/tcp.c. Update comment removing old FreeBSD version, leaving FreeBSD. Fixes #445 [ bvanassche: regenerated the configure script / edited the patch description ] commit f4e5175efbb95d2267cad7c15ab2edc58d73be66 Author: Gleb Smirnoff Date: Sat Aug 20 13:43:48 2022 -0700 agent: fix ipReasmTimeout on FreeBSD 14 FreeBSD 14 retired definition of PR_SLOWTIMO and to facilitate SNMP daemons provides a value to retrieve IP fragment TTL at runtime via sysctl. commit e2507e6bce249fe98f659b3d4ed43022757961ca Author: Bart Van Assche Date: Tue Jul 26 06:51:57 2022 -0700 Remove superfluous casts from free() calls This patch does not change any functionality. commit f4d4e4ec19e3eaf03bf47c62561461cb16249207 Author: Bart Van Assche Date: Tue Jul 26 06:55:28 2022 -0700 CHANGES: libsnmp: Remove the SNMP_SWIPE_MEM() macro Remove this macro since it is not used in the Net-SNMP code base. commit bc3ebfe12665d38b9b1496302a25089070fcf0e0 Author: Bart Van Assche Date: Sun Jul 24 18:14:51 2022 -0700 ci: Also build the disable-set, mini and read-only modes Leave out the minimalist mode for now since the minimalist build is broken. commit 51f315046a0bec13934930edde9c145b31bf7d53 Author: Bart Van Assche Date: Sun Jul 24 16:45:05 2022 -0700 agent/Makefile.in: Unbreak the --enable-minimalist build Build the features rules in the mibgroup directory before building the features rules in the helpers directory. Fixes: 51128ad09507 ("agent/Makefile.in: Build the MIB module code once") Fixes: https://github.com/net-snmp/net-snmp/issues/438 commit 53ea215ce2f02e392a188aee2ad1e34c05348fa2 Author: Bart Van Assche Date: Sun Jul 24 15:56:19 2022 -0700 Makefile.rules: Simplify the ftsubdirs code Other than adding two echo statements, this patch does not change any functionality. commit 9714a9bdb717dac827920891569d894e3f3797c0 Author: Bart Van Assche Date: Sun Jul 24 15:36:52 2022 -0700 Makefile.in: Shorten the include path Leave out the Net-SNMP top directory and also the agent/mibgroup directory from the include file path. commit fe52cb48caa0a1b7cb1ac92cddd232b4fb2c5120 Author: Bart Van Assche Date: Fri Jul 22 06:51:28 2022 -0700 NET-SNMP-EXTEND-MIB: Fix a buffer overflow Fixes: https://github.com/net-snmp/net-snmp/issues/437 commit 2e8e6086440269337cd37fbd8ac3efbd32b052c9 Author: Bart Van Assche Date: Tue Jul 5 09:21:26 2022 -0700 snmptrapd: Rework support for old MySQL versions Older versions of MySQL had to be initialized by calling MY_INIT() while newer versions have to be initialized by calling mysql_init(). Only include the old header files if mysql_init() is not supported. Fixes: https://github.com/net-snmp/net-snmp/issues/433 commit 11f4cf41fb84db5fc4873851faaca34cb93b9680 Author: Bart Van Assche Date: Wed Jul 6 19:03:44 2022 -0700 ci, Windows: Bump the OpenSSL version number commit 20564b54eba953403ca83f36ce07a76e3ddeb393 Author: Bart Van Assche Date: Wed Jul 6 16:00:54 2022 -0700 ci: Ignore package installation failures commit 448bcbf0ccd1216b70ba7101cf24fa17fe3de25c Author: Wes Hardaker Date: Tue Jul 5 08:27:17 2022 -0700 increment 'libcurrent' commit 1048dd76799e2b7890844013e0fd55f5fdb80aa6 Author: Bart Van Assche Date: Mon Jul 4 17:45:27 2022 -0700 testing/fulltests/snmpv3/T050etimetest_capp: Suppress a set-but-not-used variable warning commit 0fb09cf24425e2f35a33cee744424d8e625feb66 Author: Bart Van Assche Date: Mon Jul 4 17:34:05 2022 -0700 .gitignore: Update commit 964d028dce7125391548d4790dac92e2d6767bdc Author: Bart Van Assche Date: Mon Jul 4 17:30:03 2022 -0700 ci: Move the code for rewriting /etc/hosts This patch fixes the following oss-fuzz warning: net-snmp/ci/install.sh: line 6: sudo: command not found commit e87d0066e36c89bd80e419be298cd8f414d4980c Author: Bart Van Assche Date: Mon Jul 4 17:05:40 2022 -0700 Python: Stop using the ... package This patch fixes the following warning: python/setup.py:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.core import setup, Extension commit f1fa5c8b5404d449a7241def319c3b4ac325926b Author: Bart Van Assche Date: Mon Jul 4 16:57:22 2022 -0700 snmpps: Use #ifdef instead of #if to test HAVE_* macros This patch suppresses the following compiler warning: snmpps.c:70:5: warning: 'HAVE_NCURSES_CURSES_H' is not defined, evaluates to 0 [-Wundef] commit b883086e82d984d411f029e8fef777614867a1ff Author: Bart Van Assche Date: Sat Jul 2 16:25:22 2022 -0700 ci, Windows: Bump the OpenSSL version number ---------------------------------------------------------------------- Changes: V5.9.3.rc1 -> V5.9.3 commit d6644ac380a3563b3bce8400d62c789604695447 Author: Wes Hardaker Date: Wed Jul 13 10:43:01 2022 -0700 drop rc commit 47d4972916e4cbbc5c8df65f1546c5e1b8632928 Author: Wes Hardaker Date: Wed Jul 13 10:42:39 2022 -0700 Version number update: 5.9.3 ---------------------------------------------------------------------- Changes: V5.9.2 -> V5.9.3.rc1 commit ca067c485f06e330a0db13c88ad7321124a0b22a Author: Wes Hardaker Date: Wed Jul 6 07:39:29 2022 -0700 Release Candidate for V5-9-3-branch commit e672baf238ebb7e80b03d0191345f14afaf5a311 Author: Wes Hardaker Date: Wed Jul 6 07:39:27 2022 -0700 Version number update: 5.9.3.rc1 commit 035216c0fae83dd8e37b0e5b504d4f8b7076b56f Author: Wes Hardaker Date: Tue Jul 5 08:27:17 2022 -0700 increment 'libcurrent' ---------------------------------------------------------------------- Changes: V5.9.2.rc2 -> V5.9.2 commit 1154e3cd9b280f39cc956d21327ff1abcefae4fd Author: Wes Hardaker Date: Thu Jun 30 16:38:13 2022 -0700 reopen 5.9 patches commit 9705b5f1414b3092934eb3879483dc3e831f7b7b Author: Wes Hardaker Date: Thu Jun 30 16:37:21 2022 -0700 Version number update: 5.9.2 ---------------------------------------------------------------------- Changes: V5.9.2.rc1 -> V5.9.2.rc2 commit 1b7564a375c4e8b2ca2282a2a2ec5c9b19d6a4dc Author: Wes Hardaker Date: Wed Jun 22 15:01:30 2022 -0700 Version number update: 5.9.2.rc2 commit ce66eb97c17aa9a48bc079be7b65895266fa6775 Author: Wes Hardaker Date: Wed Jun 22 15:00:17 2022 -0700 updates to CHANGES/NEWS commit a8ea1e4aadc542aebda46a09258aec76f71b19e9 Author: Bart Van Assche Date: Sun Jun 12 20:00:34 2022 -0700 ci/perl.bat: Bump the Perl version commit 4022d51d5036bd4b0fb80c92d58e375bc51b0b96 Author: Bart Van Assche Date: Sun Jun 12 09:32:29 2022 -0700 ci, Windows: Bump the OpenSSL version number commit ab410b3628b4aa8e8d51d72a03bcdba6fdfdcc7e Author: Bart Van Assche Date: Thu May 5 21:11:12 2022 -0700 configure: Regenerate with the correct version of autotools Fixes: 9e188ca935f3 ("Version number update: 5.9.2.rc1") ---------------------------------------------------------------------- Changes: V5.9.2.rc2 -> V5.9.2 commit 1154e3cd9b280f39cc956d21327ff1abcefae4fd Author: Wes Hardaker Date: Thu Jun 30 16:38:13 2022 -0700 reopen 5.9 patches commit 9705b5f1414b3092934eb3879483dc3e831f7b7b Author: Wes Hardaker Date: Thu Jun 30 16:37:21 2022 -0700 Version number update: 5.9.2 ---------------------------------------------------------------------- Changes: V5.9.2.rc1 -> V5.9.2.rc2 commit 1b7564a375c4e8b2ca2282a2a2ec5c9b19d6a4dc Author: Wes Hardaker Date: Wed Jun 22 15:01:30 2022 -0700 Version number update: 5.9.2.rc2 commit ce66eb97c17aa9a48bc079be7b65895266fa6775 Author: Wes Hardaker Date: Wed Jun 22 15:00:17 2022 -0700 updates to CHANGES/NEWS commit a8ea1e4aadc542aebda46a09258aec76f71b19e9 Author: Bart Van Assche Date: Sun Jun 12 20:00:34 2022 -0700 ci/perl.bat: Bump the Perl version commit 4022d51d5036bd4b0fb80c92d58e375bc51b0b96 Author: Bart Van Assche Date: Sun Jun 12 09:32:29 2022 -0700 ci, Windows: Bump the OpenSSL version number commit ab410b3628b4aa8e8d51d72a03bcdba6fdfdcc7e Author: Bart Van Assche Date: Thu May 5 21:11:12 2022 -0700 configure: Regenerate with the correct version of autotools Fixes: 9e188ca935f3 ("Version number update: 5.9.2.rc1") ---------------------------------------------------------------------- Changes: V5.9.2.pre1 -> V5.9.2.rc1 commit 88766d759bdf998d645fb09f050d4701dd39b2b2 Author: Wes Hardaker Date: Thu Apr 21 15:35:47 2022 -0700 Release Candidate for V5-9-patches commit 9e188ca935f3cc84110973decb7efb5be42989b9 Author: Wes Hardaker Date: Thu Apr 21 15:35:45 2022 -0700 Version number update: 5.9.2.rc1 commit 37dd47517ece80209f1eb0bd82235a7bd50a00c3 Author: Stuart Henderson Date: Tue Apr 12 09:59:55 2022 +0100 libsnmp: Don't try to install factory.h 87d45755edd made factory.h a private header, but snmplib/Makefile.in continues to try to install it from include/net-snmp/library, resulting in an error from "make install". Fixes: https://github.com/net-snmp/net-snmp/pull/417 commit 9adb432e1a23d3114e1074a0d0b088024a402108 Author: Bart Van Assche Date: Wed Apr 6 13:57:51 2022 -0700 ci, Windows: Bump the OpenSSL version number commit b33d6bbe72b26a5b2a8cced96178c6de1105181f Author: Bart Van Assche Date: Tue Apr 5 12:57:32 2022 -0700 python: Return 'None' instead of an object for GET requests of non-existing OIDs Fixes: https://github.com/net-snmp/net-snmp/issues/414 commit d3d939f27286bab91e7316c4fa6b9e224621ec0c Author: Bart Van Assche Date: Tue Apr 5 12:49:42 2022 -0700 python: Add a unit test for a non-existing OID ---------------------------------------------------------------------- Changes: V5.9.1 -> V5.9.2.pre1 commit 8c55dc5fd5165017965abef158a343719eefde60 Author: Wes Hardaker Date: Tue Apr 5 08:46:11 2022 -0700 Version number update: 5.9.2.pre1 commit d9611b05980423f0cf0c72408681af8d3d44e969 Author: Wes Hardaker Date: Tue Apr 5 08:46:03 2022 -0700 version update for 5.9.2.pre1 commit 7d4289129d4bd6e6fae5dc4470d2a5953fa3281f Author: lijog Date: Fri Feb 25 20:58:52 2022 -0800 Solaris: Fix ifHighSpeed The ifHighSpeed value is not being fetched correctly for Solaris systems as seen in the following example. For a 10Gbps interface, we see > snmpwalk -v 2c -c public localhost ifdescr IF-MIB::ifDescr.2 = STRING: net0 > snmpwalk -v 2c -c public localhost ifspeed IF-MIB::ifSpeed.2 = Gauge32: 1410065408 > snmpwalk -v 2c -c public localhost ifHighSpeed IF-MIB::ifHighSpeed.1 = Gauge32: 127 IF-MIB::ifHighSpeed.2 = Gauge32: 1410 > dladm show-phys -Z LINK ZONE MEDIA STATE SPEED DUPLEX DEVICE net0 global Ethernet up 10000 full ixgbe0 > kstat -p|grep speed .... ixgbe:0:phys:ifspeed 10000000000 //10Gbps .. The expected output is 10000000000 expressed in Mbps, i.e 10000 IF-MIB::ifSpeed.2 = Gauge32: 10000 The issue occurs as we are using an integer(Gauge) type to fetch the ifspeed value and simply convert it into Mbps for the ifHighSpeed value, which will fail for speeds > INT_MAX-1. From the net-snmp documentation at http://www.net-snmp.org/docs/mibs/interfaces.html: "An estimate of the interface's current bandwidth in bits per second. For interfaces which do not vary in bandwidth or for those where no accurate estimation can be made, this object should contain the nominal bandwidth. If the bandwidth of the interface is greater than the maximum value reportable by this object then this object should report its maximum value (4,294,967,295) and ifHighSpeed must be used to report the interace's speed. For a sub-layer which has no concept of bandwidth, this object should be zero." The fix will use a uint64 type for storing the ifspeed value, and will display the ifspeed value as per the docs. Here's the output after applying the fix > snmpwalk -c public -v 2c localhost ifSpeed IF-MIB::ifSpeed.2 = Gauge32: 4294967295 > snmpwalk -c public -v 2c localhost ifHighSpeed IF-MIB::ifHighSpeed.2 = Gauge32: 10000 Fixes: https://github.com/net-snmp/net-snmp/pull/409 [ bvanassche: reformatted commit message / combined four patches into one ] commit d45fe61a133449b6bc47f2d2b51f7636b7b343e0 Author: Bart Van Assche Date: Mon Jan 3 17:18:30 2022 -0800 snmptrap: Improve documentation of the 'AGENT' argument Fixes: https://github.com/net-snmp/net-snmp/issues/395 commit 28e3bb4f9ff78f32ee968d6d76c8a3c04b761abe Author: Bart Van Assche Date: Tue Dec 28 14:11:57 2021 -0800 libsnmp: snmpSTDDomain: Remove an exit() call Apparently calling exit() from a child process confuses oss-fuzz. Hence remove the exit() call from the child process. This patch does not change any functionality. commit 0ccf55e7e9c19c8e23bd94b19901ed8692423293 Author: Bart Van Assche Date: Tue Dec 28 14:03:18 2021 -0800 libsnmp: Fix a memory leak in an error path of parse_objectid() Link newly allocated nodes earlier such that these are freed from the error path. Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39320 Fixes: 5201c852e0f6 ("Initial revision") commit 8c3a094fbe9ebe38ed762488082d52c6d4e04ddb Author: Bart Van Assche Date: Sat Dec 25 13:02:06 2021 -0800 configure: Use pkg-config to detect the OpenSSL dependencies Which libraries must be linked in addition to the ssl library depends on the configuration of OpenSSL and on the platform. Hence use pkg-config to detect these libraries if pkg-config is available. Provide a fallback if pkg-config is not available. See also "compile fails with net-snmp-5.8 and openssl-1.1.1d" (https://github.com/net-snmp/net-snmp/issues/25). commit 672e23a3f7a0f54961f9aa1e927f5064a0c1969e Author: Giulio Benetti Date: Wed Sep 12 20:16:39 2018 +0200 configure, static linking: Fix SSL checks During checking of DTLS_method, the stub program is linked only with -ssl libssl.a lacks some function from -lcrypto: RAND_*() ERR_*() BUF_MEM_*() etc. and -lz: - inflate() - deflate() Append -lcrypto and -lz to LIBS variable when checking DTLS_method. See also https://sourceforge.net/p/net-snmp/patches/1374/ . Signed-off-by: Giulio Benetti [bvanassche: Edited subject / rewrote this patch] commit 72dee028836d233979e4563ce3c3d5e303e0e042 Author: Bart Van Assche Date: Mon Dec 20 09:23:48 2021 -0800 CHANGES: net-snmp-create-v3-user: Fix the snmpd.conf path @datadir@ is expanded in ${datarootdir} so datarootdir must be set before @datadir@ is used. See also https://github.com/net-snmp/net-snmp/pull/394 . Fixes: d784eb53f38a ("NEWS: misc: separate user management from net-snmp-config into new net-snmp-create-v3-user script") commit f5cc42798c996796ec04e38d67f5589153353bd8 Author: Bart Van Assche Date: Fri Dec 17 09:12:37 2021 -0800 ci/openssl.bat: Bump the OpenSSL version commit bd7394d5d266916d655b804e5b40bc0673030ccd Author: Bart Van Assche Date: Sun Dec 12 13:08:25 2021 -0800 CHANGES: Win32: winExtDLL: Load evntagnt.dll and lmmib2.dll by default Load those two DLLs except if these are excluded by e.g. -I-lmmib2.dll. Work around generic errors for all OIDs with prefix .1.3.6.1.4.1.77. commit fc4591ff585f62b28af2d118b72d21a928381295 Author: Bart Van Assche Date: Sun Dec 12 13:42:45 2021 -0800 Improve Doxygen documentation Remove $(srcdir) since apparently it is no longer supported. Fix most warnings about function headers reported by Doxygen 1.9.2. commit 7f1b973e90ab6736400f72c23f71e4b5ef7726ae Author: Bart Van Assche Date: Sun Dec 12 13:25:35 2021 -0800 libsnmp: Leave out superfluous parentheses from OID comparison functions Additionally, improve the Doxygen documentation. This patch does not change any functionality. commit 07dc7379a0ca6e8a8ded03430cc423ae44022920 Author: Bart Van Assche Date: Sat Dec 11 14:35:45 2021 -0800 CHANGES: Win32: winExtDLL: Windows 10 improvements Load evntagnt.dll and lmmib2.dll on Windows 10. Skip OIDs for which it is known that GETNEXT fails with "generic error". commit af3b5237962cb9b535c2ac8058d7817950776dad Author: Bart Van Assche Date: Sat Dec 11 14:35:21 2021 -0800 CHANGES: Win32: winExtDLL: Make long strings occupy a single line Make it easier to look up error messages in the source code by making long strings occupy a single source code line. commit aaafd8c236033c06d3b59354a3236553f976771e Author: Bart Van Assche Date: Sat Dec 11 15:59:52 2021 -0800 CHANGES: Win32: winExtDLL: Fix multiple compiler warnings commit 51818e49b244fc9eed0edb6afcdae27f3e476d6a Author: Bart Van Assche Date: Sat Dec 11 14:26:03 2021 -0800 README.win32: Remove references to Cygwin Since Net-SNMP users use MinGW instead of Cygwin, remove the instructions about how to build Net-SNMP for Cygwin. Additionally, mention that Net-SNMP must be built in 32-bit mode to use winExtDLL and also that snmp_mib must be excluded. commit 8e433146c79bb09a3daff012e609094ad5a83712 Author: Bart Van Assche Date: Fri Dec 10 20:37:36 2021 -0800 CHANGES: Win32: winExtDLL: Restore MIB-II support Commit 59b4d40f3970 ("CHANGES: Windows: Make winExtDLL work on 64-bit Windows systems") caused snmpd to skip MIB-II on 64-bit systems. Revert that change such that the Windows MIB-II implementation can be used on Windows 10. See also: * https://github.com/net-snmp/net-snmp/issues/383 * https://github.com/net-snmp/net-snmp/issues/388 With this patch applied, I see the following output in a Windows VM: $ /c/usr/bin/snmpwalk -v2c -cpublic localhost .1.3.6.1.2.1.2 IF-MIB::ifNumber.0 = INTEGER: 9 IF-MIB::ifIndex.1 = INTEGER: 1 IF-MIB::ifIndex.2 = INTEGER: 2 IF-MIB::ifIndex.3 = INTEGER: 3 IF-MIB::ifIndex.4 = INTEGER: 4 IF-MIB::ifIndex.5 = INTEGER: 5 IF-MIB::ifIndex.6 = INTEGER: 6 IF-MIB::ifIndex.7 = INTEGER: 7 IF-MIB::ifIndex.8 = INTEGER: 8 IF-MIB::ifIndex.9 = INTEGER: 9 IF-MIB::ifDescr.1 = STRING: Software Loopback Interface 1 IF-MIB::ifDescr.2 = STRING: Microsoft 6to4 Adapter IF-MIB::ifDescr.3 = STRING: Microsoft Kernel Debug Network Adapter IF-MIB::ifDescr.4 = STRING: Microsoft IP-HTTPS Platform Adapter IF-MIB::ifDescr.5 = STRING: Intel(R) 82574L Gigabit Network Connection IF-MIB::ifDescr.6 = STRING: Microsoft Teredo Tunneling Adapter IF-MIB::ifDescr.7 = STRING: Intel(R) 82574L Gigabit Network Connection-WFP Native MAC Layer LightWeight Filter-0000 IF-MIB::ifDescr.8 = STRING: Intel(R) 82574L Gigabit Network Connection-QoS Packet Scheduler-0000 IF-MIB::ifDescr.9 = STRING: Intel(R) 82574L Gigabit Network Connection-WFP 802.3 MAC Layer LightWeight Filter-0000 IF-MIB::ifType.1 = INTEGER: softwareLoopback(24) IF-MIB::ifType.2 = INTEGER: tunnel(131) IF-MIB::ifType.3 = INTEGER: ethernetCsmacd(6) IF-MIB::ifType.4 = INTEGER: tunnel(131) IF-MIB::ifType.5 = INTEGER: ethernetCsmacd(6) IF-MIB::ifType.6 = INTEGER: tunnel(131) IF-MIB::ifType.7 = INTEGER: ethernetCsmacd(6) IF-MIB::ifType.8 = INTEGER: ethernetCsmacd(6) IF-MIB::ifType.9 = INTEGER: ethernetCsmacd(6) IF-MIB::ifMtu.1 = INTEGER: 1500 IF-MIB::ifMtu.2 = INTEGER: 0 IF-MIB::ifMtu.3 = INTEGER: 0 IF-MIB::ifMtu.4 = INTEGER: 0 IF-MIB::ifMtu.5 = INTEGER: 1500 IF-MIB::ifMtu.6 = INTEGER: 0 IF-MIB::ifMtu.7 = INTEGER: 1500 IF-MIB::ifMtu.8 = INTEGER: 1500 IF-MIB::ifMtu.9 = INTEGER: 1500 IF-MIB::ifSpeed.1 = Gauge32: 1073741824 IF-MIB::ifSpeed.2 = Gauge32: 0 IF-MIB::ifSpeed.3 = Gauge32: 0 IF-MIB::ifSpeed.4 = Gauge32: 0 IF-MIB::ifSpeed.5 = Gauge32: 1000000000 IF-MIB::ifSpeed.6 = Gauge32: 0 IF-MIB::ifSpeed.7 = Gauge32: 1000000000 IF-MIB::ifSpeed.8 = Gauge32: 1000000000 IF-MIB::ifSpeed.9 = Gauge32: 1000000000 IF-MIB::ifPhysAddress.1 = STRING: IF-MIB::ifPhysAddress.2 = STRING: IF-MIB::ifPhysAddress.3 = STRING: IF-MIB::ifPhysAddress.4 = STRING: IF-MIB::ifPhysAddress.5 = STRING: 52:54:0:bb:6f:2f IF-MIB::ifPhysAddress.6 = STRING: IF-MIB::ifPhysAddress.7 = STRING: 52:54:0:bb:6f:2f IF-MIB::ifPhysAddress.8 = STRING: 52:54:0:bb:6f:2f IF-MIB::ifPhysAddress.9 = STRING: 52:54:0:bb:6f:2f IF-MIB::ifAdminStatus.1 = INTEGER: up(1) IF-MIB::ifAdminStatus.2 = INTEGER: down(2) IF-MIB::ifAdminStatus.3 = INTEGER: down(2) IF-MIB::ifAdminStatus.4 = INTEGER: down(2) IF-MIB::ifAdminStatus.5 = INTEGER: up(1) IF-MIB::ifAdminStatus.6 = INTEGER: down(2) IF-MIB::ifAdminStatus.7 = INTEGER: up(1) IF-MIB::ifAdminStatus.8 = INTEGER: up(1) IF-MIB::ifAdminStatus.9 = INTEGER: up(1) IF-MIB::ifOperStatus.1 = INTEGER: up(1) IF-MIB::ifOperStatus.2 = INTEGER: down(2) IF-MIB::ifOperStatus.3 = INTEGER: down(2) IF-MIB::ifOperStatus.4 = INTEGER: down(2) IF-MIB::ifOperStatus.5 = INTEGER: up(1) IF-MIB::ifOperStatus.6 = INTEGER: down(2) IF-MIB::ifOperStatus.7 = INTEGER: up(1) IF-MIB::ifOperStatus.8 = INTEGER: up(1) IF-MIB::ifOperStatus.9 = INTEGER: up(1) IF-MIB::ifLastChange.1 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.2 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.3 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.4 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.5 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.6 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.7 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.8 = Timeticks: (0) 0:00:00.00 IF-MIB::ifLastChange.9 = Timeticks: (0) 0:00:00.00 IF-MIB::ifInOctets.1 = Counter32: 0 IF-MIB::ifInOctets.2 = Counter32: 0 IF-MIB::ifInOctets.3 = Counter32: 0 IF-MIB::ifInOctets.4 = Counter32: 0 IF-MIB::ifInOctets.5 = Counter32: 3902284436 IF-MIB::ifInOctets.6 = Counter32: 0 IF-MIB::ifInOctets.7 = Counter32: 3902284436 IF-MIB::ifInOctets.8 = Counter32: 3902284436 IF-MIB::ifInOctets.9 = Counter32: 3902284436 IF-MIB::ifInUcastPkts.1 = Counter32: 0 IF-MIB::ifInUcastPkts.2 = Counter32: 0 IF-MIB::ifInUcastPkts.3 = Counter32: 0 IF-MIB::ifInUcastPkts.4 = Counter32: 0 IF-MIB::ifInUcastPkts.5 = Counter32: 265150678 IF-MIB::ifInUcastPkts.6 = Counter32: 0 IF-MIB::ifInUcastPkts.7 = Counter32: 265150678 IF-MIB::ifInUcastPkts.8 = Counter32: 265150678 IF-MIB::ifInUcastPkts.9 = Counter32: 265150678 IF-MIB::ifInNUcastPkts.1 = Counter32: 0 IF-MIB::ifInNUcastPkts.2 = Counter32: 0 IF-MIB::ifInNUcastPkts.3 = Counter32: 0 IF-MIB::ifInNUcastPkts.4 = Counter32: 0 IF-MIB::ifInNUcastPkts.5 = Counter32: 28 IF-MIB::ifInNUcastPkts.6 = Counter32: 0 IF-MIB::ifInNUcastPkts.7 = Counter32: 28 IF-MIB::ifInNUcastPkts.8 = Counter32: 28 IF-MIB::ifInNUcastPkts.9 = Counter32: 28 IF-MIB::ifInDiscards.1 = Counter32: 0 IF-MIB::ifInDiscards.2 = Counter32: 0 IF-MIB::ifInDiscards.3 = Counter32: 0 IF-MIB::ifInDiscards.4 = Counter32: 0 IF-MIB::ifInDiscards.5 = Counter32: 0 IF-MIB::ifInDiscards.6 = Counter32: 0 IF-MIB::ifInDiscards.7 = Counter32: 0 IF-MIB::ifInDiscards.8 = Counter32: 0 IF-MIB::ifInDiscards.9 = Counter32: 0 IF-MIB::ifInErrors.1 = Counter32: 0 IF-MIB::ifInErrors.2 = Counter32: 0 IF-MIB::ifInErrors.3 = Counter32: 0 IF-MIB::ifInErrors.4 = Counter32: 0 IF-MIB::ifInErrors.5 = Counter32: 0 IF-MIB::ifInErrors.6 = Counter32: 0 IF-MIB::ifInErrors.7 = Counter32: 0 IF-MIB::ifInErrors.8 = Counter32: 0 IF-MIB::ifInErrors.9 = Counter32: 0 IF-MIB::ifInUnknownProtos.1 = Counter32: 0 IF-MIB::ifInUnknownProtos.2 = Counter32: 0 IF-MIB::ifInUnknownProtos.3 = Counter32: 0 IF-MIB::ifInUnknownProtos.4 = Counter32: 0 IF-MIB::ifInUnknownProtos.5 = Counter32: 0 IF-MIB::ifInUnknownProtos.6 = Counter32: 0 IF-MIB::ifInUnknownProtos.7 = Counter32: 0 IF-MIB::ifInUnknownProtos.8 = Counter32: 0 IF-MIB::ifInUnknownProtos.9 = Counter32: 0 IF-MIB::ifOutOctets.1 = Counter32: 0 IF-MIB::ifOutOctets.2 = Counter32: 0 IF-MIB::ifOutOctets.3 = Counter32: 0 IF-MIB::ifOutOctets.4 = Counter32: 0 IF-MIB::ifOutOctets.5 = Counter32: 1952733666 IF-MIB::ifOutOctets.6 = Counter32: 0 IF-MIB::ifOutOctets.7 = Counter32: 1952733666 IF-MIB::ifOutOctets.8 = Counter32: 1952733666 IF-MIB::ifOutOctets.9 = Counter32: 1952733666 IF-MIB::ifOutUcastPkts.1 = Counter32: 0 IF-MIB::ifOutUcastPkts.2 = Counter32: 0 IF-MIB::ifOutUcastPkts.3 = Counter32: 0 IF-MIB::ifOutUcastPkts.4 = Counter32: 0 IF-MIB::ifOutUcastPkts.5 = Counter32: 137686780 IF-MIB::ifOutUcastPkts.6 = Counter32: 0 IF-MIB::ifOutUcastPkts.7 = Counter32: 137686780 IF-MIB::ifOutUcastPkts.8 = Counter32: 137686780 IF-MIB::ifOutUcastPkts.9 = Counter32: 137686780 IF-MIB::ifOutNUcastPkts.1 = Counter32: 0 IF-MIB::ifOutNUcastPkts.2 = Counter32: 0 IF-MIB::ifOutNUcastPkts.3 = Counter32: 0 IF-MIB::ifOutNUcastPkts.4 = Counter32: 0 IF-MIB::ifOutNUcastPkts.5 = Counter32: 115 IF-MIB::ifOutNUcastPkts.6 = Counter32: 0 IF-MIB::ifOutNUcastPkts.7 = Counter32: 115 IF-MIB::ifOutNUcastPkts.8 = Counter32: 115 IF-MIB::ifOutNUcastPkts.9 = Counter32: 115 IF-MIB::ifOutDiscards.1 = Counter32: 0 IF-MIB::ifOutDiscards.2 = Counter32: 0 IF-MIB::ifOutDiscards.3 = Counter32: 0 IF-MIB::ifOutDiscards.4 = Counter32: 0 IF-MIB::ifOutDiscards.5 = Counter32: 0 IF-MIB::ifOutDiscards.6 = Counter32: 0 IF-MIB::ifOutDiscards.7 = Counter32: 0 IF-MIB::ifOutDiscards.8 = Counter32: 0 IF-MIB::ifOutDiscards.9 = Counter32: 0 IF-MIB::ifOutErrors.1 = Counter32: 0 IF-MIB::ifOutErrors.2 = Counter32: 0 IF-MIB::ifOutErrors.3 = Counter32: 0 IF-MIB::ifOutErrors.4 = Counter32: 0 IF-MIB::ifOutErrors.5 = Counter32: 0 IF-MIB::ifOutErrors.6 = Counter32: 0 IF-MIB::ifOutErrors.7 = Counter32: 0 IF-MIB::ifOutErrors.8 = Counter32: 0 IF-MIB::ifOutErrors.9 = Counter32: 0 IF-MIB::ifOutQLen.1 = Gauge32: 0 IF-MIB::ifOutQLen.2 = Gauge32: 0 IF-MIB::ifOutQLen.3 = Gauge32: 0 IF-MIB::ifOutQLen.4 = Gauge32: 0 IF-MIB::ifOutQLen.5 = Gauge32: 0 IF-MIB::ifOutQLen.6 = Gauge32: 0 IF-MIB::ifOutQLen.7 = Gauge32: 0 IF-MIB::ifOutQLen.8 = Gauge32: 0 IF-MIB::ifOutQLen.9 = Gauge32: 0 IF-MIB::ifSpecific.1 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.2 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.3 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.4 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.5 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.6 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.7 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.8 = OID: SNMPv2-SMI::zeroDotZero IF-MIB::ifSpecific.9 = OID: SNMPv2-SMI::zeroDotZero commit 4abad4b6eed22c8bc54be9f6ad77d5abe14bac75 Author: Bart Van Assche Date: Fri Dec 10 20:58:56 2021 -0800 README.win32: Document how to install the SNMP service on Windows 10 commit 83c0a8f38dc8789f8cc0cef76af344a2c2f6b50b Author: Bart Van Assche Date: Fri Dec 3 20:37:42 2021 -0800 libsnmp: Prepare for using the recommended OpenSSL functions This patch does not change any functionality. commit 447e80b7f1c8ad9899f30afb8c7c31b232c79fb2 Author: Bart Van Assche Date: Fri Dec 3 20:36:58 2021 -0800 configure: Check for more OpenSSL functions commit fad66f9957fb2a19b711cf660b7f23d7410e47e6 Author: Bart Van Assche Date: Thu Dec 2 15:03:13 2021 -0800 Revert "libsnmp: Use the recommended OpenSSL functions" This reverts commit 0bb1243671fe9a1389d3c735100747982a1b3c3c. Revert this commit because it breaks the regression tests. commit e87892b94ed90d17730730c2ead69b4e17a47ec2 Author: Bart Van Assche Date: Tue Nov 30 22:13:42 2021 -0800 configure: Restore support for compilers that do not support -Werror See also https://github.com/net-snmp/net-snmp/issues/376 . commit 0bb1243671fe9a1389d3c735100747982a1b3c3c Author: Bart Van Assche Date: Sun Nov 28 16:09:21 2021 -0800 libsnmp: Use the recommended OpenSSL functions See also https://github.com/net-snmp/net-snmp/issues/294 . commit 86231d18704a5560f217089a5c83a2bd9cfe2340 Author: Bart Van Assche Date: Sun Nov 28 21:09:08 2021 -0800 configure: Fix --disable-perl-cc-checks Instead of only skipping the PERLCC assignment, also skip the compiler compatibility check. See also https://sourceforge.net/p/net-snmp/bugs/2885/ . commit 5b9515d0c7281f52a327e0e8d1144725a706e794 Author: minfrin Date: Tue Jan 5 23:17:14 2021 +0000 Add support for digests detected from ECC certificates Previously, the digest could be detected on RSA certificates only. This patch adds detection for ECC certificates. [ bvanassche: changed _htmap2 into a two-dimensional array and renamed _htmap2 back to _htmap ] commit f720ee7aed1ec26501db384d32bc8a29bb0f43d9 Author: Bart Van Assche Date: Tue Nov 9 21:15:37 2021 -0800 configure: #include before testing select() This should improve the detection of the type of the fifth argument of select() on Solaris. commit 1a560274d0f440d5c604c36b2c32b36e2a3d9a28 Author: David Korczynski Date: Sat Nov 6 00:18:56 2021 +0000 libsnmp: Fix stack-based buffer underflow Ensure `strlen(defbuf)` is above zero before the code `defbuf[strlen(defbuf) - 1] = 0;` Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40699 Signed-off-by: David Korczynski commit d26d9e4570e3c2a441c1fd700df5e8134c3ecd17 Author: Wes Hardaker Date: Tue Nov 9 07:52:32 2021 -0800 patch from Charles Polisher to fix the if syntax commit 17a1691b66b96ed7b5b863621966871bc66047e3 Author: Bart Van Assche Date: Wed Oct 27 21:04:21 2021 -0700 libsnmp: Unbreak the build if OpenSSL support is disabled Fixes: 9d7b9669a577 ("snmpd: Fix memory leaks in USM and DH algorithms") commit a4932f7987efc213ccb152d5d307111c49b63f17 Author: Bart Van Assche Date: Wed Oct 27 19:51:06 2021 -0700 ci: Also run the build-and-test action on pull requests commit 4fcb0b77c12936d63f462c936e31b02fed8efa59 Author: Bart Van Assche Date: Sun Oct 17 13:14:32 2021 -0700 RMON-MIB: Fix two compiler warnings commit fb361fd42247802c738885e026ceb22992cdf9cb Author: Bart Van Assche Date: Sun Oct 17 13:12:43 2021 -0700 libsnmp: Use tolower() directly From the ANSI C standard (1998): "If the argument is a character for which isupper is true and there are one or more corresponding characters, as specified by the current locale, for which islower is true, the tolower function returns one of the corresponding characters (always the same one for any giv en locale); otherwise, the argument is returned unchanged." Hence use tolower() directly. commit d0891c58f94520d302246534fcd97e41ec3f950f Author: David Korczynski Date: Thu Oct 14 11:37:13 2021 +0100 snmpd: Fix memory allocation Ensure memory allocation of more than 1 byte in case asp->vbcount is 0 Further clarification of this is found here: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39901#c1 This also fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39930 Signed-off-by: David Korczynski commit e49f81d24299f5196ac06b74ff54595f4fb7ed55 Author: Bart Van Assche Date: Wed Oct 13 20:05:48 2021 -0700 libsnmp: Fix a compiler warning Fix the following compiler warning: transports/snmpTLSBaseDomain.c: In function ‘_openssl_log_error’: transports/snmpTLSBaseDomain.c:1194:9: warning: ‘%s’ directive argument is null [-Wformat-overflow=] 1194 | snmp_log(LOG_ERR, "%s (file %s, func %s, line %d)\n", | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1195 | ERR_error_string(numerical_reason, NULL), file, func, line); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fixes: b4ec52560170 ("libsnmp: Port to OpenSSL 1.1.1e") commit e8c5d07a501d1473db5c9ef90d695e2782f88708 Author: Bart Van Assche Date: Wed Oct 13 19:57:08 2021 -0700 libsnmp: Only include if it is available See also commit 9d7b9669a577 ("snmpd: Fix memory leaks in USM and DH algorithms"). commit 9d7b9669a57757ba1b01d67cc0658b04002698be Author: EZenderink Date: Mon Sep 27 14:14:55 2021 +0200 snmpd: Fix memory leaks in USM and DH algorithms [ bvanassche: made small additional changes and edited the patch description ] commit 16be05e0cad51bd5b0e905066ea2092e574377fd Author: lukas-wimmer <66684408+lukas-wimmer@users.noreply.github.com> Date: Mon Oct 4 13:14:23 2021 +0200 libsnmp: Fix an openssl error ring segmentation fault Fixes: e498db9f886c ("CHANGES: moved transport code into a separate subdirectory in snmplib") [ bvanassche: combined two patches into one / edited patch description ] commit 167f3116cd552e71c4a746f3c63ddb710ec05332 Author: Bart Van Assche Date: Sun Oct 3 17:35:03 2021 -0700 SNMP-NOTIFICATION-MIB: Fix a crash during shutdown This patch fixes the following Valgrind complaint: Invalid read of size 8 at 0x4CBE442: CONTAINER_CLEAR (container.c:505) by 0x49FCE63: _container_free (snmpNotifyFilterTable_interface.c:1882) by 0x49FCE63: _snmpNotifyFilterTable_container_shutdown (snmpNotifyFilterTable_interface.c:1939) by 0x49FCE63: _snmpNotifyFilterTable_shutdown_interface (snmpNotifyFilterTable_interface.c:410) by 0x49D2E4D: shutdown_table_snmpNotifyFilterTable (snmpNotifyFilterTable.c:125) by 0x49D2E87: shutdown_snmpNotifyFilterTable (snmpNotifyFilterTable.c:72) by 0x4A33291: _shutdown_mib_modules (mib_module_shutdown.h:52) by 0x4C8931F: snmp_call_callbacks (callback.c:360) by 0x4C58CA5: snmp_shutdown (snmp_api.c:977) by 0x405203: main (snmpd.c:1087) Address 0x64c6730 is 208 bytes inside a block of size 224 free'd at 0x484317B: free (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so) by 0x4CBFC80: netsnmp_binary_array_release (container_binary_array.c:205) by 0x4CBFD87: _ba_free (container_binary_array.c:690) by 0x4CBE316: CONTAINER_FREE (container.c:484) by 0x49D2125: shutdown_snmpNotifyFilterTable_data_storage (snmpNotifyFilterTable_data_storage.c:89) by 0x4A33287: _shutdown_mib_modules (mib_module_shutdown.h:51) by 0x4C8931F: snmp_call_callbacks (callback.c:360) by 0x4C58CA5: snmp_shutdown (snmp_api.c:977) by 0x405203: main (snmpd.c:1087) Block was alloc'd at at 0x48455EF: calloc (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so) by 0x4CBEACD: netsnmp_container_get_binary_array (container_binary_array.c:797) by 0x4CBDC12: netsnmp_container_find (container.c:302) by 0x49D2071: snmpNotifyFilter_storage_container_create (snmpNotifyFilterTable_data_storage.c:58) by 0x49D20F3: init_snmpNotifyFilterTable_data_storage (snmpNotifyFilterTable_data_storage.c:75) by 0x4A3457B: init_mib_modules (mib_module_inits.h:141) by 0x404F89: main (snmpd.c:904) commit 1035c405bfd69dac7d09533d3d43608af732c655 Author: Bart Van Assche Date: Sun Oct 3 12:15:52 2021 -0700 mibs: Declare netsnmp_fsys_info pointers that are not modified const This patch does not change any functionality. commit 6db7d2ca701c54d08e7c959011af254e5f193883 Author: Bart Van Assche Date: Sun Oct 3 12:15:47 2021 -0700 fsys: Remove two superfluous assignments Null-terminating of the output argument of strlcpy() is not necessary since strlcpy() guarantees null-termination. commit 2740eaee234104d6abae132f933ef381976862fe Author: Bart Van Assche Date: Sun Sep 19 15:46:33 2021 -0700 perl: Leave out -Wimplicit-fallthrough Leave out this compiler flag since it is not supported by older versions of gcc. commit 19e75743173cb8d49d49fd685b8e0249e83cc820 Author: Bart Van Assche Date: Wed Sep 8 20:39:42 2021 -0700 libsnmp: Fix the build against OpenSSL 3.0 Fixes: https://github.com/net-snmp/net-snmp/issues/343 commit 1672d705202e0f758133707b3a291319bebfdc66 Author: Bart Van Assche Date: Tue Sep 7 20:07:42 2021 -0700 SNMP-NOTIFICATION-MIB: Fix filter lookup The notification filter information is stored in one container but during filtering, a different container is being used to look for matching filters. Change agent/mibgroup/snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_data_storage.h and agent/mibgroup/snmp-notification-mib/snmpNotifyFilterTable/snmpNotifyFilterTable_data_access.c to expose the data_storage method that creates the container (used when actual filtering) so that this method can be used when creating the container used to store the notification filters. Fixes: https://github.com/net-snmp/net-snmp/issues/342 commit 64a88cc2fdd3e6f4cb7a66d4c2846da97112494e Author: Bart Van Assche Date: Tue Sep 7 20:29:51 2021 -0700 libsnmp: Provide a default value for netsnmp_container.ncompare Fixes: https://github.com/net-snmp/net-snmp/issues/342 commit 94ca941e06bef157bf0e13251f8ca1471daa9393 Author: Kaarle Ritvanen Date: Fri Aug 27 14:21:45 2021 +0300 snmpd: always exit after displaying usage Currently, viewing the help text with -h results in snmpd being started in the background, whereas this does not happen with --help. Similarly, when an error is detected in command line syntax, the help text is displayed but sometimes snmpd gets started anyway, depending on the execution path. This patch makes snmpd consistently terminate whenever the usage function gets called. It also removes the goto statements no longer needed. commit 7330e3e3e08d9baff23332e764f9a53561939fff Author: Bart Van Assche Date: Thu Sep 2 21:06:54 2021 -0700 libsnmp: Log "Truncating integer value >32 bits" once Log this message once instead of every time sysUpTime and/or hrSystemUptime are accessed after snmpd is running for more than 497 days. Fixes: https://github.com/net-snmp/net-snmp/issues/144 commit d7be3dd3329182c178975b3f005c17bb363baca2 Author: Bart Van Assche Date: Tue Aug 31 17:05:19 2021 -0700 ci/openssl.bat: Bump the OpenSSL version commit 3d9111050a9b5f72797700d84dc0c1cfb4bd3388 Author: Bart Van Assche Date: Tue Aug 31 16:08:36 2021 -0700 ci/net-snmp-configure: Make this script again compatible with Darwin commit a64fbaaa0e08d29e140014f6f51f338558d503c8 Author: Bart Van Assche Date: Tue Aug 31 15:46:24 2021 -0700 libsnmp: Use asprintf() instead of open-coding it commit 6090fbed3feea13c635348d67d6be6583b209bc6 Author: Bart Van Assche Date: Tue Aug 31 15:45:25 2021 -0700 libsnmp: Clear freed pointers commit 6506da8d78e9f53be7fda393deeb4eb0e321e4e1 Author: Bart Van Assche Date: Mon Aug 30 15:56:26 2021 -0700 libsnmp: Return early from alloc_node() if memory allocation fails commit ae0cea08e45427ce4e607538e1abf79a304bbca9 Author: Bart Van Assche Date: Mon Aug 30 15:49:58 2021 -0700 libsnmp: Simplify free_node() Remove the if-tests since free() accepts a NULL pointer. Remove a (char *) cast since free() accepts an argument of type void *. commit 19ac11e17903aeb8afb64a15ca1a3584c97c54c3 Author: Niels Baggesen Date: Mon Aug 30 22:18:06 2021 +0200 Fix a spurious warning when running tests commit fdd0ab46b1fb84e4bcc188eca8e2cc5c6075e858 Author: Niels Baggesen Date: Mon Aug 30 22:07:54 2021 +0200 Fix build for NetBSD by adding kernel_netbsd commit 36168dc6a338c6fce2c02e76947b748fb74cc5ef Author: Niels Baggesen Date: Mon Aug 30 22:06:38 2021 +0200 apps/Makefile.in: add mysql libs to snmåptrapd link commit b7bd3636123497b908bf78d64aba229831ccfab2 Author: Niels Baggesen Date: Mon Aug 30 22:01:41 2021 +0200 mibs: updated IANAifType-MIB, IANA-ADDRESS-FAMILY-NUMBERS-MIB commit c3ac5ac59bd8f40aec6d383208a7cd0d52a868f6 Author: Bart Van Assche Date: Sun Aug 29 17:33:44 2021 -0700 apps/snmppcap: Do not cast away constness commit 00901cf770855826f187db76f27258e646c6fd2d Author: Bart Van Assche Date: Sun Aug 29 12:23:11 2021 -0700 ci/net-snmp-configure: Refine when to enable embedded Perl Only enable embedded Perl if Net-SNMP and the Perl interpreter are built with the same compiler type. If different compilers are used and if embedded Perl is enabled, the configure script reports the following: configure: error: This build is using a GNU C compiler (clang) while Perl has been compiled with a non-GNU (or non-working) compiler (x86_64-linux-gnu-gcc). This likely won't work for building with Perl support. Either specify a different compiler (--with-cc=PATH), disable this check (--disable-perl-cc-checks) or build without Perl (--without-perl-modules). commit b9308221b1d0c1f77c8b2511e196376dc2870211 Author: Bart Van Assche Date: Sun Aug 29 09:25:06 2021 -0700 libsnmp: Fix more undefined behavior in asn_build_int() According to the C standard, triggering an overflow by shifting a signed integer left results in undefined behavior. Fix this by inserting a cast. Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=37808 commit 416705ce8abf2d33f693d057d77aa5bc1b0fb364 Author: Bart Van Assche Date: Sat Aug 28 17:17:35 2021 -0700 ci: Disable the Python tests because these fail sporadically commit c21ad2b5b3b48d68b6973c1d768042e5417e92e0 Author: Bart Van Assche Date: Sat Aug 28 16:14:29 2021 -0700 ci/net-snmp-configure: Improve this script Introduce functions for retrieving the version of a software package. Reenable the DISMAN expression MIB. Use the recommended approach to pass $CFLAGS, $CPPFLAGS and $LDFLAGS to the configure script. commit 9fca293b2de46d3a734cd3d6e68611de6ac207a5 Author: Bart Van Assche Date: Fri Aug 27 10:33:46 2021 -0700 snmpd, IP-MIB, UCD-MIB: Remove superfluous string termination code Since snprintf(buf, sizeof(buf), ...) guarantees that the string written into `buf` is '\0' terminated if sizeof(buf) >= 1, remove the following statement if it occurs just past such a snprintf() statement: buf[sizeof(buf) - 1] = '\0'; See also https://pubs.opengroup.org/onlinepubs/009695399/functions/fprintf.html. commit 277d75633d8008cde468d026694289ca32f2cb6d Author: Bart Van Assche Date: Thu Aug 26 10:17:11 2021 -0700 libsnmp: Fix undefined behavior in asn_build_int() According to the C standard, triggering an overflow by shifting a signed integer results in undefined behavior. Fix this by inserting a cast. Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=37579 commit d700c957f991912a63b9637720b716f6cf8696fd Author: Bart Van Assche Date: Thu Aug 26 10:14:31 2021 -0700 libsnmp: Fix a comment in asn_build_int() commit 85bff70932178ccd08b55112cadcb0e1bedb909d Author: EZenderink <55834436+EZenderink@users.noreply.github.com> Date: Wed Aug 18 17:27:01 2021 +0200 IF-MIB: Fix deprecated retrans_time syscall warning (and base_reachable_time) Remove the check which retrans_time and base_reachable_time interface is available from `netsnmp_arch_interface_init`, which uses the "default" network interface to determine which is available, but this network interface is not always available (e.g. network namespaces). Determine at runtime which procfs file to read. [ bvanassche: Reformatted commit message and edited patch ] commit 9a0cd7c00947d5e1c6ceb54558d454f87c3b8341 Author: Bill Fenner Date: Tue Aug 24 07:55:00 2021 -0700 CHANGES: snmpd: recover SET status from delegated request Reported by: Yu Zhang of VARAS@IIE, Nanyu Zhong of VARAS@IIE Fixes by: Arista Networks When a SET request includes a mix of delegated and non-delegated requests (e.g., objects handled by master agent and agentx sub-agent), the status can get lost while waiting for the reply from the sub-agent. Recover the status into the session from the requests even if it has already been processed. commit 67ebb43e9038b2dae6e74ae8838b36fcc10fc937 Author: Bill Fenner Date: Wed Jun 30 14:00:28 2021 -0700 CHANGES: snmpd: fix bounds checking in NET-SNMP-AGENT-MIB, NET-SNMP-VACM-MIB, SNMP-VIEW-BASED-ACM-MIB, SNMP-USER-BASED-SM-MIB Reported by: Yu Zhang of VARAS@IIE, Nanyu Zhong of VARAS@IIE Fixes by: Arista Networks commit 557fdffef0a9a8e1085bb84e613d7176180fff0b Author: Bill Fenner Date: Wed Jun 30 13:57:55 2021 -0700 snmppcap: add the ability to process packets like the agent commit 57ce1fb360db21e43b6ade25540a4080d68d5469 Author: Bart Van Assche Date: Sun Aug 22 20:23:13 2021 -0700 HOST-MIB: Remove four global variables Global variables make code harder to maintain than necessary. Hence remove four global variables from the HOST-MIB implementation. commit d48428f47834c01e611b45df912941ad70d4f086 Author: Bart Van Assche Date: Sun Aug 22 20:22:51 2021 -0700 HOST-MIB: Reindent two functions Reindent two functions before modifying these. commit 6889d8af5830c1b4b017b9d43bbaf88e3b4cbf46 Author: Bart Van Assche Date: Sun Aug 22 14:36:26 2021 -0700 include/net-snmp/agent/hardware/fsys.h: Remove nonexistant functions Since neither netsnmp_fsys_get_byIdx() nor netsnmp_fsys_get_next_byIdx() are defined inside the Net-SNMP codebase, remove their declarations. commit 24c519bf899b92049e19d84293929d0253cfb9e8 Author: Bart Van Assche Date: Fri Aug 20 15:36:45 2021 -0700 HOST-MIB: Do not store NULL pointers in _fsys_container If malloc() fails, return immediately instead of storing a NULL pointer in _fsys_container. commit 5dd3b37a9d2fa02851cb989b51cf76272ab0bc1d Author: Bart Van Assche Date: Tue Aug 17 17:23:21 2021 -0700 net-snmp-configure: Respect the $CFLAGS environment variable commit 89a7860829fdc618efa223f9fc0549a9a122fcb3 Author: Bart Van Assche Date: Thu Aug 19 16:30:26 2021 -0700 IP-MIB: Fix the --disable-ipv6 build Fixes: https://github.com/net-snmp/net-snmp/issues/202 commit 50e36447179140fefddb957bbf9fc6aca7a81d39 Author: Bart Van Assche Date: Thu Aug 19 20:04:00 2021 -0700 IF-MIB: Add more comments commit d2822f221afbec9101b7926b88a95b235490f9d7 Author: Bart Van Assche Date: Tue Aug 17 09:05:46 2021 -0700 ci/build.sh: Show the $CC compiler path if $CC has been set commit 44db9e673687aa9455b969aea218f218ba4e688b Author: Bart Van Assche Date: Mon Aug 16 21:55:21 2021 -0700 ci/net-snmp-run-tests: Do not rerun configure commit faf345430c4fa23b7aa937b8848eaae9339914f2 Author: Bart Van Assche Date: Mon Aug 16 20:19:34 2021 -0700 ci/install.sh: Install pkg-config commit abbb0db992dd6a7278d93e144fcd599e9b706396 Author: Bart Van Assche Date: Mon Aug 16 19:25:11 2021 -0700 configure: Add LIBNLROUTE3_CFLAGS to the compiler flags commit 34fe22233a99774673fd0c1738ad8f0ca48fd349 Author: Bart Van Assche Date: Mon Aug 16 18:42:50 2021 -0700 ci/install.sh: Also install 'make' commit b7fd1d6fd872ca8379e8f63c51682043708b47fc Author: Bart Van Assche Date: Mon Aug 16 18:40:30 2021 -0700 ci: Move 'sudo' out of ci/install.sh This makes it possible to use the install script inside Docker containers that do not support 'sudo'. commit f0b896767ac2b2452162d4c4e03824fa6fd2d597 Author: Bart Van Assche Date: Mon Aug 16 09:11:09 2021 -0700 ci: Rename before.sh into setup.sh The new name better reflects the purpose of this script. commit 5bf51b1798c9c707c18db25d9e95c30b2852835b Author: Bart Van Assche Date: Mon Aug 16 09:15:34 2021 -0700 ci: Add v5.9 branch to github workflow triggers commit 01d10ab33b39988dbe659fe7903eaf132d39f1ef Author: Bart Van Assche Date: Mon Aug 16 09:13:34 2021 -0700 ci: Copy github workflow from master branch commit 3a6a246260243f320a53ab57bba31086467e39e9 Author: Bart Van Assche Date: Mon Aug 16 08:57:33 2021 -0700 ci/before.sh: Add libnl-route-3-dev commit d80419d7f9bcc9c982b166fa2a9ed53daaaf48b6 Author: Bart Van Assche Date: Sun Aug 1 21:28:45 2021 -0700 IF-MIB: Split netsnmp_access_interface_ioctl_flags_get() This patch does not change any functionality. commit a688adf2d8ef6622e1d57011566b06431b90152e Author: Bart Van Assche Date: Sun Aug 1 20:23:58 2021 -0700 IF-MIB: Introduce netsnmp_convert_arphrd_type() This patch does not change any functionality. commit be78525370b26218a385d220f17e66ca3d8724b2 Author: Bart Van Assche Date: Sun Aug 1 13:38:24 2021 -0700 IF-MIB: Introduce netsnmp_derive_interface_id() This patch does not change any functionality. commit 8609bd42cdcbdea0bc52f8619f1338a7ed8537a5 Author: Bart Van Assche Date: Sun Aug 1 13:32:09 2021 -0700 IF-MIB: Introduce the function netsnmp_guess_interface_type() This patch does not change any functionality. commit 7aff0c50f6cdeeee626b8cc80f619ab53ee4cdd0 Author: Bart Van Assche Date: Sun Aug 1 13:34:38 2021 -0700 IF-MIB: Remove dead code The preprocessor macro APPLIED_PATCH_836390 is not defined. Hence remove the code guarded by that macro. commit 971cae99db5ba9bf926f70c98dd139fbf7ec9dbd Author: Bart Van Assche Date: Sun Aug 15 12:19:48 2021 -0700 ci: Also install the libkrb5-dev and libncurses-dev packages commit 8872b39470509896a05c38bf35cf4ffafbaeacb0 Author: Bart Van Assche Date: Sat Aug 14 20:26:45 2021 -0700 ci/before.sh: Improve this script Add option -qq to apt-get to make it less noisy. Install libpcre3-dev. Do not yet install libkrb5-dev because support for libkrb5 in the configure script is broken. commit 3a2d729f6c6b36794379621a9e1f6964489444ce Author: Bart Van Assche Date: Sat Aug 14 20:11:05 2021 -0700 configure: Run autoconf commit 08d6868cc9d0785e861bc0670af3f9ec90fd64f4 Author: Bart Van Assche Date: Sat Aug 14 11:14:13 2021 -0700 testing: Add a read_mib() unit test commit c26ee3631ad964c3bfaf232efeb6f10bb89eead6 Author: Bart Van Assche Date: Sat Aug 14 11:37:32 2021 -0700 testing: Improve unit test T026read_config_clib.c Improve the messages that are reported while running this unit test. Remove the file created by this test. commit b3353512d8e4c7dc26a0e37bb08c7089df2ee40f Author: Bart Van Assche Date: Mon Aug 9 16:28:58 2021 -0700 testing: Add a read_config() unit test commit 7e6b198840404294014fb0553dae25a5705bab1e Author: Bart Van Assche Date: Mon Aug 9 17:08:09 2021 -0700 libsnmp: Add more netsnmp_assert() statements commit 413b17eecd6af8e8247501805b5a366b709828bf Author: Bart Van Assche Date: Mon Aug 9 14:07:20 2021 -0700 libsnmp: Fix the getoid() error path Fixes: d0277ca1ccd6 ("libsnmp: Fix a memory leak in a MIB parser error path") commit 2cd0e7d72a76ba27a18315b9ae67e6ed6d2c464a Author: Bart Van Assche Date: Mon Aug 9 13:38:36 2021 -0700 IF-MIB: Add a trailing newline to an error message Fixes: 8bb544fbd2d6 ("Linux: IF-MIB: Fix a memory leak") commit 5ecd04c215f0cbe416434cb5ee0e36ec81a3a63f Author: Bart Van Assche Date: Sat Aug 7 11:23:30 2021 -0700 libsnmp: Fix a read-past-end-of-buffer Prevent that the code 'cp2 = cp + 1; *cp2' reads past the end of the input buffer if the input buffer consists of one double quote. This patch should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36874. commit 359729bf94950df6e8a541570151683b0d5475ab Author: Bart Van Assche Date: Sat Aug 7 10:58:15 2021 -0700 libsnmp, cert_util: Fix a memory leak in an error path This leak was detected by Coverity. See also CID 372223. commit 42fe5ee281beba9793017018aa200a5183a8671e Author: Bart Van Assche Date: Sat Aug 7 10:55:40 2021 -0700 IP-MIB: Fix a use-after-free in an error path See also Coverity report 372225. commit d0277ca1ccd6ec8d786355a433717a9dbf41112e Author: Bart Van Assche Date: Sat Aug 7 08:32:03 2021 -0700 libsnmp: Fix a memory leak in a MIB parser error path This patch should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36879. commit 20683e974b0cbacb4c2dbdc5d84d2b831f61b5db Author: Bart Van Assche Date: Sat Aug 7 08:25:51 2021 -0700 libsnmp: Remove a superfluous declaration commit 776ca4f9c9f599172dc83e488f5b603692319957 Author: Bart Van Assche Date: Fri Aug 6 20:16:32 2021 -0700 libsnmp: Include from This patch fixes a build issue on Alpine Linux. commit cf3a6c18b8fb0d558ce57bf19d13634ab7b31ea8 Author: Bart Van Assche Date: Fri Aug 6 19:38:23 2021 -0700 libsnmp/sd-daemon.c: Fix the Alpine Linux build commit 6fd24f2c42fbde05960759db03f2bca99071dcb2 Author: Bart Van Assche Date: Fri Aug 6 19:38:18 2021 -0700 DISMAN-MIB: Fix a compiler warning commit 2e9779aff0d18d891ffe5d77d8335798f80e29ca Author: Bart Van Assche Date: Thu Aug 5 21:09:04 2021 -0700 DISMAN-MIB: Fix the build on Alpine Linux commit 92ded667923c1efdb1c529d2cbed7f2a26485e8f Author: Bart Van Assche Date: Thu Aug 5 21:10:53 2021 -0700 DISMAN-MIB: Fix the build on Alpine Linux Include for the definition of HZ. commit f561a1f7149c677309beea720019f3e4e20a5ecf Author: Bart Van Assche Date: Thu Aug 5 21:09:33 2021 -0700 DISMAN-MIB: Include instead of commit ddc807b3407d1f2f86b6796f8698be4ea2a4c8e2 Author: Bart Van Assche Date: Thu Aug 5 21:07:47 2021 -0700 DISMAN-MIB: Include instead of According to POSIX should be included. commit 32f7cff5e30da41eed709544eab6deeb020e3540 Author: Bart Van Assche Date: Thu Aug 5 19:20:24 2021 -0700 libsnmp: Remove two casts from node_to_oid() This patch does not change any functionality. commit b3e032934ffd748b9d51716590c25aa6dcf90b33 Author: Bart Van Assche Date: Thu Aug 5 18:47:16 2021 -0700 HOST-RESOURCES-MIB: Add a trailing newline in a log message commit eadccb50810a1898288d29c768544fbd93b68c66 Author: Bart Van Assche Date: Thu Aug 5 19:11:46 2021 -0700 IF-MIB: Fix memory leaks in error paths Do not leak 'addr_container' if returning early. commit d4b58c60367a262d829eb33e7888d28cd4337481 Author: Bart Van Assche Date: Thu Aug 5 18:56:50 2021 -0700 IF-MIB: Fix a recently introduced use-after-free Do not free the netsnmp_interface_entry corresponding to the previous line from /proc/dev/net if an interface disappeared. Additionally, reduce the scope of the 'entry' variable. Fixes: 600c54135b10 ("IF-MIB, IP-FORWARD-MIB: Improve robustness") commit 74a51bc9e36cbfe96ffbf00ba20bbeea33a76cac Author: Bart Van Assche Date: Thu Aug 5 18:58:44 2021 -0700 IF-MIB: Fix source code indentation commit ba1d664f1712f5f90a6c74c1f62604787e5c0ea4 Author: Bart Van Assche Date: Thu Aug 5 18:44:02 2021 -0700 libsnmp: Disable the binary array consistency checks Disable the consistency checks added by the previous commit since the test these were intended for has completed. See also https://github.com/net-snmp/net-snmp/issues/107 . commit 1660027cf1d2b3068f05d3575fc5604766e1ade0 Author: Bart Van Assche Date: Wed Aug 4 20:03:43 2021 -0700 libsnmp: Verify container properties at runtime commit 1e2fd7a932503a43905df973630f013a6e5977e6 Author: Bart Van Assche Date: Wed Aug 4 19:50:15 2021 -0700 libsnmp: Improve the code for inserting in a binary array Only search for duplicates if duplicates are allowed. Fix a bug in the code for detecting duplicates: also skip duplicates if the first element matches (i == 0). commit 359bde7a04b84054029e21cbc9e6d84d42635659 Author: Bart Van Assche Date: Tue Aug 3 21:40:22 2021 -0700 testing: Improve the T012binary_array_oid unit test commit f85e82772565c76a71b683508d0cf49937d93fad Author: Bart Van Assche Date: Tue Aug 3 20:17:23 2021 -0700 IF-MIB: Remove a superfluous cast commit c125de54d1de991560bbbc19b0834c78f6390201 Author: Bart Van Assche Date: Tue Aug 3 20:12:46 2021 -0700 IF-MIB: Add an assert() statement commit 5fce79b8cafb5b9c56ce6ac9dd8b788a25c9b608 Author: Bart Van Assche Date: Tue Aug 3 21:22:11 2021 -0700 libsnmp: Fix the duplicate check in netsnmp_binary_array_insert() commit f1a8f8545a9d9a370487c196db230d5bc8f1adae Author: Bart Van Assche Date: Tue Aug 3 21:20:33 2021 -0700 libsnmp: Fix a bounds check in netsnmp_binary_array_insert_before() commit f205b3b285841328e81bb2cc62128b013b118162 Author: Bart Van Assche Date: Tue Aug 3 20:50:47 2021 -0700 libsnmp: Simplify the binary array linear search code commit e289bbe323543a912fafcb6d77cee761a4df88a8 Author: Bart Van Assche Date: Tue Aug 3 20:41:32 2021 -0700 libsnmp: Use qsort() instead of open-coding it commit 09975fff4c73ef288e772f883b4cb592287169ea Author: Bart Van Assche Date: Tue Aug 3 20:31:29 2021 -0700 libsnmp: Document and simplify netsnmp_binary_array_options_set() commit e46b9a126be956cdf372546fa0477694c1ae538a Author: Bart Van Assche Date: Tue Aug 3 19:39:44 2021 -0700 libsnmp: Fix the linked list _get() function If looking for an exact match in a sorted list, return NULL instead of the next element if there is no exact match. Additionally, inverse the polarity of the third argument of this function. Note: I'm not aware of any code inside the Net-SNMP project that is affected by this change. commit 5067b47e6cf0e9f041774bca2cbd3218d9bbd47d Author: Bart Van Assche Date: Mon Aug 2 20:28:58 2021 -0700 ci: Enable the MacOS build Leave the tests disabled since these do not yet pass. commit a137fe6bd3eba4ecf477e1ee25cd5b78c2330a63 Author: Bart Van Assche Date: Mon Aug 2 20:06:52 2021 -0700 ci: Disable Ubuntu2004 commit 600c54135b1015d56070f702d878772dd9f0d51e Author: Bart Van Assche Date: Mon Aug 2 19:04:31 2021 -0700 IF-MIB, IP-FORWARD-MIB: Improve robustness It can happen that a network interface disappears after scanning has started and before netsnmp_arch_interface_index_find() or another query function is called. If that happens, ignore the network interface silently. commit 52d4e67b4162dbd5d5d18ab5f3e550074d3e67b8 Author: Bart Van Assche Date: Mon Aug 2 19:14:20 2021 -0700 IF-MIB: Do not log ioctl() failures The most common cause for the "ioctl %d returned -1" error message is that the network interface disappeared. Since this is quite common on systems that run e.g. Docker, do not log an error message in case an ioctl() failed for a network interface. commit a9a140d2a550c3090845069955d45b75b4ad2a15 Author: Bart Van Assche Date: Mon Aug 2 19:35:51 2021 -0700 IF-MIB: Fix spelling in a debug message commit 8970ada022dbbcd2724cda315048eb15b0dda4aa Author: Bart Van Assche Date: Sun Aug 1 20:35:55 2021 -0700 configure: Run autoreconf Fixes: 6da5defc5369 ("configure: Only add -lpcre if --with_pcre != no") commit 585ac1c81e3ea4816c7bd7e8ed52060fcb3b4e90 Author: Bart Van Assche Date: Sat Jul 31 20:43:02 2021 -0700 IF-MIB: Make _add_new_interface() easier to read This patch does not change any functionality. commit cc234ac171cbd5e926c460e5e7c3d1f5ccb1d94d Author: Bart Van Assche Date: Sat Jul 31 19:18:46 2021 -0700 IF-MIB: Simplify ifTable_index_to_oid() Instead of storing the interface index in an SNMP variable and converting that variable into an OID, convert the interface index directly into an OID. This patch does not change any functionality. commit 31a59fd008220ddd417ba18a5653a1b11ffbddcf Author: Bart Van Assche Date: Sat Jul 31 19:08:42 2021 -0700 IF-MIB: Inline ifTable_indexes_set_tbl_idx() Inline this function since it is short and since it only has one caller. commit 8bb544fbd2d6986a9b73d3fab49235a4baa96c23 Author: Bart Van Assche Date: Sat Jul 31 16:21:16 2021 -0700 Linux: IF-MIB: Fix a memory leak The Linux kernel regenerates proc files in their entirety every time a 4 KiB boundary is crossed. This can result in reading the same network interface twice if network information changes while it is being read. Fix a memory leak that can be triggered if /proc/net/dev changes while being read. commit 8da919e4ad66dec376f54a6d2f7dd7a7fe68b8f0 Author: Bart Van Assche Date: Sat Jul 31 16:01:11 2021 -0700 Linux: IF-MIB: Pass the network interface index to netsnmp_access_interface_entry_create() Instead of letting netsnmp_access_interface_entry_create() call netsnmp_arch_interface_index_find() a second time, pass the network interface index to that function. commit 55c68cacb7e84403f3c46c7ff4bd399ab9e87149 Author: Bart Van Assche Date: Sat Jul 31 10:25:47 2021 -0700 CHANGES: IF-MIB: Update ifTable entries even if the interface name has changed At least on Linux a network interface index may be reused for a network interface with a different name. Hence this patch that enables replacing network interface information even if the network interface name has changed. commit 2c963cd43b7ddb86dd6d1407e60fdbaf984d22f4 Author: Bart Van Assche Date: Sat Jul 31 14:29:31 2021 -0700 IF-MIB: Inline two functions Since the ifTable_rowreq_ctx_init() and ifTable_rowreq_ctx_cleanup() implementations are short and since both functions only have one caller, inline these functions. commit eecec3182ff3ded6603ca3c08685badde5675fdd Author: Bart Van Assche Date: Sat Jul 31 13:59:12 2021 -0700 IF-MIB: Add an assert statement commit 07819e00660b3382c5464db49a85d5fbd188da23 Author: Bart Van Assche Date: Sat Jul 31 12:09:06 2021 -0700 IF-MIB: Improve type safety commit 8ce7e6adad5a51294d139f5b8fb4a8aabe0329f8 Author: Bart Van Assche Date: Sat Jul 31 13:59:21 2021 -0700 IF-MIB: Make the ifTable_row_find_by_mib_index() code shorter This patch does not change any functionality. commit 2ad4be5703e73e53e715de26e96bea1cb9a259ae Author: Bart Van Assche Date: Sat Jul 31 10:31:06 2021 -0700 IF-MIB: Simplify netsnmp_access_interface_entry_free() Passing NULL to free() is allowed. Hence change if (x) free (x) into free(x). commit f1781a422aedf8a94af120d6a1262e2637192f1e Author: Bart Van Assche Date: Sat Jul 31 10:27:57 2021 -0700 IF-MIB: Simplify the netsnmp_access_interface_entry_copy() implementation This patch does not change any functionality. commit 0a0a9bd3c3abd991a6e980c97e2a984f4af0b025 Author: Bart Van Assche Date: Sat Jul 31 10:24:19 2021 -0700 IF-MIB: Remove a superfluous cast commit 7d33deab54da5ff54585f7d870fa0bd82606babb Author: Bart Van Assche Date: Sat Jul 31 13:12:33 2021 -0700 libsnmp: Declare more counter64 input arguments 'const' commit 9cf1f56fbda6410c290a932a0757e172598c6aa9 Author: Bart Van Assche Date: Sat Jul 24 19:40:54 2021 -0700 IF-MIB: Remove four function pointer casts This patch does not change any functionality. commit 280bf2b6eb870a1076105525e3a74f931431506f Author: Bart Van Assche Date: Sat Jul 24 19:59:52 2021 -0700 IF-MIB: Make _ifTable_initialize_interface() easier to read This patch does not change any functionality. commit 402bf358b8d8b8090525045960a0dd814a3b9c03 Author: Bart Van Assche Date: Sun Jul 25 17:20:37 2021 -0700 IF-MIB: Improve _check_interface_entry_for_updates() documentation Additionally, improve coding style conformance of _check_interface_entry_for_updates(). commit a34a5f277bbcc6b994583df383ffc573ae5188f7 Author: Bart Van Assche Date: Sun Jul 25 13:35:18 2021 -0700 IF-MIB: Improve ifTable_container_load() documentation commit 9d8bc4790f231a0a172de41299c9d142a8aeadbb Author: Bart Van Assche Date: Sat Jul 24 20:24:44 2021 -0700 IF-MIB: Remove the cd_container typedef Make it explicit that cd_container is a struct by removing the typedef for that data structure. commit 95264228088eeda47e0ede41945854404f11d78a Author: Bart Van Assche Date: Sat Jul 24 21:14:50 2021 -0700 IF-MIB: Insert a blank line in the source code commit fa240e457deddfb966e7df278b8a6e0789be0fef Author: Bart Van Assche Date: Sun Jul 25 19:32:31 2021 -0700 libsnmp, container_list_ssll: Simplify netsnmp_container_ssll_init() This patch does not change any functionality. commit 94f5ba19434b9ed05786b4e8f2e485dbdfc220b1 Author: Bart Van Assche Date: Sun Jul 25 19:35:12 2021 -0700 libsnmp: Change the type of the factory 'produce' function This patch does not change any functionality. commit 87d45755edd101bb8943ce1f6f28ca1436caa425 Author: Bart Van Assche Date: Sat Jul 24 21:31:55 2021 -0700 libsnmp: Make factory.h a private header file This makes it possible to remove unused declarations from the factory.h header file. commit c6f144370f82d0f3e4f4360a30538b4ea97e1719 Author: Bart Van Assche Date: Sun Jul 25 13:12:54 2021 -0700 libsnmp: Document the purpose of netsnmp_container_find() commit 18bfcecc7cc79096c0a7e931bfbb51644c9e4aed Author: Bart Van Assche Date: Sun Jul 25 13:03:56 2021 -0700 libsnmp: Remove a cast This patch does not change any functionality. commit a6e88f17f30a283479bf2ff6db9cc5aac5d7bd34 Author: Bart Van Assche Date: Sun Jul 25 13:35:45 2021 -0700 treewide: Change 'invovles' into 'involves' commit 500d7638be37f3dfe3fbd525cd0ab12e6bf68208 Author: Bart Van Assche Date: Sat Jul 24 21:37:07 2021 -0700 treewide: Change 'allcoated' into 'allocated' commit 9f8d1b3bea2aa11ba4d0b53b18f6f42d8d978b96 Author: Bart Van Assche Date: Thu Apr 15 11:59:10 2021 -0700 UCD-SNMP-MIB: Remove the old disk implementation The old disk implementation has been superseded since 2011. Hence remove it. commit 6da5defc53697d4c342cf6193c92a55ee43d8abf Author: Bart Van Assche Date: Wed Jul 14 14:29:01 2021 -0700 configure: Only add -lpcre if --with_pcre != no Fixes: bbd53ed4a429 ("network pcre detection") commit e5ca544df5c98e92ca88b20ea59b2aff5d72b696 Author: Natanael Copa Date: Mon Jul 12 20:56:01 2021 +0200 MIBs: Use #ifdef instead of #if to test HAVE_* macros [ bvanassche: edited patch description ] commit f7acd99f64d08db935a81a605383655dade07966 Author: Natanael Copa Date: Mon Jul 12 20:49:03 2021 +0200 NET-SNMP-EXTEND-MIB: Fix set but not used compiler warning Fix the following error with -Werror: mibgroup/agent/extend.c:1590:25: error: variable 'exten' set but not used [-Werror=unused-but-set-variable] 1590 | netsnmp_old_extend *exten = NULL; | ^~~~~ [ bvanassche: modified patch description and modified patch ] commit 4b3711a9a058b1ed355e4469029dd022fd7d0681 Author: Natanael Copa Date: Mon Jul 12 20:29:45 2021 +0200 snmpd: Include for PATH_MAX Additionally, use #ifdef instead of #if to test whether a macro has been defined. [ bvanassche: edited patch description ] commit 51128ad095074488992982fa23ae641f7c7be4ae Author: Bart Van Assche Date: Sun Jul 11 14:40:56 2021 -0700 agent/Makefile.in: Build the MIB module code once Fixes: 91033077790c ("remake make's Makefile's to make better making") Signed-off-by: Srivalli231@github.com [bvanassche: added patch description] commit 9620e5926aba5ff4fc1d3c2e150778c772b7d3da Author: Sean Wei Date: Fri Jul 9 17:03:05 2021 +0800 mib2c-update: Fix some shellcheck warnings commit 35586b9fcabf3349cbff945e7f999a1f3cda4fce Author: Sean Wei Date: Fri Jul 9 16:44:29 2021 +0800 mib2c-update: Fix misbehavior when the path includes space commit 1e3f5bde3e13d1378579f26e14671ac6e8bcc87f Author: Bart Van Assche Date: Mon Jul 5 11:44:18 2021 -0700 IP-MIB: Improve ipAddressTable SIGHUP support _init_ipAddressTable() is called after the configuration has been read. Upon SIGHUP the configuration is reread and hence _init_ipAddressTable() is called again. Prevent that the following message is reported upon SIGHUP: duplicate registration: MIB modules ipAddressTable and ipAddressTable See also https://github.com/net-snmp/net-snmp/issues/312 . commit 829445d1478bc86f627d019e4debf6df00dc9786 Author: Bart Van Assche Date: Mon Jul 5 20:11:43 2021 -0700 IF-MIB: Fix a source code comment Fixes: e772b8017d7e ("fix issue #99: read stored ifXTable config at startup") commit b54879bc0853cff90a8ab90bbe4ddbcd32dc3ef1 Author: Bart Van Assche Date: Mon Jul 5 17:28:30 2021 -0700 testing: Capture core dump messages and the snmpd/snmptrapd exit code commit e9f415db8e64787b316ec7527abf6e7a69ef2710 Author: Bart Van Assche Date: Mon Jul 5 11:28:08 2021 -0700 snmpd: Introduce snmpd_reconfig() This patch does not change any functionality. commit b80d4d7d4c78d39db500f84dff3e811aa9974031 Author: Bart Van Assche Date: Mon Jul 5 14:15:47 2021 -0700 SNMPv2-MIB: Shorten the agent/mibgroup/mibII/setSerialNo.c code This patch does not change any functionality. commit 080695397b7c9c9c0d016d30d476e9cc889ab439 Author: Bart Van Assche Date: Mon Jul 5 14:22:43 2021 -0700 libsnmp: Make the container comparison functions easier to read This patch does not change any functionality. commit 26e9971ed8b5003d512b6700561290ac64f2d579 Author: Bart Van Assche Date: Mon Jun 28 21:08:45 2021 -0700 ci: Install more Ubuntu packages and temporarily disable OS/X builds commit bdd5531bc4c349b8fcd1dffd4ea76e86378dccc2 Author: Bart Van Assche Date: Sun Jun 27 20:57:11 2021 -0700 libsnmp: Make the endianness detection code compatible with Solaris' cc commit 6bd559626e22d563ff7db80b0ec4d2e70a76c89c Author: Bart Van Assche Date: Sun Jun 27 09:55:37 2021 -0700 ci: Switch from Travis to AppVeyor Since June 15th, 2021, the building on travis-ci.org is ceased. Hence switch to AppVeyor. commit afc185457f958f94e9076ea7ea39eaf2075f3850 Author: Bart Van Assche Date: Sun Jun 27 15:02:58 2021 -0700 snmpd: Do not leak the trap destination community string This patch fixes the following Valgrind complaint: 14 bytes in 2 blocks are definitely lost in loss record 20 of 322 at 0x402F5ED: malloc (vg_replace_malloc.c:299) by 0x4548965: strdup (in /lib/libc-2.27.so) by 0x424D370: netsnmp_parse_args (in /lib/libnetsnmp.so.35.0.1) by 0x4064519: snmpd_parse_config_trapsess (in /lib/libnetsnmpagent.so.35.0.1) by 0x425287E: run_config_handler (in /lib/libnetsnmp.so.35.0.1) by 0x42539DB: read_config (in /lib/libnetsnmp.so.35.0.1) by 0x4253A5F: read_config_with_type_when (in /lib/libnetsnmp.so.35.0.1) by 0x4253D67: read_configs_optional (in /lib/libnetsnmp.so.35.0.1) by 0x4254642: read_configs (in /lib/libnetsnmp.so.35.0.1) by 0x4245849: init_snmp (in /lib/libnetsnmp.so.35.0.1) by 0x804A887: ??? (in /bin/snmpd) by 0x44E6E50: (below main) (in /lib/libc-2.27.so) See also https://github.com/net-snmp/net-snmp/issues/300 . Fixes: 09f2cbaed980 ("libsnmp, netsnmp_parse_args(): Fix memory leaks in error paths") commit 0d58651b47337a910d4e1567a8ac2729a2b012fe Author: Bart Van Assche Date: Sun Jun 27 19:12:38 2021 -0700 UCD-SNMP proxy: Fix a memory leak commit 1ead68076cebf1aa438b575faf6ca06cbc6cbd58 Author: Bart Van Assche Date: Sun Jun 27 19:08:53 2021 -0700 UCD-SNMP proxy: Consolidate error paths in proxy_parse_config() commit f84d62d3b38251fa5e01c2cc95e12e139474e3c4 Author: Bart Van Assche Date: Sun Jun 27 09:44:53 2021 -0700 Darwin: MIB-II: Include mibII/kernel_sysctl for kernel versions >= 10 This patch breaks support for Darwin kernel versions < 10. If it ever would be necessary to restore support for Darwin kernel versions < 10 that can be done by modifying the agent/mibgroup/mibII/kernel_sysctl.c source file. Fixes: f01c45c53cdc ("Darwin: Unify system header files") Fixes: https://github.com/net-snmp/net-snmp/issues/226 commit dbb49acfa2afb2539741d68403b8f9a49df93042 Author: Ryan Schmidt Date: Sat Sep 15 00:58:05 2018 -0500 Allow perl compiler name to contain periods Fixes: https://sourceforge.net/p/net-snmp/patches/1375/ commit a7aa206599fff95078b4e51e5b6d052d6e3e12db Author: Bart Van Assche Date: Tue Jun 22 19:58:27 2021 -0700 libsnmp: Remove a cast This cast was introduced by commit df863a5348aa ("Fix Bug #2427: Cannot resolve IPv6 only hostnames, by accepting a list of transport domains.") commit 39390a0233e7ce5fdf94f67e832df3183b96a511 Author: Bart Van Assche Date: Tue Jun 22 13:48:52 2021 -0700 TCP-MIB: Fix several memory leaks See also https://github.com/net-snmp/net-snmp/issues/300 . commit 685d31a2baf564d992aedf9b210962e04c9ed78a Author: Bart Van Assche Date: Fri Jun 18 14:52:03 2021 -0700 Use #ifdef instead of #if to test HAVE_* macros commit f3f78e208fdf37be6f47595d5f99e592cc393390 Author: Bart Van Assche Date: Fri Jun 18 10:51:46 2021 -0700 libsnmp: Improve the netsnmp_getaddrinfo() debug output Display the hints passed to netsnmp_getaddrinfo() and show both IPv4 and IPv6 addresses in the debug output. commit 5eea934e4a3fc77fbaf49566a8ef39d91a45f30e Author: Bart Van Assche Date: Fri Jun 18 10:10:13 2021 -0700 win32/build.pl: Improve the menu script further Change the default OpenSSL directory into the new default directory of the OpenSSL installer. Remove the remaining references to the platform SDK. commit 2c6bf7556d78e7ed9c499bf2e9aed1223a93cb44 Author: Bart Van Assche Date: Thu Jun 17 09:42:53 2021 -0700 Windows, MSVC: Use getaddrinfo() This patch changes the minimum requirement for snmpd.exe built with MSVC to Windows XP / Windows Server 2003. See also https://docs.microsoft.com/en-us/windows/win32/api/ws2tcpip/nf-ws2tcpip-getaddrinfo . See also https://github.com/net-snmp/net-snmp/issues/304 . commit 321ff9d75d3fe2c73665466f04d3c3b22fc517ed Author: Bart Van Assche Date: Thu Jun 17 09:41:56 2021 -0700 Revert "Windows, MSVC: Use getaddrinfo() if it is available" Reverts commit 6024a9e8613f because it is not sufficient to add IPv6 support on Windows. commit 1942fe5b0f404335c7987702436d6a5d4a481acd Author: Bart Van Assche Date: Wed Jun 16 11:22:59 2021 -0700 Python: Use % NETSNMP_PRIo u instead of %lu commit 239d715336dbbc5640652895ee4e02882361e7ca Author: Bart Van Assche Date: Wed Jun 16 11:12:48 2021 -0700 Use #ifdef instead of #if to test HAVE_* macros commit 3fb026f068c3010b29c0be44998fae3d93feccbc Author: Bart Van Assche Date: Thu Jun 17 09:24:13 2021 -0700 win32/build.pl: Fix menu system Fixes: bbbf866c1c26 ("Windows: Always use the 'Platform SDK'") commit 428b834b34736d3182ad310eb1fb558de402ce66 Author: Bart Van Assche Date: Wed Jun 16 12:12:33 2021 -0700 ci: Remove Cygwin from continuous integration testing No Cygwin bug reports have been received in the past two years. Hence stop supporting Cygwin. Windows users can use MinGW or MSVC instead. commit bbbf866c1c261615e71e52ad4cdfcac2504c92fb Author: Bart Van Assche Date: Tue Jun 15 20:06:47 2021 -0700 Windows: Always use the 'Platform SDK' The 'Platform SDK' is an optional download for Visual Studio 6, released in 1998. Since that version of Visual Studio is no longer supported, remove the corresponding menu option. commit 6024a9e8613facc0c8b62fc1abe2477910ff38dc Author: Bart Van Assche Date: Tue Jun 15 16:31:52 2021 -0700 Windows, MSVC: Use getaddrinfo() if it is available commit dbc89942439259d8990cdcccf227b97779ce5eb4 Author: Bart Van Assche Date: Mon Jun 14 14:54:58 2021 -0700 Windows: Support running build.bat from inside a Cygwin shell commit b31f31e248f065edc83f23768f081fb152318233 Author: Bart Van Assche Date: Sat Jun 12 14:15:11 2021 -0700 IP-FORWARD-MIB: Initialize mask.sin_port This was detected by Coverity. commit 8118c519b94c61865239a3f657f46ae622d943bc Author: Bart Van Assche Date: Sat Jun 12 14:05:58 2021 -0700 libsnmp: Fix a typo in the read_objid() documentation Additionally, remove a duplicate comment. commit b9d1d1345a799b4b08a313b18456e68330199888 Author: Bart Van Assche Date: Tue Jun 15 16:44:06 2021 -0700 Use #ifdef instead of #if to test HAVE_* macros commit e4d86779da4a6b8b2c7529297cb2e7a968ba19be Author: Bart Van Assche Date: Tue Jun 15 17:25:31 2021 -0700 Windows, MinGW: Fix the build of agent/mibgroup/hardware/fsys/hw_fsys.c commit f5116764b3db20599cef68dfa7a2841221e6f253 Author: Bart Van Assche Date: Tue Jun 15 17:18:47 2021 -0700 MIB-II: Do not test whether an unsigned variable is positive commit 8aa8b94a9871c698815c4e38986b0dfbfebdef0c Author: Bart Van Assche Date: Tue Jun 15 17:14:53 2021 -0700 snmpd: Reduce the scope of the variable 'ret' This patch suppresses the following compiler warning on Windows: snmpd.c:1172:38: warning: unused variable 'ret' [-Wunused-variable] 1172 | int count, block, i, ret; | ^~~ commit f1a32a5606e1c0794fbe770424e3f2859b608d91 Author: Bart Van Assche Date: Sat Jun 12 13:13:05 2021 -0700 Use #ifdef instead of #if to test HAVE_* macros commit ce75820dbca71487dbaa4038aac42443622be52b Author: Bart Van Assche Date: Sat Jun 12 13:23:42 2021 -0700 snmpd: Do not use HAVE_STDDEF_H The stddef.h header file is an ANSI C header file and HAVE_STDDEF_H is not define. Hence, remove #if HAVE_STDDEF_H / #endif. commit 3feb2a75d20aac77712246d93b8afc6c21a46cd2 Author: Bart Van Assche Date: Sat Jun 12 13:41:54 2021 -0700 configure: Run autoreconf Fixes: fe43b05dac6f ("configure: Add -Wundef to the developer compiler flags") commit 5570ef925080551b665889d00325b1398983df7e Author: Bart Van Assche Date: Sat Jun 12 07:49:15 2021 -0700 libsnmp: Remove an obsolete comment Remove a comment that is obsolete since commit e2f9573849bd ("CHANGES: snmplib: remove inline versions of container funcs"). commit 8b980841780102b1f925308d0b4f7f8b847c0666 Author: Bart Van Assche Date: Fri Jun 11 14:45:11 2021 -0700 snmptrapd: Reduce the scope of the 'uid' and 'gid' variables commit 9cb51252312ee0d3fcf65f8458fd1a2cb95f1e81 Author: Christopher Wong Date: Mon Jun 7 23:17:53 2021 +0200 Make snmptrapd accept a group name in addition to a numerical group ID snmptrapd only supports numerical gids. This behavior is different than snmpd which accepts group names and numerical gits. Make snmptrapd behavior consistent with that of snmpd. [ bvanassche: edited patch description ] commit 2c217277b6bec8a1b0c5172aaddd31e7c024e8aa Author: Thomas Viehweger Date: Fri Jun 11 21:46:29 2021 +0200 Fix inconsistent use of #if vs. #ifdef HAVE_PCRE_H HAVE_PCRE_H is undefined if could or should not be used. Fix compiler warnings / errors if compiled with the compiler flags -Wundef or -Werror=undef. commit c99b1a1c527085cefd6a7fa7a6c99fb7f43fcfb2 Author: Bart Van Assche Date: Wed Jun 9 14:58:01 2021 -0700 Python: Improve the unit tests commit 8c1dad23301692799749d75a3c039b8ae7c07f8e Author: Bart Van Assche Date: Wed Jun 9 14:19:46 2021 -0700 Python: Fix snmpwalk with UseNumeric=1 Fixes: c744be5ffed6 ("Python: Introduce build_python_varbind()") Fixes: https://github.com/net-snmp/net-snmp/issues/303 commit 0ad796b13e5b4f09940cc125f041fac2364917c0 Author: Bart Van Assche Date: Wed Jun 9 14:27:42 2021 -0700 testing/RUNFULLTESTS: Fix an undefined value complaint Fixes: b6a9aa8938d9 ("testing/RUNFULLTESTS: Respect $LD_LIBRARY_PATH") commit aa7a51ce94ef3f4cf1d9e26c2c81b89bf4a59d02 Author: Bart Van Assche Date: Sat Jun 5 19:55:03 2021 -0700 Makefiles: Move @LD_NO_UNDEFINED@ Move @LD_NO_UNDEFINED@ from $(LIB_LD_CMD) invocations into the $(LIB_LD_CMD) definition. This patch adds @LD_NO_UNDEFINED@ when linking libnetsnmptrapd. commit b6a9aa8938d999b70df9fd895702483eea9ee4f4 Author: Bart Van Assche Date: Thu Jun 3 21:00:56 2021 -0700 testing/RUNFULLTESTS: Respect $LD_LIBRARY_PATH commit 5522ccce502c2e30be952ea539c2fe4757ccf1ae Author: Bart Van Assche Date: Mon May 31 15:56:31 2021 -0700 UCD-SNMP-MIB: Reorder functions commit 19a6e90f0239903f1eba18056018523d89864802 Author: Bart Van Assche Date: Mon May 31 15:39:16 2021 -0700 UCD-SNMP-MIB: Simplify _expand_disk_array() commit 7aa03757ddf46c52290d385d2128e7cfa471af68 Author: Bart Van Assche Date: Mon May 31 15:34:50 2021 -0700 UCD-SNMP-MIB: Declare local variables 'static' commit ee51abd5523eafd773103714df9db735f46cde49 Author: Bart Van Assche Date: Mon May 31 15:30:23 2021 -0700 UCD-SNMP-MIB: Reindent agent/mibgroup/ucd-snmp/disk_hw.c commit fe43b05dac6fc94ec7e54ce027330e3ecea803f5 Author: Bart Van Assche Date: Mon May 31 14:51:27 2021 -0700 configure: Add -Wundef to the developer compiler flags commit 91afcd8a557e1dea57a44ce7f01dfec932994cca Author: Thomas Viehweger Date: Thu May 27 23:08:26 2021 +0200 Fix inconsistent use of #if vs. #ifdef NETSNMP_CAN_USE_SYSCTL NETSNMP_CAN_USE_SYSCTL could be undefined. Fix compiler warnings / errors if compiled with the compiler flags -Wundef or -Werror=undef. [ bvanassche: edited commit message ] ---------------------------------------------------------------------- Changes: V5.9.1.rc1 -> V5.9.1 commit 2eed7fe490bb6735a6c94b0cf03d9ff5d7884087 Author: Wes Hardaker Date: Tue May 25 14:49:51 2021 -0700 remove the RC flag commit d9d7b9b63b7b5c7be1b6de675b94f3f0ef7596ae Author: Wes Hardaker Date: Tue May 25 14:49:10 2021 -0700 Version number update: 5.9.1 ---------------------------------------------------------------------- Changes: V5.9.1.pre1 -> V5.9.1.rc1 commit 05617ca6fd1d8355663de48280ade58d49050d33 Author: Wes Hardaker Date: Wed Apr 28 14:15:15 2021 -0700 Release Candidate for V5-9-patches commit c371b1d7aa174871367b2a5de23431cf7348f1a4 Author: Wes Hardaker Date: Wed Apr 28 14:15:13 2021 -0700 Version number update: 5.9.1.rc1 commit 5ceb3ebc2fe138d35a498f402254335baffecee5 Author: Bart Van Assche Date: Thu Apr 15 10:30:04 2021 -0700 ci/build.sh: Disable parallel compilation for minimalist mode commit f69daae8a958daa8b50e8767da216ef9570b2e6c Author: Bart Van Assche Date: Thu Apr 15 10:45:39 2021 -0700 Run 'make distdepend' commit 9f1d8188bae2990b42f8aef1c4f65dd18c1c1924 Author: Bart Van Assche Date: Thu Apr 15 09:29:30 2021 -0700 Makefile.rules: Retain only -D and -I options when regenerating dependencies The 'makedepend' command accepts the cc -D and -I options but not the other options that may occur in $(CPPFLAGS) (-f, -g, -O, -pipe, ...). commit 9ea3d8b93c9bb7da7fea13ee6c92356a6b82a5fb Author: Bart Van Assche Date: Wed Apr 14 20:03:15 2021 -0700 Makefile.in: Make sure that 'sedscript' is built before subdirectories This is a follow-up for commit 855e1c28dad5 ("Makefile.in, agent/Makefile.in: Fix parallel compilation"). commit 4fba346d04c26154098b917ad8769515e3766061 Author: Bart Van Assche Date: Wed Apr 14 17:50:59 2021 -0700 Windows: Unbreak the build Fixes: d6fac610cdea ("Fix the crash of snmpd when snmptrapd terminates the TCP connection.") commit 93ea661906fb25657a63cfd757ef7a04c4dd0b33 Author: Bart Van Assche Date: Wed Apr 14 16:12:43 2021 -0700 snmpd, FreeBSD 13: Make sure that filesystem statistics are up to date Make snmpd report the current statistics instead of statistics cached at mount time by the operating system. Fixes: https://github.com/net-snmp/net-snmp/issues/282 commit bd5bc2df5d39a5c730a86f1c452b69f35841fdba Author: Bart Van Assche Date: Wed Apr 14 09:51:18 2021 -0700 ci/build.sh: Enable parallel compilation commit 855e1c28dad53d6263c6c0c302438d2dc3128cc5 Author: Bart Van Assche Date: Wed Apr 14 09:35:24 2021 -0700 Makefile.in, agent/Makefile.in: Fix parallel compilation See also https://github.com/net-snmp/net-snmp/issues/283 . commit ec9068cd270677860e5832bee791a40ec33e08b2 Author: Bart Van Assche Date: Tue Apr 13 08:59:13 2021 -0700 ci/openssl.bat: Bump the OpenSSL version commit 021d10edbf0c4b7754b994ad0e0ffb090f6dac32 Author: Bart Van Assche Date: Tue Apr 13 08:59:13 2021 -0700 ci/openssl.bat: Bump the OpenSSL version commit 6a77db5c7dc4e31afb6bca93c5394f224c55a179 Author: Bart Van Assche Date: Mon Apr 12 21:41:15 2021 -0700 UCD-SNMP-MIB: Let configure detect whether or not getmntinfo() is available ---------------------------------------------------------------------- Changes: V5.9 -> V5.9.1.pre1 commit f9312b44b71ddd247a98c6aff3e986d027e7eaa4 Author: Wes Hardaker Date: Mon Apr 5 16:31:47 2021 -0700 version update for 5.9.1.pre1 commit 3080795082e347504a3cd290f840b6b024d729df Author: Wes Hardaker Date: Mon Apr 5 16:30:09 2021 -0700 fix comment to C commit 0b886fc4d842f0f434606c4d35e610341cb650f7 Author: Wes Hardaker Date: Mon Apr 5 15:38:35 2021 -0700 Version number update: 5.9.1.pre1 commit b5429f6d8556f05100eadec681680df215a2d9e8 Author: Wes Hardaker Date: Mon Apr 5 15:38:24 2021 -0700 version update for 5.9.1.pre1 commit f36a9c4a747863d0c258a7a816381c9f15781f3c Author: Tobias Deiminger Date: Wed Oct 7 08:36:40 2020 +0200 Fix regex for "-l" discovery in setup.py This prevents setup.py from discovering wrong library link options (-l, -L) in the middle of a word, like "inux-gnu" from "-L/usr/lib/x86_64-linux-gnu". For net-snmp-config output as follows (real world example from Ubuntu 18.04): "-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -L/usr/lib/x86_64-linux-gnu -lnetsnmp -lcrypto -lm" the former regex "-l(\S+)" would match to ['inux-gnu', 'netsnmp', 'crypto', 'm'] which obviously results in a ld error "cannot find -linux-gnu". Now we capture a string only, if "-l" is at the beginning of a string, or if "-l" is preceeded by any number of whitespace characters. commit c2db3407dd4dd1a288042b06967a35712004e093 Author: Ferenc Wágner Date: Mon Mar 15 18:00:48 2021 +0100 Enable systemd socket activation for UDP sockets Like it was possible for UNIX and TCP sockets beforehand. commit a9cf25db7e3e969dbcd9bda9a16457db6fc7210f Author: Josef Řídký Date: Mon Mar 15 09:23:41 2021 +0100 net-snmp-cert: Use sha512 as default option for generating certificates. Fixes: https://github.com/net-snmp/net-snmp/issues/231 [ bvanassche: edited commit message ] commit eb1b11bb7f3ac3281dc6e92d94e8fa749cac44e0 Author: Josef Řídký Date: Fri Mar 12 10:15:30 2021 +0100 Prevent parsing IP address twice (#199) This fixes issue, that is caused by parsing IP address twice. First as IPv4 and as IPv6 at second, even thow the address was properly parsed as a valid IPv4 address. commit dce7b17e7ce7b12954a8c799265d3001922bb0a1 Author: Bart Van Assche Date: Wed Mar 3 20:24:05 2021 -0800 ci/build.bat: Fix the Cygwin build commit dc58ed9990a1736b9b500a5e16e7517f93d194f4 Author: Bart Van Assche Date: Wed Mar 3 19:10:25 2021 -0800 net-snmp-create-v3-user: Print the version number once Print the version number once instead of keeping to print the version number forever in an endless loop. Fixes: https://sourceforge.net/p/net-snmp/bugs/2778/ commit afa2034ca57b7986e91272b56274cebff5d8d69f Author: Bart Van Assche Date: Sat Feb 27 21:25:44 2021 -0800 ci/openssl.bat: Bump the OpenSSL version commit 8c301c1e06004aa4095f956bff5f399104e71127 Author: Bart Van Assche Date: Sat Feb 27 19:46:13 2021 -0800 IF-MIB: Do not scan for PCI devices if no PCI bus is available Fixes: https://github.com/net-snmp/net-snmp/issues/271 commit 385d555606ee31a23d5ed711a7ffba45f4197d50 Author: Bart Van Assche Date: Mon Feb 15 08:44:13 2021 -0800 Perl: Only use $prefix on Unix systems This patch reworks commit f64e0111ad10 ("Perl: Set the $prefix variable on Windows"). commit f64e0111ad10b948aeadd386063a69ba5fc7fc7b Author: Bart Van Assche Date: Sat Feb 13 20:04:29 2021 -0800 Perl: Set the $prefix variable on Windows Fixes: https://github.com/net-snmp/net-snmp/issues/261 commit 428a486d92ca631d83f5bfc42c319f630b152bea Author: Bart Van Assche Date: Sat Feb 13 19:19:19 2021 -0800 Python: Use netsnmp_memdup() instead of open-coding it commit 6ad61e6628ecf1bde987c78de37674c4886a16b9 Author: Bart Van Assche Date: Sat Feb 13 19:35:57 2021 -0800 Python: Do not report "error: set: adding variable/value to PDU" when clearing an OCTETSTR Fixes: https://github.com/net-snmp/net-snmp/issues/265 commit ddd338fab038bf0ea25426d43518f4f24ac20853 Author: Bart Van Assche Date: Sat Feb 13 19:19:01 2021 -0800 python/netsnmp/tests/test.py: Add a test for setting an OCTETSTR commit f03582450d1eabae6df66b1fde5699a8e2a97b81 Author: Bart Van Assche Date: Sat Feb 13 11:02:37 2021 -0800 snmplib: Add more comments in netsnmp_random() commit b754da08461bd062632924fb773cb6f7c8c348d7 Author: Bart Van Assche Date: Sat Feb 13 09:24:12 2021 -0800 Enable the compiler flag -Wtype-limits commit b71b52f03398f2c42f100dd960009b824e6c306b Author: Bart Van Assche Date: Sat Feb 13 09:22:54 2021 -0800 Fix the -Wtype-limits compiler warnings commit a29685e5a35ff4a88b396e7952e59b53b9c24ebd Author: Bart Van Assche Date: Sat Feb 13 08:29:48 2021 -0800 configure: Only display the message "Checking for developer gcc flags" in developer mode commit 0dcebaf3d4b142638cd86de725ef23372495005f Author: Bart Van Assche Date: Fri Feb 12 20:55:42 2021 -0800 python/netsnmp/tests/test.py: Also perform a full MIB walk commit 8d8d8439d5d211ec1782d609e0ad67180c975d7b Author: Bart Van Assche Date: Fri Feb 12 19:49:18 2021 -0800 HOST-RESOURCES-MIB: Add JFFS2 support Fixes: https://github.com/net-snmp/net-snmp/issues/268 commit d468c8ad86c86ceb1807ccd51408594526940137 Author: Bart Van Assche Date: Fri Feb 12 19:35:44 2021 -0800 HOST-RESOURCES-MIB: Simplify the code for recognizing "other" filesystems commit 02bc1baf0d4f6031085e107a9cddc05dfbd74db2 Author: Bart Van Assche Date: Sun Jan 10 16:58:09 2021 -0800 snmpd: Exclude the /dev/kmem code if configured with --without-kmem-usage This is a follow-up for 9e933893751f ("snmpd: Exclude the /dev/kmem code if configured with --without-kmem-usage"). Fixes: https://github.com/net-snmp/net-snmp/issues/251 commit 4d92f40112dd768d89a9f0a20cf743b18d951e45 Author: Filip Jensen Date: Tue Jan 5 16:57:43 2021 +0100 Fix compilation when feature NETSNMP_FEATURE_REMOVE_LOGGING_STDIO is used commit e3601420c8fce713924038901f824e57e6855e72 Author: Bart Van Assche Date: Mon Jan 4 13:01:47 2021 -0800 Revert "Read intermediate certificates from PEM files" This reverts commit 916110b15f28f8ae04598ad637ac26e4585ff385 and thereby removes support for intermediate certificates from the v5.9 branch. commit 2b93ee55d1b9b32c86c3f725c59b8fd17912ae18 Author: Bart Van Assche Date: Mon Jan 4 13:01:42 2021 -0800 Revert "libsnmp: Fix a NULL pointer dereference in an error path" This reverts commit 99a72177c7c69c5ca1a5ecb68f5f2db7d971e97a. commit baef04f9c6fe0eb3ac74dd4d26a19264eeaf7fa1 Author: Bart Van Assche Date: Mon Jan 4 10:00:33 2021 -0800 testi