Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I'm using a paypal form which requires that I put my email address as my identifier. I've written a form which points to a script on my server and which correlates information before it forwards to paypal. I thought that the best approach would be to encode the email address with a set parameter (not talking high security here!) and then decode it in the script before forwarding it to paypal. Could anyone give some advice on how to do this, please? Thanks.

Replies are listed 'Best First'.
Re: encoding and decoding an email address
by atemon (Chaplain) on Jul 19, 2007 at 14:38 UTC

    If you are NOT going for high security, you may use something like Crypt::Lite. This is a simple encrypting module, easy to use also. If you want real securityike Digitaly signing it, try Crypt::GPG. A search on CPAN will give you hundreds of such modules.

    Cheers!

    --VC

    There are three sides to any argument.....
    your side, my side and the right side.

Re: encoding and decoding an email address
by Anonymous Monk on Jul 19, 2007 at 14:41 UTC
    My apologies, on reading this I think it is not clear that I cannot simply put the email address into the forwarding script as I am using this for multiple users. Therefore the email address has to go in the form parameter.

      The modules like GPG or Crypt::Lite can be used to encrypt the email ID and you can send the encrypted string to your script as param. Your program will decrypt the param to get email ID.

      --VC

      There are three sides to any argument.....
      your side, my side and the right side.

        Thanks very much for your help.