Skip to content

feat(auth-doctor): warn when an app won't send identity_provider with prompt - #176

Merged
Alexanderamiri merged 1 commit into
mainfrom
feat/doctor-identity-provider-param
Oct 30, 2026
Merged

Alexanderamiri merged 1 commit into
mainfrom
feat/doctor-identity-provider-param

Conversation

@Alexanderamiri

Copy link
Copy Markdown
Member

Why

The probe client (#174) showed that Cognito managed login forwards prompt=select_account to Google only when the request also sends identity_provider. auth-doctor.py always adds identity_provider, so an app that sends only prompt passed but would get no account chooser after the Google cutover (#175).

What

  • New chooser check (WARN only): an app that renames auth variables via auth.env but doesn't alias COGNITO_IDENTITY_PROVIDER almost certainly doesn't send it. Apps that read the platform variables directly aren't flagged, since the doctor can't see their code.
  • The authorize warning and the docstring explain the identity_provider requirement.

How verified

  • python3 -m unittest discover -s scripts/tests: 133 tests, OK. There are 4 new tests: aliased without IdP warns, aliased with IdP passes, no aliases passes, and the probe names the IdP.
  • python3 -m unittest discover -s terraform/lambda-src/tests: 219 tests, OK.
  • Live against the current pool:

Rollout

Script only, with no Terraform changes. App deploys pick it up from platform main.

🤖 Generated with Claude Code

… prompt

Managed login forwards prompt=select_account to Google only when the
authorize request also names the IdP (probe client, #174). The doctor always
sent identity_provider, so an app that only sends prompt still passed. Warn
when an app aliases auth variables (auth.env) but not
COGNITO_IDENTITY_PROVIDER, and say why in the authorize warning and docstring.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Alexanderamiri
Alexanderamiri requested a review from a team as a code owner October 30, 2026 08:46
@github-actions

Copy link
Copy Markdown

Terraform Plan

✅ No changes — infrastructure is up to date.

Plan output
Acquiring state lock. This may take a few moments...
aws_ssm_parameter.atlassian_org_id: Refreshing state... [id=/javabin/platform/atlassian-org-id]
aws_ssm_parameter.atlassian_api_key: Refreshing state... [id=/javabin/platform/atlassian-api-key]

No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration
and found no differences, so no changes are needed.

@Alexanderamiri
Alexanderamiri merged commit 450ce08 into main Oct 30, 2026
4 checks passed
@Alexanderamiri
Alexanderamiri deleted the feat/doctor-identity-provider-param branch October 30, 2026 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant