When I try to open a pdf from with a Pixel 7 pro from the Files app, Fenix returns a 404. But it works when I try to open a pdf from Chrome. I added some logging in: https://searchfox.org/mozilla-central/source/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/ContentInputStream.java#115-132 and when the pdf is provided by Files (`content://com.google.android.apps.nbu.files.provider...`), `isExported` return `false`, when it returns `true` when opened from Chrome (`content://media/external/downloads/...`). Checking if the provider is exported is one of the mitigations proposed here: https://developer.android.com/privacy-and-security/risks/content-resolver#mitigations_2 After reading this again and again, I can see that there is a "OR" between each possibility. So here we want to be sure that the user granted the provider and consequently we don't need to check if it's exported. :olivia, wdyt ?
Bug 1868382 Comment 0 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
When I try to open a pdf with a Pixel 7 pro from the Files app, Fenix returns a 404. But it works when I try to open a pdf from Chrome. I added some logging in: https://searchfox.org/mozilla-central/source/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/ContentInputStream.java#115-132 and when the pdf is provided by Files (`content://com.google.android.apps.nbu.files.provider...`), `isExported` return `false`, when it returns `true` when opened from Chrome (`content://media/external/downloads/...`). Checking if the provider is exported is one of the mitigations proposed here: https://developer.android.com/privacy-and-security/risks/content-resolver#mitigations_2 After reading this again and again, I can see that there is a "OR" between each possibility. So here we want to be sure that the user granted the provider and consequently we don't need to check if it's exported. :olivia, wdyt ?
When I try to open a pdf with a Pixel 7 pro from the Files app, Fenix returns a 404. But it works when I try to open a pdf from Chrome. I added some logging in: https://searchfox.org/mozilla-central/source/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/ContentInputStream.java#115-132 and when the pdf is provided by Files (`content://com.google.android.apps.nbu.files.provider...`), `isExported` returns `false`, when it returns `true` when opened from Chrome (`content://media/external/downloads/...`). Checking if the provider is exported is one of the mitigations proposed here: https://developer.android.com/privacy-and-security/risks/content-resolver#mitigations_2 After reading this again and again, I can see that there is a "OR" between each possibility. So here we want to be sure that the user granted the provider and consequently we don't need to check if it's exported. :olivia, wdyt ?