| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 | 
							- syntax = "proto3";
 
- package v2ray.core.app.router;
 
- option csharp_namespace = "V2Ray.Core.App.Router";
 
- option go_package = "router";
 
- option java_package = "com.v2ray.core.app.router";
 
- option java_multiple_files = true;
 
- import "v2ray.com/core/common/net/port.proto";
 
- import "v2ray.com/core/common/net/network.proto";
 
- // Domain for routing decision. 
 
- message Domain {
 
-   // Type of domain value.
 
-   enum Type {
 
-     // The value is used as is.
 
-     Plain = 0;
 
-     // The value is used as a regular expression.
 
-     Regex = 1;
 
-     // The value is a domain.
 
-     Domain = 2;
 
-   }
 
-   // Domain matching type.
 
-   Type type = 1;
 
-   // Domain value.
 
-   string value = 2;
 
- }
 
- // IP for routing decision, in CIDR form.
 
- message CIDR {
 
-   // IP address, should be either 4 or 16 bytes.
 
-   bytes ip = 1;
 
-   // Number of leading ones in the network mask.
 
-   uint32 prefix = 2;
 
- }
 
- message GeoIP {
 
-   string country_code = 1;
 
-   repeated CIDR cidr = 2;
 
- }
 
- message GeoIPList {
 
-   repeated GeoIP entry = 1;
 
- }
 
- message GeoSite {
 
-   string country_code = 1;
 
-   repeated Domain domain = 2;
 
- }
 
- message GeoSiteList{
 
-   repeated GeoSite entry = 1;
 
- }
 
- message RoutingRule {
 
-   string tag = 1;
 
-   repeated Domain domain = 2;
 
-   repeated CIDR cidr = 3;
 
-   v2ray.core.common.net.PortRange port_range = 4;
 
-   v2ray.core.common.net.NetworkList network_list = 5;
 
-   repeated CIDR source_cidr = 6;
 
-   repeated string user_email = 7;
 
-   repeated string inbound_tag = 8;
 
-   repeated string protocol = 9;
 
- }
 
- message Config {
 
-   enum DomainStrategy {
 
-     // Use domain as is.
 
-     AsIs = 0;
 
-     // Always resolve IP for domains.
 
-     UseIp = 1;
 
-     // Resolve to IP if the domain doesn't match any rules.
 
-     IpIfNonMatch = 2;
 
-     // Resolve to IP if any rule requires IP matching.
 
-     IpOnDemand = 3;
 
-   }
 
-   DomainStrategy domain_strategy = 1;
 
-   repeated RoutingRule rule = 2;
 
- }
 
 
  |