use Digest::MD5 qw(md5_hex); my $salt = md5_hex( time().{}.rand().$$ );