-
Notifications
You must be signed in to change notification settings - Fork 291
Add configure outbound proxy #753
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -115,3 +115,79 @@ If the listen address is set to anything other than `127.0.0.1`, then proxy clie | |||||||||
|
||||||||||
- When running `adguard-cli config set listen_address <address>` where `<address>` is not `127.0.0.1`, AdGuard CLI will prompt for a username and password if proxy authentication is not already configured. | ||||||||||
- When editing the config file directly, look for the `listen_auth`key. Set the `enabled` sub-key to `true`, and `username` and `password` to non-empty values. | ||||||||||
|
||||||||||
## Configure outbound proxy | ||||||||||
|
||||||||||
You can configure `outbound_proxy` if you want AdGuard CLI to work through another proxy server. | ||||||||||
|
||||||||||
There are two ways to configure it: | ||||||||||
|
||||||||||
### 1. Configure via URL (recommended) | ||||||||||
|
||||||||||
Instead of setting each option step by step, you can set all parameters in a single line using a URL: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy https://user:pass@host:port | ||||||||||
``` | ||||||||||
|
||||||||||
:::info | ||||||||||
|
||||||||||
Supported modes are HTTP, HTTPS, SOCKS4, SOCKS5. | ||||||||||
|
||||||||||
::: | ||||||||||
|
||||||||||
You can also quickly enable or disable `outbound_proxy`: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy false | ||||||||||
``` | ||||||||||
|
||||||||||
Or quickly clear the settings: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy "" | ||||||||||
``` | ||||||||||
|
||||||||||
### 2. Configure individual parameters | ||||||||||
|
||||||||||
The ability to adjust specific parameters is also available: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy.enabled true | ||||||||||
adguard-cli config set outbound_proxy.host localhost | ||||||||||
adguard-cli config set outbound_proxy.port 3128 | ||||||||||
adguard-cli config set outbound_proxy.username user | ||||||||||
adguard-cli config set outbound_proxy.password pass | ||||||||||
``` | ||||||||||
|
||||||||||
Disable certificate verification for HTTPS proxies: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy.trust_any_certificate true | ||||||||||
``` | ||||||||||
|
||||||||||
Enable SOCKS5 proxy for UDP traffic: | ||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config set outbound_proxy.udp_through_socks5_enabled true | ||||||||||
``` | ||||||||||
|
||||||||||
:::info NOTE | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
|
||||||||||
If your SOCKS5 proxy does not support UDP, connections may fail. | ||||||||||
|
||||||||||
::: | ||||||||||
|
||||||||||
### Checking the current configuration | ||||||||||
|
||||||||||
To view the current outbound_proxy configuration, enter: | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. или
Suggested change
|
||||||||||
|
||||||||||
```sh | ||||||||||
adguard-cli config show outbound_proxy | ||||||||||
``` | ||||||||||
|
||||||||||
:::info Compatibility | ||||||||||
|
||||||||||
Configuring outbound_proxy via URL is available starting from version 1.1.26 nightly and stable release 1.1. | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
|
||||||||||
::: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.