getsentry / sentry-cocoa

The official Sentry SDK for iOS, tvOS, macOS, watchOS.
https://sentry.io/for/cocoa/
MIT License
815 stars 330 forks source link

Simplify `deviceAppHash` #4022

Open kahest opened 6 months ago

kahest commented 6 months ago

Description

The deviceAppHash is generated in https://github.com/getsentry/sentry-cocoa/blob/7741a2de06bd1aa1ce411c5787ff0dd7db32bde1/Sources/SentryCrash/Recording/Monitors/SentryCrashMonitor_System.m#L393 from various factors. It ends up on crash reports in device_app_hash.

Suggestion: Look into whether it's possible to eliminate some of the factors and make the hash more random, while retaining the minimum uniqueness required for functionality.

philipphofmann commented 5 months ago

Let's replace app.context.device_app_hash with the installationID, which we already do on Android. We have to do this in the next major. While this doesn't violate Apple's Privacy Policy, we don't want to keep the deviceAppHash in its current form cause you could use it to track a user across the same app installations.