# Heartbeat Config advice

**URL:** <https://discuss.elastic.co/t/heartbeat-config-advice/155611>\
**Category:** Beats\
**Tags:** heartbeat\
**Created:** [November 6, 2018, 7:55pm UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611 "2018-11-06T19:55:11Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Francois\_013](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/francois_013/32/37046_2.png) [@Francois\_013](https://discuss.elastic.co/u/Francois_013)\
**Post date:** [November 6, 2018, 7:55pm UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/1 "2018-11-06T19:55:11Z")

</div>

Hi,

I’m trying to configure a heartbeat http monitor to monitor a https URL protected by a client certificate. But it seems that I cannot get it working in a proper way.

I’ve tried serval configs listed below:

Config 1:  
heartbeat.monitors:

- type: http  
urls: ["[https://URL.url](https://URL.url)"]  
schedule: '@every 10s'  
ssl:  
certificate\_authorities: ['ca.crt']  
certificate: ['cert.crt']  
key: ['key.key']

This results in that I can start the service but the http monitor fails with:  
ERROR beater/manager.go:155 failed to load monitor tasks: can not convert 'object' into 'string' accessing 'ssl.certificate' (source:'C:\Program Files\Heartbeat\heartbeat.yml') when initializing monitor http(0)

Config 2:  
heartbeat.monitors:

- type: http  
urls: ["[https://URL.url](https://URL.url)"]  
schedule: '@every 10s'  
ssl:  
certificate\_authorities: “ca.crt”  
certificate: “cert.crt”  
key: “'key.key”

This results in a complete failure of the service. (refuses to start)

Config 3: (Only using the CA as authenticator)  
heartbeat.monitors:

- type: http  
urls: ["[https://url.url](https://url.url)"]  
schedule: '@every 10s'  
ssl:  
certificate\_authorities: ['CA.crt']

This results in a start of the service and the http monitor functions.  
But I’m getting a response: “x509: certificate signed by unknown authority”

Can somebody point out what I’m doing wrong?

Many thanks in advance!

---

<div class="post-metadata">

**Author:** ![Andrew\_Cholakian1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrew_cholakian1/32/3612_2.png) [@Andrew\_Cholakian1](https://discuss.elastic.co/u/Andrew_Cholakian1)\
**Post date:** [November 7, 2018, 9:27pm UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/2 "2018-11-07T21:27:21Z")

</div>

Thanks for the report. I've created an issue to track this: [https://github.com/elastic/beats/issues/8979](https://github.com/elastic/beats/issues/8979).

I'll post updates there

---

<div class="post-metadata">

**Author:** ![Andrew\_Cholakian1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrew_cholakian1/32/3612_2.png) [@Andrew\_Cholakian1](https://discuss.elastic.co/u/Andrew_Cholakian1)\
**Post date:** [November 8, 2018, 4:00am UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/3 "2018-11-08T04:00:08Z")

</div>

@Francois I added a test case for this, which we needed [in #8984](https://github.com/elastic/beats/pull/8984), but it wound up showing that client auth works.

For case 2, can you provide any error logs showing what specifically did not work?

---

<div class="post-metadata">

**Author:** ![ramkumargopal](https://avatars.discourse-cdn.com/v4/letter/r/a587f6/32.png) [@ramkumargopal](https://discuss.elastic.co/u/ramkumargopal)\
**Post date:** [November 15, 2018, 8:35am UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/4 "2018-11-15T08:35:03Z")

</div>

i have a similar issue when i monitor https URL , http works fine .

---

<div class="post-metadata">

**Author:** ![Andrew\_Cholakian1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrew_cholakian1/32/3612_2.png) [@Andrew\_Cholakian1](https://discuss.elastic.co/u/Andrew_Cholakian1)\
**Post date:** [November 16, 2018, 5:24pm UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/5 "2018-11-16T17:24:27Z")

</div>

Hmmmm, can you validate that this client cert works? Have you tried testing it with cURL for instance?

---

<div class="post-metadata">

**Author:** ![ramkumargopal](https://avatars.discourse-cdn.com/v4/letter/r/a587f6/32.png) [@ramkumargopal](https://discuss.elastic.co/u/ramkumargopal)\
**Post date:** [November 17, 2018, 3:21am UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/6 "2018-11-17T03:21:08Z")

</div>

Tried disableing ssl verification ssl.verification\_mode: none and it worked

---

<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:** [December 15, 2018, 3:21am UTC](https://discuss.elastic.co/t/heartbeat-config-advice/155611/7 "2018-12-15T03:21:11Z")

</div>

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