working encryption/decryption