Reputation: 585
$key = "12345678876543211234567887654321";
$iv = "1234567887654321";
$plaindata = "String to be encrypted.";
$enc = base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $key, $plaindata, MCRYPT_MODE_CBC, $iv));
echo($enc);
Output:
EIZDQJWOIepUeNjFL2wl3RYA5bDmFd05Xu6z4e0aiWQ=
How this could be decrypted in Perl???
Upvotes: 2
Views: 1394
Reputation: 69274
Looks like you'll need a combination of MIME::Base64 and MCrypt.
Upvotes: 2
Reputation: 2623
There is a package in cpan .. MCrypt
http://search.cpan.org/perldoc?MCrypt
Check this out
Upvotes: 1