What Do You Mean K8s Doesn't Have Users? How Do I Manage User Access Then?
summary
Kubernetes does not store or manage user accounts: authentication is external and the API server only receives a username string to feed into RBAC. Four practical auth options exist: client certificates are effectively unrevocable because the cluster CA stays static, static token file requires API server restart to change tokens, webhook token auth calls TokenReview to an external service for per-request validation, and use OpenID Connect with signed JWTs to tie existing identity providers into RBAC.
AI-written summary · about
chapters (17)
- 0:00Intro
- 2:00TRY TO REALIZE THE TRUTH
- 2:47Topics • How AAA works in general
- 3:30How AAA works in k8s API server • Every call to API is tied to
- 5:34Two categories of identities • ServiceAccount For processes (pods)
- 7:40User is a "transient" thing • User data not stored on etcd User info is "just a string"
- 8:20Ways to identify a user • X509 certs
- 8:52User identification - client certs • Control plane manages CA
- 10:46Client cert - gothas (in a typical setup) • CA is static for the lifetime of cluster Other cluster components authenticating with client certs
- 12:23User identification - token file • CSV file for user tokens
- 13:25Token file - gotchas • Tokens loaded only at api-server boot • Tokens in plain text Tokens cannot be invalidated
- 14:25User identification - Webhook Token Auth • External service validating
- 16:39User identification - OIDC • api-server configured to trust
- 19:08Comparison / Summary
- 22:40Authorization • Can a user perform the action?
- 23:54How to tie users into RBAC
- 25:21Summary • User is a "transient" thing
related talks
41mKubernetes Auth and Access Control
33mBeyond Cluster-Admin: Getting Started with Kubernetes Users and Permissions
33mHow the Basics Of Kubernetes Auth Scale For Organizations
35mRBAC to the Future: Untangling Authorization in Kubernetes
31mKubernetes RBAC Security: A Practical Overview
19mAuditing Kubernetes Users: Tracking Security Holes
25mMastering K8s Security
45mBeyond cluster-admin: Getting Started with Kubernetes Users and Permissions
