diff --git a/v2rayN/v2rayN/Handler/ConfigHandler.cs b/v2rayN/v2rayN/Handler/ConfigHandler.cs index bf99b053..cec06f2e 100644 --- a/v2rayN/v2rayN/Handler/ConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/ConfigHandler.cs @@ -1674,14 +1674,15 @@ namespace v2rayN.Handler public static int InitBuiltinRouting(Config config, bool blImportAdvancedRules = false) { + var ver = "V2-"; var items = LazyConfig.Instance.RoutingItems(); - if (blImportAdvancedRules || items.Count <= 0) + if (blImportAdvancedRules || items.Where(t => t.remarks.StartsWith(ver)).ToList().Count <= 0) { var maxSort = items.Count; //Bypass the mainland var item2 = new RoutingItem() { - remarks = "绕过大陆(Whitelist)", + remarks = $"{ver}绕过大陆(Whitelist)", url = string.Empty, sort = maxSort + 1, }; @@ -1690,7 +1691,7 @@ namespace v2rayN.Handler //Blacklist var item3 = new RoutingItem() { - remarks = "黑名单(Blacklist)", + remarks = $"{ver}黑名单(Blacklist)", url = string.Empty, sort = maxSort + 2, }; @@ -1699,7 +1700,7 @@ namespace v2rayN.Handler //Global var item1 = new RoutingItem() { - remarks = "全局(Global)", + remarks = $"{ver}全局(Global)", url = string.Empty, sort = maxSort + 3, }; diff --git a/v2rayN/v2rayN/Sample/custom_routing_black b/v2rayN/v2rayN/Sample/custom_routing_black index 3fbd928a..37913f70 100644 --- a/v2rayN/v2rayN/Sample/custom_routing_black +++ b/v2rayN/v2rayN/Sample/custom_routing_black @@ -13,20 +13,10 @@ }, { "outboundTag": "proxy", - "ip": [ - "geoip:cloudflare", - "geoip:cloudfront", - "geoip:facebook", - "geoip:fastly", - "geoip:google", - "geoip:netflix", - "geoip:telegram", - "geoip:twitter" - ], + "domain": [ - "geosite:gfw", - "geosite:greatfire", - "geosite:tld-!cn" + "geosite:geolocation-!cn", + "geosite:greatfire" ] }, { diff --git a/v2rayN/v2rayN/Sample/custom_routing_white b/v2rayN/v2rayN/Sample/custom_routing_white index a708ae0d..37ed49da 100644 --- a/v2rayN/v2rayN/Sample/custom_routing_white +++ b/v2rayN/v2rayN/Sample/custom_routing_white @@ -15,7 +15,8 @@ { "outboundTag": "direct", "domain": [ - "geosite:cn" + "geosite:cn", + "geosite:geolocation-cn" ] }, { diff --git a/v2rayN/v2rayN/Sample/dns_v2ray_normal b/v2rayN/v2rayN/Sample/dns_v2ray_normal index add15f19..c4b9ba02 100644 --- a/v2rayN/v2rayN/Sample/dns_v2ray_normal +++ b/v2rayN/v2rayN/Sample/dns_v2ray_normal @@ -7,7 +7,8 @@ { "address": "223.5.5.5", "domains": [ - "geosite:cn" + "geosite:cn", + "geosite:geolocation-cn" ], "expectIPs": [ "geoip:cn"