fix https protocol bug