To read from or write to a Kerberised Kafka cluster that runs on Linux operating system, configure the default realm, KDC, and Kafka advanced source or target properties.
You can configure Kerberos authentication for a Kafka client by placing the required Kerberos configuration files on the Secure Agent machine and specifying the required JAAS configuration in the Kafka connection. The JAAS configuration defines the keytab and principal details that the Kafka broker must use to authenticate the Kafka client.
Before you read from or write to a Kerberised Kafka cluster, perform the following tasks:
1Ensure that you have the krb5.conf file for the Kerberised Kafka cluster.
2Configure the default realm and KDC. If the default /etc/krb5.conf file is not configured or you want to change the configuration, add the following lines to the /etc/krb5.conf file:
[realms] <REALM NAME> = { kdc = <Location where KDC is installed> admin_server = <Location where KDC is installed> } [domain_realm] .<domain name or hostname> = <KERBEROS DOMAIN NAME> <domain name or hostname> = <KERBEROS DOMAIN NAME>
3To pass a static JAAS configuration file into the JVM using the java.security.auth.login.config property at runtime, perform the following tasks:
Configure the Consumer Configuration Properties property in the advanced source properties to override the value specified in the Additional Connection Properties property in a Kafka connection. Specify the value in the following format:
Configure the Producer Configuration Properties property in the advanced target properties to override the value specified in the Additional Connection Properties property in a Kafka connection. Specify the value in the following format:
Configure the Consumer Configuration Properties property in the advanced source properties to override the value specified in the Kerberos Configuration Properties property in a Kafka connection. Specify the value in the following format:
Configure the Producer Configuration Properties property in the advanced target properties to override the value specified in the Kerberos Configuration Properties property in a Kafka connection. Specify the value in the following format: