Fixed cryptography encrypt and decrypt methods.