improve handling of SSL Non-Verify Hostname and Certificate