hostnamed cannot update system hostname with information obtained
from dhcpcd.
Add interface to sysnetwork.if allowing rw access to unix stream
sockets on dhcpc_t
Signed-off-by: Chris Richards <[email protected]>
---
policy/modules/system/sysnetwork.if | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/policy/modules/system/sysnetwork.if b/policy/modules/system/sysnetwork.if
index 8e71fb7..7e31057 100644
--- a/policy/modules/system/sysnetwork.if
+++ b/policy/modules/system/sysnetwork.if
@@ -231,6 +236,25 @@ interface(`sysnet_read_dhcpc_state',`
read_files_pattern($1, dhcpc_state_t, dhcpc_state_t)
')
+########################################
+## <summary>
+## Read and write the dhcp client unix
+## stream socket.
+## </summary>
+## <param name="domain">
+## <summary>
+## Domain allowed access.
+## </summary>
+## </param>
+#
+interface(`sysnet_rw_dhcpc_stream_sockets',`
+ gen_require(`
+ type dhcpc_t;
+ ')
+
+ allow $1 dhcpc_t:unix_stream_socket { read write };
+')
+
#######################################
## <summary>
## Delete the dhcp client state files.
--
1.7.3.4