slackware-current/patches/source/dnsmasq/rc.dnsmasq
Patrick J Volkerding 0ab769ac69 Mon Sep 26 19:43:54 UTC 2022
patches/packages/dnsmasq-2.87-x86_64-1_slack15.0.txz:  Upgraded.
  Fix write-after-free error in DHCPv6 server code.
  For more information, see:
    https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-0934
  (* Security fix *)
patches/packages/vim-9.0.0594-x86_64-1_slack15.0.txz:  Upgraded.
  Fixed stack-based buffer overflow.
  Thanks to marav for the heads-up.
  In addition, Mig21 pointed out an issue where the defaults.vim file might
  need to be edited for some purposes as its contents will override the
  settings in the system-wide vimrc. Usually this file is replaced whenever
  vim is upgraded, which in those situations would be inconvenient for the
  admin. So, I've added support for a file named defaults.vim.custom which
  (if it exists) will be used instead of the defaults.vim file shipped in
  the package and will persist through upgrades.
  For more information, see:
    https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-3296
  (* Security fix *)
patches/packages/vim-gvim-9.0.0594-x86_64-1_slack15.0.txz:  Upgraded.
2022-09-27 13:30:30 +02:00

43 lines
814 B
Bash

#!/bin/sh
# Start/stop/restart dnsmasq (a small DNS/DHCP server):
# Start dnsmasq:
dnsmasq_start() {
if [ -x /usr/sbin/dnsmasq ]; then
echo "Starting dnsmasq: /usr/sbin/dnsmasq"
/usr/sbin/dnsmasq
fi
}
# Stop dnsmasq:
dnsmasq_stop() {
# Try to use the .pid file first:
if pgrep -l -F /var/run/dnsmasq.pid 2> /dev/null | grep -q dnsmasq ; then
echo "Stopping dnsmasq."
pkill -F /var/run/dnsmasq.pid 2> /dev/null
else # kill any dnsmasq processes in this namespace:
echo "Stopping dnsmasq."
killall --ns $$ dnsmasq 2> /dev/null
fi
}
# Restart dnsmasq:
dnsmasq_restart() {
dnsmasq_stop
sleep 1
dnsmasq_start
}
case "$1" in
'start')
dnsmasq_start
;;
'stop')
dnsmasq_stop
;;
'restart')
dnsmasq_restart
;;
*)
echo "usage rc.dnsmasq: start|stop|restart"
esac