adding encrypt/decrypt functionality