You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(ios): bump Auth0.swift to 3.3.1 to finish token refresh in background - #1738
Bumps Auth0.swift from 3.3.0 to 3.3.1. The new release fixes one cause of #1374, where users get logged out with "reused refresh token detected".
With refresh token rotation, Auth0 rotates the refresh token as soon as it handles the exchange. If iOS suspends the app before the response is stored, the keychain keeps the old refresh token. Once the rotation overlap passes, the next renewal sends that old token, reuse detection revokes the token family, and the user has to log in again. 3.3.1 runs each refresh token exchange inside a UIKit background task, so the app keeps running until the new credentials are stored.
NativeBridge.swift already goes through those four Credentials Manager calls for getCredentials, getApiCredentials and getSSOCredentials, so no bridge changes are needed. 3.3.1 also stores rotated credentials before it returns a largeMinTTL error, so that error no longer drops the new refresh token.
spm/Package.swift: pin bumped to 3.3.1
A0Auth0.podspec: synced with scripts/sync-ios-deps.sh
README.md, EXAMPLES.md: version text updated
There's no public API change and the stored credential format doesn't change. Reverting is just pinning back to 3.3.0. Only iOS apps are affected, and the main side effect is that the app can stay alive in the background for a few extra seconds while a refresh is in flight. Android has no equivalent fix yet, so this doesn't close#1374 on Android.
This is a dependency bump only. The new behaviour is covered by Auth0.swift's own tests and by the device A/B test in auth0/Auth0.swift#1321. To check it here: run pod install in example/ios, sign in, expire the access token, call getCredentials(), and background the app right away. The renewal should complete and the new refresh token should be stored.
This change adds unit test coverage
This change has been tested on the latest version of the platform/language or why not
No actionable comments were generated in the recent review.
Summary
Summary by CodeRabbit
Chores
Updated the iOS Auth0 integration to version 3.3.1.
Documentation
Updated the iOS setup guidance to reflect the current Auth0 version. Other documented versions and linkage instructions remain unchanged.
The iOS Auth0.swift dependency version changes from 3.3.0 to 3.3.1 in the Swift Package and podspec pins, and in the README and examples documentation.
Changes: Auth0.swift version update
Layer / File(s)
Summary
Update Auth0.swift version pin and documentation spm/Package.swift, A0Auth0.podspec, README.md, EXAMPLES.md
The exact Auth0.swift dependency pins and the documented iOS dependency version change from 3.3.0 to 3.3.1. Other listed dependencies remain unchanged.
auth0/react-native-auth0#1727: It establishes the version sync contract between spm/Package.swift and A0Auth0.podspec, both updated here.
Suggested reviewers:utkrishtsahu, pmathew92
Merge Risk: Minimal · up to 1316a
This updates the iOS Auth0 dependency to a patch release that targets refresh-token rotation failures after app suspension. The manifest, podspec and docs agree on the version. No concrete merge-blocking risk was found, though running pod install and a background refresh check on iOS is a sensible smoke test.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title names the main change: bumping the Auth0.swift dependency from 3.3.0 to 3.3.1 on iOS. It also states the purpose, finishing token refresh in the background. The changeset matches this. It is…
Description check
The description matches the changeset. It explains the Auth0.swift bump from 3.3.0 to 3.3.1 and the refresh-token rotation issue behind #1374. It lists the changed files (spm/Package.swift, A0Auth0.po…
Linked Issues check
Issue #1374 reports iOS users logged out after "reused refresh token detected". Its only coding requirement is to address that logout problem. The PR changes the Auth0.swift pin from 3.3.0 to 3.3.1 in…
Out of Scope Changes check
All four changed files contain only Auth0.swift version updates: spm/Package.swift pin, A0Auth0.podspec pin, and version text in README.md and EXAMPLES.md. These changes match the stated objective. No…
Full details: Title check
Explanation
The title names the main change: bumping the Auth0.swift dependency from 3.3.0 to 3.3.1 on iOS. It also states the purpose, finishing token refresh in the background. The changeset matches this. It is a version bump across spm/Package.swift, A0Auth0.podspec, README.md and EXAMPLES.md.
Full details: Description check
Explanation
The description matches the changeset. It explains the Auth0.swift bump from 3.3.0 to 3.3.1 and the refresh-token rotation issue behind #1374. It lists the changed files (spm/Package.swift, A0Auth0.podspec, README.md, EXAMPLES.md). It also gives testing steps and the iOS-only scope.
Full details: Linked Issues check
Explanation
Issue #1374 reports iOS users logged out after "reused refresh token detected". Its only coding requirement is to address that logout problem. The PR changes the Auth0.swift pin from 3.3.0 to 3.3.1 in spm/Package.swift and A0Auth0.podspec (both now 3.3.1, consistent with each other). The PR states that 3.3.1 runs refresh exchanges in a background task and stores rotated credentials before returning largeMinTTL. Those upstream behaviors are in the Auth0.swift release and are not present in this repository, so this assessment relies on the PR description for them. The change targets an iOS cause of #1374. The PR states it does not close the issue for Android, so #1374 stays open. No automated test is added in this repository. The PR relies on upstream tests and a manual device check.
Full details: Out of Scope Changes check
Explanation
All four changed files contain only Auth0.swift version updates: spm/Package.swift pin, A0Auth0.podspec pin, and version text in README.md and EXAMPLES.md. These changes match the stated objective. No unrelated code or configuration changes appear in the diff. The podspec pin matches the Package.swift pin, as scripts/sync-ios-deps.sh requires. The NativeBridge.swift change was not made, which the PR states is intended.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Reviewing files that changed from the base of the PR and between 572b83b and 1316a60.
Files selected for processing: 4
A0Auth0.podspec
EXAMPLES.md
README.md
spm/Package.swift
Included review availability: This review used your included allowance. 7 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 8 reviews per hour.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Bumps Auth0.swift from 3.3.0 to 3.3.1. The new release fixes one cause of #1374, where users get logged out with "reused refresh token detected".
With refresh token rotation, Auth0 rotates the refresh token as soon as it handles the exchange. If iOS suspends the app before the response is stored, the keychain keeps the old refresh token. Once the rotation overlap passes, the next renewal sends that old token, reuse detection revokes the token family, and the user has to log in again. 3.3.1 runs each refresh token exchange inside a UIKit background task, so the app keeps running until the new credentials are stored.
NativeBridge.swiftalready goes through those four Credentials Manager calls forgetCredentials,getApiCredentialsandgetSSOCredentials, so no bridge changes are needed. 3.3.1 also stores rotated credentials before it returns alargeMinTTLerror, so that error no longer drops the new refresh token.spm/Package.swift: pin bumped to 3.3.1A0Auth0.podspec: synced withscripts/sync-ios-deps.shREADME.md,EXAMPLES.md: version text updatedThere's no public API change and the stored credential format doesn't change. Reverting is just pinning back to 3.3.0. Only iOS apps are affected, and the main side effect is that the app can stay alive in the background for a few extra seconds while a refresh is in flight. Android has no equivalent fix yet, so this doesn't close #1374 on Android.
References
Testing
This is a dependency bump only. The new behaviour is covered by Auth0.swift's own tests and by the device A/B test in auth0/Auth0.swift#1321. To check it here: run
pod installinexample/ios, sign in, expire the access token, callgetCredentials(), and background the app right away. The renewal should complete and the new refresh token should be stored.Checklist