httptoolkit / httptoolkit-android

Automatic Android interception & debugging with HTTP Toolkit, for Android
https://httptoolkit.com
GNU Affero General Public License v3.0
476 stars 72 forks source link

Network is not seen as Wi-Fi by many applications when I have HTTP Toolkit interception enabled #24

Closed SomeGuyCalledBru closed 4 months ago

SomeGuyCalledBru commented 4 months ago

Device: Redmi Note 8, Android 11 rooted with Magisk 27.0, on latest HTTP Toolkit Windows/Android. I have the HTTP Toolkit CA on my system store

I am facing an odd issue(not really an issue, a behavior, let's say) with HTTP Toolkit. Whenever I include an app into interception, it reads my network type as something other than WiFi, even when I am connected to WiFi. I can't observe this behavior on other interception apps like PCAPdroid(I also have its CA on my system store, if it is possibly related to that), or other VPNs such as Proton VPN. When I exclude an app from the interception, the issue is gone. I observe this behavior on all Xiaomi and Google apps, Google Photos for example won't back up automatically as it thinks I am not on WiFi, Android warns me about downloading an OTA update because it thinks I am on mobile data, and YouTube warns me about downloading a video because it also thinks I am not on a wireless network.

When I query the connectivity service via ADB shell dumpsys, the active connection ID is indicated as WiFi.

Sorry if this is expected behavior under Android APIs/HTTP Toolkit, I just thought I'd make sure.

pimterry commented 4 months ago

Ah, this makes sense! That's very interesting, I think there's a non-metered flag that we might not be setting that could cause this. I'll do some testing but I think this should be an easy fix, watch this space.

pimterry commented 4 months ago

Now fixed and released in the latest Android version (v1.3.12). You can download the latest APK from https://github.com/httptoolkit/httptoolkit-android/releases or it'll be available via Google Play within 24 hours (once their review is completed).

SomeGuyCalledBru commented 4 months ago

Thank you! I'll test it out when I can.

Edit; it's working as expected right now.