mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-01-03 07:56:42 -05:00
Fix: logic of domain override
This commit is contained in:
parent
82495d092b
commit
3c0aff73e8
@ -182,7 +182,7 @@ func shouldOverride(result SniffResult, domainOverride []string) bool {
|
|||||||
protocolString = resComp.ProtocolForDomainResult()
|
protocolString = resComp.ProtocolForDomainResult()
|
||||||
}
|
}
|
||||||
for _, p := range domainOverride {
|
for _, p := range domainOverride {
|
||||||
if strings.HasPrefix(protocolString, p) && strings.HasSuffix(protocolString, p) {
|
if strings.HasPrefix(protocolString, p) || strings.HasSuffix(protocolString, p) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
if resultSubset, ok := result.(SnifferIsProtoSubsetOf); ok {
|
if resultSubset, ok := result.(SnifferIsProtoSubsetOf); ok {
|
||||||
|
Loading…
Reference in New Issue
Block a user