This week I added the JS file to encrypt/decrypt text using the Vigenere cypher. This has been an interesting experiment. I used the algebraic formula listed on wikipedia to compute the cipher. My algorithm is as follows:
1) Convert both text and key into number arrays.
2) Padd the key to match the length of the text.
3) For the length of the text, encrypt the letter one by one using the formula mentioned above.
4) Convert the ciphertext back to alphanumeric characters.
5) Join the array to remove commas from the array.
6)Display the ciphertext for the user.
And the decryption is the reverse of the above algorithm. Does it work? Sorta. It has successfully encrypted and decrypted a message, but a few characters seem a bit off. I’ll have to go over the algorithm again to make sure everything is right. Anyway, sign in to the site with login: guest and pass: guest. The encrypter and decrypter is what I have implemented. Feel free to try it out!