set encrypt and decrypt