Apache Kafka security

Specific Kafka security controls below the hardening overview: TLS and mTLS, SCRAM and Kerberos, ACL design, delegation tokens, Connect and JMX, encryption at rest, patching and testing.

Configuring TLS encryption for Kafka listeners

Encrypting client and inter-broker traffic: keystores and truststores, listener and security protocol maps, hostname verification, enabled TLS protocols and certificate rotation without downtime.

Mutual TLS client authentication in Apache Kafka

Authenticating clients with certificates: ssl.client.auth required, mapping certificate subjects to principals for ACLs, issuing and revoking client certificates and why requested mode gives false comfort.

SASL/SCRAM authentication in KRaft-mode Kafka

Username and password authentication done safely: SCRAM-SHA-256 or 512 credentials in the metadata log, creating them at format time or with kafka-configs, TLS as a requirement and rotating credentials.

Kafka Kerberos authentication with SASL/GSSAPI

Using Kerberos for Kafka in Active Directory or FreeIPA environments: service principals and keytabs for brokers, client JAAS configuration, principal mapping rules and common ticket problems.

Designing Kafka ACLs for least privilege

Building an ACL model that scales: deny-by-default with the StandardAuthorizer, prefixed ACLs per team or application, producer and consumer convenience options, super users, and reviewing ACLs regularly.

Encryption at rest for Apache Kafka data

Protecting Kafka data on disk when Kafka itself does not encrypt it: disk or volume encryption, encrypting tiered storage buckets, sensitive metadata stored unencrypted in KRaft, and application-level payload encryption.

Securing Kafka JMX and monitoring endpoints

Exposing metrics without exposing control: keeping remote JMX off, using an exporter on a restricted port, JMX authentication and TLS when needed, and network rules for monitoring traffic.

Penetration testing an Apache Kafka deployment

Scoping a security test of Kafka: listener exposure and plaintext ports, authentication bypass, ACL gaps, the Connect REST API, JMX, Schema Registry and UIs, run safely against production-like clusters.

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.