Catch more exceptions in EncryptedStreams
added test keypair