Skip to content
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

Can not grant android.permission.WRITE_EXTERNAL_STORAGE to org.mozilla.fenix #2304

Closed
TheGameratorT opened this issue Aug 22, 2021 · 3 comments · Fixed by #2306
Closed

Can not grant android.permission.WRITE_EXTERNAL_STORAGE to org.mozilla.fenix #2304

TheGameratorT opened this issue Aug 22, 2021 · 3 comments · Fixed by #2306

Comments

@TheGameratorT
Copy link

Is this a feature request or a bug?

Bug

What is the current behavior?

Can't test my extensions on Firefox for Android because it's package doesn't ask for android.permission.WRITE_EXTERNAL_STORAGE.

D:\MyUser\Dev\Vs\PrivateCookies>web-ext run -t firefox-android --adb-device ifjbnnvsmv7hbqwg --firefox-apk org.mozilla.fenix
Running web extension from D:\MyUser\Dev\Vs\PrivateCookies
Selected ADB device: ifjbnnvsmv7hbqwg

s: Required android.permission.WRITE_EXTERNAL_STORAGE has not be granted for org.mozilla.fenix. Please grant them using the Android Settings or using the following adb command:
         adb shell pm grant org.mozilla.fenix android.permission.WRITE_EXTERNAL_STORAGE



D:\MyUser\Dev\Vs\PrivateCookies>adb shell pm grant org.mozilla.fenix android.permission.WRITE_EXTERNAL_STORAGE

Exception occurred while executing 'grant':
java.lang.SecurityException: Package org.mozilla.fenix has not requested permission android.permission.WRITE_EXTERNAL_STORAGE
        at com.android.server.pm.permission.BasePermission.enforceDeclaredUsedAndRuntimeOrDevelopment(BasePermission.java:446)
        at com.android.server.pm.permission.PermissionManagerService.grantRuntimePermissionInternal(PermissionManagerService.java:1491)
        at com.android.server.pm.permission.PermissionManagerService.grantRuntimePermission(PermissionManagerService.java:1444)
        at com.android.server.pm.PackageManagerShellCommand.runGrantRevokePermission(PackageManagerShellCommand.java:2300)
        at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:251)
        at android.os.BasicShellCommandHandler.exec(BasicShellCommandHandler.java:98)
        at android.os.ShellCommand.exec(ShellCommand.java:44)
        at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:22202)
        at android.os.Binder.shellCommand(Binder.java:929)
        at android.os.Binder.onTransact(Binder.java:813)
        at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:4687)
        at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:4449)
        at android.os.Binder.execTransactInternal(Binder.java:1159)
        at android.os.Binder.execTransact(Binder.java:1123)

What is the expected or desired behavior?

The extension should be temporarily loaded in Firefox for Android.

Version information (for bug reports)

  • Firefox version: Nightly 93.0a1
  • OS and version: Android 11 RP1A.200720.011 (MIUI 12.5.2.0 RGGEUXM)
node version: v14.17.0
npm version: 6.14.13
web-ext version: 6.3.0
@m-khvoinitsky
Copy link

m-khvoinitsky commented Aug 24, 2021

Same here.

  • Firefox Nightly 93.0a1
  • Galaxy Tab S7+ with Android 11

It doesn't looks like web-ext issue but Nightly's packaging.

@jduelfer
Copy link

I opened the above issue in the Fenix repo. Experiencing the same on Galaxy A72 with Android 11.

@jduelfer
Copy link

jduelfer commented Sep 10, 2021

Installation from source working great until this gets pushed in a new npm version. Thanks for tackling this! Got my add-on running nicely on my Galaxy A72 with Android 11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants