From cebbd07700d45a74cf6cdbe48d22bf6319177d12 Mon Sep 17 00:00:00 2001 From: Donald Buczek Date: Thu, 9 Jul 2020 11:25:56 +0200 Subject: [PATCH] checktrust: Add /usr/sbin/checktrust command Add a script to determine whether the system has lost the trust of other systems. Query a few remote systems which are supposed to be online most of the time. Note, that this script has a tristate result (trusted, not trusted, unknown) so we don't communicate the result via exit status, but output "trusted", "not trusted" or nothing. --- checktrust/checktrust | 12 ++++++++++++ install.sh | 1 + 2 files changed, 13 insertions(+) create mode 100755 checktrust/checktrust diff --git a/checktrust/checktrust b/checktrust/checktrust new file mode 100755 index 0000000..ba55e28 --- /dev/null +++ b/checktrust/checktrust @@ -0,0 +1,12 @@ +#! /usr/bin/bash + +for host in wtf afk pummelfee; do + reply="$(netcat -w 1 $host 236