# hex up your image open IMG, "$ARGV[0]" or die "Couldn't open $ARGV[0]: $!\n"; binmode(IMG); undef $/; $image = ; $hex = unpack("H*", $image); close IMG; while ($txt = substr($hex,0,32,'')) { print "'$txt'\n"; }