Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add LDAP auth for elasticsearch using nginx-ldapauth-proxy #250

Open
virtuman opened this issue Aug 8, 2018 · 4 comments
Open

Add LDAP auth for elasticsearch using nginx-ldapauth-proxy #250

virtuman opened this issue Aug 8, 2018 · 4 comments
Labels
kind:design Solution design choices legacy Anything related to MetalK8s 1.x state:question Further information is requested topic:operations Operations-related issues topic:security Security-related issues

Comments

@virtuman
Copy link

virtuman commented Aug 8, 2018

Since nginx-ingress is already part of metal-k8s, wouldn't it be beneficial to add nginx-ldapauth-proxy to metal-k8s as an optional component to allow to securely expose kibana and maybe elasticsearch?

Helm Chart itself:
https://github.com/helm/charts/tree/master/stable/nginx-ldapauth-proxy

And the use-case example:
https://github.com/helm/charts/blob/master/incubator/elastic-stack/requirements.yaml#L20
https://github.com/helm/charts/blob/master/incubator/elastic-stack/values.yaml#L18

@NicolasT NicolasT added state:question Further information is requested kind:design Solution design choices topic:security Security-related issues topic:operations Operations-related issues labels Aug 8, 2018
@NicolasT NicolasT added this to To do in OIDC Authentication & Authorization via automation Aug 8, 2018
@NicolasT
Copy link
Contributor

NicolasT commented Aug 8, 2018

To access cluster-provisioned services like Kibana and Grafana, we document the use of kubectl proxy to access these through the API. This allows us to define fine-grained roles giving access to these cluster services.

The Elasticsearch as deployed with MetalK8s is not really intended to be used by any other services except for cluster logging, so this shouldn't be exposed through an Ingress object.

If at some point we integrate an OIDC provider (see #85, #83, #84) we could deploy a mechanism to access Kibana and Grafana more directly, without going through the API proxy, by fronting them with e.g. keycloak-proxy or similar.

I'd rather not integrate nginx-ldapauth-proxy because this ties us too much into LDAP. Instead using a federated protocol, potentially backed by an LDAP directory (as Dex could provide) seems to be a better approach.

Overall, access to cluster resources, be it K8s API, Kibana logs, Grafana,... all falls somewhat in the same realm authentication/authorization-wise.

@virtuman
Copy link
Author

i didn't know that Dex can be configured in such a way to allow http auth to a resource, such as kibana to be password protected. does it? i thought it can only operate as a backend to something that consumes dex like if it was a database of users, but some script still needs to attempt to access "dex"?

@NicolasT
Copy link
Contributor

Dex doesn't, but an OIDC-aware authenticating proxy (like keycloak-proxy) can.

@NicolasT
Copy link
Contributor

With helm/charts@b19cd59#diff-1104eae0826c45bb7d9cd233aff17b1e in the Kibana chart, once we have the Helm 'values override' in place everywhere (cfr. #291), it should be possible to set up auth for Kibana without any changes to MetalK8s required.

@gdemonet gdemonet added the legacy Anything related to MetalK8s 1.x label Feb 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:design Solution design choices legacy Anything related to MetalK8s 1.x state:question Further information is requested topic:operations Operations-related issues topic:security Security-related issues
Projects
No open projects
Development

No branches or pull requests

3 participants