← All posts

One login, fewer passwords to look after

Run enough services for yourself and you can end up administering a small organisation whose main employee is you. Each application wants an account and a password. I'd rather not repeat that work everywhere.

That's my main reason for single sign-on, or SSO. I use Authentik wherever I can integrate it, including authentication for kubectl, the Kubernetes command-line tool. Easier onboarding for family and friends is useful too, but the convenience earns its place for me alone.

One identity, several services

An application sends me to Authentik to sign in, then uses the returned identity to establish its own session. Where the policies allow it, an existing Authentik session lets me enter another service without signing in again. The application doesn't need another password from me.

I prefer integrations using OpenID Connect, or OIDC, because it's a documented standard for exchanging identity information. It gives me a clearer way to understand the integration than a different custom login mechanism for every service. Changing providers still takes work.

Browser or kubectl -> Authentik -> identity token
                                      |
                                      v
                        Application or Kubernetes
                        checks its own permissions

Knowing who I am doesn't decide everything I'm allowed to do. Applications keep their own permissions. In Zebra, my Kubernetes cluster, role-based access control (RBAC) determines what an authenticated identity can change. The tenant setup uses scoped permissions; my administrative identity has cluster-admin authority. OIDC doesn't make that authority smaller.

What happens after sign-in

The Kubernetes API server validates a token's signature and expiry without asking Authentik about every request. Disabling an account therefore doesn't necessarily stop an already issued token immediately. Applications can also retain their own sessions, and refresh tokens may obtain new credentials without another interactive login.

That's why a stolen laptop session is different from a guessed password. Revoking access needs to cover the relevant tokens and sessions, not just changing the password and assuming every door has closed. I need to test the behaviour of important integrations rather than treat them all alike.

My configuration includes a WebAuthn passkey path with user verification required. Passkeys bind authentication to the service's origin, helping against fake login pages. Enrolment isn't forced by that configuration, and the ordinary password flow is separate. Having passkeys available doesn't establish mandatory multi-factor protection for every account or fallback.

Local application accounts and API keys also need attention. Centralising sign-in reduces repeated password management, but doesn't retire every other credential by itself. The security assessment follows those remaining paths.

Keeping a way back in

Authentik runs inside the cluster I administer through it. If it is down and I have no usable credentials left, I need another route to repair it. New sign-ins can fail even while an application is healthy; existing sessions depend on that application's behaviour.

Vaultwarden, our password manager, is a deliberate exception to SSO. Its login must not depend on Authentik or the private mesh. That avoids a recovery loop while leaving its hosting dependencies intact. I explain those limits in getting access when the login service is down.

For two applications, separate accounts may be less work. With my collection, a shared login reduces enough repetition to justify looking after it. If you're considering the same, keep the permissions separate and practise the way back in. I want fewer passwords to manage, not a particularly elegant way to lock myself out.

← Back to the notebook