-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
When upgrading from 10.29.0 to 11.0.0 the user gets logged out. #13662
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
Thanks for the report, @knopp and apologies for the trouble. I took a look back and it looks like there are a few things going on here. In short, it was a mistake that the This flag was added to this code in 10.05 to fix an issue where accessing the keychain on macOS would show pop-ups. The 10.05 release notes: https://firebase.google.com/support/release-notes/ios#version_1050_-_february_7_2023 Apple recommends setting the Here is the discussion for the original issue #10582 that prompted adding this flag to this code. |
EDIT: the particular issue described below does not happen in 11.3.0 sourceI just tried to do an update from If I build my iOS app, user is logged out =O (using Sign in with Apple) Is there a way to avoid getting users logged out? Is there a way I can do some migration myself? Seems like quite a big change? @ncooke3 Edit 1: updating to Edit 2: here are release notes - I can't find any mention of all users getting logged out (yet) |
Hi @kgaidis, this issue should only have effected macOS (because the key in question defaults to true on iOS). Could you please try updating to 11.3.0 and see if you are still affected? 11.3 fixed an unrelated regression where users may be signed out in some cases if keychain sharing is used. |
I just tested 11.3.0, and based off this quick test, as you said, that issue seems to have gone away (there's a clear difference between 11.2.0 behavior and 11.3.0 behavior). Thank you! Apologies for conflating the issues. For some context (maybe interesting to get in the mind of SDK adopters), I was a little afraid to go straight to the newest (11.3.0 instead of 11.2.0) because adopting the latest SDK's during iOS 18.0 upgrade was a bumpy road with insta-crashes (not Firebase fault, Apple SDK issues). Because there were 20 days between September 10 release and September 30 release, I was guessing that 11.2.0 was stable since there were no "hotfixes." Maybe a big warning label for 11.2.0 release notes would have helped. |
Thanks for confirming. |
This is still an issue for us when migrating to 11.3.0 on iOS. Users are still getting logged out every time immediately. Migrating to 10.29.0 works great with no problems. But every version above 11.0.0 has issues including the latest version 11.4.2. We have ~200K daily active users and it'd be too disruptive to have all of them log out. @ncooke3 do you have any suggestions here? Or is there a fix coming up that can prevent iOS users from getting logged out? |
Hi @JCsplash, apologies for the trouble here. This was resolved for the other developer in this thread so I'm thinking something else could be at play. Could you please open a new issue and include the following information:
Additionally, if you have a minimal reproducible example or repro instructions, that'd be helpful to include. Thank you! |
In case it helps, to add more data here, 11.3 fixed the bug for my setup (Sign in with Apple and Anonymous Users).
|
Description
The reason for this is that new version can not read the keychain entry due to
kSecUseDataProtectionKeychain
.This is
genericPasswordQueryWithKey:
from 10.29.0:On the surface it seems like it is setting the
kSecUseDataProtectionKeychain
flag. However it's not really, becauseFIREBASE_AUTH_MACOS_TESTING
is defined to 1 in FirebaseAuth.podspec. So the code inside#ifndef
is never included and thekSecUseDataProtectionKeychain
flag is never set.Compared to that, the new swift version is actually setting the
kSecUseDataProtectionKechain
flag:This seems like a rather painful regression and the flag should probably be disabled until there is migration in place?
Reproducing the issue
No response
Firebase SDK Version
11.0
Xcode Version
15.4
Installation Method
CocoaPods
Firebase Product(s)
Authentication
Targeted Platforms
macOS
Relevant Log Output
No response
If using Swift Package Manager, the project's Package.resolved
No response
If using CocoaPods, the project's Podfile.lock
Expand
Podfile.lock
snippetThe text was updated successfully, but these errors were encountered: