2

I try to capture requests on an Android application and it works very well for the HTTP/HTTPS protocol but it seems that the proxy defined in the wifi settings is not taken into account for requests other than HTTP (TCP, UDP, WSS).The MITM Proxy certificate is also in trusted authority at root level.

I didn't find anyone talking about this problem while searching (maybe I'm wrong), if someone would have a solution to propose me to capture these protocols, I'm interested.

I specify that this test phone has a root access which should open some possibilities.

Thanks to all

  • WSS should work as the connection is started as HTTP connection but raw TCP and UDP require a socks proxy (and mitm is a HTTP proxy). Furthermore as far as I know Android does not support to use socks proxies. – Robert Oct 27 '21 at 10:32
  • WSS and TCP/UDP are supported by MITMProxy, when i use it for sniffing on Windows it work without any problem. It just on Android the proxy is ignored for requests that are not HTTP. And actually the problem append on WSS, because even if it's like HTTP for the start of the requests, the proxy is also ignored – 0x0000000000000 Oct 27 '21 at 11:03
  • 1
    Then Windows uses Mitmproxy as socks proxy. You need to configure Android to use you Mitmproxy as socks proxy, https://android.stackexchange.com/q/208696/2241 luckily you have a rooted device as without you can't use socks proxy. – Robert Oct 27 '21 at 11:09
  • Thanks for this, i will take a look at this. – 0x0000000000000 Oct 27 '21 at 11:17
  • 1
    Take it from the horse's mouth: We currently do support HTTP, HTTPS, WS, WSS, and generic TCP forwarding (even in HTTP proxy mode via `CONNECT` requests). For now we don't support any UDP (yet). – Maximilian Hils Oct 28 '21 at 07:26
  • Actually as said 3x time, the problem don't come from MITM itself but because TCP connections ignores the wifi proxy settings on Android. – 0x0000000000000 Oct 29 '21 at 15:43

0 Answers0