feat(cognito): hosted login page, PKCE and refresh-token grant #2

Merged
Zakaria merged 1 commits from feat/cognito-hosted-login into main 2026-10-24 15:46:36 +00:00
Owner

The pool's own users can now sign in through /oauth2/authorize the way apps
expect Cognito to work: without identity_provider (or with COGNITO) the
browser lands on a hosted login page, and a correct password redirects to the
registered callback with a one-time code.

  • GET/POST /cognito-idp/login (and /login on custom domains), with a CSRF
    cookie and the same password rules and Pre/Post Authentication triggers as
    USER_PASSWORD_AUTH; wrong passwords, unknown and unconfirmed users get the
    same answer until the password is right
  • a one-hour browser session, so the next authorize skips the form unless it
    sends prompt=login, and /logout with LogoutURLs validation
  • PKCE S256 on both hosted and federated codes, and nonce in the ID token
  • refresh_token grant on /oauth2/token
  • codes now fire Pre Token Generation with TokenGeneration_HostedAuth instead
    of skipping the trigger
The pool's own users can now sign in through /oauth2/authorize the way apps expect Cognito to work: without identity_provider (or with COGNITO) the browser lands on a hosted login page, and a correct password redirects to the registered callback with a one-time code. - GET/POST /cognito-idp/login (and /login on custom domains), with a CSRF cookie and the same password rules and Pre/Post Authentication triggers as USER_PASSWORD_AUTH; wrong passwords, unknown and unconfirmed users get the same answer until the password is right - a one-hour browser session, so the next authorize skips the form unless it sends prompt=login, and /logout with LogoutURLs validation - PKCE S256 on both hosted and federated codes, and nonce in the ID token - refresh_token grant on /oauth2/token - codes now fire Pre Token Generation with TokenGeneration_HostedAuth instead of skipping the trigger
Zakaria added 1 commit 2026-10-24 15:46:32 +00:00
The pool's own users can now sign in through /oauth2/authorize the way apps
expect Cognito to work: without identity_provider (or with COGNITO) the
browser lands on a hosted login page, and a correct password redirects to the
registered callback with a one-time code.

- GET/POST /cognito-idp/login (and /login on custom domains), with a CSRF
  cookie and the same password rules and Pre/Post Authentication triggers as
  USER_PASSWORD_AUTH; wrong passwords, unknown and unconfirmed users get the
  same answer until the password is right
- a one-hour browser session, so the next authorize skips the form unless it
  sends prompt=login, and /logout with LogoutURLs validation
- PKCE S256 on both hosted and federated codes, and nonce in the ID token
- refresh_token grant on /oauth2/token
- codes now fire Pre Token Generation with TokenGeneration_HostedAuth instead
  of skipping the trigger
Zakaria merged commit 2e7ebefca9 into main 2026-10-24 15:46:36 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Zakaria/FlociClone#2