Skip to content

Commit 4689a38

Browse files
committed
Config envs PROXY_LISTENER_KEY_PASSWORD, TLS_CLIENT_KEY_PASSWORD, SASL_PASSWORD and GSSAPI_PASSWORD
1 parent 051075f commit 4689a38

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ VERSION ?= $(shell git describe --tags --always --dirty)
1010
GOPKGS = $(shell go list ./... | grep -v /vendor/)
1111
BUILD_FLAGS ?=
1212
LDFLAGS ?= -X github.com/grepplabs/kafka-proxy/config.Version=$(VERSION) -w -s
13-
TAG ?= "v0.3.4"
13+
TAG ?= "v0.3.5"
1414
GOARCH ?= amd64
1515
GOOS ?= linux
1616

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ The Proxy can terminate TLS traffic and authenticate users using SASL/PLAIN. The
1818
is configurable and uses golang plugin system over RPC.
1919

2020
The proxies can also authenticate each other using a pluggable method which is transparent to other Kafka servers and clients.
21-
Currently the Google ID Token for service accounts is implemented i.e. proxy client requests and sends service account JWT and proxy server receives and validates it against Google JWKS.
21+
Currently, the Google ID Token for service accounts is implemented i.e. proxy client requests and sends service account JWT and proxy server receives and validates it against Google JWKS.
2222

2323
Kafka API calls can be restricted to prevent some operations e.g. topic deletion or produce requests.
2424

@@ -47,11 +47,11 @@ As not every Kafka release adds new messages/versions which are relevant to the
4747

4848
Linux
4949

50-
curl -Ls https://github.com/grepplabs/kafka-proxy/releases/download/v0.3.4/kafka-proxy-v0.3.4-linux-amd64.tar.gz | tar xz
50+
curl -Ls https://github.com/grepplabs/kafka-proxy/releases/download/v0.3.5/kafka-proxy-v0.3.5-linux-amd64.tar.gz | tar xz
5151

5252
macOS
5353

54-
curl -Ls https://github.com/grepplabs/kafka-proxy/releases/download/v0.3.4/kafka-proxy-v0.3.4-darwin-amd64.tar.gz | tar xz
54+
curl -Ls https://github.com/grepplabs/kafka-proxy/releases/download/v0.3.5/kafka-proxy-v0.3.5-darwin-amd64.tar.gz | tar xz
5555

5656
2. Move the binary in to your PATH.
5757

@@ -69,7 +69,7 @@ Docker images are available on [Docker Hub](https://hub.docker.com/r/grepplabs/k
6969
7070
You can launch a kafka-proxy container for trying it out with
7171
72-
docker run --rm -p 30001-30003:30001-30003 grepplabs/kafka-proxy:v0.3.4 \
72+
docker run --rm -p 30001-30003:30001-30003 grepplabs/kafka-proxy:v0.3.5 \
7373
server \
7474
--bootstrap-server-mapping "localhost:19092,0.0.0.0:30001" \
7575
--bootstrap-server-mapping "localhost:29092,0.0.0.0:30002" \
@@ -88,7 +88,7 @@ Docker images with precompiled plugins located in `/opt/kafka-proxy/bin/` are ta
8888
8989
You can launch a kafka-proxy container with auth-ldap plugin for trying it out with
9090
91-
docker run --rm -p 30001-30003:30001-30003 grepplabs/kafka-proxy:v0.3.4-all \
91+
docker run --rm -p 30001-30003:30001-30003 grepplabs/kafka-proxy:v0.3.5-all \
9292
server \
9393
--bootstrap-server-mapping "localhost:19092,0.0.0.0:30001" \
9494
--bootstrap-server-mapping "localhost:29092,0.0.0.0:30002" \

cmd/kafka-proxy/server.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ func initFlags() {
102102
Server.Flags().BoolVar(&c.Proxy.TLS.Enable, "proxy-listener-tls-enable", false, "Whether or not to use TLS listener")
103103
Server.Flags().StringVar(&c.Proxy.TLS.ListenerCertFile, "proxy-listener-cert-file", "", "PEM encoded file with server certificate")
104104
Server.Flags().StringVar(&c.Proxy.TLS.ListenerKeyFile, "proxy-listener-key-file", "", "PEM encoded file with private key for the server certificate")
105-
Server.Flags().StringVar(&c.Proxy.TLS.ListenerKeyPassword, "proxy-listener-key-password", "", "Password to decrypt rsa private key")
105+
Server.Flags().StringVar(&c.Proxy.TLS.ListenerKeyPassword, "proxy-listener-key-password", os.Getenv("PROXY_LISTENER_KEY_PASSWORD"), "Password to decrypt rsa private key")
106106
Server.Flags().StringVar(&c.Proxy.TLS.CAChainCertFile, "proxy-listener-ca-chain-cert-file", "", "PEM encoded CA's certificate file. If provided, client certificate is required and verified")
107107
Server.Flags().StringSliceVar(&c.Proxy.TLS.ListenerCipherSuites, "proxy-listener-cipher-suites", []string{}, "List of supported cipher suites")
108108
Server.Flags().StringSliceVar(&c.Proxy.TLS.ListenerCurvePreferences, "proxy-listener-curve-preferences", []string{}, "List of curve preferences")
@@ -153,7 +153,7 @@ func initFlags() {
153153
Server.Flags().BoolVar(&c.Kafka.TLS.InsecureSkipVerify, "tls-insecure-skip-verify", false, "It controls whether a client verifies the server's certificate chain and host name")
154154
Server.Flags().StringVar(&c.Kafka.TLS.ClientCertFile, "tls-client-cert-file", "", "PEM encoded file with client certificate")
155155
Server.Flags().StringVar(&c.Kafka.TLS.ClientKeyFile, "tls-client-key-file", "", "PEM encoded file with private key for the client certificate")
156-
Server.Flags().StringVar(&c.Kafka.TLS.ClientKeyPassword, "tls-client-key-password", "", "Password to decrypt rsa private key")
156+
Server.Flags().StringVar(&c.Kafka.TLS.ClientKeyPassword, "tls-client-key-password", os.Getenv("TLS_CLIENT_KEY_PASSWORD"), "Password to decrypt rsa private key")
157157
Server.Flags().StringVar(&c.Kafka.TLS.CAChainCertFile, "tls-ca-chain-cert-file", "", "PEM encoded CA's certificate file")
158158

159159
//Same TLS client cert tls-same-client-cert-enable
@@ -162,15 +162,15 @@ func initFlags() {
162162
// SASL by Proxy
163163
Server.Flags().BoolVar(&c.Kafka.SASL.Enable, "sasl-enable", false, "Connect using SASL")
164164
Server.Flags().StringVar(&c.Kafka.SASL.Username, "sasl-username", "", "SASL user name")
165-
Server.Flags().StringVar(&c.Kafka.SASL.Password, "sasl-password", "", "SASL user password")
165+
Server.Flags().StringVar(&c.Kafka.SASL.Password, "sasl-password", os.Getenv("SASL_PASSWORD"), "SASL user password")
166166
Server.Flags().StringVar(&c.Kafka.SASL.JaasConfigFile, "sasl-jaas-config-file", "", "Location of JAAS config file with SASL username and password")
167167
Server.Flags().StringVar(&c.Kafka.SASL.Method, "sasl-method", "PLAIN", "SASL method to use (PLAIN, SCRAM-SHA-256, SCRAM-SHA-512, GSSAPI, AWS_MSK_IAM")
168168

169169
// SASL GSSAPI
170170
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.AuthType, "gssapi-auth-type", config.KRB5_KEYTAB_AUTH, "GSSAPI auth type: KEYTAB or USER")
171171
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.ServiceName, "gssapi-servicename", "kafka", "ServiceName")
172172
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.Username, "gssapi-username", "kafka", "Username")
173-
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.Password, "gssapi-password", "", "Password for auth type USER")
173+
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.Password, "gssapi-password", os.Getenv("GSSAPI_PASSWORD"), "Password for auth type USER")
174174
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.Realm, "gssapi-realm", "", "Realm")
175175
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.KerberosConfigPath, "gssapi-krb5", "/etc/krb5.conf", "krb5.conf file path, default: /etc/krb5.conf")
176176
Server.Flags().StringVar(&c.Kafka.SASL.GSSAPI.KeyTabPath, "gssapi-keytab", "", "krb5.keytab file location")

0 commit comments

Comments
 (0)