fix(dashpay): remove unused Firebase Dynamic Links SDK - #1056
fix(dashpay): remove unused Firebase Dynamic Links SDK#1056QuantumExplorer wants to merge 1 commit into
Conversation
Nothing in the app referenced Dynamic Links, but the SDK still ran: its component registers as EagerInDefaultApp, so the unconditional [FIRApp configure] instantiated it, and automatic retrieval defaults to enabled because neither Info.plist set FirebaseDeepLinkAutomaticRetrievalEnabled. On the first run after install it POSTed to firebasedynamiclinks.googleapis.com/installAttribution with screen resolution, locale, timezone, device model, iOS version and app installation time — install-attribution fingerprinting, against a product Google shut down in 2025. Invitation universal links already bypass it; continueUserActivity routes them straight into DWInvitationLinkNormalizer, and the associated-domains entitlement is untouched. Depend on Firebase/CoreOnly directly in place of the removed subspec. CoreOnly ships Firebase.h and its module map, which is what `@import Firebase` and `import Firebase` resolve against; it previously arrived implicitly via Firebase/DynamicLinks. FirebaseStorage has no module map of its own, so dropping the umbrella outright would break both imports. Firebase.h reaches Storage through __has_include, and guards its DynamicLinks include the same way, so that branch compiles out and no source imports change. Also drops the two Info.plist keys that only configured the removed SDK, and DWURLParser.shouldIgnoreURL:, which existed solely to swallow the "No pre-install link matched for this device." URL Dynamic Links handed back on first run (e5c6011). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Warning Review limit reachedNext included review available in 54 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
This will not link: I checked out the branch, ran
Linking against that combination gives This is very likely why your build never reached a successful link. The four Fix: I applied that locally and re-checked: Two minor things:
Everything else checks out. The |
What
Removes the
Firebase/DynamicLinkspod and its leftover configuration. Nothing in the app used it, and its only observable effect was sending Google a device fingerprint on first launch.Why
This came out of a community question in the Russian Telegram group asking whether analytics/tracking are enabled in the new iOS build. There is no analytics SDK in the iOS app — no FirebaseAnalytics, GoogleAppMeasurement, Crashlytics, Mixpanel, Amplitude, Sentry or AppsFlyer is linked, there are zero
logEvent/trackEventcall sites, and there is no IDFA/ATT surface. But the audit turned up outbound calls that a privacy-focused user would reasonably call tracking, and this was one of them.The SDK self-starts and fingerprints the device
[FIRApp configure]runs unconditionally atDashWallet/AppDelegate.m:113. Dynamic Links registers its component withFIRInstantiationTimingEagerInDefaultApp, soconfigureinstantiates it immediately, and the creation block ends with:isAutomaticRetrievalEnabledreturnsYESunlessFirebaseDeepLinkAutomaticRetrievalEnabledis set in the Info.plist, and neither plist set it. So on the first run after install, the SDK POSTs tofirebasedynamiclinks.googleapis.com/v1/installAttributionwith a request body containing screen resolution, locale, timezone, device model, iOS version and app installation time — which, combined with the source IP Google observes, is probabilistic install-attribution fingerprinting.Nothing uses it
There is not a single reference to
DynamicLinks,FIRDynamicLinksorhandleUniversalLinkanywhere outsidePods/. Universal links are already routed directly, andAppDelegate.msays so incontinueUserActivity::Google shut Dynamic Links down in August 2025, so the endpoint it fingerprints against is a dead product.
Changes
Podfile— replacepod 'Firebase/DynamicLinks'withpod 'Firebase/CoreOnly'in both thedashwalletanddashpaytargets.The swap matters:
CoreOnlyis what shipsFirebase.hand its module map, which is what@import Firebase;(AppDelegate) andimport Firebase(ExploreDatabaseSyncManager) resolve against. It previously arrived implicitly as a dependency of the DynamicLinks subspec, so removing that subspec outright breaks both imports. There is noFirebaseStorageSwift module to fall back on — CocoaPods generates no module map for it, since the pod is not built withmodular_headers.Firebase.hreaches Storage through#if __has_include(<FirebaseStorage/FirebaseStorage.h>), and its DynamicLinks branch is guarded the same way, so it simply compiles out. No source imports change.Podfile.lock— regenerated withpod _1.15.2_ install, the version CI pins. The diff is exactly the DynamicLinks removal,Firebase/CoreOnlymoving intoDEPENDENCIES, and the Podfile checksum.FirebaseCorestays at 8.15.0.DashPay/dashpay-info.plist— removeFirebaseDynamicLinksCustomDomainsandFirebaseDeepLinkPasteboardRetrievalEnabled, both of which only configured the removed SDK.DWURLParser.shouldIgnoreURL:— removed, along with its call site inAppDelegate.m. It existed solely to swallow thegoogle://…?match_message=No pre-install link matched for this device.URL that Dynamic Links handed back on first run (commite5c6011e2, "Ignore dynamic link that comes from Firebase on first run"). With the SDK gone nothing can produce that URL.Not affected
Invitation handling.
invitations.dashpay.ioremains incom.apple.developer.associated-domains,continueUserActivity:still routes the universal link straight intoDWInvitationLinkNormalizer, and thedashpay://invitescheme path is unchanged. The removed plist key was Dynamic Links' own custom-domain list, not the associated-domains entitlement.Firebase Storage — the Explore Dash merchant database download from
gs://dash-wallet-firebase.appspot.com— is untouched.Verification
xcodebuild -scheme dashpay -sdk iphonesimulator ARCHS=arm64compiles the two files that import Firebase with no module-resolution errors.pod _1.15.2_ install --deployment— the exact invocation CI uses — reports "Verifying no changes" against the committed lockfile.grep -rn "DynamicLink"over*.swift/*.m/*.h/*.plistoutsidePods/returns nothing.Full disclosure on the build: it does not reach a successful link in my environment, but the remaining failure is pre-existing on
developand unrelated. It is four errors inEvonodeStatusViewModel.swift(value of type 'SDK' has no member 'getEvonodeStatus',cannot find type 'EvonodeStatus' in scope,'PlatformMasternode' has no member 'platformDAPIAddress') caused by the local../platformSwiftDashSDK checkout sitting on an unrelated feature branch that predates that API. I confirmed it by building untoucheddevelop, which produces the identical four errors and nothing else. Since this PR does change what gets linked, please confirm a clean build on a correctly-pinned platform checkout before merging.Related
Two companion PRs address the other outbound channels found in the same audit: #1053 disables the Firebase diagnostics heartbeat, and #1055 stops a per-foreground IP geolocation lookup to ip-api.com.
🤖 Generated with Claude Code