199a5d
From 3a161af91bffcd457586ab466e32ac8484028763 Mon Sep 17 00:00:00 2001
199a5d
From: Petr Mensik <pemensik@redhat.com>
199a5d
Date: Wed, 17 Jun 2020 23:17:13 +0200
199a5d
Subject: [PATCH] Update man named with Red Hat specifics
199a5d
199a5d
This is almost unmodified text and requires revalidation. Some of those
199a5d
statements are no longer correct.
199a5d
---
199a5d
 bin/named/named.rst | 35 +++++++++++++++++++++++++++++++++++
199a5d
 1 file changed, 35 insertions(+)
199a5d
199a5d
diff --git a/bin/named/named.rst b/bin/named/named.rst
199a5d
index 6fd8f87..3cd6350 100644
199a5d
--- a/bin/named/named.rst
199a5d
+++ b/bin/named/named.rst
199a5d
@@ -228,6 +228,41 @@ Files
199a5d
 ``/var/run/named/named.pid``
199a5d
    The default process-id file.
199a5d
 
199a5d
+Notes
199a5d
+~~~~~
199a5d
+
199a5d
+**Red Hat SELinux BIND Security Profile:**
199a5d
+
199a5d
+By default, Red Hat ships BIND with the most secure SELinux policy
199a5d
+that will not prevent normal BIND operation and will prevent exploitation
199a5d
+of all known BIND security vulnerabilities. See the selinux(8) man page
199a5d
+for information about SElinux.
199a5d
+
199a5d
+It is not necessary to run named in a chroot environment if the Red Hat
199a5d
+SELinux policy for named is enabled. When enabled, this policy is far
199a5d
+more secure than a chroot environment. Users are recommended to enable
199a5d
+SELinux and remove the bind-chroot package.
199a5d
+
199a5d
+*With this extra security comes some restrictions:*
199a5d
+
199a5d
+By default, the SELinux policy does not allow named to write outside directory
199a5d
+/var/named. That directory used to be read-only for named, but write access is
199a5d
+enabled by default now.
199a5d
+
199a5d
+The "named" group must be granted read privelege to
199a5d
+these files in order for named to be enabled to read them.
199a5d
+Any file updated by named must be writeable by named user or named group.
199a5d
+
199a5d
+Any file created in the zone database file directory is automatically assigned
199a5d
+the SELinux file context *named_zone_t* .
199a5d
+
199a5d
+The Red Hat BIND distribution and SELinux policy creates three directories where
199a5d
+named were allowed to create and modify files: */var/named/slaves*, */var/named/dynamic*
199a5d
+*/var/named/data*. The service is able to write and file under */var/named* with appropriate
199a5d
+permissions. They are used for better organisation of zones and backward compatibility.
199a5d
+Files in these directories are automatically assigned the '*named_cache_t*'
199a5d
+file context, which SELinux always allows named to write.
199a5d
+
199a5d
 See Also
199a5d
 ~~~~~~~~
199a5d
 
199a5d
-- 
199a5d
2.26.2
199a5d