AshAuthentication.Strategy.OAuth2.IdentityChange (ash_authentication v4.14.1)

View Source

Resolves and updates the user's identity when registering via OAuth2/OIDC.

Runs in two phases:

  • before_action - resolves which local user this sign-in belongs to, using the provider's iss/sub (never the email). See AshAuthentication.Strategy.OAuth2.UserResolver for the matching rules.
  • after_action - upserts the identity row for the resolved user so that future sign-ins with the same iss/sub resolve to them.