2011-01-12 11:47:04 -06:00
|
|
|
# ------------------------------------------------------------------
|
|
|
|
#
|
|
|
|
# Copyright (C) 2009 John Dong <jdong@ubuntu.com>
|
|
|
|
# Copyright (C) 2010 Canonical Ltd.
|
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or
|
|
|
|
# modify it under the terms of version 2 of the GNU General Public
|
|
|
|
# License published by the Free Software Foundation.
|
|
|
|
#
|
|
|
|
# ------------------------------------------------------------------
|
2010-08-05 14:00:02 -05:00
|
|
|
|
2012-04-16 23:10:43 +02:00
|
|
|
@{TFTP_DIR}=/var/tftp /srv/tftpboot
|
2011-12-16 12:15:12 -05:00
|
|
|
|
2009-11-04 14:25:42 -06:00
|
|
|
#include <tunables/global>
|
2016-04-12 16:37:26 -05:00
|
|
|
/usr/sbin/dnsmasq flags=(attach_disconnected) {
|
2009-11-04 14:25:42 -06:00
|
|
|
#include <abstractions/base>
|
2013-08-20 15:52:22 -07:00
|
|
|
#include <abstractions/dbus>
|
2009-11-04 14:25:42 -06:00
|
|
|
#include <abstractions/nameservice>
|
|
|
|
|
|
|
|
capability net_bind_service,
|
|
|
|
capability setgid,
|
|
|
|
capability setuid,
|
|
|
|
capability dac_override,
|
2011-01-12 11:47:04 -06:00
|
|
|
capability net_admin, # for DHCP server
|
|
|
|
capability net_raw, # for DHCP server ping checks
|
|
|
|
network inet raw,
|
2014-12-02 18:46:26 +01:00
|
|
|
network inet6 raw,
|
2009-11-04 14:25:42 -06:00
|
|
|
|
2014-06-23 15:31:40 -05:00
|
|
|
signal (receive) peer=/usr/sbin/libvirtd,
|
|
|
|
ptrace (readby) peer=/usr/sbin/libvirtd,
|
|
|
|
|
2015-10-16 21:50:21 +02:00
|
|
|
owner /dev/tty rw,
|
|
|
|
|
2009-11-04 14:25:42 -06:00
|
|
|
/etc/dnsmasq.conf r,
|
|
|
|
/etc/dnsmasq.d/ r,
|
|
|
|
/etc/dnsmasq.d/* r,
|
2011-08-08 23:13:15 +02:00
|
|
|
/etc/ethers r,
|
2014-02-17 22:56:02 +01:00
|
|
|
/etc/NetworkManager/dnsmasq.d/ r,
|
|
|
|
/etc/NetworkManager/dnsmasq.d/* r,
|
2009-11-04 14:25:42 -06:00
|
|
|
|
|
|
|
/usr/sbin/dnsmasq mr,
|
|
|
|
|
2011-07-14 07:57:57 -05:00
|
|
|
/{,var/}run/*dnsmasq*.pid w,
|
2011-09-15 20:58:54 +02:00
|
|
|
/{,var/}run/dnsmasq-forwarders.conf r,
|
2011-07-14 07:57:57 -05:00
|
|
|
/{,var/}run/dnsmasq/ r,
|
|
|
|
/{,var/}run/dnsmasq/* rw,
|
2009-11-04 14:25:42 -06:00
|
|
|
|
|
|
|
/var/lib/misc/dnsmasq.leases rw, # Required only for DHCP server usage
|
2010-08-05 14:00:02 -05:00
|
|
|
|
2015-10-20 23:12:35 +02:00
|
|
|
/{,usr/}bin/{ba,da,}sh ix, # Required to execute --dhcp-script argument
|
2014-12-22 17:56:37 +01:00
|
|
|
|
2014-09-06 23:06:46 +02:00
|
|
|
# access to iface mtu needed for Router Advertisement messages in IPv6
|
|
|
|
# Neighbor Discovery protocol (RFC 2461)
|
2014-09-08 20:35:31 +02:00
|
|
|
@{PROC}/sys/net/ipv6/conf/*/mtu r,
|
2014-09-06 23:06:46 +02:00
|
|
|
|
2011-12-17 12:20:53 -05:00
|
|
|
# for the read-only TFTP server
|
2011-12-16 12:15:12 -05:00
|
|
|
@{TFTP_DIR}/ r,
|
2011-12-17 12:20:53 -05:00
|
|
|
@{TFTP_DIR}/** r,
|
2011-12-16 12:15:12 -05:00
|
|
|
|
2013-10-30 21:41:28 +01:00
|
|
|
# libvirt config, lease and hosts files for dnsmasq
|
2014-08-20 22:06:15 -05:00
|
|
|
/var/lib/libvirt/dnsmasq/ r,
|
|
|
|
/var/lib/libvirt/dnsmasq/* r,
|
|
|
|
/var/lib/libvirt/dnsmasq/*.leases rw,
|
|
|
|
/var/lib/libvirt/dnsmasq/*.status* rw,
|
2011-07-25 08:28:04 -05:00
|
|
|
|
2011-01-12 11:47:04 -06:00
|
|
|
# libvirt pid files for dnsmasq
|
2011-07-14 07:57:57 -05:00
|
|
|
/{,var/}run/libvirt/network/ r,
|
|
|
|
/{,var/}run/libvirt/network/*.pid rw,
|
2011-01-12 11:47:04 -06:00
|
|
|
|
2014-08-20 22:06:15 -05:00
|
|
|
# libvirt lease helper
|
2014-12-22 17:56:37 +01:00
|
|
|
/usr/lib{,64}/libvirt/libvirt_leaseshelper ix,
|
2014-08-20 22:06:15 -05:00
|
|
|
/{,var/}run/leaseshelper.pid rwk,
|
|
|
|
|
2015-03-29 20:49:09 -07:00
|
|
|
# lxc-net pid and lease files
|
|
|
|
/{,var/}run/lxc/dnsmasq.pid rw,
|
|
|
|
/var/lib/misc/dnsmasq.*.leases rw,
|
|
|
|
|
2012-01-18 16:20:43 -06:00
|
|
|
# NetworkManager integration
|
|
|
|
/{,var/}run/nm-dns-dnsmasq.conf r,
|
2013-01-02 15:47:28 -08:00
|
|
|
/{,var/}run/sendsigs.omit.d/*dnsmasq.pid w,
|
2014-01-17 20:58:21 +01:00
|
|
|
/{,var/}run/NetworkManager/dnsmasq.conf r,
|
2014-02-17 22:56:02 +01:00
|
|
|
/{,var/}run/NetworkManager/dnsmasq.pid w,
|
2012-01-18 16:20:43 -06:00
|
|
|
|
2010-08-05 14:00:02 -05:00
|
|
|
# Site-specific additions and overrides. See local/README for details.
|
|
|
|
#include <local/usr.sbin.dnsmasq>
|
2009-11-04 14:25:42 -06:00
|
|
|
}
|