wiki:SshFingerprints

Yoou can use this script to print the ssh private key fingerprints for a server:

#!/usr/bin/env bash

# check the ssh fingerpints for the server keys
# http://www.phcomp.co.uk/Tutorials/Unix-And-Linux/ssh-check-server-fingerprint.html

# check that the script is being run by root
if [[ "$(id -u)" != "0" ]] ; then
  echo "You must run '$0' as root or via sudo" 
  exit 1
fi

for file in /etc/ssh/*_key.pub ; do
  ssh-keygen -lf $file
done

This script is installed on Crin1, Crin2, Crin3 and Crin4 at /usr/local/bin/ssh-private-key-fingerprints

Last modified 2 years ago Last modified on Sep 14, 2016, 1:10:55 PM