Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Route traffic for com.android.providers.downloads #3355

Closed
3 tasks done
BurgerTown opened this issue Feb 21, 2020 · 4 comments
Closed
3 tasks done

Route traffic for com.android.providers.downloads #3355

BurgerTown opened this issue Feb 21, 2020 · 4 comments

Comments

@BurgerTown
Copy link

Prerequisites

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

Problem Description

AdGuard can't route com.android.providers.downloads traffic so I can't Install apps from Google Play because I have to use proxy to connect to GP.

@artemiv4nov
Copy link
Contributor

Well, I think it's time to publish here the April 2020 Research results on this problem.

Prehistory

A long time ago, we added the Download Manager application to the app exclusions list because the filtering of this application broke a downloading of applications through Download Manager.

Question: Why did this task appear?

Answer:

Once users created a task about the broken Play Store. We successfully found the solution for the task and also remove a few applications from the app exclusions list (including Download Manager). The Download Manager removing from the app exclusions list provoked the complaints growth about "applications from Play Store didn't download", "Telegram updates can't be downloaded", etc.
So, we are back where we started: a lot of apps on Android could not use Download Manager to download data because filtering of this application broke a downloading of applications through Download Manager.

Question: Why did you need to remove the 1000 UID from the app exclusions list?

Answer:

There are a few locations on Earth where a user cannot use Google Play services because government providers block any connections to forbidden services. So, the user should use AdGuard with turned on the mode of Proxy and a Proxy server with access to forbidden services together. In this case, it is very important to filter anything data to tunnel them to the proxy server. Earlier, we also excluded from filtering all applications with 1000 and 1001 UIDs. These are system applications (Google play services, for example), so, we intently didn't filter them. Also, there was another reason why we did not filter them. So, we found an empirical solution with @mmyz1234 that I published in the #3280 task.

Question: Why exactly did you remove Download Manager from the app exclusions list?

Answer:

At that moment, we thought Google already fixed old Download Manager bugs. Thus, we removed com.android.providers.downloads and com.android.providers.downloads.ui package names from the app exclusions list. Well, we were wrong, Google didn't fix it or it fixed and added new bugs at the same time. Anyway, complaints appeared about Download Manager didn't work correctly.

Question: What Download Manager bugs do you mean?

Answer:

In short, Download Manager could not download data during active VPN. There are at least two issues on the Google Bug tracker about broken Download Manager: the first one, the second one. The most interesting comment is this one, with a mention of a specific commit. Also, I found two issues from other applications: Blokada and Kiwix. I've also analyzed a few Android Bug reports in full version and found several log-messages from Download Manager like "I can't bind the socket to this network (Wi-Fi), sorry". It feels like Download Manager tried to bind socket bypassing active VPN. Obviously, it cannot be worked if the active VPN doesn't support bypassing.
So, we were forced to return back the two package names to the app exclusions list (com.android.providers.downloads and com.android.providers.downloads.ui). Technically, the com.android.providers.downloads.ui package filtering breaks the Download Manager but we added both packages to get the best effect.

@TPS
Copy link
Contributor

TPS commented Aug 21, 2021

Was anything changed in this in v4.0n23? I have the strange problem that GPlay Store updates current apps fine in n22, but can't in n23. However, it installs new apps just fine in both.

@ameshkov
Copy link
Member

Nope, I don't think anything changed, the task is quite old.

@TPS
Copy link
Contributor

TPS commented Aug 23, 2021

I must've had something transient happening, then. It resolved overnight.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants