# Error Return code 21: SSL encryption between filebeat 5.2 and kafka 1.0 (self signed)

**URL:** <https://discuss.elastic.co/t/error-return-code-21-ssl-encryption-between-filebeat-5-2-and-kafka-1-0-self-signed/119126>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [February 8, 2018, 9:13pm UTC](https://discuss.elastic.co/t/error-return-code-21-ssl-encryption-between-filebeat-5-2-and-kafka-1-0-self-signed/119126 "2018-02-08T21:13:36Z")\
**Posts on this page:** 1\
**Showing post:** 15

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [February 9, 2018, 9:10pm UTC](https://discuss.elastic.co/t/error-return-code-21-ssl-encryption-between-filebeat-5-2-and-kafka-1-0-self-signed/119126/15 "2018-02-09T21:10:00Z")

</div>

OK, so openssl connects OK, which suggests kafka is correctly configured. Running out of ideas here. Searching throws up a number of other occurrences of this (e.g. [this](https://discuss.elastic.co/t/kafka-bug/90682/2), [this](https://discuss.elastic.co/t/can-not-make-tls-ssl-connection-to-kafka-v0-9-using-filebeat-v5/53219), and [this](https://discuss.elastic.co/t/beats-5-6-and-kafka-1-0-ssl-handshake-error/114145)).

Can you remove the non-SSL entry from advertised listeners?

---

_[View the full topic](https://discuss.elastic.co/t/error-return-code-21-ssl-encryption-between-filebeat-5-2-and-kafka-1-0-self-signed/119126)._
