in reply to Re^2: encrypt/decrypt string
in thread encrypt/decrypt string

I thought you might be passing login info. Once the client has logged in, you don't need to pass the info back and forth anymore; just pass an encrypted session ID, and store any other sensitive info on the server. You would probably benefit from CGI::Session, and one of its session ID helper modules such as CGI::Session::ID::MD5 (which uses Digest::MD5).


Dave

Replies are listed 'Best First'.
Re^4: encrypt/decrypt string
by artist (Parson) on Oct 19, 2006 at 18:18 UTC
    You might have slightly misunderstood. I have a link for RSS feed. When user clicks on RSS feed, it gives the URL for the RSS feed, particularly for that user. URL should be of the form: server/cgi-bin/rss.pl?feed_id=ABCDEF123456787980". They can take this feed id and plugin into their favorite RSS reader. Now, I should be able to decode the feed_id on the backend, whenever they call and genrate live RSS feed for them.
    --Artist

      Rather than encrypt/decrypt a string, why not generate a random string that you use as a key to look up the session information? That way there is nothing to decrypt, it's a one time pad in effect.


      DWIM is Perl's answer to Gödel
        I don't have to maintain a table. Also, it's not about the sessions. URL given to user, should be fixed for lifetime, based on login. Also, on decryption, I need to get the 'login' info back.
        --Artist