Skip to content
OmegaplexxPublic

About

A Tasker project that automatically switches AdGuard proxy settings, allowing it to be integrated with various VPN clients for Android

Resources

Stars

15 stars

Watchers

1 watching

Forks

Latest commit

 

History

13 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 

Repository files navigation

1000130680

AutoGuard

A Tasker project that automates AdGuard for Android to bring together VPN and ad blocking on non-rooted devices.

The issue

If you're using AdGuard in Local VPN mode, you cannot use any other VPN apps at the same time.

You may say, "But AdGuard VPN can work with it."

Sure, it works with AdGuard in Integrated mode, but what if you use Hiddify/NekoBox/Shadowsocks/other client? AutoGuard acts as an artificial Integrated mode for these apps.

How AdGuard and AdGuard VPN integration works

When you enable both apps, AdGuard VPN automatically switches to Proxy only mode and sends its proxy details (type and port) to AdGuard. AdGuard receives this information and configures filtering through that proxy. The traffic flow looks like this:

Device → AdGuard → proxy → AdGuard VPN → Internet

When you turn off AdGuard VPN, it notifies AdGuard again, and AdGuard removes the proxy from the chain:

Device → AdGuard → Internet

The proxy between the two apps is the glue. One app launches it to receive traffic, while the other forwards the filtered traffic to it.

How AutoGuard works

AutoGuard is an advanced Integration Mode. It sends signals to AdGuard when you start or stop a connection in your VPN app.

  1. Switch your VPN client to Proxy only mode
  2. Enter its proxy details (type and port) in AutoGuard

Now, when you enable your VPN app, the proxy launches inside it. AutoGuard detects this and sends a signal to AdGuard so it can reconfigure filtering through that proxy.

When VPN is on → proxy in your app is running → AutoGuard sends an intent to AdGuard → AdGuard configures filtering like below

Device → AdGuard → proxy → your VPN app → Internet

When VPN is off → proxy is stopped → AutoGuard sends an intent → AdGuard configures filtering

Device → AdGuard → Internet

How to use

  1. Import AutoGuard to Tasker
  2. Give it permission to work in background
  3. Add Tasker and your VPN app to AdGuard's filtering exclusions
  4. Enter the AdGuard automation password
  5. Enter your VPN app's proxy server type and port

Password

Open AdGuard, go to Settings → General → Advanced → Automation. Copy the password and paste into AutoGuard.

Screenshots 1000118731 1000118735 1000118736 1000118739 1000118743 The password can simply be 1234. It doesn't have to be that long.

Type and port

Switch your VPN client to the proxy only mode, then enter its inbound local proxy type and port into AutoGuard.

Shadowsocks-based clients
For Shadowsocks, SagerNet, Matsuri, NekoBox, husi, Exclave etc.

Exclave as an example.

Open sidebar, go to Settings. Set Service mode to Proxy only.

1000118844

Scroll down, check your SOCKS5 port. You can also enable HTTP server if you want.

1000118849

Enter it into AutoGuard. You can enter HTTP server port if you enabled it.

1000118859

v2rayNG
Open sidebar, go to Settings, scroll down. Remember the value in Local proxy port.

1000129802

In Mode select Proxy only. 1000129803

Enter the port to AutoGuard, set any type you want. 1000129805

Hiddify
Open Settings → Inbound. In Service mode select Proxy service only and remember the value in Mixed port.

1000131269

Enter it to AutoGuard. Choose any type you want. 1000130792

Karing
Open Settings, disable Novice Mode. Scroll down, select TUN and disable it.

1000130827 1000130828 1000130829

Return to Settings, select Port. 1000130832

Enter to AutoGuard the Rule Based one or the Proxy All port. 1000130834

Choose any type. 1000130837

WG Tunnel
In Settings, set App mode to Proxy.

1000129843

Tap on App mode, enable SOCKS5 and/or HTTP proxy type(s). Enter 127.0.0.1: and any port you want.

1000129844

Enter type and port to AutoGuard.

1000129846

InviZible Pro
AdGuard can be integrated with Tor.

On the main screen, in the three-dots dropdown menu select Proxy Mode.

1000129834

Open sidebar, go to Tor Settings. Scroll down to the proxy options. Enable SOCKS or/and HTTP type(s). 1000129833

Tap on SOCKS Port or HTTP Tunnel Port to see it. 1000129832

Enter it into AutoGuard. 1000130700

ByeByeDPI
Go to Settings, set Mode to Proxy.

1000130809

Check the value in Port. Enable HTTP proxy if you want. 1000130810

Enter the port to AutoGuard and select SOCKS5/SOCKS4 as server type. You can select HTTP if you enabled it. 1000130819

Clash Meta for Android Alpha
Open Settings → Network, disable Route System Traffic.

1000131239 Go to Settings → Override, choose any HTTP Port and Socks Port you want. 1000131240 Enter it to AutoGuard. Both SOCKS5/4 types are good for Socks Port. 1000131259

Orbot
AdGuard + Tor

Start connection to see SOCKS5/HTTP ports.

1000131207

Go to More tab. Remember one of the port values, then go to Orbot Settings → General 1000131211

Enable Power User Mode. It's equivalent to Proxy Only Mode. 1000131218

Enter one of the port values to AutoGuard and select the appropriate type. 1000131225

AdGuard v3.x support (Legacy)

AutoGuard can work with old AdGuard versions (v3.6.11 and below). Enable Legacy mode in AutoGuard's Advanced Settings.

Screenshots

1000118721 1000118722 1000118723

About

A Tasker project that automatically switches AdGuard proxy settings, allowing it to be integrated with various VPN clients for Android

Resources

Stars

15 stars

Watchers

1 watching

Forks

Releases

Contributors