Secure Settings ADB Promblem

518 views
Skip to first unread message

Harry

unread,
Jul 11, 2021, 5:40:39 AM7/11/21
to Tasker
I am transferring tasker to a new phone and trying to set permissions with adb. I need to use AutoTools Secure Settings in a task that was working fine on the old phone. Phone is a Galaxy S8 running android 9. Following is what I get when trying to execute a task using Secure Settings:

05.36.15/E FIRE PLUGIN: AutoTools Secure Settings / com.twofortyfouram.locale.intent.action.FIRE_SETTING: 6 bundle keys
05.36.15/E AutoTools Secure Settings: plugin comp: com.joaomgcd.autotools/com.joaomgcd.autotools.broadcastreceiver.IntentServiceFire
05.36.15/E add wait type Plugin1 time 60
05.36.15/E add wait type Plugin1 done
05.36.15/E handlePluginFinish: taskExeID: 1 result 3
05.36.15/E pending result code
05.36.15/E add wait task
05.36.15/E Error: 233554760
05.36.15/E No permission to change setting. Touch here or check the (i) button on the top right when configuring this action to check how to grant permissions so that AutoTools can change it


Following the text from the cmd window using ADB:

Microsoft Windows [Version 10.0.19041.1083]
(c) Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>cd \Temp\ADB\platform-tools

C:\Temp\ADB\platform-tools>adb start-server
* daemon not running; starting now at tcp:5037
* daemon started successfully

C:\Temp\ADB\platform-tools>adb shell pm grant net.dinglisch.android.taskerm android.permission.WRITE_SECURE_SETTINGS

C:\Temp\ADB\platform-tools>adb shell pm grant net.dinglisch.android.taskerm android.permission.set_volume_key_long_press_listener

Exception occurred while executing:
java.lang.IllegalArgumentException: Unknown permission: android.permission.set_volume_key_long_press_listener
        at com.android.server.pm.permission.PermissionManagerService.grantRuntimePermission(PermissionManagerService.java:2258)
        at com.android.server.pm.permission.PermissionManagerService.access$1200(PermissionManagerService.java:132)
        at com.android.server.pm.permission.PermissionManagerService$PermissionManagerInternalImpl.grantRuntimePermission(PermissionManagerService.java:3003)
        at com.android.server.pm.PackageManagerService.grantRuntimePermission(PackageManagerService.java:6464)
        at com.android.server.pm.PackageManagerShellCommand.runGrantRevokePermission(PackageManagerShellCommand.java:1730)
        at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:217)
        at android.os.ShellCommand.exec(ShellCommand.java:103)
        at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:26029)
        at android.os.Binder.shellCommand(Binder.java:642)
        at android.os.Binder.onTransact(Binder.java:540)
        at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:3145)
        at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:4758)
        at android.os.Binder.execTransact(Binder.java:739)

C:\Temp\ADB\platform-tools>adb devices
List of devices attached
98899a313741503945      device


C:\Temp\ADB\platform-tools>


Any help would be appreciated.
Harry

jmjc...@gmail.com

unread,
Jul 14, 2021, 5:01:48 AM7/14/21
to Tasker
"set_volume_key_long_press_listener"  should be in uppcase.

Harry

unread,
Jul 14, 2021, 9:39:01 AM7/14/21
to Tasker
Thank you, that did work as shown from the cmd prompt. Also, a profile using Volume Long Press Volume Up event works now:
C:\Temp\ADBplatform-tools>adb shell pm grant net.dinglisch.android.taskerm android.permission.SET_VOLUME_KEY_LONG_PRESS_LISTENER

C:\Temp\ADBplatform-tools>

but so did WRITE_SECURE_SETTINGS as shown from the cmd prompt:
C:\Temp\ADBplatform-tools>adb shell pm grant net.dinglisch.android.taskerm android.permission.WRITE_SECURE_SETTINGS

C:\Temp\ADBplatform-tools>

When I try and use AutoTools Secure Settings I get the following error:

09.18.19/E FIRE PLUGIN: AutoTools Secure Settings / com.twofortyfouram.locale.intent.action.FIRE_SETTING: 6 bundle keys
09.18.19/E AutoTools Secure Settings: plugin comp: com.joaomgcd.autotools/com.joaomgcd.autotools.broadcastreceiver.IntentServiceFire
09.18.19/E add wait type Plugin2 time 60
09.18.19/E add wait type Plugin2 done
09.18.19/E handlePluginFinish: taskExeID: 2 result 3
09.18.19/E pending result code
09.18.19/E add wait task
09.18.19/E Error: 233554760
09.18.19/E No permission to change setting. Touch here or check the (i) button on the top right when configuring this action to check how to grant permissions so that AutoTools can change it

The new phone is an S8+ same as the previous phone and is at the same Android version. I'm stumped.

jmjc...@gmail.com

unread,
Jul 14, 2021, 11:01:26 PM7/14/21
to Tasker
AutoTools is a separate app, therefore you will need to repeat the command for AutoTools:

adb shell pm grant com.joaomgcd.autotools android.permission.WRITE_SECURE_SETTINGS

Harry

unread,
Jul 15, 2021, 9:52:48 AM7/15/21
to Tasker
Thank you that did it.
Reply all
Reply to author
Forward
0 new messages