os-issue-tracker icon indicating copy to clipboard operation
os-issue-tracker copied to clipboard

Ability to grant UWB_PRIVILEGED permission

Open odlg opened this issue 11 months ago • 8 comments

I am trying to set up a Digital key for my car. During the process, I get this error:

01-01 19:31:48.974 15103 15103 E AndroidRuntime: Process: com.google.android.gms.ui, PID: 15103
01-01 19:31:48.974 15103 15103 E AndroidRuntime: java.lang.SecurityException: UwbService: Neither user 10233 nor current process has android.permission.UWB_PRIVILEGED.
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.os.Parcel.createExceptionOrNull(Parcel.java:3240)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.os.Parcel.createException(Parcel.java:3224)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.os.Parcel.readException(Parcel.java:3200)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.os.Parcel.readException(Parcel.java:3142)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.uwb.IUwbAdapter$Stub$Proxy.registerAdapterStateCallbacks(IUwbAdapter.java:1136)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.uwb.AdapterStateListener.register(AdapterStateListener.java:67)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at android.uwb.UwbManager.registerAdapterStateCallback(UwbManager.java:440)
01-01 19:31:48.974 15103 15103 E AndroidRuntime: 	at m.jff.<init>(:com.google.android.gms.optional_dck@[email protected] (150400-0):206)
.....

Is it possible to grant this permission some way?

odlg avatar Jan 01 '25 19:01 odlg

It's not currently a supported feature but it's possible we could provide something. It's likely more would be required than just this.

thestinger avatar Jan 03 '25 06:01 thestinger

Same issue here, tried setting up and same error happens. Tried sending it from iphone through e-mail and same thing happens.

This is for BMW key that has ability to unlock and start car. Phone needs to be near door handle to unlock and in center console to start car.

@thestinger let me know what is needed and i will provide.

tunayuyar avatar Jan 08 '25 06:01 tunayuyar

First uwb would need to be fixed, https://github.com/GrapheneOS/os-issue-tracker/issues/2712

Youngblood50 avatar Jan 12 '25 10:01 Youngblood50

Same problem here. Please let us know what is required to make the BMW Digital Key work.

tw-mloschwitz avatar Jul 04 '25 22:07 tw-mloschwitz

Same problem here. Please let us know what is required to make the BMW Digital Key work.

You may need to give Play Services and BMW app some permissions like nearby devices. UWB is fixed now so in theory it should work.

Youngblood50 avatar Jul 07 '25 16:07 Youngblood50

Fixed since when? Both apps have all selectable permissions, so unless something changed since Saturday, I don't think that's the issue ...

tw-mloschwitz avatar Jul 07 '25 16:07 tw-mloschwitz

UWB is fixed but we don't have a way to use the Play services privileged UWB functionality.

thestinger avatar Jul 07 '25 18:07 thestinger

What about applications that don't use Play Services like utag? Do those still require UWB_PRIVILEGED?

hashworks avatar Dec 13 '25 14:12 hashworks

UWB is fixed but we don't have a way to use the Play services privileged UWB functionality.

Does this mean that UWB can't work even if Play services is installed? Like there's some missing Google-only piece that GrapheneOS can't make use of?

I'd also like to set up my car's digital key, which appears to rely on Google Wallet and UWB. I get the same crash from com.google.android.gms.ui when trying to set it up:

type: crash
osVersion: google/komodo/komodo:16/BP4A.251205.006/2025121701:user/release-keys
package: [com.google.android](https://com.google.android/).gms:254730035, targetSdk 36
process: [com.google.android](https://com.google.android/).gms.ui
processUptime: 92884 + 270 ms
installer: app.grapheneos.apps
GmsCompatConfig version: 167

java.lang.SecurityException: UwbService: Neither user ##### nor current process has android.permission.UWB_PRIVILEGED.

Based on the last line there I wonder if the user can be granted UWB access (which I assumed was the case when the toggle is switched on) or if that's not actually the problem.

eepotter avatar Dec 21 '25 00:12 eepotter