Crypto

The attached ZIP file contains Javascript and a Ruby module that can be used to encrypt data between a web-browser and a server. They use an algorithm called BlockTEA which is a symetrical encryption algorithm and which is realtively fast but strong.

I use them to encrypt form data in transit between the server and the browser and decrypt it at either end. This is useful if you're stuck with a hosting plan that doesn't include SSL.

Whilst its reasonably strong, it does suffer from a few weaknesses, the main one being that the encryption key is transmitted as plain text from the server to the client at some point. See my blog post for a longer discussion of these issues.

Click here to download the ZIP

Click here to browse the subversion repository .

3 Responses to “Crypto”

  1. Andy Says:

    Thanks! I needed a simple encryption algorithm today for some web stuff and this works perfectly :)

  2. Pete Says:

    I’m trying to figure out the lisence agreement to use this code. Is it GPL, BSD or something else? I would like to use one of the methods in this code, but I also would need to give credit and have license to use. So can you help me out?

  3. judge Says:

    Which function?

Leave a Reply