Report non-DNSSEC infrastructure problem with details

Provide version of DNS server used and the platform, on which we are
running.
This commit is contained in:
Petr Menšík 2025-02-11 16:26:27 +01:00
commit 395fa75647

View file

@ -38,6 +38,7 @@ rlJournalStart
rlRun "REAL_RESOLV=$(realpath /etc/resolv.conf)"
rlRun "BACKUP_RESOLV=$(mktemp /etc/resolv-XXXXXX.conf)"
rlRun "rm -f $BACKUP_RESOLV"
rlRun -l "hostnamectl" 0-255 "Record type of used machine"
if [ "$REAL_RESOLV" = /run/systemd/resolve/stub-resolv.conf ]; then
rlWarning "systemd-resolved stub detected, temporary switching..."
rlRun "mv /etc/resolv.conf $BACKUP_RESOLV"
@ -56,6 +57,7 @@ rlJournalStart
DNSSEC=yes
else
rlLogWarning "nameserver $NS does not support DNSSEC!"
rlRun -l "dig +short @$NS -t txt -c ch -q version.bind" 0 "Query version of server $NS"
rlRun "sed -e '/$NS/ d' -i /etc/resolv.conf"
fi
done