# SunCertPathBuilderException when Logstash 6.4.2 outputs to HTTPS

**URL:** <https://discuss.elastic.co/t/suncertpathbuilderexception-when-logstash-6-4-2-outputs-to-https/159567>\
**Category:** Logstash\
**Created:** [December 5, 2018, 3:44pm UTC](https://discuss.elastic.co/t/suncertpathbuilderexception-when-logstash-6-4-2-outputs-to-https/159567 "2018-12-05T15:44:26Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vmaldosan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vmaldosan/32/37208_2.png) [@vmaldosan](https://discuss.elastic.co/u/vmaldosan)\
**Post date:** [December 5, 2018, 3:44pm UTC](https://discuss.elastic.co/t/suncertpathbuilderexception-when-logstash-6-4-2-outputs-to-https/159567/1 "2018-12-05T15:44:26Z")

</div>

Hi there,  
I'm trying to forward messages from RabbitMQ to an HTTPS server, using a self-signed certificate. The relevant piece of my configuration is as follows:

```
output {
    http {
        url => "https://localhost:8443/<...>"
        format => "json"
        http_method => "post"
        keystore => "<...>keystore.p12"
        keystore_type => "PKCS12"
        keystore_password => "..."
    }
}

```

The error I get is:

> :message=\>"PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target", :class=\>"Manticore::ClientProtocolException"

The body of the request is correct, since it works fine over HTTP (obviously with an updated configuration file).

Is it anything obvious I'm missing here?

---

<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:** [January 2, 2019, 3:44pm UTC](https://discuss.elastic.co/t/suncertpathbuilderexception-when-logstash-6-4-2-outputs-to-https/159567/2 "2019-01-02T15:44:32Z")

</div>

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