Digest::PBKDF2 A minimalist Digest module using the PBKDF2 algorithm.
You can only use one salt, a pre-salt, with this module. It is not smart enough to do post-salts.
my $digest = Digest::PBKDF2->new; # Or... my $digest = Digest::PBKDF2->new(encoding => 'ldap'); $digest->add('mysalt'); # salt = 'mysalt' $digest->add('k3wLP@$$w0rd'); # password = 'k3wLP@$$w0rd' $digest->add('eX+ens10n'); # password = 'k3wLP@$$w0rdeX+ens10n' my $result = $digest->digest; # $PBKDF2$HMACSHA1:1000:bXlzYWx0$4P9pwp # LoF+eq5jwUbMw05qRQyZs=
That's about it.
Create a new Digest::PBKDF2 object. This defaults to using the "ldap" encoding available in Crypt::PBKDF2--please see Crypt::PBKDF2 for details.
Copies the data and state from the original Digest::PBKDF2 object, and returns a new object.
Pass this method your salt and data chunks. They are stored up until you call digest.
This encrypts your data and returns the encrypted string.
After calling digest, the module calls reset on its self, clearing data and the record of how many additions were made to the data to be digested.
Amiri Barksdale, <firstname.lastname@example.org>
Copyright (c) 2014 by Campus Explorer, Inc.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.