Skip to content

GoogleSignIn_Disconnect not implemented in Unity plugin 0.9.0 — prevents proper re-auth after account revocation #48

@mdolzhansky

Description

@mdolzhansky

Hello.
In version 0.9.0 of the Google Sign-In Unity plugin, the method:

static void GoogleSignIn_Disconnect(HandleRef self) 
    => throw new NotImplementedException();

is not implemented.

This is a problem because when a user revokes the app’s access in their Google account settings (Settings → Google → All Services → Connected Apps → Remove connection), the stored refresh token becomes invalid.
After that, calling SignIn() silently fails (empty AuthCode is gotten), even if I remove the local profile/cache, because the plugin still tries to use the stale authorization state.

The documented and expected fix from Google’s native SDKs is to call Disconnect() to revoke the current client-side grant and force the next sign-in to present the consent screen again.
In Unity, this is not possible because GoogleSignIn_Disconnect is just a placeholder.

Impact:
Users who revoke app access cannot sign in again without reinstalling the app.
This breaks progress restore in games and leads to account lockouts.
There is no way to recover by code since the plugin does not expose a working Disconnect().

Repro steps:
Sign in with Google in the Unity app.
Save progress to that account.
Revoke app access in Google account settings (Settings > Google > > All Services > Connected Apps > [APPNAME] > Delete All Connections.)
Try to sign in again in the Unity app.
Observe: Sign-in fails silently, even after profile/cache deletion.
GoogleSignIn_Disconnect cannot be used because it throws NotImplementedException.

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions