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

Update wireguard.md reserved domainStrategy Explanation [ENG] #429

Merged
merged 1 commit into from
Dec 24, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions docs/en/config/outbounds/wireguard.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ Wireguard is a standard implementation of the Wireguard protocol.
}
],
"mtu": 1420, // optional, default 1420
"reserved": [1, 2, 3],
"workers": 2 // optional, default runtime.NumCPU()
"domainStrategy": "ForceIP" // Requires Xray-core v1.8.6 or higher
}
```

Expand All @@ -44,6 +46,12 @@ Wireguard will create a virtual network interface `tun` locally. Use one or more

The fragment size of the underlying `tun` device in Wireguard.

> `reserved` \[ number \]

Wireguard Reserved Bytes.<br>
For example, when connecting to warp via wireguard, some IPs in Hong Kong and Los Angeles need to have a reserved value in order to connect successfully due to cloudflare limitations.<br>
The value of reserved can be obtained using third-party tools such as [warp-reg](https://github.com/badafans/warp-reg)、[warp-reg.sh](https://github.com/chise0713/warp-reg.sh)

> `workers`: int

The number of threads used by Wireguard.
Expand All @@ -52,6 +60,12 @@ The number of threads used by Wireguard.

A list of Wireguard servers, where each item is a server configuration.

> `domainStrategy`: "ForceIPv6v4" | "ForceIPv6" | "ForceIPv4v6" | "ForceIPv4" | "ForceIP"

Requires Xray-core v1.8.6 or higher.<br>
The default value is `"ForceIP"` when left blank.<br>
When the incoming request is for a domain name, regardless of whether `domainStrategy` is left empty (or if `domainStrategy` is not written), use the [built-in DNS server](./dns.md) to get an IP (if the DNS part is not written in the configuration, system DNS is used), and this IP is used to send the connection via wireguard.

### Peers

```json
Expand Down
Loading