Skip to content

Commit 559dc19

Browse files
committed
docs: document native v4/v3 adoption — linking, claim validation, build floors
Covers the consumer-facing docs carved out of SDK-10039/SDK-10040 (SDK-10615): - README: correct iOS floor to 15.1 (min_ios_version_supported), state Android minSdk 26 / compileSdk 36 / JDK 17, and make the Expo requirement consistently SDK 55 for v6. - README: add iOS use_frameworks! linkage guidance. Verified by building the example app under both USE_FRAMEWORKS=static and =dynamic (pod install + iOS simulator build succeeded in each). - MIGRATION_GUIDE §9: document the opt-in ID-token claim validation state on direct token requests, with per-flow accuracy (passkey signin validates on both platforms; passkey signup, Custom Token Exchange, MFA, passwordless validate on neither — deliberate iOS/Android parity). SDK-10615
1 parent b51c5be commit 559dc19

2 files changed

Lines changed: 50 additions & 13 deletions

File tree

MIGRATION_GUIDE.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,21 @@ Two codes were added for the new Auth0.swift cases, both iOS-only: `AUTHENTICATI
235235
236236
`SSO_EXCHANGE_FAILED` (iOS and Android) and `CLEAR_FAILED` (iOS) are now reported instead of being collapsed into a generic credentials-manager error. No action is required unless you exhaustively match on these codes.
237237
238+
#### ID-token claim validation is now opt-in on direct token requests
239+
240+
Auth0.swift 3.0 made ID-token claim validation **opt-in** on `TokenRequestable` (`.validateClaims()`), matching the long-standing behaviour on Auth0.Android. Web Authentication (`authorize()`) is unaffected — the browser-based flow still validates the ID token internally on both platforms. What changed is only the **direct token-request** paths, where the SDK now opts in per flow. The current state is:
241+
242+
| Flow | ID-token claims validated? |
243+
| :--------------------------------- | :------------------------: |
244+
| Web Authentication (`authorize()`) | ✅ (both platforms) |
245+
| Passkey **signin** | ✅ (both platforms) |
246+
| Passkey **signup** | ❌ (both platforms) |
247+
| Custom Token Exchange | ❌ (both platforms) |
248+
| MFA challenge/verify | ❌ (both platforms) |
249+
| Passwordless | ❌ (both platforms) |
250+
251+
The `` rows are **deliberate iOS/Android parity**, not an oversight — these flows validate on neither platform, so behaviour is identical everywhere. No action is required; this is documented so you know exactly which responses carry a validated ID token.
252+
238253
### 10. Interfaces no longer use the `I` prefix ✅
239254
240255
The platform contracts in `src/core/interfaces/` dropped their `I` prefix, so the interface now takes the plain name and the implementations keep their platform prefix (`Auth0Client` is the contract; `NativeAuth0Client` and `WebAuth0Client` implement it).

README.md

Lines changed: 35 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -36,23 +36,25 @@ This SDK targets apps that are using React Native SDK version `0.82.0` and up. I
3636

3737
React Native `0.82` is the first React Native release that runs **entirely on the New Architecture**. As of v6, this SDK is **New Architecture-only** — the Legacy Architecture is no longer supported. If your app has not yet moved to the New Architecture, upgrade to React Native `0.82`+ or stay on v5.x. For Expo, this SDK requires **Expo SDK 55 or higher** (Expo 54 ships React Native `0.81`, below the `0.82` floor).
3838

39-
> ⚠️ **Warning**: If you are using Expo version less than 53, you need to use react-native-auth0 version 4.x or earlier. Version 5.x supports Expo 53 and above.
39+
> ⚠️ **Warning**: For Expo, this version requires **Expo SDK 55 or higher** (Expo 54 ships React Native `0.81`, below the `0.82` floor). If you are on an earlier Expo version, upgrade Expo or stay on react-native-auth0 `5.x` (Expo 53–54) or `4.x` (below Expo 53).
4040
4141
### Platform compatibility
4242

4343
The following shows platform minimums for running projects with this SDK:
4444

45-
| Platform | Minimum version |
46-
| -------- | :-------------: |
47-
| iOS | 14.0 |
48-
| Android | 35 |
45+
| Platform | Minimum version |
46+
| -------- | :------------------: |
47+
| iOS | 15.1 |
48+
| Android | API 26 (Android 8.0) |
4949

50-
Our SDK requires a minimum iOS deployment target of 14.0. In your project's ios/Podfile, ensure your platform target is set to 14.0.
50+
**iOS.** This SDK requires a minimum iOS deployment target of `15.1`, inherited from the React Native `0.82`+ Pods (`min_ios_version_supported`). In your project's `ios/Podfile`, set the platform accordingly — following the older `14.0` value will fail `pod install`:
5151

52-
```
53-
platform :ios, '14.0'
52+
```ruby
53+
platform :ios, '15.1'
5454
```
5555

56+
**Android.** This SDK requires **`minSdkVersion` 26** (Android 8.0). It compiles against **`compileSdkVersion` 36** and must be built with **JDK 17**. Raise these in your app's `android/build.gradle` (and verify your toolchain with `java -version`) if you are coming from an earlier setup. See the [Migration Guide](https://github.com/auth0/react-native-auth0/blob/master/MIGRATION_GUIDE.md) for details.
57+
5658
The iOS pod ships a privacy manifest (`PrivacyInfo.xcprivacy`) that declares no tracking, no required-reason API usage, and a user identifier collected only for app functionality. Xcode includes it automatically when you generate a privacy report, so you don't have to describe this SDK's behavior yourself. You are still responsible for reviewing that report and for keeping your App Store Connect privacy answers accurate for your app as a whole, including the data this SDK collects.
5759

5860
### Installation
@@ -71,6 +73,26 @@ Then, you need to run the following command to install the ios app pods with Coc
7173

7274
`$ cd ios && pod install`
7375

76+
#### iOS framework linkage (`use_frameworks!`)
77+
78+
This SDK's native dependencies — Auth0 3.0.1, JWTDecode 4.0.0, and SimpleKeychain 1.3.0 — are Swift pods. They install with the default React Native static-library linkage (no `use_frameworks!`), so **most apps need no extra Podfile changes**.
79+
80+
If your project requires `use_frameworks!` (for example, because another dependency ships as a framework), both linkage modes are supported — this was verified by building the example app under each:
81+
82+
```ruby
83+
# Static frameworks
84+
use_frameworks! :linkage => :static
85+
86+
# ...or dynamic frameworks
87+
use_frameworks! :linkage => :dynamic
88+
```
89+
90+
No additional `post_install` step is required for this SDK beyond what React Native already generates. After changing linkage, run a clean install:
91+
92+
```bash
93+
cd ios && rm -rf Pods Podfile.lock && pod install --repo-update
94+
```
95+
7496
### Configure the SDK
7597

7698
You need to make your Android, iOS or Expo applications aware that an authentication result will be received from the browser. This SDK makes use of the Android's Package Name and its analogous iOS's Product Bundle Identifier to generate the redirect URL. Each platform has its own set of instructions.
@@ -679,12 +701,12 @@ instead — for example [Custom Token Exchange](EXAMPLES.md#custom-token-exchang
679701
the raw OAuth error from the token endpoint — don't get a normalized `type`; there, `code` is the
680702
correct (and only) thing to switch on.
681703

682-
| Property | Use it for |
683-
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |
684-
| `type` | **Control flow** for the six normalized subclasses. A normalized code, stable across platforms. Compare against the `…ErrorCodes` constants. |
704+
| Property | Use it for |
705+
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
706+
| `type` | **Control flow** for the six normalized subclasses. A normalized code, stable across platforms. Compare against the `…ErrorCodes` constants. |
685707
| `code` | **Diagnostics** for the normalized subclasses (raw code from the underlying platform SDK or wire response, varies by platform); **control flow** for plain `AuthError` flows that have no normalized `type`. |
686-
| `message` | Human-readable description. Not stable — do not parse it. |
687-
| `status` | HTTP status, when the failure came from an HTTP response (`0` otherwise). |
708+
| `message` | Human-readable description. Not stable — do not parse it. |
709+
| `status` | HTTP status, when the failure came from an HTTP response (`0` otherwise). |
688710

689711
Each of the six normalized classes ships a companion constants object and a matching TypeScript
690712
union. Handle every value explicitly (no `default` branch) and TypeScript enforces exhaustiveness

0 commit comments

Comments
 (0)