changed encryptable api to be more modular for future encryption schemes. updated tests.