So it's password based encryption which uses MD5 as hash function and DES as underlying block cipher. The pdf file which can be found at the link I provided, describes in detail how it works.
The defaults from the Java class imply the PBKDF1 key derivation function with MD5 as hash function, and the PBES1 encryption, using DES. I may hope it's not necessary to implement all steps yourself. I would start with Digest::MD5 and Crypt::Des. I don't think there is an off-the-shelf perl solution to your problem. Maybe you should look for an openSSL perl module?
Hope this helps, Harry
NB Keep in mind that for some applications the chosen parameters will not be safe enough. I think the 1000 iterations is really a minimum and DES was cracked long ago.
|