java.lang.SecurityException: Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH.

JIRA | Joni | 11 months ago
  1. 0

    Phone crashes totally, need hard reset, when making a call at car via bluetooth. The problem setup goes: - you need to have for example oneplus one original flip cover - keep lid closed - make any call -> call wont succeed, phone hangs (bluetooth connection stays on until phone automatically reboots, sometimes no reboot) Calling succeeds: - when lid open - when face down - when lid open at pocket so that proximity is for sure covered This has been like this since first CM13 builds. I have some logs from unofficial build but this happens with nightlies too. 01-07 19:44:40.378 5196 5342 E AndroidRuntime: FATAL EXCEPTION: BluetoothAvrcpHandler 01-07 19:44:40.378 5196 5342 E AndroidRuntime: Process: com.android.bluetooth, PID: 5196 01-07 19:44:40.378 5196 5342 E AndroidRuntime: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH. 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.app.ContextImpl.enforce(ContextImpl.java:1450) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.app.ContextImpl.enforceCallingOrSelfPermission(ContextImpl.java:1482) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.content.ContextWrapper.enforceCallingOrSelfPermission(ContextWrapper.java:681) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.btservice.AdapterService.getRemoteName(AdapterService.java:1962) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.btservice.AdapterService$AdapterServiceBinder.getRemoteName(AdapterService.java:1050) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.bluetooth.BluetoothDevice.getName(BluetoothDevice.java:726) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.avrcp.Avrcp$AvrcpMessageHandler.handleMessage(Avrcp.java:1034) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.HandlerThread.run(HandlerThread.java:61) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: Error reporting crash 01-07 19:44:40.379 5196 5342 E AndroidRuntime: android.os.DeadObjectException 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.os.BinderProxy.transactNative(Native Method) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.os.BinderProxy.transact(Binder.java:503) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.app.ActivityManagerProxy.handleApplicationCrash(ActivityManagerNative.java:4447) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at com.android.internal.os.RuntimeInit$UncaughtHandler.uncaughtException(RuntimeInit.java:90) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:693) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:690)

    JIRA | 11 months ago | Joni
    java.lang.SecurityException: Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH.
  2. 0

    Phone crashes totally, need hard reset, when making a call at car via bluetooth. The problem setup goes: - you need to have for example oneplus one original flip cover - keep lid closed - make any call -> call wont succeed, phone hangs (bluetooth connection stays on until phone automatically reboots, sometimes no reboot) Calling succeeds: - when lid open - when face down - when lid open at pocket so that proximity is for sure covered This has been like this since first CM13 builds. I have some logs from unofficial build but this happens with nightlies too. 01-07 19:44:40.378 5196 5342 E AndroidRuntime: FATAL EXCEPTION: BluetoothAvrcpHandler 01-07 19:44:40.378 5196 5342 E AndroidRuntime: Process: com.android.bluetooth, PID: 5196 01-07 19:44:40.378 5196 5342 E AndroidRuntime: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH. 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.app.ContextImpl.enforce(ContextImpl.java:1450) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.app.ContextImpl.enforceCallingOrSelfPermission(ContextImpl.java:1482) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.content.ContextWrapper.enforceCallingOrSelfPermission(ContextWrapper.java:681) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.btservice.AdapterService.getRemoteName(AdapterService.java:1962) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.btservice.AdapterService$AdapterServiceBinder.getRemoteName(AdapterService.java:1050) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.bluetooth.BluetoothDevice.getName(BluetoothDevice.java:726) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at com.android.bluetooth.avrcp.Avrcp$AvrcpMessageHandler.handleMessage(Avrcp.java:1034) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148) 01-07 19:44:40.378 5196 5342 E AndroidRuntime: at android.os.HandlerThread.run(HandlerThread.java:61) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: Error reporting crash 01-07 19:44:40.379 5196 5342 E AndroidRuntime: android.os.DeadObjectException 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.os.BinderProxy.transactNative(Native Method) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.os.BinderProxy.transact(Binder.java:503) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at android.app.ActivityManagerProxy.handleApplicationCrash(ActivityManagerNative.java:4447) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at com.android.internal.os.RuntimeInit$UncaughtHandler.uncaughtException(RuntimeInit.java:90) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:693) 01-07 19:44:40.379 5196 5342 E AndroidRuntime: at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:690)

    JIRA | 11 months ago | Joni
    java.lang.SecurityException: Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH.
  3. 0

    GitHub comment 143#169623122

    GitHub | 11 months ago | 42SK
    java.lang.SecurityException: No permission to write to /storage/emulated/0/NewPipe/Free software, free society: Richard Stallman at TEDxGeneva 2014.webm: Neither user 10126 nor current proc ess has android.permission.WRITE_EXTERNAL_STORAGE.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Android 6 - phone crashes when bluetooth device found

    Stack Overflow | 6 months ago | knight37x
    java.lang.SecurityException: Need BLUETOOTH_ADMIN permission: Neither user 1002 nor current process has android.permission.BLUETOOTH_ADMIN.
  6. 0

    custom icon for google maps for android

    Stack Overflow | 2 years ago | lycastos
    java.lang.SecurityException: attempting to read gservices without permission: Neither user 10050 nor current process has com.google.android.providers.gsf.permission.READ_GSERVICES.
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.SecurityException

    Need BLUETOOTH permission: Neither user 1002 nor current process has android.permission.BLUETOOTH.

    at android.app.ContextImpl.enforce()
  2. Android Platform
    ContextWrapper.enforceCallingOrSelfPermission
    1. android.app.ContextImpl.enforce(ContextImpl.java:1450)
    2. android.app.ContextImpl.enforceCallingOrSelfPermission(ContextImpl.java:1482)
    3. android.content.ContextWrapper.enforceCallingOrSelfPermission(ContextWrapper.java:681)
    3 frames
  3. com.android.bluetooth
    AdapterService$AdapterServiceBinder.getRemoteName
    1. com.android.bluetooth.btservice.AdapterService.getRemoteName(AdapterService.java:1962)
    2. com.android.bluetooth.btservice.AdapterService$AdapterServiceBinder.getRemoteName(AdapterService.java:1050)
    2 frames
  4. Android Platform
    BluetoothDevice.getName
    1. android.bluetooth.BluetoothDevice.getName(BluetoothDevice.java:726)
    1 frame
  5. com.android.bluetooth
    Avrcp$AvrcpMessageHandler.handleMessage
    1. com.android.bluetooth.avrcp.Avrcp$AvrcpMessageHandler.handleMessage(Avrcp.java:1034)
    1 frame
  6. Android Platform
    HandlerThread.run
    1. android.os.Handler.dispatchMessage(Handler.java:102)
    2. android.os.Looper.loop(Looper.java:148)
    3. android.os.HandlerThread.run(HandlerThread.java:61)
    3 frames