Hysteria transport: Add congestion config (""/"reno"/"bbr"/"brutal"/"force-brutal") (#5549)

Closes https://github.com/XTLS/Xray-core/issues/5546
This commit is contained in:
LjhAUMEM authored and GitHub committed 2026-01-17 13:29:50 +00:00
1 parent 5f7474120f
commit cfc78b3ac1
7 files changed
+112 -51

No files matched your search

+4
View File
@@ -17,6 +17,7 @@ import (
"github.com/xtls/xray-core/common/task"
"github.com/xtls/xray-core/core"
"github.com/xtls/xray-core/features/policy"
hyCtx "github.com/xtls/xray-core/proxy/hysteria/ctx"
"github.com/xtls/xray-core/transport"
"github.com/xtls/xray-core/transport/internet"
"github.com/xtls/xray-core/transport/internet/hysteria"
@@ -55,6 +56,9 @@ func (c *Client) Process(ctx context.Context, link *transport.Link, dialer inter
ob.CanSpliceCopy = 3
target := ob.Target
if target.Network == net.Network_UDP {
hyCtx.ContextWithRequireDatagram(ctx)
}
conn, err := dialer.Dial(ctx, c.server.Destination)
if err != nil {
return errors.New("failed to find an available destination").AtWarning().Base(err)