Is there an existing issue for this?
Which plugins are affected?
Auth
Which platforms are affected?
macOS
Description
Volledig Bug Rapport voor FlutterFire GitHub Issue (Geüpdatet)
Title
macOS Firebase Auth Keychain Error: OSStatus error 13 (errSecNotAvailable) met Flutter 3.44.4 + Firebase Auth 6.5.6 + Xcode 26.6 + macOS 26.5.1
Description
Firebase Authentication op macOS geeft een keychain-error met OSStatus error 13 (errSecNotAvailable) ondanks correcte code signing, entitlements en Keychain Sharing capability.
Belangrijk: Een volledig nieuwe minimale Flutter app met alleen firebase_core en firebase_auth geeft exact dezelfde fout, wat suggereert dat dit een regressie is in de SDK/toolchain combinatie.
Steps to Reproduce
- Flutter 3.44.4, Xcode 26.6, macOS 26.5.1
- Nieuw Flutter project met firebase_core 4.12.1 en firebase_auth 6.5.6
- Correcte code signing met Apple Development certificaat (Team ID: WN59633PU4)
- Keychain Sharing capability toegevoegd via Xcode
- Entitlements geverifieerd met
codesign -d --entitlements :-
- Probeer in te loggen met Firebase Auth
- Zie
keychain-error met OSStatus error 13
Expected behavior
Firebase Auth moet kunnen inloggen en credentials opslaan in macOS Keychain zonder foutmeldingen.
Actual behavior
FirebaseAuthException met code: keychain-error en bericht: "An error occurred when accessing the keychain. The NSLocalizedFailureReasonErrorKey field in the NSError.userInfo dictionary will contain more information about the error encountered"
Native macOS logs tonen: OSStatus error 13 (errSecNotAvailable)
Which plugins are affected?
- firebase_auth (6.5.6)
- firebase_core (4.12.1)
Which platforms are affected?
- macOS (desktop)
- Getest op macOS 26.5.1 (25F80)
- Niet getest op iOS, Android, web, Linux, Windows
Environment
- Flutter version: 3.44.4 (stable, revision ad70ec4617, 2026-06-24)
- Dart version: 3.12.2
- firebase_core: 4.12.1
- firebase_auth: 6.5.6
- firebase_auth_platform_interface: 9.0.5
- macOS version: 26.5.1 (25F80)
- Xcode version: 26.6 (Build 17F113)
- Development Team ID: WN59633PU4
- Code signing: Apple Development (automatic signing)
- Keychain Sharing: Enabled via Xcode
- Bundle ID: com.apojo.community (hoofdproject), com.example.firebaseAuthTest (testproject)
Additional context
Geteste Oplossingen (zonder resultaat)
- ✅ Keychain Sharing capability toegevoegd via Xcode
- ✅ Entitlements geverifieerd met codesign
- ✅ Apple Development signing geconfigureerd
- ✅ Sandbox uitgeschakeld in Debug mode
- ✅ Firebase configuratie geverifieerd (bundle ID, app ID)
- ✅ Minimale test app gemaakt met alleen firebase_core en firebase_auth
- ❌ Oudere Firebase versies geprobeerd (firebase_auth 4.2.1, firebase_core 2.4.0)
- ❌ Keychain Sharing capability heeft geen effect
Entitlements (geverifieerd met codesign)
<key>com.apple.security.app-sandbox</key>
<false/>
<key>com.apple.security.network.client</key>
<true/>
<key>com.apple.security.keychain-access-groups</key>
<array>
<string>WN59633PU4.com.apojo.community</string>
</array>
<key>com.apple.security.application-groups</key>
<array>
<string>WN59633PU4.com.apojo.community</string>
</array>
Native Logs
2026-07-30 07:28:08.952 apojoCommunityApp[57293:11126110] The operation couldn't be completed. (OSStatus error 13.)
Workaround
await FirebaseAuth.instance.setPersistence(Persistence.none);
Dit werkt maar logt gebruikers uit bij app sluiting.
Reproducibility
Het probleem is reproduceerbaar in:
- Hoofdproject (Apojo Community App)
- Minimale test project (firebase_auth_test)
- Zowel met als zonder Keychain Sharing capability
- Zowel met als zonder sandbox
Dit suggereert een regressie in de combinatie van Flutter 3.44.x + Firebase Auth 6.5.x + Xcode 26.x + macOS 26.x.
Related Issues
Reproducing the issue
Steps to reproduce
- Create a new Flutter application.
- Add the latest
firebase_core and firebase_auth packages.
- Configure Firebase using FlutterFire CLI.
- Enable macOS and configure code signing with an Apple Development Team.
- Enable the Keychain Sharing capability in Xcode.
- Initialize Firebase:
await Firebase.initializeApp(
options: DefaultFirebaseOptions.currentPlatform,
);
- Call:
await FirebaseAuth.instance.signInWithEmailAndPassword(
email: "your-test-email@example.com",
password: "your-password",
);
- Run the app on macOS.
Result
The call fails with:
[firebase_auth/keychain-error]
An error occurred when accessing the keychain.
Native macOS log:
OSStatus error 13 (errSecNotAvailable)
The issue is reproducible in both my main project and a brand-new minimal Flutter project.
Firebase Core version
4.12.1
Flutter Version
Flutter 3.44.4 • channel stable Framework • revision ad70ec4617 Engine • revision a10d8ac38d Dart 3.12.2
Relevant Log Output
flutter: Attempting sign in with email: lizenko.official@gmail.com (attempt 1/3)
flutter: FirebaseAuthException
flutter: code: keychain-error
flutter: message: An error occurred when accessing the keychain. The NSLocalizedFailureReasonErrorKey field in the NSError.userInfo dictionary will contain more information about the error encountered
flutter: details: [firebase_auth/keychain-error] An error occurred when accessing the keychain. The NSLocalizedFailureReasonErrorKey field in the NSError.userInfo dictionary will contain more information about the error encountered
Native macOS log:
OSStatus error 13 (errSecNotAvailable)
Flutter dependencies
Expand Flutter dependencies snippet
Replace this line with the contents of your `flutter pub deps -- --style=compact`.
Additional context and comments
The issue occurs in:
- my production application
- a brand new Flutter application created only to reproduce the issue
I verified:
- Apple Development code signing
- Automatic signing enabled
- Development Team configured
- Keychain Sharing capability enabled
- Firebase configured with FlutterFire CLI
- Correct bundle identifier
- Correct entitlements
- Firebase initializes successfully
The error only occurs when calling:
FirebaseAuth.instance.signInWithEmailAndPassword(...)
The same error occurs in both projects on the same machine.
Is there an existing issue for this?
Which plugins are affected?
Auth
Which platforms are affected?
macOS
Description
Volledig Bug Rapport voor FlutterFire GitHub Issue (Geüpdatet)
Title
macOS Firebase Auth Keychain Error: OSStatus error 13 (errSecNotAvailable) met Flutter 3.44.4 + Firebase Auth 6.5.6 + Xcode 26.6 + macOS 26.5.1
Description
Firebase Authentication op macOS geeft een
keychain-errormet OSStatus error 13 (errSecNotAvailable) ondanks correcte code signing, entitlements en Keychain Sharing capability.Belangrijk: Een volledig nieuwe minimale Flutter app met alleen firebase_core en firebase_auth geeft exact dezelfde fout, wat suggereert dat dit een regressie is in de SDK/toolchain combinatie.
Steps to Reproduce
codesign -d --entitlements :-keychain-errormet OSStatus error 13Expected behavior
Firebase Auth moet kunnen inloggen en credentials opslaan in macOS Keychain zonder foutmeldingen.
Actual behavior
FirebaseAuthException met code:
keychain-erroren bericht: "An error occurred when accessing the keychain. The NSLocalizedFailureReasonErrorKey field in the NSError.userInfo dictionary will contain more information about the error encountered"Native macOS logs tonen:
OSStatus error 13 (errSecNotAvailable)Which plugins are affected?
Which platforms are affected?
Environment
Additional context
Geteste Oplossingen (zonder resultaat)
Entitlements (geverifieerd met codesign)
Native Logs
Workaround
Dit werkt maar logt gebruikers uit bij app sluiting.
Reproducibility
Het probleem is reproduceerbaar in:
Dit suggereert een regressie in de combinatie van Flutter 3.44.x + Firebase Auth 6.5.x + Xcode 26.x + macOS 26.x.
Related Issues
Reproducing the issue
Steps to reproduce
firebase_coreandfirebase_authpackages.Result
The call fails with:
Native macOS log:
The issue is reproducible in both my main project and a brand-new minimal Flutter project.
Firebase Core version
4.12.1
Flutter Version
Flutter 3.44.4 • channel stable Framework • revision ad70ec4617 Engine • revision a10d8ac38d Dart 3.12.2
Relevant Log Output
Flutter dependencies
Expand
Flutter dependenciessnippetReplace this line with the contents of your `flutter pub deps -- --style=compact`.Additional context and comments
The issue occurs in:
I verified:
The error only occurs when calling:
The same error occurs in both projects on the same machine.