Added encryption support.