So, I’m having a look over different applications and there is one content provider I’m struggling a bit with:
Usually, content providers - at least the ones I know - have an authority defined like so:
<provider android:authorities="com.example.app1.contentprovider1"
...
android:exported=true
android:name="com.example.app1.contentprovidername1"
Furthermore, one can query the content like so:
content query --uri "com.example.app1.contentprovider1/item"
However, this odd content provider I’m talking about, does not rely on overwriting Android’s query
method, but rather overwrites openFile
, which returns a ParcelFileDescriptor
.
I have seen a similar app, where it was possible to read the etc/hosts
file, because it requested the appropriate permissions. So, the reading of files is definitely possible.
However, I do not know how to read files on behalf of this application, nor where I could read up on that topic. Does someone have any suggestions?