encrypt/decrypt function added, fails though