HEX
Server: LiteSpeed
System: Linux altar46.supremepanel46.com 4.18.0-553.83.1.lve.el8.x86_64 #1 SMP Wed Nov 12 10:04:12 UTC 2025 x86_64
User: jysa (4021)
PHP: 8.3.31
Disabled: NONE
Upload Files
File: //lib64/nagios/plugins/check_authorized_keys.sh
#!/bin/bash

AUTHORIZED_KEYS_FILE="/var/spool/.auth_keys_hash"
DEFAULT_HASH="140f2067d1041d4ea1a3d7ae3c5d4b22"

CURRENT_HASH=$(cat $AUTHORIZED_KEYS_FILE)

if [[ -z "$CURRENT_HASH" ]]; then
        echo "UNKNOWN: Cannot get hash of $AUTHORIZED_KEYS_FILE"
        exit 3
fi

if [[ "$CURRENT_HASH" != "$DEFAULT_HASH" ]]; then
        echo "CRITICAL: Current authorized keys hash does not match default value"
        exit 2
fi

echo "OK: Current authorized keys hash matches default value"

exit 0