Skip to content
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

RefreshAuthToken crash #14277

Closed
ttcloud opened this issue Dec 20, 2024 · 12 comments
Closed

RefreshAuthToken crash #14277

ttcloud opened this issue Dec 20, 2024 · 12 comments

Comments

@ttcloud
Copy link

ttcloud commented Dec 20, 2024

Description

Image
We’ve encountered a crash related to Firebase's refreshAuthToken method, which has already affected three users. The crash seems to occur when attempting to refresh the authentication token. This issue is preventing users from successfully authenticating or maintaining their session, leading to interruptions in app usage.

Reproducing the issue

  • A user is logged into the app.
  • The app attempts to refresh the authentication token via Firebase’s refreshAuthToken method.
  • The app crashes unexpectedly, with the following error (or behavior):
    (Include any error messages or logs if available)

Firebase SDK Version

11.6

Xcode Version

16.1

Installation Method

CocoaPods

Firebase Product(s)

Messaging

Targeted Platforms

iOS

Relevant Log Output

If using Swift Package Manager, the project's Package.resolved

Expand Package.resolved snippet
Replace this line with the contents of your Package.resolved.

If using CocoaPods, the project's Podfile.lock

Expand Podfile.lock snippet
Replace this line with the contents of your Podfile.lock!
@google-oss-bot
Copy link

I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.

@rizafran
Copy link
Contributor

Thanks for reaching out, @ttcloud. I'm wondering if you have made any changes before this issue has occurred?

@paulb777
Copy link
Member

Also, please share the Podfile.lock.

@ttcloud
Copy link
Author

ttcloud commented Dec 23, 2024

  • FBSDKCoreKit (5.2.3):
    • FBSDKCoreKit/Basics (= 5.2.3)
    • FBSDKCoreKit/Core (= 5.2.3)
  • FBSDKCoreKit/Basics (5.2.3)
  • FBSDKCoreKit/Core (5.2.3):
    • FBSDKCoreKit/Basics
  • FBSDKLoginKit (5.2.3):
    • FBSDKCoreKit (~> 5.0)
  • FCAlertView (1.4.2)
  • Firebase (11.6.0):
    • Firebase/Core (= 11.6.0)
  • Firebase/Analytics (11.6.0):
    • Firebase/Core
  • Firebase/Auth (11.6.0):
    • Firebase/CoreOnly
    • FirebaseAuth (~> 11.6.0)
  • Firebase/Core (11.6.0):
    • Firebase/CoreOnly
    • FirebaseAnalytics (~> 11.6.0)
  • Firebase/CoreOnly (11.6.0):
    • FirebaseCore (~> 11.6.0)
  • Firebase/Crashlytics (11.6.0):
    • Firebase/CoreOnly
    • FirebaseCrashlytics (~> 11.6.0)
  • Firebase/Database (11.6.0):
    • Firebase/CoreOnly
    • FirebaseDatabase (~> 11.6.0)
  • Firebase/Functions (11.6.0):
    • Firebase/CoreOnly
    • FirebaseFunctions (~> 11.6.0)
  • Firebase/InAppMessaging (11.6.0):
    • Firebase/CoreOnly
    • FirebaseInAppMessaging (~> 11.6.0-beta)
  • Firebase/Messaging (11.6.0):
    • Firebase/CoreOnly
    • FirebaseMessaging (~> 11.6.0)
  • Firebase/Performance (11.6.0):
    • Firebase/CoreOnly
    • FirebasePerformance (~> 11.6.0)
  • Firebase/Storage (11.6.0):
    • Firebase/CoreOnly
    • FirebaseStorage (~> 11.6.0)
  • FirebaseABTesting (11.6.0):
    • FirebaseCore (~> 11.6.0)
  • FirebaseAnalytics (11.6.0):
    • FirebaseAnalytics/AdIdSupport (= 11.6.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • GoogleUtilities/AppDelegateSwizzler (~> 8.0)
    • GoogleUtilities/MethodSwizzler (~> 8.0)
    • GoogleUtilities/Network (~> 8.0)
    • "GoogleUtilities/NSData+zlib (~> 8.0)"
    • nanopb (~> 3.30910.0)
  • FirebaseAnalytics/AdIdSupport (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • GoogleAppMeasurement (= 11.6.0)
    • GoogleUtilities/AppDelegateSwizzler (~> 8.0)
    • GoogleUtilities/MethodSwizzler (~> 8.0)
    • GoogleUtilities/Network (~> 8.0)
    • "GoogleUtilities/NSData+zlib (~> 8.0)"
    • nanopb (~> 3.30910.0)
  • FirebaseAppCheckInterop (11.6.0)
  • FirebaseAuth (11.6.0):
    • FirebaseAppCheckInterop (~> 11.0)
    • FirebaseAuthInterop (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseCoreExtension (~> 11.6.0)
    • GoogleUtilities/AppDelegateSwizzler (~> 8.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GTMSessionFetcher/Core (< 5.0, >= 3.4)
    • RecaptchaInterop (~> 100.0)
  • FirebaseAuthInterop (11.6.0)
  • FirebaseCore (11.6.0):
    • FirebaseCoreInternal (~> 11.6.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/Logger (~> 8.0)
  • FirebaseCoreExtension (11.6.0):
    • FirebaseCore (~> 11.6.0)
  • FirebaseCoreInternal (11.6.0):
    • "GoogleUtilities/NSData+zlib (~> 8.0)"
  • FirebaseCrashlytics (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • FirebaseRemoteConfigInterop (~> 11.0)
    • FirebaseSessions (~> 11.0)
    • GoogleDataTransport (~> 10.0)
    • GoogleUtilities/Environment (~> 8.0)
    • nanopb (~> 3.30910.0)
    • PromisesObjC (~> 2.4)
  • FirebaseDatabase (11.6.0):
    • FirebaseAppCheckInterop (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseSharedSwift (~> 11.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • leveldb-library (~> 1.22)
  • FirebaseFunctions (11.6.0):
    • FirebaseAppCheckInterop (~> 11.0)
    • FirebaseAuthInterop (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseCoreExtension (~> 11.6.0)
    • FirebaseMessagingInterop (~> 11.0)
    • FirebaseSharedSwift (~> 11.0)
    • GTMSessionFetcher/Core (< 5.0, >= 3.4)
  • FirebaseInAppMessaging (11.6.0-beta):
    • FirebaseABTesting (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • nanopb (~> 3.30910.0)
  • FirebaseInstallations (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • PromisesObjC (~> 2.4)
  • FirebaseMessaging (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • GoogleDataTransport (~> 10.0)
    • GoogleUtilities/AppDelegateSwizzler (~> 8.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/Reachability (~> 8.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • nanopb (~> 3.30910.0)
  • FirebaseMessagingInterop (11.6.0)
  • FirebasePerformance (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • FirebaseRemoteConfig (~> 11.0)
    • FirebaseSessions (~> 11.0)
    • GoogleDataTransport (~> 10.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/MethodSwizzler (~> 8.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • nanopb (~> 3.30910.0)
  • FirebaseRemoteConfig (11.6.0):
    • FirebaseABTesting (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • FirebaseRemoteConfigInterop (~> 11.0)
    • FirebaseSharedSwift (~> 11.0)
    • GoogleUtilities/Environment (~> 8.0)
    • "GoogleUtilities/NSData+zlib (~> 8.0)"
  • FirebaseRemoteConfigInterop (11.6.0)
  • FirebaseSessions (11.6.0):
    • FirebaseCore (~> 11.6.0)
    • FirebaseCoreExtension (~> 11.6.0)
    • FirebaseInstallations (~> 11.0)
    • GoogleDataTransport (~> 10.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GoogleUtilities/UserDefaults (~> 8.0)
    • nanopb (~> 3.30910.0)
    • PromisesSwift (~> 2.1)
  • FirebaseSharedSwift (11.6.0)
  • FirebaseStorage (11.6.0):
    • FirebaseAppCheckInterop (~> 11.0)
    • FirebaseAuthInterop (~> 11.0)
    • FirebaseCore (~> 11.6.0)
    • FirebaseCoreExtension (~> 11.6.0)
    • GoogleUtilities/Environment (~> 8.0)
    • GTMSessionFetcher/Core (< 5.0, >= 3.4)
      @paulb777 @rizafran

@ttcloud
Copy link
Author

ttcloud commented Dec 23, 2024

Thanks for reaching out, @ttcloud. I'm wondering if you have made any changes before this issue has occurred?

No other changes, only update firebase

@rizafran
Copy link
Contributor

rizafran commented Jan 7, 2025

Thanks for the info, @ttcloud. Could you provide the following:

  • Exact error message received when trying to refresh the token
  • Confirmation if the issue is reproducible using other network
  • MCVE that reproduces the issue, if possible

@jesus-mg-ios
Copy link

@rizafran any ETA to fix this?

@google-oss-bot
Copy link

Hey @ttcloud. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

@google-oss-bot
Copy link

Since there haven't been any recent updates here, I am going to close this issue.

@ttcloud if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.

@jesus-mg-ios
Copy link

I'm still experiencing it.

@rizafran
Copy link
Contributor

rizafran commented Feb 3, 2025

Hi @jesus-mg-ios, please provide the info mentioned in #14277 (comment). Thanks.

@jesus-mg-ios
Copy link

jesus-mg-ios commented Feb 3, 2025

  1. Exact error message received when trying to refresh the token: => Crash Kern Invalid Address

  2. Confirmation if the issue is reproducible using other network: I think it is not related to network, possible causes:
    => Dereferencing a Null or Uninitialized Pointer - Attempting to read or write memory that hasn't been properly allocated.
    => Buffer Overflow – Accessing memory beyond the allocated range.
    => Use-After-Free – Trying to access memory after it has been deallocated.
    => Stack or Heap Corruption – Writing out of bounds can corrupt memory structures.
    => Incorrect Memory Mapping – Using calloc or malloc incorrectly.

  3. MCVE that reproduces the issue, if possible: Not viable
    @rizafran

@firebase firebase locked and limited conversation to collaborators Feb 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants