Skip to content

serverpod_auth_idp_server: Apple verifyIdentityToken uses nonce: null — identity token replayable for its full exp window #6056

Backlog

Description

@HusseinAdeiza

Apple IDP sign-in calls verifyIdentityToken with nonce: null, which per the sign_in_with_apple_server dependency (v1.0.0) skips nonce validation entirely. For an existing user the single-use authorizationCode is never consumed (exchangeAuthorizationCode only runs in the createNewAccount branch), so a captured identity-token login request stays replayable until the token's ~24h exp and returns a fresh session each time.

apple_idp_utils.dart:78-81 (providers/apple/business/):

verifyIdentityToken(identityToken, useBundleIdentifier: ..., nonce: null)

Suggested hardening:

  • pass a server-generated nonce and enforce it; and/or
  • consume / dedup the authorizationCode (or add replay protection) on the existing-account login path.

Disclosed privately 2026-11-06; the security team confirmed it and will address it as a hardening change. Opening here for the record.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions