mirror of
https://github.com/wyx2685/V2bX.git
synced 2025-02-02 06:48:14 -05:00
fix proxy protocol not work
This commit is contained in:
parent
695da4f4c5
commit
bb430dbb8d
@ -50,7 +50,7 @@ func buildInbound(config *conf.ControllerConfig, nodeInfo *panel.NodeInfo, tag s
|
|||||||
sniffingConfig.Enabled = false
|
sniffingConfig.Enabled = false
|
||||||
}
|
}
|
||||||
inbound.SniffingConfig = sniffingConfig
|
inbound.SniffingConfig = sniffingConfig
|
||||||
if nodeInfo.NodeType == "tcp" {
|
if *inbound.StreamSetting.Network == "tcp" {
|
||||||
if inbound.StreamSetting.TCPSettings != nil {
|
if inbound.StreamSetting.TCPSettings != nil {
|
||||||
inbound.StreamSetting.TCPSettings.AcceptProxyProtocol = config.EnableProxyProtocol
|
inbound.StreamSetting.TCPSettings.AcceptProxyProtocol = config.EnableProxyProtocol
|
||||||
} else {
|
} else {
|
||||||
@ -59,7 +59,7 @@ func buildInbound(config *conf.ControllerConfig, nodeInfo *panel.NodeInfo, tag s
|
|||||||
} //Enable proxy protocol
|
} //Enable proxy protocol
|
||||||
inbound.StreamSetting.TCPSettings = tcpSetting
|
inbound.StreamSetting.TCPSettings = tcpSetting
|
||||||
}
|
}
|
||||||
} else if nodeInfo.NodeType == "ws" {
|
} else if *inbound.StreamSetting.Network == "ws" {
|
||||||
inbound.StreamSetting.WSSettings = &coreConf.WebSocketConfig{
|
inbound.StreamSetting.WSSettings = &coreConf.WebSocketConfig{
|
||||||
AcceptProxyProtocol: config.EnableProxyProtocol} //Enable proxy protocol
|
AcceptProxyProtocol: config.EnableProxyProtocol} //Enable proxy protocol
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user