# FIlebeat SSL Issue

**URL:** <https://discuss.elastic.co/t/filebeat-ssl-issue/188577>\
**Category:** Beats\
**Created:** [July 2, 2019, 7:29pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577 "2019-07-02T19:29:07Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![adwaitjoshi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adwaitjoshi/32/35098_2.png) [@adwaitjoshi](https://discuss.elastic.co/u/adwaitjoshi)\
**Post date:** [July 2, 2019, 7:29pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/1 "2019-07-02T19:29:07Z")

</div>

I am using SSL for Kibana and have the following config values set in the filebeat.yml file

ssl.enabled: true  
ssl.certificate: "cert.pem"  
ssl.key: "key.pem"  
ssl.key\_passphrase: "XXXXXXXX"

when I try to run filebeat setup I get the following error

Index setup finished.  
Loading dashboards (Kibana must be running and reachable)  
Exiting: error connecting to Kibana: fail to load the TLS config: 1 error: tls: failed to parse private key

I am a 100% certain my passphrase is right and the certs are good. Any ideas what may be going on?

---

<div class="post-metadata">

**Author:** ![Juanma](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/juanma/32/49076_2.png) [@Juanma](https://discuss.elastic.co/u/Juanma)\
**Post date:** [July 2, 2019, 8:12pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/2 "2019-07-02T20:12:52Z")

</div>

Hello @adwaitjoshi

Where have you seen these parameters for kibana setup?

I just configured a filebeat 7.2 against kibana and worked just fine with the following configuration:

```
  setup.kibana:

  # Kibana Host
  # Scheme and port can be left out and will be set to the default (http and 5601)
  # In case you specify and additional path, the scheme is required: http://localhost:5601/path
  # IPv6 addresses should always be defined as: https://[2001:db8::1]:5601
  host: "https://hostname:5601"

```

As you can see at [https://www.elastic.co/guide/en/beats/filebeat/current/configuration-ssl.html](https://www.elastic.co/guide/en/beats/filebeat/current/configuration-ssl.html) the key parameter is for authentication so unless you have ssl auth it won't be necessary.

In case to add a parameter I would add the CA as in the following link [https://www.elastic.co/guide/en/beats/filebeat/current/setup-kibana-endpoint.html](https://www.elastic.co/guide/en/beats/filebeat/current/setup-kibana-endpoint.html)

I hope this help. 🙂

---

<div class="post-metadata">

**Author:** ![adwaitjoshi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adwaitjoshi/32/35098_2.png) [@adwaitjoshi](https://discuss.elastic.co/u/adwaitjoshi)\
**Post date:** [July 3, 2019, 2:33pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/3 "2019-07-03T14:33:49Z")

</div>

So yes, we do have authentication on ES and Kibana. I have tried the following configs as well

host: "x.x.x.x:5601"  
protocol: "https"  
username: "elastic"  
password: "XXXXXXXXXX"

and then I get the following error

Index setup finished.  
Loading dashboards (Kibana must be running and reachable)  
Exiting: error connecting to Kibana: fail to get the Kibana version: HTTP GET request to [https://x.x.x.x:5601/s/filebeat/api/status](https://x.x.x.x:5601/s/filebeat/api/status) fails: fail to execute the HTTP GET request: Get [https://x.x.x.x:5601/s/filebeat/api/status:](https://x.x.x.x:5601/s/filebeat/api/status:) x509: cannot validate certificate for x.x.x.x because it doesn't contain any IP SANs. Response: .

---

<div class="post-metadata">

**Author:** ![Juanma](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/juanma/32/49076_2.png) [@Juanma](https://discuss.elastic.co/u/Juanma)\
**Post date:** [July 3, 2019, 3:03pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/4 "2019-07-03T15:03:16Z")

</div>

Hello @adwaitjoshi

Seems that you are using and ip on the URI.

In order to make ssl work you have to use the hostname provided in the certificate or change the certificate including the ip in it. You also can disable certificate validation.

I hope this helps 🙂

---

<div class="post-metadata">

**Author:** ![adwaitjoshi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adwaitjoshi/32/35098_2.png) [@adwaitjoshi](https://discuss.elastic.co/u/adwaitjoshi)\
**Post date:** [July 3, 2019, 5:34pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/5 "2019-07-03T17:34:29Z")

</div>

Disabling validation would be the right approach in our case, however there seems to be no such property on filebeat or kibana. Unless i am overlooking something.

---

<div class="post-metadata">

**Author:** ![Juanma](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/juanma/32/49076_2.png) [@Juanma](https://discuss.elastic.co/u/Juanma)\
**Post date:** [July 3, 2019, 6:29pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/6 "2019-07-03T18:29:19Z")

</div>

Hello

Try with setup.kibana.ssl.verification\_mode to none, source: [https://www.elastic.co/guide/en/beats/filebeat/current/configuration-ssl.html](https://www.elastic.co/guide/en/beats/filebeat/current/configuration-ssl.html)

---

<div class="post-metadata">

**Author:** ![adwaitjoshi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adwaitjoshi/32/35098_2.png) [@adwaitjoshi](https://discuss.elastic.co/u/adwaitjoshi)\
**Post date:** [July 3, 2019, 6:39pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/7 "2019-07-03T18:39:52Z")

</div>

WOW I feel like an idiot now I must have looked for it over an hour! That did the trick. Thanks.

---

<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:** [July 31, 2019, 8:39pm UTC](https://discuss.elastic.co/t/filebeat-ssl-issue/188577/8 "2019-07-31T20:39:52Z")

</div>

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