[PATCH RFC] Disable save-entropy in jails

Xin Li delphij at delphij.net
Tue Dec 24 20:44:35 UTC 2013


Hi,

I think we shouldn't save entropy inside jails, as the data is not going
to be used by rc script (pjd at 126744).  If there is no objections, I will
commit this changeset on January 1, 2014.

Index: libexec/save-entropy/save-entropy.sh
===================================================================
--- libexec/save-entropy/save-entropy.sh	(revision 259828)
+++ libexec/save-entropy/save-entropy.sh	(working copy)
@@ -42,6 +42,10 @@ elif [ -r /etc/rc.conf ]; then
 	. /etc/rc.conf 2>/dev/null
 fi

+if [ `/sbin/sysctl -n security.jail.jailed` -eq 1 ]; then
+	exit 0
+fi
+
 case ${entropy_dir} in
 [Nn][Oo])
 	exit 0

Cheers,
-- 
Xin LI <delphij at delphij.net>    https://www.delphij.net/
FreeBSD - The Power to Serve!           Live free or die


More information about the freebsd-current mailing list