Support loading Basic Auth credentials from Kubernetes Secrets
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 71
- Forks
- 111
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 110
Description
Current Limitation
Currently, the Gateway Operator only allows configuring Basic Authentication users via the values.yaml inside a ConfigMap. This requires embedding sensitive credentials (passwords or hashes) directly into the ConfigMap manifests or Helm values.
Storing credentials in ConfigMaps is not a security best practice as they are not encrypted at rest by default and are often checked into version control systems in plain text.
Suggested Improvement
Introduce a mechanism to load Basic Authentication users from a standard Kubernetes
Secret
###Proposed Design:
- Update the Gateway CRD to include an optional authSecretRef field.
- The Operator should look for a users.yaml key within the referenced Secret.
- This Secret-based configuration should take precedence over the existing ConfigMap configuration if both are present.
Example Secret:
apiVersion: v1
kind: Secret
type: Opaque
stringData:
users.yaml: |
- username: "admin"
password: "secure-password"
roles: ["admin"]
Example Gateway CR:
spec:
authSecretRef:
name: my-auth-secret
This ensures sensitive data is handled securely using native Kubernetes primitives.
Version
No response
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the Gateway CRD and the Gateway Operator configuration path that currently reads Basic Auth users from ConfigMap values. Trace how an authSecretRef and its users.yaml key should be represented, then verify Secret-only and both-sources cases; done means the CRD accepts the reference and Secret users take precedence over ConfigMap users.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- backend, infrastructure, security
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100