google / bundletool

Bundletool is a command-line tool to manipulate Android App Bundles
https://g.co/androidappbundle
Apache License 2.0
3.52k stars 385 forks source link

SplitCompat doesn't have executable permissions for extracted native libs #267

Closed eakteam closed 2 years ago

eakteam commented 2 years ago

Regarding to that bug report : https://github.com/google/bundletool/issues/155 , SplitCompat native libs directory should allow executing native libs from the directory where they are extracted.

In normal circumstances if the Dynamic Feature Module is configured as install-time we are able to execute native libs using : context.getApplicationInfo().nativeLibraryDir, "libexampleexec.so", but if it is configured as on-demand and trying to execute native libs from that directory : context.filesDir.path + File.separator + "splitcompat" + File.separator + MainApplication.versionCode + File.separator + "native-libraries" it fails with access denied.

Why it doesn't have such permissions ?

ymakhno commented 2 years ago

This issue doesn't relate to bundletool.

I believe you can not execute any binary inside /data/data/... folder since Android Q as this is Android security constraint. In #155 question was: Is splitcompat dir has exec permissions?, directory itself has such permission, files inside can not have it.