feat!: OIDC admin login and built-in IndieAuth server (v2.0.0)

Admin login now uses OpenID Connect (PKCE, nonce, ID token verified
against the provider JWKS) and only OIDC_ADMIN_SUB may log in. Micropub
tokens are issued and verified by StarPunk itself, with a consent screen
behind the OIDC session and a Connected Apps page to revoke them, so an
external IndieAuth server (Gondulf) is no longer needed.

Existing notes, media, tags, webmentions, author profile and sessions
are unchanged. Migration 011 adds new tables only.

BREAKING CHANGE: production requires OIDC_ISSUER, OIDC_CLIENT_ID,
OIDC_CLIENT_SECRET and OIDC_ADMIN_SUB. The ADMIN_ME page must point
Micropub apps at StarPunk's IndieAuth endpoints. See ADR-064.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
PhilandClaude Opus 5.5 committed 2026-10-31 11:38:27 -06:00
1 parent d3fa5b7a2a
commit b84cf23e1a
29 files changed
+1824 -2354

No files matched your search

+4 -3
View File
@@ -212,11 +212,12 @@ class TestAdminTemplates:
assert response.status_code == 200
assert b"<form" in response.data
def test_login_has_me_input(self, client):
"""Test login form has 'me' URL input"""
def test_login_has_sso_button(self, client):
"""Test login form offers OIDC sign-in, not a URL field (v2.0.0)"""
response = client.get("/auth/login")
assert response.status_code == 200
assert b'name="me"' in response.data or b'id="me"' in response.data
assert b"Sign in with" in response.data
assert b'name="me"' not in response.data
def test_login_has_submit_button(self, client):
"""Test login form has submit button"""