Take Pireon's webhooks: a deactivation or a revocation counts at once
Until now, an account switched off or a token revoked at the identity server kept working here: bearer tokens until the introspection cache ran out, panel sessions until they ended, and machine tokens for good, as they only look at the local account. POST /api/v1/webhooks/pireon takes user.deactivated (the account goes inactive, which stops its machine tokens and the panel; its sessions end and its cached tokens are forgotten) and token.revoked (sessions and cached tokens go). Pireon signs each delivery with the secret of the client that registered the webhook, so either PIREON_WEBHOOK_SECRET (password client) or PIREON_REDIRECT_WEBHOOK_SECRET («Entrar con Pireon») verifies it; with neither, the endpoint refuses everything. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -85,6 +85,12 @@ PIREON_REDIRECT_CLIENT_ID=
|
||||
PIREON_REDIRECT_CLIENT_SECRET=
|
||||
# PIREON_REDIRECT_LOGIN=
|
||||
|
||||
# Webhooks at ${APP_URL}/api/v1/webhooks/pireon (user.deactivated, token.revoked):
|
||||
# register it on each client and paste the secret each one returns. Empty: the
|
||||
# endpoint refuses everything and a revocation waits for the cache below.
|
||||
PIREON_WEBHOOK_SECRET=
|
||||
PIREON_REDIRECT_WEBHOOK_SECRET=
|
||||
|
||||
# Grants. The panel's sign-in form uses the password grant, so turning this off
|
||||
# locks everyone out of the panel as well as out of POST /api/v1/auth/token.
|
||||
PIREON_PASSWORD_GRANT=true
|
||||
|
||||
Reference in New Issue
Block a user