Skip to main content

多路复用

入站

{
"enabled": true,
"padding": false,
"brutal": {}
}

出站

{
"enabled": true,
"protocol": "smux",
"max_connections": 4,
"min_streams": 4,
"max_streams": 0,
"padding": false,
"brutal": {}
}

入站字段

enabled

启用多路复用支持。

padding

如果启用,将拒绝非填充连接。

brutal

参阅 TCP Brutal

出站字段

enabled

启用多路复用。

protocol

多路复用协议

协议描述
smuxhttps://github.com/xtaci/smux
yamuxhttps://github.com/hashicorp/yamux
h2muxhttps://golang.org/x/net/http2

默认使用 h2mux。

max_connections

最大连接数量。

max_streams 冲突。

min_streams

在打开新连接之前,连接中的最小多路复用流数量。

max_streams 冲突。

max_streams

在打开新连接之前,连接中的最大多路复用流数量。

max_connectionsmin_streams 冲突。

padding

note

需要 sing-box 服务器版本 1.3-beta9 或更高。

启用填充。

brutal

参阅 TCP Brutal