Finding Hashes
Monday, July 23, 2012
To search for SHA1 in file:
cat FILE | grep -o -E -e "[0-9a-f]{40}" | sort | uniq -u > all-SHA1
To search for SHA-256 in file:
cat FILE | grep -o -E -e "[0-9a-f]{64}" | sort | uniq -u > all-SHA256
To search for SHA-512 in file:
cat FILE | grep -o -E -e "[0-9a-f]{128}" | sort | uniq -u > all-SHA512
To search for MD5 in file:
cat FILE | grep -o -E -e "[0-9a-f]{32}" | sort | uniq -u > all-md5
To search for MD5crypt in file:
cat FILE | grep '^\$1\$' | cut -d: -f2- | sort | uniq -u > all-md5crypt
To search for NTLM in file:
cat FILE | grep -o -E -e ':\$NT\$[[:alnum:]]{32}:' | sort | uniq -u > all-NTLM
cat FILE | grep -o -E -e ':\$NT\$[[:alnum:]]{30,34}:' | sort | uniq -u > all-NTLM
Labels:
passwords