Files
self/packages/native-shell-ios/Sources/SelfNativeShell/WebView
Seshanth.S 37b8f0ca71 Scope KMP SDK to 3-domain parity (KR-01, KR-02, KR-03) (#1915)
* KR-01: Scope KMP Android to 3-domain parity with provider delegation

Move SecureStorageProvider, CryptoProvider, and CryptoBridgeHandler to
commonMain so both platforms share the same contract. Add default Android
providers (EncryptedSharedPreferencesProvider, AndroidKeystoreCryptoProvider)
that consumers can replace via SdkProviderRegistry.

- Rewrite Android SecureStorageBridgeHandler to delegate to provider and
  fix get() response shape to return { value: string | null }
- Register only 3 handlers (secureStorage, crypto, lifecycle) in Activity
- Add WebChromeClient with permission and file upload handling
- Add query param support to WebView URL loading
- Add bridge protocol version validation to MessageRouter
- Remove NFC/camera/biometric dependencies from build.gradle.kts
- Remove out-of-scope permissions from AndroidManifest.xml
- Create IosProviderRegistry for iOS-specific provider fields

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* KR-02: Scope KMP iOS to 3-domain parity with query param support

Move SecureStorageBridgeHandler to commonMain (fixes iOS get() response
shape to return { value: string | null } matching the bridge adapter).
Both Android and iOS now share the same handler via commonMain.

- Register only 3 handlers on iOS (secureStorage, crypto, lifecycle)
- Add queryParams parameter to WebViewProvider interface
- Update IosWebViewHost to forward query params from VerificationRequest
- Update WebViewProviderImpl.swift to append query params to URL
- Relax isConfigured check to only require secureStorage + crypto + webView
- Remove unused handler imports from SelfSdk.ios.kt

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* KR-03: Simplify test app to 3-domain smoke harness

Gut the MRZ/NFC-first flow from the test app and replace with a focused
3-domain smoke test screen that validates secureStorage (set/get/remove
round-trip), crypto (generateKey/getPublicKey/sign/deleteKey), and
lifecycle (validated via SDK launch flow).

- Add DomainSmokeScreen with pass/fail output per domain
- Remove MRZ/NFC navigation routes and expect/actual screen declarations
- Remove NFC/CAMERA permissions from Android manifest
- Remove camera dependency from build.gradle.kts
- Scope iOS test app to register only required providers (secureStorage,
  crypto, webView)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Fix issues - test app

* coderabbit comments

* fix ci

* klint

* coderabbit review comments

* Enhance permission handling in AndroidWebViewHost

* fix registry

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Justin Hernandez <justin.hernandez@self.xyz>
2026-04-03 11:45:07 -07:00
..