Added support for SSL