-
Notifications
You must be signed in to change notification settings - Fork 205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
device.id
vs installation.id
on Android and iOS
#1874
Comments
Note: #1474 is somewhat related, but has a different focus. |
On Apple platforms, it is not possible - by design - to get an id identifying a particular device across applications. The nearest thing, technically, is advertisingIdentifier, which, however, cannot be legally used for telemetry and requires user consent. In my view, the concept of an |
Thanks for the discussion @bencehornak . I think that I understand most of the points here, and in general this seems reasonable to me, but wanted to make a few points:
If I've gotten any of those wrong, please point it out. Thanks again! |
@breedx-splk thanks for your points, I think they'll serve as a good start for the requirements of the proposed
The Android ones I mostly took from the article Decoding Unique Identifiers in Android: Risks, Impacts, and Solutions. So based on the table I would refine your points as following:
I wouldn't go as far as to deprecate
One use-case for
What do you think about these modified points? |
The enterprise here seems a bit iffy to me. I guess what we are really after is making it very clear that this attribute can pose privacy issues and must be used with care. At first I was more inclined to just deprecate it, as it doesn't sound like a good idea for semconv to have such thing that can be misused like this. But your use case about the museum seems legit. So maybe we drop these two:
And rather keep the existing disclaimer/warning as part of the brief
Also, it should definitely be |
CC @marandaneto maybe you also can chime in here :) |
@joaopgrassi sounds good, I'm totally fine with your suggestions! |
@bencehornak cool! Will you be working on it? Let me know so then I can assign this issue to you. |
Sure, you can assign it to me |
A little late to this, but I have a couple of thoughts: First, the following may not be possible:
On Android, install-identifying IDs are typically stored in a place that that can be cleared by users without uninstalling (e.g. app data, shared preferences, etc.), so any app-data purge is effectively a factor reset without actually uninstalling. We should probably put in a caveat to allow for any install-resetting actions to recreate this. Second, another use case that requires a install-dependent ID is to differentiate between the different accounts that are using the same install. This isn't the same as an account/user ID, because you don't want the same account on two installs to have the same ID. Think of it as a device-account tuple. In that case, should |
@bidetofevil good points, thanks for the feedback, I have made the following adjustments in fd2e226:
I have relaxed the wording to 'SHOULD'. (Its value SHOULD remain the same between launches of the same installation of an application.)
Added the following sentence: Additionally, users might be able to reset this value (e.g. by clearing application data).
Added the following sentence: If an app is installed multiple times on the same device (e.g. in different accounts on Android), each installation SHOULD have a different value. Let me know, if you would like to see further adjustments! |
Area(s)
area:device
What's missing?
Take a look at the current definition of
device.id
:semantic-conventions/model/device/registry.yaml
Lines 14 to 21 in b855a36
The obligatory recommendation for Android (Firebase Installation ID or a globally unique UUID which is persisted across sessions in your application) mostly mirrors the recommendation for Google
The one for iOS suggests using
identifierForVendor
.Now I have multiple remarks to these recommendations:
None of the two Android recommendations and the one iOS recommendation are really device ids, they are more like installation ids. For consumer apps the difference is probably insignificant, however, for enterprise apps on managed Android/iOS devices it is important. One could have many managed applications on the same device, so the expectation for
device.id
s would be that they are identical across all apps, which neither the Firebase Installation ID, nor the random generated UUID or the iOSidentifierForVendor
fulfill.There is another ID, which fits my use case better on Android, called
Settings.Secure.ANDROID_ID
, because I don't want to use Firebase, but I want an ID which survives uninstalls, and which is consistent across all my in-house apps.Although not recommended by Google for Android, one could still use actual device IDs, such as the IMEI or proprietary APIs provided by the vendor (e.g. Zebra's API), which are bound to the device for its whole lifetime. For enterprise-managed hardware there might be a legitimate use for such actual device ids, so these IDs would rather deserve to be the definition of
device.id
.Describe the solution you'd like
I would recommend these 3 changes:
installation.id
, and recommend it for most use-cases on Android and iOS.installation.id
, thatdevice.id
currently has, but extend it with the possibility to useSettings.Secure.ANDROID_ID
device.id
due to privacy reasons, but leave it open to custom implementations, such as IMEI or proprietary APIs.The text was updated successfully, but these errors were encountered: