#!/usr/bin/perl #attempts to crack a md5 hash using a dictionary file #you run the program this way # perl md5 hash_to_crack dictionary_file use warnings; use strict; use Digest::MD5 qw(md5_hex); my $hash=shift || die "Give me a hash to crack\n"; my $file=shift || die "Give me a dictionary file\n"; open(F,$file) || die "can't open the file\n"; while() { print "Processing $_"; chomp($_); my $t=md5_hex($_); print " $t\n"; die "Found it -> $_\n" if($t eq $hash); }