Bug #1076
openMHT files open blank until refreshed
0%
Description
When I tap on a MHT file (with .mht
extension), which I previously saved with Privacy Browser, in Android's default "Files" app (also called "DocumentsUI", com.android.documentsui
), it doesn't give me the possibility to open the file with Privacy Browser.
I saw in the app's configuration that it should work with .mht
extensions, but don't know why it doesn't, and if this is specific to my device for this app.
I installed jQuarks viewer to test on it, and it works.
Files
Updated by Soren Stoutner over 1 year ago
- File Open .mht files.png Open .mht files.png added
- Status changed from New to Closed
The answer to your question can be found in the changelog at https://www.stoutner.com/privacy-browser-3-8/.
Basically, Google broke this for any app targeting API >= 30. jQuarks targets API 29, so it is unaffected.
There is some upstream discussion with Google at the following two issues, but I don't expect them to rectify the situation anytime soon.
https://issuetracker.google.com/issues/183687627
https://issuetracker.google.com/issues/183677221
In the meantime, you can open .mht files using the open command from the Navigation Menu.
Updated by v ... over 1 year ago
- Subject changed from Unable to open MHT files to Unable to open MHT files via DocumentsUI
- Description updated (diff)
Updated by v ... over 1 year ago
Thanks. Don't know why, I didn't see the "Open" command.
However, have you experienced the following?
- Open the "Navigation menu" ;
- Tap on "Open"
- Check "The file is an MHT web archive" (otherwise PB is asking to save the file) ;
- Tap on "BROWSE" ;
- Choose an
.mht
file ; - Tap on "OPEN" ;
- An empty page is displayed (URL seems OK, e.g. file:///data/user/0/com.stoutner.privacybrowser.standard/cache/temporary_mht_file8411118225466051011.mht) ;
- Tap on the URL bar ;
- Tap Enter on the (virtual) keyboard ;
- The content of the selected MHT file is now displayed.
Should I rise a separate issue for that?
Updated by Soren Stoutner over 1 year ago
- Subject changed from Unable to open MHT files via DocumentsUI to MHT files open blank until refreshed
- Status changed from Closed to Feedback
We can just repurpose this bug report.
I have not observed that behavior before. Does that happen every time or only sometimes?
Updated by v ... over 1 year ago
That's the first time I'm trying to open MHT files, so I don't know if this is a new behaviour/bug.
Yes, that happens every time. Refreshing via the "Refresh" button doesn't work, I have to tap on the URL bar and then tap on Enter.
Updated by Soren Stoutner over 1 year ago
Do you have access to more than one Android device for testing?
Updated by ask low over 1 year ago
I can confirm. Just tested this by saving this issue page as archive, & went through steps in #note-3
Updated by Soren Stoutner over 1 year ago
Can you please attach a screen recording demonstrating the problem and a copy of About > Version? I have so far been unable to replicate it (tested on both a Pixel 5 and a Samsung Galaxy Tab A7).
Updated by ask low over 1 year ago
https://gitlab.com/gitlab-org/gitlab/uploads/a68915359a6b3573d2f504d1652e31cc/offline-page-issue.mp4
Privacy Browser
Version 3.15.1 (version code 71)
Hardware
Brand: Google
Manufacturer: Google
Model: Pixel 7 Pro
Device: cheetah
Bootloader: r3-0.5-9473955
Radio: MPSS.AT.4.4.c6-00062-3,MPSS.AT.4.4.c6-00062-3
Software
Android: 13 (API 33)
Security Patch: 2023-05-05
Build: TQ2A.230505.002
Kernel: 4.14.303-EAS
WebView Provider: org.bromite.webview
WebView Version: 108.0.5359.156
Memory Usage
App Consumed Memory: 20.37 MiB
App Available Memory: 19.52 MiB
App Total Memory: 39.89 MiB
App Maximum Memory: 512.00 MiB
System Consumed Memory: 3,442.08 MiB
System Available Memory: 2,132.83 MiB
System Total Memory: 5,574.91 MiB
Filter Lists
EasyList: 202306072303
EasyPrivacy: 202306072159
Fanboy’s Annoyance List: 202306072220
Fanboy’s Social Blocking List: 202306072159
UltraList: 1
UltraPrivacy: 3
Package Signature
Issuer DN: CN=FDroid, OU=FDroid, O=fdroid.org, L=ORG, ST=ORG, C=UK
Subject DN: CN=FDroid, OU=FDroid, O=fdroid.org, L=ORG, ST=ORG, C=UK
Start Date: Apr 17, 2016 1:44:13 PM GMT+05:30
End Date: Sep 3, 2043 1:44:13 PM GMT+05:30
Certificate Version: 3
Serial Number: 166629308
Signature Algorithm: SHA256withRSA
Updated by ask low over 1 year ago
I think this is some sort file access inability issue. I think you gotta look into open feature code whether if any function is not able to respond to the open dialog after you selected the file from the file picker.
Updated by Soren Stoutner over 1 year ago
Can you test with a modern, standard WebView? It is possible that 108 had some bug in relation to this issue, and it is also possible that Bromite made some change that affects this.
Updated by ask low over 1 year ago
I'm currently on a metered network, so can't install or download anything heavy.
But I'm sure this hasn't to do anything with bromite webview, although it could be older webview version issue whether it's bromite or google.
@v ... can you confirm whether you have older webview version. If not, then it could be something else.
Updated by v ... over 1 year ago
I have the exact same version of Bromite (declared as the Android WebView package).
WebView Provider: com.android.webview
WebView Version: 108.0.5359.156
As @ask low wrote, maybe it's because of the old version. Or because of some changes made by Bromite.
Updated by ask low over 1 year ago
I've just tried changing to a latest webview (v117).
Just to let you know that changing it even temporarily, you'll loose all of your logins & cookie sessions from all of your user installed apps like browsers, as well as webview based mail clients like tutanota, etc. I've literally logged back in again, which was very tiring tbh.
The situation's the same. It's not webview issue at all, as I said. Something problematic with pb itself.
Updated by Soren Stoutner over 1 year ago
What do you think is causing the problem? I can't replicate it on any of the devices I have tried.
Updated by Soren Stoutner over 1 year ago
Whenever you have a situation where a bug manifests on some devices and not others, it is often impossible to fix until you can determine why it manifests on some devices and not others. There must be some underlying difference between the devices that causes the difference in behavior.
So far, we have eliminated differences in WebView. Looking at the information you posted above, one other difference is that you are using a fairly outdated security update of 2023-05-05. On a Pixel 7 Pro I would expect this to be 2023-08-05. Another difference is that the Pixel 7 Pro uses Google's Tensor processor. Both of my test devices use Qualcomm Snapdragon processors. I would be interesting to see a full About > Version from @v ..., as that might help narrow down the differences between devices that work and devices that don't.
Updated by Soren Stoutner over 1 year ago
ask low wrote in #note-10:
System Total Memory: 5,574.91 MiB
@ask low Your post above says that you are using a Pixel 7 Pro, but this is the wrong amount of system memory for that device (the Pixel 7 Pro has 12 GB of RAM). There are also several other entries that are different than what what I would expect from a Pixel 7 Pro. Are you running some sort of custom ROM that is misrepresenting the hardware?
FYI, since the last time I have posted I have tested both a Pixel 6a and a Pixel 7 (non pro) without being able to replicate this problem. I have also tested production builds from F-Droid and www.stoutner.com as well as debug builds from Android Studio. I also did some testing in an emulator. Whatever the root cause of the problem, it does not appear to be something that manifests on the majority of devices.
Updated by v ... over 1 year ago
Soren Stoutner wrote in #note-17:
[...]
Both of my test devices use Qualcomm Snapdragon processors. I would be interesting to see a full About > Version from @v ..., as that might help narrow down the differences between devices that work and devices that don't.
Here you are, see attached image. My device's processor is based on Qualcomm Snapdragon.
Updated by Soren Stoutner over 1 year ago
@v ..., are you able to test with a current WebView? @ask low tried a copy of 117, which is currently the beta release. That shouldn't make a difference, but I would recommend you go with a stable 116 release.
https://apkpure.com/android-system-webview/com.google.android.webview
Updated by ask low over 1 year ago
Yes. I run custom AOSP (ph husson's GSI to be precise). I spoof my device so that no one knows what device I have (kind of privatizing my device). And based on @v ... 's version info, I would say fairphone runs Lineage OS bydefault (which is a customized AOSP fork too). I'm skeptical whether this could be filepicker issue on these custom systems.
@Soren Stoutner Are you on stock pixel setup btw ? It could be worth testing this by virtually booting into any AOSP GSI whether this happens on it.
Updated by Soren Stoutner over 1 year ago
Yes, I am on a stock ROM. Also, all of the devices I have tested are on stock ROMs.
I don't think spoofing your device provides any real security. And, if you are spoofing things to the degree that the system is reporting an incorrect amount of system memory, I would be concerned that making that level of modifications to AOSP would more likely be the cause of this type of problem than anything in Privacy Browser itself.
Ultimately, there is not much I can do at Privacy Browser's level to work around devices running broken versions of Android.
Updated by ask low over 1 year ago
This is a very low priority issue. Hitting enter in the url fixes the offline page anyways.
I meant privacy, not security. Spoofing fixes some of the fingerprinting issues arise through some online services. I have a service daemon where the specs change/randomize on every reboot I do. (important for me caz I'm a govt employee).