Skip to content

Sign-in and users

Liftway has three authentication modes, chosen at deployment time with authMode (Helm) or RUNWAY_AUTH_MODE.

Mode Who signs in Use
password (default) Personal accounts with server-side sessions; optional SSO Every shared installation
token One shared bearer token with administrator rights Legacy API-only setups
disabled Nobody; everyone is Dev user Only with RUNWAY_ENV=development — the controller refuses to start otherwise

If RUNWAY_AUTH_MODE is unset, Liftway uses token when RUNWAY_API_TOKEN is set and password otherwise.

The built-in administrator

On first start in password mode, Liftway creates the account admin from RUNWAY_ADMIN_PASSWORD (Helm: Secret adminPasswordSecret, key password). The value must be 12–256 characters and not admin, or the controller refuses to start.

  • The bootstrap value is used once. Changing the Secret later does not change the password; use Account → Change Password.
  • An old admin/admin account from early versions is replaced by the bootstrap password on upgrade.
  • admin bypasses roles and is the only account that can use the administration endpoints (settings, roles, SSO bindings, registration, users). Keep its password in a password manager and use personal accounts for daily work.

Sessions

Property Value
Cookie runway_session, HttpOnly, SameSite=Strict, Secure outside development
Lifetime 12 hours (shorter for SSO, see below)
Storage Only a SHA-256 digest of the session token is stored, in PostgreSQL
Revocation Sign-out, password change, deactivation, username change, deletion
Password hashing PBKDF2-SHA256, 600,000 iterations, per-password salt
Throttling 5 failed sign-ins from one client address block sign-in for 5 minutes (429)

For any request that changes something (POST, PUT, DELETE), the controller compares the browser's Origin header with its own base URL. Behind a TLS-terminating gateway, set forwardedAllowIps so the controller sees https://; otherwise you get Cross-origin request rejected (403).

Users

Users → Add creates a person in the directory and, with an initial password, a login account.

Field Rules
Username 1–100 of A–Z a–z 0–9 _ . @ -; unique ignoring case; admin is reserved
Name, surname Name required
Email Optional, validated, unique ignoring case
Password 8–256 characters, with confirmation; required for new users; write-only
Active Inactive users cannot sign in; deactivating ends their sessions
Organisations Memberships for orientation

Leaving the password empty when editing keeps the current one; setting it resets the password and signs the user out everywhere. A new user has no roles — assign them under Roles and permissions.

Account → Account Info shows the signed-in user's name, login, email and organisations; Change Password requires the current password and signs out all of the user's sessions.

Self-registration

Administration → Users → Registration can open a sign-up form on the login page. It is closed by default. People who register become active local users with no roles, so they can sign in but do nothing until an administrator assigns a role. All fields — name, surname, email, username, password and confirmation — are required.

Single sign-on

Liftway does not run the OIDC browser flow itself. An identity gateway (for example OAuth2 Proxy) in front of Liftway does, and passes the resulting ID token to Liftway. Liftway verifies it and maps the user's immutable subject to a local account.

1. Browser ──► your gateway (HTTPS) ──► /api/auth/sso is routed to the identity gateway
2. Identity gateway (OAuth2 Proxy) ◄──OIDC code flow──► identity provider
3. Identity gateway ──► Liftway, with  Authorization: Bearer <ID token>
4. Liftway verifies RS256 signature, issuer, audience and expiry against the JWKS
5. Liftway maps the token's sub to a bound, active user and sets the session cookie
6. Browser is redirected to /

Configure

  1. Register a dedicated OIDC client for Liftway in your identity provider.
  2. Configure the identity gateway with the authorization-code flow, TLS, its redirect URI and cookie secret, and make it replace the incoming Authorization header with the ID token (OAuth2 Proxy: --pass-authorization-header).
  3. Route the exact path /api/auth/sso through the identity gateway to Liftway, on the same external host as the rest of Liftway. Keep all other paths — including runner callbacks — on the normal route.
  4. Set on every controller:

    Variable Example
    RUNWAY_OIDC_ISSUER https://sso.example.com/realms/ops
    RUNWAY_OIDC_CLIENT_ID runway
    RUNWAY_OIDC_JWKS_URL https://sso.example.com/realms/ops/protocol/openid-connect/certs

    Issuer and JWKS URL must be HTTPS, and password mode must be on; otherwise the controller refuses to start. The chart has no values for these variables yet — add them with your deployment tooling (a Kustomize patch, an Argo CD or Flux post-renderer).

  5. Sign in as admin, open Administration → Users → Single sign-on and bind each provider subject (sub) to an active local user. Use the subject, not the email.

  6. Test: SSO sign-in, a request the user's role forbids, sign-out, and sign-in after deactivating the user.

Behaviour

  • Only RS256 tokens are accepted; sub, exp and iat are required and the audience must match exactly.
  • A matching email or name grants nothing: an unbound subject gets SSO identity has no active account binding (403).
  • The Liftway session lasts as long as the ID token is valid, at most 12 hours. Short-lived ID tokens mean short sessions; the user signs in through the gateway again.
  • Signing out of Liftway ends the Liftway session only. The identity gateway and the provider keep their own sessions.
  • Bindings are stored per issuer. Changing RUNWAY_OIDC_ISSUER hides old bindings.
  • LDAP or SAML directories work through an OIDC-capable provider that federates them; Liftway does not bind to LDAP or process SAML itself.

Token mode

authMode: token with a Secret apiTokenSecret (key token, at least 24 random characters). Every API call sends Authorization: Bearer <token> and acts as API token administrator. There are no personal accounts or roles in this mode. Prefer password mode with a dedicated user and role for automation clients.

Development mode

make dev runs in password mode with a generated admin password. disabled exists for explicitly marked development environments only and attributes every action to Dev user.