zhuowei/Xenologer

Permission errors

Closed this issue · 1 comments

When I run the Glass Setup it crashes with the following permission errors:

E/HiddenApiHelper(23331): Unable to enable ComponentInfo{com.google.glass.deviceadmin/com.google.glass.deviceadmin.GlassDeviceAdminReceiver}
E/HiddenApiHelper(23331): java.lang.reflect.InvocationTargetException
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invokeNative(Native Method)
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invoke(Method.java:511)
E/HiddenApiHelper(23331):   at com.google.glass.util.HiddenApiHelper.setActiveAdmin(HiddenApiHelper.java:790)
E/HiddenApiHelper(23331):   at com.google.glass.setup.SetupActivity$9.run(SetupActivity.java:659)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
E/HiddenApiHelper(23331):   at java.lang.Thread.run(Thread.java:856)
E/HiddenApiHelper(23331): Caused by: java.lang.SecurityException: Neither user 10095 nor current process has android.permission.BIND_DEVICE_ADMIN.
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1425)
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1379)
E/HiddenApiHelper(23331):   at android.app.admin.IDevicePolicyManager$Stub$Proxy.setActiveAdmin(IDevicePolicyManager.java:1796)
E/HiddenApiHelper(23331):   at android.app.admin.DevicePolicyManager.setActiveAdmin(DevicePolicyManager.java:1428)
E/HiddenApiHelper(23331):   ... 7 more
D/overlay (  159): Set pipe=RGB1 dpy=0; 
E/HiddenApiHelper(23331): Unable to set backups enabled to true
E/HiddenApiHelper(23331): java.lang.reflect.InvocationTargetException
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invokeNative(Native Method)
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invoke(Method.java:511)
E/HiddenApiHelper(23331):   at com.google.glass.util.HiddenApiHelper.setBackupEnabled(HiddenApiHelper.java:564)
E/HiddenApiHelper(23331):   at com.google.glass.setup.SettingsRestoreHelper.restoreSettings(SettingsRestoreHelper.java:36)
E/HiddenApiHelper(23331):   at com.google.glass.setup.SetupActivity$9.run(SetupActivity.java:662)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
E/HiddenApiHelper(23331):   at java.lang.Thread.run(Thread.java:856)
E/HiddenApiHelper(23331): Caused by: java.lang.SecurityException: setBackupEnabled: Neither user 10095 nor current process has android.permission.BACKUP.
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1425)
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1379)
E/HiddenApiHelper(23331):   at android.app.backup.IBackupManager$Stub$Proxy.setBackupEnabled(IBackupManager.java:434)
E/HiddenApiHelper(23331):   ... 8 more
D/SettingsRestoreHelper(23331): Enabled backup manager.
D/UserEventHelper(23331): Logging user event [action=PROTO_REQUEST_DISPATCHER_BATCH, data=|r=1|breq=17|bres=114|l=529|e=0|].
E/PerformanceUtil(23331): File doesn't exist: /sys/devices/platform/notle_pcb_sensor.0/temperature
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/charge_now
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/charge_full
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/temp
D/UserEventHelper(23331): Logging user event [action=PROTO_REQUEST_DISPATCHER_REQUEST_SIZE, data=|p=sua|breq=17|bres=110|].
E/PerformanceUtil(23331): File doesn't exist: /sys/devices/platform/notle_pcb_sensor.0/temperature
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/charge_now
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/charge_full
E/PerformanceUtil(23331): File doesn't exist: /sys/class/power_supply/bq27520-0/temp
E/HiddenApiHelper(23331): Unable to set backup transport to com.google.android.backup/.BackupTransportService
E/HiddenApiHelper(23331): java.lang.reflect.InvocationTargetException
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invokeNative(Native Method)
E/HiddenApiHelper(23331):   at java.lang.reflect.Method.invoke(Method.java:511)
E/HiddenApiHelper(23331):   at com.google.glass.util.HiddenApiHelper.selectBackupTransport(HiddenApiHelper.java:581)
E/HiddenApiHelper(23331):   at com.google.glass.setup.SettingsRestoreHelper.restoreSettings(SettingsRestoreHelper.java:40)
E/HiddenApiHelper(23331):   at com.google.glass.setup.SetupActivity$9.run(SetupActivity.java:662)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
E/HiddenApiHelper(23331):   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
E/HiddenApiHelper(23331):   at java.lang.Thread.run(Thread.java:856)
E/HiddenApiHelper(23331): Caused by: java.lang.SecurityException: selectBackupTransport: Neither user 10095 nor current process has android.permission.BACKUP.
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1425)
E/HiddenApiHelper(23331):   at android.os.Parcel.readException(Parcel.java:1379)
E/HiddenApiHelper(23331):   at android.app.backup.IBackupManager$Stub$Proxy.selectBackupTransport(IBackupManager.java:756)
E/HiddenApiHelper(23331):   ... 8 more
D/SettingsRestoreHelper(23331): Selected Google backup transport.
W/ActivityManager(  520): Unable to start service Intent { cmp=com.google.glass.logging/.UserEventService (has extras) } U=0: not found
W/dalvikvm(23331): threadid=17: thread exiting with uncaught exception (group=0x41028930)
W/ActivityManager(  520): Permission Denial: Accessing service ComponentInfo{com.google.android.backup/com.google.android.backup.BackupTransportService} from pid=23331, uid=10095 requires android.permission.BACKUP
E/AndroidRuntime(23331): FATAL EXCEPTION: AsyncTask #4
E/AndroidRuntime(23331): java.lang.SecurityException: Not allowed to start service Intent { act=com.google.android.backup.SetBackupAccount (has extras) } without permission android.permission.BACKUP
E/AndroidRuntime(23331):    at android.app.ContextImpl.startServiceAsUser(ContextImpl.java:1371)
E/AndroidRuntime(23331):    at android.app.ContextImpl.startService(ContextImpl.java:1353)
E/AndroidRuntime(23331):    at android.content.ContextWrapper.startService(ContextWrapper.java:450)
E/AndroidRuntime(23331):    at com.google.glass.setup.SettingsRestoreHelper.restoreSettings(SettingsRestoreHelper.java:47)
E/AndroidRuntime(23331):    at com.google.glass.setup.SetupActivity$9.run(SetupActivity.java:662)
E/AndroidRuntime(23331):    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
E/AndroidRuntime(23331):    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
E/AndroidRuntime(23331):    at java.lang.Thread.run(Thread.java:856)

It's intended; after Glass runs setup, it attempts to restore contacts, which it can't do. However, the setup completed prior to the crash, so you should still see the Continue button on MyGlass.