summaryrefslogtreecommitdiffstats
path: root/patches/source/net-snmp/rc.snmpd
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2022-07-21 18:13:18 +0000
committer Eric Hameleers <alien@slackware.com>2022-07-22 13:30:29 +0200
commit7e930376320e016856285807d7788b01e51cc594 (patch)
tree42af5ffdc9af82005c3a34b0e42960ac8c6b50e5 /patches/source/net-snmp/rc.snmpd
parent83e918a9794a98459b443e0095a9d13369d2fc7f (diff)
downloadcurrent-7e930376320e016856285807d7788b01e51cc594.tar.gz
current-7e930376320e016856285807d7788b01e51cc594.tar.xz
Thu Jul 21 18:13:18 UTC 202220220721181318_15.0
patches/packages/net-snmp-5.9.3-x86_64-1_slack15.0.txz: Upgraded. This update fixes security issues: A buffer overflow in the handling of the INDEX of NET-SNMP-VACM-MIB can cause an out-of-bounds memory access. A malformed OID in a GET-NEXT to the nsVacmAccessTable can cause a NULL pointer dereference. Improper Input Validation when SETing malformed OIDs in master agent and subagent simultaneously. A malformed OID in a SET request to SNMP-VIEW-BASED-ACM-MIB::vacmAccessTable can cause an out-of-bounds memory access. A malformed OID in a SET request to NET-SNMP-AGENT-MIB::nsLogTable can cause a NULL pointer dereference. A malformed OID in a SET to the nsVacmAccessTable can cause a NULL pointer dereference. For more information, see: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24805 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24809 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24806 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24807 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24808 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24810 (* Security fix *)
Diffstat (limited to 'patches/source/net-snmp/rc.snmpd')
-rw-r--r--patches/source/net-snmp/rc.snmpd55
1 files changed, 55 insertions, 0 deletions
diff --git a/patches/source/net-snmp/rc.snmpd b/patches/source/net-snmp/rc.snmpd
new file mode 100644
index 000000000..ae847e68b
--- /dev/null
+++ b/patches/source/net-snmp/rc.snmpd
@@ -0,0 +1,55 @@
+#!/bin/sh
+#
+# rc.snmpd This shell script takes care of starting and stopping
+# the net-snmp SNMP daemon
+
+[ -r /etc/default/snmpd ] && . /etc/default/snmpd
+SNMPD_OPTIONS=${SNMPD_OPTIONS:-"-A -p /var/run/snmpd -a"}
+
+start() {
+ if [ -x /usr/sbin/snmpd -a -f /etc/snmp/snmpd.conf ]; then
+ echo -n "Starting snmpd: "
+ /usr/sbin/snmpd $SNMPD_OPTIONS -c /etc/snmp/snmpd.conf
+ echo " /usr/sbin/snmpd $SNMPD_OPTIONS -c /etc/snmp/snmpd.conf"
+ fi
+}
+
+stop() {
+ # Stop daemons.
+ COUNT=0
+ echo -n "Shutting down snmpd: "
+ while `killall snmpd 2>/dev/null`; do
+ echo -n "."
+ sleep 1
+ COUNT=$((COUNT+1))
+ if [ $COUNT -ge 30 ]; then
+ killall -9 snmpd
+ sleep 1
+ break
+ fi
+ done
+ echo " DONE"
+}
+
+# See how we were called.
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
+ ;;
+ restart|reload)
+ stop
+ start
+ ;;
+ condrestart)
+ if [ -f /var/run/snmpd ]; then
+ stop
+ start
+ fi
+ ;;
+ *)
+ echo $"Usage: $0 {start|stop|restart|condrestart}"
+ ;;
+esac