Skip to content

AUTH-004 — Link a Google identity to an existing Firebase member account #82

Description

@daliu

Outcome

Allow an already signed-in member to link a Google sign-in credential to the same Firebase UID without creating a second MPRC account or changing membership.

Scope

  • Link Google identity to the current Firebase user after reauthentication.
  • Request identity-only access; do not request Drive, Sites, Groups, or Directory scopes from members.
  • Store only minimum non-secret provider metadata.
  • Handle cancellation, different Google email, provider conflict, and credential already linked to another Firebase UID.
  • Provide safe unlink and account-recovery behavior.

Acceptance criteria

  • Existing email/password account keeps its UID and all data after linking.
  • Provider identity is verified from Firebase token/provider data, never request fields.
  • Linking, unlinking, or email equality never grants member/admin role.
  • No Google OAuth token appears in client-readable Firestore, custom claims, logs, or issues.
  • Conflict, cancellation, reauthentication, unlink, and relink tests pass.
  • Privacy/consent copy explains why Google identity is linked.

Dependencies

#81 (MEMBERS-IDENTITY-001) and coordinating backlog AUTH-001.

Official references

Coordination

Parent: #79

Do not begin implementation until dependencies are complete, this issue is assigned, and a timestamped CLAIMED comment naming the agent and branch is posted. Creation of this ticket is not a claim. Preserve the parallel agent work tracked by stable IDs in GITHUB_ISSUES.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:authAuthentication and authorizationarea:firebaseFirebase services and dataarea:google-sitesGoogle Sites and Google Groups accesspriority:P1High-priority follow-upsize:MMedium multi-file issuestatus:proposedDesigned but dependencies or decisions remaintype:featureProduct capability

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions