mirror of
https://github.com/XTLS/Xray-core.git
synced 2026-05-14 10:00:34 +00:00
XHTTP transport: Fix "auto" mode with REALITY (#5638)
Fixes https://github.com/XTLS/Xray-core/issues/5635 BTW, fixes https://github.com/XTLS/Xray-core/issues/5631
This commit is contained in:
@@ -272,11 +272,6 @@ func Dial(ctx context.Context, dest net.Destination, streamSettings *internet.Me
|
||||
requestURL.Host = dest.Address.String()
|
||||
}
|
||||
|
||||
sessionId := ""
|
||||
if transportConfiguration.Mode != "stream-one" {
|
||||
sessionIdUuid := uuid.New()
|
||||
sessionId = sessionIdUuid.String()
|
||||
}
|
||||
requestURL.Path = transportConfiguration.GetNormalizedPath()
|
||||
requestURL.RawQuery = transportConfiguration.GetNormalizedQuery()
|
||||
|
||||
@@ -293,6 +288,12 @@ func Dial(ctx context.Context, dest net.Destination, streamSettings *internet.Me
|
||||
}
|
||||
}
|
||||
|
||||
sessionId := ""
|
||||
if mode != "stream-one" {
|
||||
sessionIdUuid := uuid.New()
|
||||
sessionId = sessionIdUuid.String()
|
||||
}
|
||||
|
||||
errors.LogInfo(ctx, fmt.Sprintf("XHTTP is dialing to %s, mode %s, HTTP version %s, host %s", dest, mode, httpVersion, requestURL.Host))
|
||||
|
||||
requestURL2 := requestURL
|
||||
|
||||
Reference in New Issue
Block a user