public inbox for development@lists.ipfire.org
 help / color / mirror / Atom feed
From: "Peter Müller" <peter.mueller@link38.eu>
To: development@lists.ipfire.org
Subject: [PATCH] show RNGD status at WebUI service page, too
Date: Fri, 08 Sep 2017 20:27:27 +0200	[thread overview]
Message-ID: <20170908202727.58c12115.peter.mueller@link38.eu> (raw)

[-- Attachment #1: Type: text/plain, Size: 1981 bytes --]

Also show the status of the hardware random number generator ("RNGD")
at the services.cgi page in the WebUI. Before, this was only shown
at the entropy.cgi page, which was a bit inconsistent.

Signed-off-by: Peter Müller <peter.mueller(a)link38.eu>
---
diff --git a/html/cgi-bin/services.cgi b/html/cgi-bin/services.cgi
index 64fdbba05..6629ee006 100644
--- a/html/cgi-bin/services.cgi
+++ b/html/cgi-bin/services.cgi
@@ -56,6 +56,7 @@ my %servicenames =(
 	$Lang::tr{'secure shell server'} => 'sshd',
 	$Lang::tr{'vpn'} => 'charon',
 	$Lang::tr{'web proxy'} => 'squid',
+	$Lang::tr{'random number generator daemon'} => 'rngd',
 	'OpenVPN' => 'openvpn'
 );
 
@@ -74,7 +75,8 @@ my %link =(
 	"$Lang::tr{'intrusion detection system'} (GREEN)" => "<a href=\'ids.cgi\'>$Lang::tr{'intrusion detection system'} (GREEN)</a>",
 	"$Lang::tr{'intrusion detection system'} (RED)" => "<a href=\'ids.cgi\'>$Lang::tr{'intrusion detection system'} (RED)</a>",
 	"$Lang::tr{'intrusion detection system'} (ORANGE)" => "<a href=\'ids.cgi\'>$Lang::tr{'intrusion detection system'} (ORANGE)</a>",
-	"$Lang::tr{'intrusion detection system'} (BLUE)" => "<a href=\'ids.cgi\'>$Lang::tr{'intrusion detection system'} (BLUE)</a>"
+	"$Lang::tr{'intrusion detection system'} (BLUE)" => "<a href=\'ids.cgi\'>$Lang::tr{'intrusion detection system'} (BLUE)</a>",
+	"$Lang::tr{'random number generator daemon'}" => "<a href=\'entropy.cgi\'>$Lang::tr{'random number generator daemon'}</a>"
 );
 
 my $lines=0; # Used to count the outputlines to make different bgcolor
@@ -327,3 +329,4 @@ sub isrunningaddon{
 	}
 	return $status;
 }
+
diff --git a/src/initscripts/system/rngd b/src/initscripts/system/rngd
index df4aa7da2..5cd3b53ec 100644
--- a/src/initscripts/system/rngd
+++ b/src/initscripts/system/rngd
@@ -34,6 +34,7 @@ case "${1}" in
 			echo_ok
 		else
 			loadproc /usr/sbin/rngd --no-tpm=1
+			test -f /run/rngd.pid && chmod 755 /run/rngd.pid
 		fi
 		;;
 	

                 reply	other threads:[~2017-09-08 18:27 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170908202727.58c12115.peter.mueller@link38.eu \
    --to=peter.mueller@link38.eu \
    --cc=development@lists.ipfire.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox