mirror of
https://github.com/XTLS/Xray-docs-next.git
synced 2026-10-07 14:28:03 +03:00
Remove QUIC, DomainSocket and global transport from EN/RU (#571)
This commit is contained in:
@@ -4,75 +4,6 @@ Transports specify how Xray communicates with peers.
|
||||
|
||||
Transports specify how to achieve stable data transmission. Both ends of a connection often need to specify the same transport protocol to successfully establish a connection. Like, if one end uses WebSocket, the other end must also use WebSocket, or else the connection cannot be established.
|
||||
|
||||
Transport configuration consists of two parts:
|
||||
|
||||
1. ~~Global config ([TransportObject](#transportobject)) (deprecated)~~
|
||||
2. Local config ([StreamSettingsObject](#streamsettingsobject)).
|
||||
|
||||
- When locally configured, you can specify how each inbound or outbound connection is transmitted individually.
|
||||
- Server inbounds and client outbounds often need to use the same transport protocol. When a transport protocol is specified without local configs, the transport will fall back to global transport configs.
|
||||
|
||||
<details>
|
||||
<summary>Global configuration (deprecated)</summary>
|
||||
|
||||
## TransportObject (deprecated)
|
||||
|
||||
The `TransportObject` corresponds to the `transport` property in the config root.
|
||||
|
||||
```json
|
||||
{
|
||||
"transport": {
|
||||
"tcpSettings": {},
|
||||
"kcpSettings": {},
|
||||
"wsSettings": {},
|
||||
"httpSettings": {},
|
||||
"quicSettings": {},
|
||||
"dsSettings": {},
|
||||
"grpcSettings": {},
|
||||
"httpupgradeSettings": {}
|
||||
"splithttpSettings": {}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
> `tcpSettings`: [TcpObject](./transports/tcp.md)
|
||||
|
||||
Configures TCP connections.
|
||||
|
||||
> `kcpSettings`: [KcpObject](./transports/mkcp.md)
|
||||
|
||||
Configures mKCP connections.
|
||||
|
||||
> `wsSettings`: [WebSocketObject](./transports/websocket.md)
|
||||
|
||||
Configures WebSocket connections.
|
||||
|
||||
> `httpSettings`: [HttpObject](./transports/h2.md)
|
||||
|
||||
Configures HTTP/2 connections.
|
||||
|
||||
> `quicSettings`: [QuicObject](./transports/quic.md)
|
||||
|
||||
Configures QUIC connections.
|
||||
|
||||
> `grpcSettings`: [GRPCObject](./transports/grpc.md)
|
||||
|
||||
Configures gRPC connections.
|
||||
|
||||
> `httpupgradeSettings`: [HttpUpgradeObject](./transports/httpupgrade.md)
|
||||
|
||||
Configures HTTPUpgrade connections.
|
||||
|
||||
> `dsSettings`: [DomainSocketObject](./transports/domainsocket.md)
|
||||
|
||||
Configures Domain Socket connections.
|
||||
|
||||
> `splithttpSettings`: [SplitHttpObject](./transports/splithttp.md)
|
||||
|
||||
Configures SplitHTTP connections.
|
||||
|
||||
</details>
|
||||
|
||||
## StreamSettingsObject
|
||||
|
||||
`StreamSettingsObject` corresponds to the `streamSettings` property in the inbound or outbound config. Each inbound or outbound can be configured with different transports and can use `streamSettings` to specify local configs.
|
||||
@@ -86,8 +17,6 @@ Configures SplitHTTP connections.
|
||||
"kcpSettings": {},
|
||||
"wsSettings": {},
|
||||
"httpSettings": {},
|
||||
"quicSettings": {},
|
||||
"dsSettings": {},
|
||||
"grpcSettings": {},
|
||||
"httpupgradeSettings": {},
|
||||
"splithttpSettings": {},
|
||||
@@ -112,7 +41,7 @@ Configures SplitHTTP connections.
|
||||
}
|
||||
```
|
||||
|
||||
> `network`: "tcp" | "kcp" | "ws" | "http" | "quic" | "grpc" | "httpupgrade" | "splithttp"
|
||||
> `network`: "tcp" | "kcp" | "ws" | "http" | "grpc" | "httpupgrade" | "splithttp"
|
||||
|
||||
The underlying protocol of the transport used by the data stream of the connection, defaulting to `"tcp"`.
|
||||
|
||||
@@ -152,18 +81,10 @@ Configures the current WebSocket connection. Valid only when WebSocket is used.
|
||||
|
||||
Configures the current HTTP/2 connection. Valid only when HTTP/2 is used. Same schema as global.
|
||||
|
||||
> `quicSettings`: [QUICObject](./transports/quic.md)
|
||||
|
||||
Configures the current QUIC connection. Valid only when QUIC is used. Same schema as global.
|
||||
|
||||
> `grpcSettings`: [GRPCObject](./transports/grpc.md)
|
||||
|
||||
Configures the current gRPC connection. Valid only when gRPC is used. Same schema as global.
|
||||
|
||||
> `dsSettings`: [DomainSocketObject](./transports/domainsocket.md)
|
||||
|
||||
Configures the current Domain Socket connection. Valid only when Domain Socket is used. Same schema as global.
|
||||
|
||||
> `httpupgradeSettings`: [HttpUpgradeObject](./transports/httpupgrade.md)
|
||||
|
||||
Configures the current HTTPUpgrade connection. Valid only when HTTPUpgrade is used. Same schema as global.
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
# Domain Socket
|
||||
|
||||
::: danger
|
||||
We recommend writing it to the `listen` field in [inbounds](../inbound.md)and the transport mode can be TCP, WebSocket, or HTTP/2.
|
||||
|
||||
Note that the DomainSocket option here may be deprecated in the future.
|
||||
:::
|
||||
|
||||
Domain Socket uses standard Unix domain sockets to transmit data.
|
||||
|
||||
The advantage of using DomainSocket is that it uses the built-in transport channel of the operating system and does not occupy the network cache. Theoretically, it is slightly faster than local loopback networks.
|
||||
|
||||
Currently, it can only be used on platforms that support Unix domain sockets, such as Linux and macOS. It is not available until Windows 10 Build 17036.
|
||||
|
||||
If DomainSocket is specified as the transport mode, the ports and IP addresses configured in the inbound and outbound proxies will be invalidated, and all transports will be replaced by DomainSocket.
|
||||
|
||||
## DomainSocketObject
|
||||
|
||||
`DomainSocketObject` corresponds to the `dsSettings` item.
|
||||
|
||||
```json
|
||||
{
|
||||
"path": "/path/to/ds/file",
|
||||
"abstract": false,
|
||||
"padding": false
|
||||
}
|
||||
```
|
||||
|
||||
> `path`: string
|
||||
|
||||
A valid file path.
|
||||
|
||||
::: danger
|
||||
This file must not exist before running Xray.
|
||||
:::
|
||||
|
||||
> `abstract`: true | false
|
||||
|
||||
Whether it is an abstract domain socket, with a default value of `false`.
|
||||
|
||||
> `padding`: true | false
|
||||
|
||||
Whether the abstract domain socket has padding, with a default value of `false`.
|
||||
@@ -1,75 +0,0 @@
|
||||
# QUIC
|
||||
|
||||
QUIC (Quick UDP Internet Connection) is a protocol proposed by Google for multiplexed and concurrent transmission using UDP. Its main advantages are:
|
||||
|
||||
1. Reduced number of roundtrips in handshake phase. (1-RTT or 0-RTT)
|
||||
2. Multiplexing, and no [Head-of-Line blocking](https://calendar.perfplanet.com/2020/head-of-line-blocking-in-quic-and-http-3-the-details/) problem.
|
||||
3. Connection migration, (mainly on the client side) when switching from Wifi to 4G, the connection will not be interrupted.
|
||||
|
||||
QUIC is currently in the experimental phase and uses IETF implementation that is still being standardized, so compatibility with the final version cannot be guaranteed.
|
||||
|
||||
- Default settings:
|
||||
- 12-byte Connection ID
|
||||
- Automatically disconnect the connection if no data is transmitted for 30 seconds (which may affect the use of some [persistent connections](https://en.wikipedia.org/wiki/HTTP_persistent_connection)).
|
||||
|
||||
## QuicObject
|
||||
|
||||
`QuicObject` corresponds to the `quicSettings` item in the [Transport Protocol](../transport.md).
|
||||
|
||||
::: danger
|
||||
The configurations of both endpoints must be identical, otherwise the connection will fail.
|
||||
|
||||
QUIC requires TLS to be enabled and if it is not enabled in the [Transport Protocol](../transport.md), Xray will issue a self-signed certificate for TLS communication.
|
||||
:::
|
||||
|
||||
```json
|
||||
{
|
||||
"security": "none",
|
||||
"key": "",
|
||||
"header": {
|
||||
"type": "none"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
> `security`: "none" | "aes-128-gcm" | "chacha20-poly1305"
|
||||
|
||||
Encryption method.
|
||||
|
||||
Extra encryption over entire QUIC packet, include the frame head part. Default value is "none" for no encryption. After being encrypted, QUIC packets will not be detected as QUIC but some other unknown traffic.
|
||||
|
||||
The default value is `none`
|
||||
|
||||
> `key`: string
|
||||
|
||||
Encryption key used for encryption.
|
||||
|
||||
It can be any string and is effective when "security" is not set to "none".
|
||||
|
||||
> `header`: [HeaderObject](#headerobject)
|
||||
|
||||
Packet header obfuscation settings.
|
||||
|
||||
### HeaderObject
|
||||
|
||||
```json
|
||||
{
|
||||
"type": "none"
|
||||
}
|
||||
```
|
||||
|
||||
> `type`: string
|
||||
|
||||
Type of obfuscation. Corresponding inbound and outbound proxy must have the same settings. Choices are:
|
||||
|
||||
- `"none"`: Default value. No obfuscation is used.
|
||||
- `"srtp"`: Obfuscated as SRTP traffic. It may be recognized as video calls such as Facetime.
|
||||
- `"utp"`: Obfuscated as uTP traffic. It may be recognized as Bittorrent traffic.
|
||||
- `"wechat-video"`: Obfuscated to WeChat traffic.
|
||||
- `"dtls"`: Obfuscated as DTLS 1.2 packets.
|
||||
- `"wireguard"`: Obfuscated as WireGuard packets. (NOT true WireGuard protocol)
|
||||
|
||||
::: tip
|
||||
When neither encryption nor obfuscation is enabled, QUIC transport is compatible with other QUIC tools.
|
||||
However it is recommended to enable either or both for better undetectable communication.
|
||||
:::
|
||||
Reference in New Issue
Block a user