-
Notifications
You must be signed in to change notification settings - Fork 873
Oauth bearer integration test setup
Matt Howlett edited this page Aug 20, 2020
·
1 revision
Some configuration settings suitable for running the oauth bearer tests.
testconf.json:
{
"bootstrapServers": "127.0.0.1:9092",
"oauthbearerBootstrapServers": "127.0.0.1:9093"
}
jaas.conf file:
KafkaServer {
org.apache.kafka.common.security.oauthbearer.OAuthBearerLoginModule required
unsecuredLoginStringClaim_sub="Tester";
};
zookeeper config:
dataDir=/tmp/zookeeper-oauth
clientPort=2182
maxClientCnxns=0
admin.enableServer=false
server config:
broker.id=0
listener.name.sasl_ssl.oauthbearer.sasl.jaas.config=org.apache.kafka.common.security.oauthbearer.OAuthBearerLoginModule required unsecuredLoginStringClaim_sub="Tester";
listeners=SASL_PLAINTEXT://127.0.0.1:9093
advertised.listeners=SASL_PLAINTEXT://127.0.0.1:9093
sasl.mechanism.inter.broker.protocol=OAUTHBEARER
sasl.enabled.mechanisms=OAUTHBEARER
security.inter.broker.protocol=SASL_PLAINTEXT
num.network.threads=3
num.io.threads=8
socket.send.buffer.bytes=102400
socket.receive.buffer.bytes=102400
socket.request.max.bytes=104857600
log.dirs=/tmp/kafka-logs-oauth
num.partitions=1
num.recovery.threads.per.data.dir=1
offsets.topic.replication.factor=1
transaction.state.log.replication.factor=1
transaction.state.log.min.isr=1
log.retention.hours=168
log.segment.bytes=1073741824
log.retention.check.interval.ms=300000
zookeeper.connect=localhost:2182
zookeeper.connection.timeout.ms=18000
group.initial.rebalance.delay.ms=0
before starting kafka:
export KAFKA_OPTS="-Djava.security.auth.login.config=/path/to/jaas.conf