package kafka-eio
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=88c2b9c6d263a1eb114cc5d1b570288a
sha512=44f5395fcc58b8d4303bc0b36113a17193da3a1925125cb0742fabeb96f32eb6b243c98d2fde283b6c95872ff36ddbf96de6e98b7612799e2aefeb2f85a1db95
doc/kafka-eio.core/Kafka_security/index.html
Module Kafka_securitySource
Security transport configuration shared by producer and consumer.
type protocol = [ | `Plaintext(*No encryption or authentication. Local dev default.
*)| `Ssl(*TLS encryption, no SASL authentication.
*)| `Sasl_plaintext(*SASL authentication, no TLS encryption.
*)| `Sasl_ssl(*SASL authentication over TLS. Production default.
*)
]Plaintext. Use for local dev and unit tests. Do not use in production — requires explicit Ssl or Sasl_ssl.
Parse a finite Kafka security protocol value. Accepted values are "plaintext", "ssl", "sasl_plaintext", and "sasl_ssl", case insensitively.
Build from environment variables:
KAFKA_SECURITY_PROTOCOL—"plaintext" | "ssl" | "sasl_plaintext" | "sasl_ssl"(default:"plaintext", unknown values returnError)KAFKA_SSL_CA_LOCATION— path to CA cert bundleKAFKA_SASL_MECHANISM—"PLAIN" | "SCRAM-SHA-256" | "SCRAM-SHA-512"KAFKA_SASL_USERNAMEKAFKA_SASL_PASSWORD
Set librdkafka security.protocol, ssl.ca.location, and sasl.* keys on conf. Returns Error msg if any key is rejected by librdkafka. SASL credentials are required by the Sasl_plaintext and Sasl_ssl constructors. Called internally by producer and consumer conf_of_config; not part of the public API.