Server IP : 52.91.253.208 / Your IP : 3.137.172.115 [ Web Server : Apache System : Linux ip-172-26-9-9 4.19.0-25-cloud-amd64 #1 SMP Debian 4.19.289-1 (2023-07-24) x86_64 User : daemon ( 1) PHP Version : 7.3.18 Disable Function : NONE Domains : 3 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : OFF Directory : /lib/cloud-init/ |
Upload File : |
#!/bin/sh # This file is part of cloud-init. See LICENSE file for license information. logger_opts="-p user.info -t ec2" # rhels' version of logger_opts does not support long # for of -s (--stderr), so use short form. logger_opts="$logger_opts -s" # Redirect stderr to stdout exec 2>&1 fp_blist=",${1}," key_blist=",${2}," { echo echo "#############################################################" echo "-----BEGIN SSH HOST KEY FINGERPRINTS-----" for f in /etc/ssh/ssh_host_*key.pub; do [ -f "$f" ] || continue read ktype line < "$f" # skip the key if its type is in the blacklist [ "${fp_blist#*,$ktype,}" = "${fp_blist}" ] || continue ssh-keygen -l -f "$f" done echo "-----END SSH HOST KEY FINGERPRINTS-----" echo "#############################################################" } | logger $logger_opts echo "-----BEGIN SSH HOST KEY KEYS-----" for f in /etc/ssh/ssh_host_*key.pub; do [ -f "$f" ] || continue read ktype line < "$f" # skip the key if its type is in the blacklist [ "${key_blist#*,$ktype,}" = "${key_blist}" ] || continue cat $f done echo "-----END SSH HOST KEY KEYS-----"