http: use new API with LibreSSL >=2.7.0