How to encrypt or decrypt message