Encrypting tokens
Created by: chayim
This code implements AES encryption and decryption of strings, based on a token we provide. We use a nonce on a per action basis, in order to ensure that the encryption is both reproducible and separate. Similarly, this includes tests to validate the encryption/decryption cycle, and the contra-positive - an invalid key cannot decrypt.