Update commonlib to latest version.
Use more correct checking of HTTPS_ONLY configuration parameter.