Skip to content

hoverkraft-tech/http-header-authenticator

Repository files navigation

http-header-authenticator

Go micro-service used to authenticate http requests based on provided fix http headers

usage

http-header-authenticator check -H 'X-acme-auth' -V 'SomeSecurePassword'
curl -H 'X-acme-auth: SomeSecurePassword' localhost:8080 # -> 200
curl localhost:8080 # -> 404

Can be used with nginx-ingress controller to authenticate requests comming from CDN servers See https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/configmap/#global-auth-url for inspiration

installation

using helm

helm upgrade http-header-authenticator oci://harbor.hoverkraft.cloud/public/charts/http-header-authenticator \
  --install --create-namespace --namespace http-header-authenticator

docker

docker-compose up -d --build

from sources

go build -o ./bin/http-header-authenticator ./src/github.com/hoverkraft-tech/http-header-authenticator