# \[2021-08-18T14:40:31,056\]\[WARhttp client did not trust this server's certificate, closing connection Netty4HttpChannel

**URL:** <https://discuss.elastic.co/t/2021-08-18t1431-056-warhttp-client-did-not-trust-this-servers-certificate-closing-connection-netty4httpchannel/281869>\
**Category:** Elasticsearch\
**Tags:** es-hadoop\
**Created:** [August 18, 2021, 7:11pm UTC](https://discuss.elastic.co/t/2021-08-18t1431-056-warhttp-client-did-not-trust-this-servers-certificate-closing-connection-netty4httpchannel/281869 "2021-08-18T19:11:01Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mlo](https://avatars.discourse-cdn.com/v4/letter/m/7c8e57/32.png) [@mlo](https://discuss.elastic.co/u/mlo)\
**Post date:** [August 18, 2021, 7:11pm UTC](https://discuss.elastic.co/t/2021-08-18t1431-056-warhttp-client-did-not-trust-this-servers-certificate-closing-connection-netty4httpchannel/281869/1 "2021-08-18T19:11:02Z")

</div>

Hi,

I am working in databricks and had this working and now it stopped without any changes to my code.

I am connecting to Elastic with the es-hadoop client via pyspark. Here are my settings

```auto
.format("org.elasticsearch.spark.sql") \
        .option("es.resource",esindex) \
        .option("es.port", 9200) \
        .option("es.nodes", datanode) \
        .option("es.net.ssl","true") \
        .option("es.nodes.wan.only", "true") \
        .option("es.net.ssl.certificate_authorities", "/dbfs/FileStore/tables/trustedroot.crt") \
        .option("es.net.ssl.supported_protocols", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384") \
        .option("es.net.ssl.verification_mode", "false") \
        .option("es.net.ssl.certtp.allow.self.signed", "true") \
        .option("es.net.http.auth.user", username) \
        .option("es.net.http.auth.pass", password) \
        .option("es.spark.dataframe.write.null", "true")

```

and I am now getting this error in the elastic logs. and getting this error on the client side.  
**Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target**

Any help is appreciated

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 15, 2021, 7:11pm UTC](https://discuss.elastic.co/t/2021-08-18t1431-056-warhttp-client-did-not-trust-this-servers-certificate-closing-connection-netty4httpchannel/281869/2 "2021-09-15T19:11:50Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
