P3.2: Enable password grant on local-llm Authentik provider #7

Closed
opened 2026-09-08 04:41:11 +00:00 by rock · 1 comment
Owner

Summary

Update local-llm OAuth2 provider in Authentik to support password grant type with headless auth flow.

Config repo: rock/homelabscripts/iam/authentik-provision.py

Changes

  • Add "password" to local-llm grant_types
  • Bind SA_AUTHENTICATION_FLOW_PK (headless: identification->password->login, no MFA)
  • Add roles + permissions scope mappings to property_mappings

Verification

curl -X POST https://authentik.riotpiao.com/application/o/token/ \
  -d "grant_type=password&client_id=local-llm&client_secret=$SECRET&username=rock&password=$PASS&scope=openid roles permissions"
# Expect JWT with roles/permissions claims

Review checklist

  • Headless flow bound (not default with MFA)
  • Idempotent on re-run (patch_existing)
  • client_secret not rotated
  • Wrong password returns proper error (not 500)

Blocked by

Nothing — this is the first task in the chain

## Summary Update `local-llm` OAuth2 provider in Authentik to support `password` grant type with headless auth flow. **Config repo:** `rock/homelab` — `scripts/iam/authentik-provision.py` ## Changes - Add `"password"` to `local-llm` grant_types - Bind `SA_AUTHENTICATION_FLOW_PK` (headless: identification->password->login, no MFA) - Add `roles` + `permissions` scope mappings to property_mappings ## Verification ```bash curl -X POST https://authentik.riotpiao.com/application/o/token/ \ -d "grant_type=password&client_id=local-llm&client_secret=$SECRET&username=rock&password=$PASS&scope=openid roles permissions" # Expect JWT with roles/permissions claims ``` ## Review checklist - [ ] Headless flow bound (not default with MFA) - [ ] Idempotent on re-run (patch_existing) - [ ] client_secret not rotated - [ ] Wrong password returns proper error (not 500) ## Blocked by Nothing — this is the first task in the chain
rock added this to the Phase 3: OAuth2 Token Exchange & Identity Propagation milestone 2026-09-08 04:41:11 +00:00
rock added the area/authentiktype/infrastatus/todopriority/high labels 2026-09-08 04:41:12 +00:00
rock self-assigned this 2026-09-08 04:41:12 +00:00
rock added this to the API-GW OAuth project 2026-09-08 04:43:46 +00:00
rock moved this to Todo in API-GW OAuth on 2026-09-08 04:44:39 +00:00
rock closed this issue 2026-09-08 22:50:28 +00:00
Author
Owner

Closed manually — applied via scripts/iam/provision-rbac.py (not tracked). No PR.

Closed manually — applied via scripts/iam/provision-rbac.py (not tracked). No PR.
Sign in to join this conversation.