-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[firebase_auth]: Apple signInWithCredential throws invalid-credential when used with error.credential #12944
Comments
Yes I think its related to this #12944 |
Hey @eli1stark - fairly sure this is the same issue as @MirceaX2Mobile. Might be worth trying this branch locally in your project and seeing if it fixes the issue: https://github.com/firebase/flutterfire/tree/auth-12931 Just update your pubspec.yaml with this for firebase_auth:
git:
url: https://github.com/firebase/flutterfire.git
path: packages/firebase_auth/firebase_auth
ref: auth-12931 Let me know how it goes 🙏 |
@russellwheatley Thank you for your quick response and fix! I can confirm that it's reproduced on firebase_auth: 5.1.0 but not on the branch you provided. |
@eli1stark - Thanks for confirmation! Also, for producing quality issues/reproductions 👍 |
Is there an existing issue for this?
Which plugins are affected?
Auth
Which platforms are affected?
iOS
Description
firebase_auth: 4.20.0
When converting an anonymous user to a registered account,
linkWithProvider
may throw an error if the account is already linked to another user. However, we can recover from the error by signing in to the account using the credential fromFirebaseAuthException
and calling thesignInWithCredential
function. But for some reason, it throws an error: "[firebase_auth/invalid-credential] The supplied auth credential is malformed, has expired, or is not currently supported." It also prints, "Support for an auth provider with identifier 'apple.com' is not implemented," even though Apple Auth is enabled. The process works fine when used withsignInWithProvider
. So it seems there is something wrong with the credential passed by the error.Reproducing the issue
Firebase Core version
2.32.0
Flutter Version
3.22.0
Relevant Log Output
No response
Flutter dependencies
Expand
Flutter dependencies
snippetReplace this line with the contents of your `flutter pub deps -- --style=compact`.
Additional context and comments
Maybe related to #12931 and #11841.
The issue is reproducible on the latest versions:
firebase_core: 3.1.0
firebase_auth: 5.1.0
The issue is reproducible on the following versions:
firebase_core: 2.32.0
firebase_auth: 4.20.0
The issue is NOT reproducible on the following versions:
firebase_core: 2.31.0
firebase_auth: 4.19.5
There is interesting error when using the following versions:
firebase_core: 2.32.0
firebase_auth: 4.19.5
Click to see the error
The text was updated successfully, but these errors were encountered: