Add Content-Length header and default use https protocol