Skip to content

fix(types)!: remove is_multi_factor_auth_enabled from SignUpRequest#48

Merged
lakhansamani merged 2 commits into
mainfrom
fix/remove-mfa-flag-from-signup
Jul 23, 2026
Merged

fix(types)!: remove is_multi_factor_auth_enabled from SignUpRequest#48
lakhansamani merged 2 commits into
mainfrom
fix/remove-mfa-flag-from-signup

Conversation

@lakhansamani

Copy link
Copy Markdown
Contributor

Why

Server PR authorizerdev/authorizer#710 (release 2.4.0-rc.6) removed is_multi_factor_auth_enabled from SignupRequest / input SignUpRequest in both the GraphQL schema and the proto message. It was a security fix: the field let an unauthenticated signup caller bypass the server's MFA-on-by-default policy for their own new account.

What changed

  • src/types.ts: removed is_multi_factor_auth_enabled from the SignUpRequest interface (and its SignupRequest alias). The signup() mutation in src/index.ts sends the whole typed object as GraphQL variables, so no separate query-string change was needed.

Scope

Narrowly scoped to this one breaking field removal on the signup path only:

  • UpdateProfileRequest / updateProfile()untouched. The field remains valid and required there.
  • Admin UpdateUserRequest / updateUser() (src/admin.ts) — untouched. Same, unaffected by the server change.
  • No README/example code referenced this field on the signup path (grepped, none found).
  • src/admin.ts's adminSignup/AdminSignupRequest never had this field — unaffected.

This is a breaking change for TS consumers who set is_multi_factor_auth_enabled on signup() — expected, matching the server's break. It is additive-safe (removing an optional field is source-compatible for anyone who wasn't already setting it).

Verification

  • npm run build — passes, no type errors.
  • npx tsc --noEmit — clean, no other references to the field on the signup path.
  • npx jest — 7/9 suites pass. The 2 failing suites (index.test.ts, admin.test.ts) fail identically on main before this change too — they spin up a real Authorizer server via Docker pinned to quay.io/authorizer/authorizer:2.4.0-rc.1, which is a 404 in the registry (pre-existing environment/pinned-tag issue, unrelated to this diff).

Refs authorizerdev/authorizer#710

Server (authorizerdev/authorizer PR #710, release 2.4.0-rc.6) removed
this field from SignupRequest/input SignUpRequest — it let an
unauthenticated signup caller bypass the server's MFA-on-by-default
policy for their own new account. Field stays valid on
UpdateProfileRequest and admin UpdateUserRequest; only the signup path
lost it.

BREAKING CHANGE: SignUpRequest/SignupRequest no longer has
is_multi_factor_auth_enabled. Passing it to signup() is now ignored by
the server.
@lakhansamani
lakhansamani merged commit 0f39394 into main Jul 23, 2026
2 checks passed
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