Added support for protocol configuration, so that HTTPS can be used.