Encryption functions cleanup