documentation: Add hysteria2

This commit is contained in:
世界 2023-09-09 13:42:38 +08:00
parent 53475c7390
commit 8cb41b5fa6
No known key found for this signature in database
GPG Key ID: CD109927C34A63C4
9 changed files with 338 additions and 0 deletions

View File

@ -0,0 +1,85 @@
### Structure
```json
{
"type": "hysteria2",
"tag": "hy2-in",
... // Listen Fields
"up_mbps": 100,
"down_mbps": 100,
"obfs": {
"type": "salamander",
"password": "cry_me_a_r1ver"
},
"users": [
{
"name": "tobyxdd",
"password": "goofy_ahh_password"
}
],
"ignore_client_bandwidth": false,
"masquerade": "",
"tls": {}
}
```
!!! warning ""
QUIC, which is required by Hysteria2 is not included by default, see [Installation](/#installation).
### Listen Fields
See [Listen Fields](/configuration/shared/listen) for details.
### Fields
#### up_mbps, down_mbps
Max bandwidth, in Mbps.
Not limited if empty.
Conflict with `ignore_client_bandwidth`.
#### obfs.type
QUIC traffic obfuscator type, only available with `salamander`.
Disabled if empty.
#### obfs.password
QUIC traffic obfuscator password.
#### users
Hysteria2 users
#### users.password
Authentication password
#### ignore_client_bandwidth
Commands the client to use the BBR flow control algorithm instead of Hysteria CC.
Conflict with `up_mbps` and `down_mbps`.
#### masquerade
HTTP3 server behavior when authentication fails.
| Scheme | Example | Description |
|--------------|-------------------------|--------------------|
| `file` | `file:///var/www` | As a file server |
| `http/https` | `http://127.0.0.1:8080` | As a reverse proxy |
A 404 page will be returned if empty.
#### tls
==Required==
TLS configuration, see [TLS](/configuration/shared/tls/#inbound).

View File

@ -0,0 +1,83 @@
### 结构
```json
{
"type": "hysteria2",
"tag": "hy2-in",
... // 监听字段
"up_mbps": 100,
"down_mbps": 100,
"obfs": {
"type": "salamander",
"password": "cry_me_a_r1ver"
},
"users": [
{
"name": "tobyxdd",
"password": "goofy_ahh_password"
}
],
"ignore_client_bandwidth": false,
"masquerade": "",
"tls": {}
}
```
!!! warning ""
默认安装不包含被 Hysteria2 依赖的 QUIC参阅 [安装](/zh/#_2)。
### 监听字段
参阅 [监听字段](/zh/configuration/shared/listen/)。
### 字段
#### up_mbps, down_mbps
支持的速率,默认不限制。
`ignore_client_bandwidth` 冲突。
#### obfs.type
QUIC 流量混淆器类型,仅可设为 `salamander`
如果为空则禁用。
#### obfs.password
QUIC 流量混淆器密码.
#### users
Hysteria 用户
#### users.password
认证密码。
#### ignore_client_bandwidth
命令客户端使用 BBR 流量控制算法而不是 Hysteria CC。
`up_mbps``down_mbps` 冲突。
#### masquerade
HTTP3 服务器认证失败时的行为。
| Scheme | 示例 | 描述 |
|--------------|-------------------------|---------|
| `file` | `file:///var/www` | 作为文件服务器 |
| `http/https` | `http://127.0.0.1:8080` | 作为反向代理 |
如果为空,则返回 404 页。
#### tls
==必填==
TLS 配置, 参阅 [TLS](/zh/configuration/shared/tls/#inbound)。

View File

@ -27,6 +27,8 @@
| `naive` | [Naive](./naive) | X | | `naive` | [Naive](./naive) | X |
| `hysteria` | [Hysteria](./hysteria) | X | | `hysteria` | [Hysteria](./hysteria) | X |
| `shadowtls` | [ShadowTLS](./shadowtls) | TCP | | `shadowtls` | [ShadowTLS](./shadowtls) | TCP |
| `tuic` | [TUIC](./tuic) | X |
| `hysteria2` | [Hysteria2](./hysteria2) | X |
| `vless` | [VLESS](./vless) | TCP | | `vless` | [VLESS](./vless) | TCP |
| `tun` | [Tun](./tun) | X | | `tun` | [Tun](./tun) | X |
| `redirect` | [Redirect](./redirect) | X | | `redirect` | [Redirect](./redirect) | X |

View File

@ -26,6 +26,10 @@
| `trojan` | [Trojan](./trojan) | TCP | | `trojan` | [Trojan](./trojan) | TCP |
| `naive` | [Naive](./naive) | X | | `naive` | [Naive](./naive) | X |
| `hysteria` | [Hysteria](./hysteria) | X | | `hysteria` | [Hysteria](./hysteria) | X |
| `shadowtls` | [ShadowTLS](./shadowtls) | TCP |
| `tuic` | [TUIC](./tuic) | X |
| `hysteria2` | [Hysteria2](./hysteria2) | X |
| `vless` | [VLESS](./vless) | TCP |
| `tun` | [Tun](./tun) | X | | `tun` | [Tun](./tun) | X |
| `redirect` | [Redirect](./redirect) | X | | `redirect` | [Redirect](./redirect) | X |
| `tproxy` | [TProxy](./tproxy) | X | | `tproxy` | [TProxy](./tproxy) | X |

View File

@ -0,0 +1,78 @@
### Structure
```json
{
"type": "hysteria2",
"tag": "hy2-out",
"server": "127.0.0.1",
"server_port": 1080,
"up_mbps": 100,
"down_mbps": 100,
"obfs": {
"type": "salamander",
"password": "cry_me_a_r1ver"
},
"password": "goofy_ahh_password",
"network": "tcp",
"tls": {},
... // Dial Fields
}
```
!!! warning ""
QUIC, which is required by Hysteria2 is not included by default, see [Installation](/#installation).
### Fields
#### server
==Required==
The server address.
#### server_port
==Required==
The server port.
#### up_mbps, down_mbps
Max bandwidth, in Mbps.
If empty, the BBR congestion control algorithm will be used instead of Hysteria CC.
#### obfs.type
QUIC traffic obfuscator type, only available with `salamander`.
Disabled if empty.
#### obfs.password
QUIC traffic obfuscator password.
#### password
Authentication password.
#### network
Enabled network
One of `tcp` `udp`.
Both is enabled by default.
#### tls
==Required==
TLS configuration, see [TLS](/configuration/shared/tls/#outbound).
### Dial Fields
See [Dial Fields](/configuration/shared/dial) for details.

View File

@ -0,0 +1,79 @@
### 结构
```json
{
"type": "hysteria2",
"tag": "hy2-out",
"server": "127.0.0.1",
"server_port": 1080,
"up_mbps": 100,
"down_mbps": 100,
"obfs": {
"type": "salamander",
"password": "cry_me_a_r1ver"
},
"password": "goofy_ahh_password",
"network": "tcp",
"tls": {},
... // 拨号字段
}
```
!!! warning ""
默认安装不包含被 Hysteria2 依赖的 QUIC参阅 [安装](/zh/#_2)。
### 字段
#### server
==必填==
服务器地址。
#### server_port
==必填==
服务器端口。
#### up_mbps, down_mbps
最大带宽。
如果为空,将使用 BBR 流量控制算法而不是 Hysteria CC。
#### obfs.type
QUIC 流量混淆器类型,仅可设为 `salamander`
如果为空则禁用。
#### obfs.password
QUIC 流量混淆器密码.
#### password
认证密码。
#### network
启用的网络协议。
`tcp``udp`
默认所有。
#### tls
==必填==
TLS 配置, 参阅 [TLS](/zh/configuration/shared/tls/#outbound)。
### 拨号字段
参阅 [拨号字段](/zh/configuration/shared/dial/)。

View File

@ -29,6 +29,8 @@
| `shadowsocksr` | [ShadowsocksR](./shadowsocksr) | | `shadowsocksr` | [ShadowsocksR](./shadowsocksr) |
| `vless` | [VLESS](./vless) | | `vless` | [VLESS](./vless) |
| `shadowtls` | [ShadowTLS](./shadowtls) | | `shadowtls` | [ShadowTLS](./shadowtls) |
| `tuic` | [TUIC](./tuic) |
| `hysteria2` | [Hysteria2](./hysteria2) |
| `tor` | [Tor](./tor) | | `tor` | [Tor](./tor) |
| `ssh` | [SSH](./ssh) | | `ssh` | [SSH](./ssh) |
| `dns` | [DNS](./dns) | | `dns` | [DNS](./dns) |

View File

@ -28,6 +28,9 @@
| `hysteria` | [Hysteria](./hysteria) | | `hysteria` | [Hysteria](./hysteria) |
| `shadowsocksr` | [ShadowsocksR](./shadowsocksr) | | `shadowsocksr` | [ShadowsocksR](./shadowsocksr) |
| `vless` | [VLESS](./vless) | | `vless` | [VLESS](./vless) |
| `shadowtls` | [ShadowTLS](./shadowtls) |
| `tuic` | [TUIC](./tuic) |
| `hysteria2` | [Hysteria2](./hysteria2) |
| `tor` | [Tor](./tor) | | `tor` | [Tor](./tor) |
| `ssh` | [SSH](./ssh) | | `ssh` | [SSH](./ssh) |
| `dns` | [DNS](./dns) | | `dns` | [DNS](./dns) |

View File

@ -87,6 +87,7 @@ nav:
- ShadowTLS: configuration/inbound/shadowtls.md - ShadowTLS: configuration/inbound/shadowtls.md
- VLESS: configuration/inbound/vless.md - VLESS: configuration/inbound/vless.md
- TUIC: configuration/inbound/tuic.md - TUIC: configuration/inbound/tuic.md
- Hysteria2: configuration/inbound/hysteria2.md
- Tun: configuration/inbound/tun.md - Tun: configuration/inbound/tun.md
- Redirect: configuration/inbound/redirect.md - Redirect: configuration/inbound/redirect.md
- TProxy: configuration/inbound/tproxy.md - TProxy: configuration/inbound/tproxy.md
@ -105,6 +106,7 @@ nav:
- ShadowsocksR: configuration/outbound/shadowsocksr.md - ShadowsocksR: configuration/outbound/shadowsocksr.md
- VLESS: configuration/outbound/vless.md - VLESS: configuration/outbound/vless.md
- TUIC: configuration/outbound/tuic.md - TUIC: configuration/outbound/tuic.md
- Hysteria2: configuration/outbound/hysteria2.md
- Tor: configuration/outbound/tor.md - Tor: configuration/outbound/tor.md
- SSH: configuration/outbound/ssh.md - SSH: configuration/outbound/ssh.md
- DNS: configuration/outbound/dns.md - DNS: configuration/outbound/dns.md