AdguardForAndroid icon indicating copy to clipboard operation
AdguardForAndroid copied to clipboard

Forwarding vpn traffic to downstream proxy will cause the connection to be interrupted

Open xxxsen opened this issue 3 years ago • 9 comments

Prerequisites

Please answer the following questions for yourself before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.

  • [x] I am running the latest version
  • [x] I checked the documentation and found no answer
  • [x] I checked to make sure that this issue has not already been filed

Issue Details

Adguard config with socks proxy will cause frequent connection drops, especially in game app.

  • AdGuard version:
    • 3.6.4(32)
  • Filtering mode:
    • local vpn with a socks proxy as outbound
  • Device:
    • OnePlus 7p
  • Operating system and version:
    • android 11(lineage 18.1)
  • Root access:
    • no

Expected Behavior

connections won't be droped unexpectedly

Actual Behavior

connections drop frequently

Screenshots

Additional Information

this problem can be reproduced even after removing all filter rules. only represent when use a socks proxy. and it was not cause by socks proxy server(I test it with more than one proxy)

step to reproduce

  1. install connectbot (android ssh tool)
  2. setup adguard with socks proxy outbound
  3. enable Adguard protection on connectbot(enable ad blocking only and don't enable https filter)
  4. open connectbot and connect to you ssh server
  5. when the password input box pops up, do not enter the password immediately but enter it slowly. After a few seconds, the connection will be disconnected

xxxsen avatar Oct 26 '21 15:10 xxxsen

image

this screenshot shows connection was closed by adguardforandroid ip end with 113 is my android phone. ip end with 187 is my socks5 proxy hosted by xray.

in the pic, adguard sent FIN packet cause whole connection closed

xxxsen avatar Oct 26 '21 15:10 xxxsen

@xxxsen Hello! Did we understand your configuration correctly: you had connected to some remote server via AdGuard and tried to monitor the behavior via connectbot ? Could you try it with AdGuard VPN and send us the debug logs so we could see the traffic?

Here's how you can do it:

  1. Collect the debug log as it's explained here;
  2. Remember the exact time when the issue was reproduced. We will need it to find the corresponding records in the log file;
  3. Send it to [email protected]. Mention the Github issue number and the exact time when the issue was reproduced.

Birbber avatar Oct 28 '21 08:10 Birbber

@xxxsen Do you use Connectbot as the outbound proxy for Adguard, or it is just an example?

sfionov avatar Oct 28 '21 08:10 sfionov

no, outbound proxy is xray hosted on another machine, and traffic of connectbot was route by adguard

traffic of connectbot->adguard->xray svr(socks proxy)->remote svr

@Birbber @sfionov I already sent my log to [email protected] at Oct 27, 2021, 12:11 AM

Sergey Fionov @.***> 于2021年10月28日周四 下午4:50写道:

@xxxsen https://github.com/xxxsen Do you use Connectbot as the outbound proxy for Adguard, or it is just an example?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/AdguardTeam/AdguardForAndroid/issues/4005#issuecomment-953642530, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA5TKVCZANWQJ3U3WPAP7O3UJEFGNANCNFSM5GYECOLA .

xxxsen avatar Oct 28 '21 08:10 xxxsen

@xxxsen We've identified the issue, will be fixed with the next release.

Birbber avatar Oct 29 '21 13:10 Birbber

@Birbber ok, thank you for your reply

xxxsen avatar Oct 29 '21 13:10 xxxsen

still not fixed in ver. 3.67 Premium. any update?

Oddly enough, changing Adguard DNS from upstream SOCKS5 DNS to public DNS solved this issue temporarily.

kdurov avatar Apr 05 '22 01:04 kdurov

A tentative solution is scheduled for version 4.0.

Stay tuned :)

Chinaski1 avatar Apr 12 '22 11:04 Chinaski1

and when is that happening? It's a critical bug. An urgent fix is required :(

kdurov avatar Apr 15 '22 00:04 kdurov