github.com/Uhtred009/v2ray-core-1@v4.31.2+incompatible/transport/internet/config.proto (about)

     1  syntax = "proto3";
     2  
     3  package v2ray.core.transport.internet;
     4  option csharp_namespace = "V2Ray.Core.Transport.Internet";
     5  option go_package = "v2ray.com/core/transport/internet";
     6  option java_package = "com.v2ray.core.transport.internet";
     7  option java_multiple_files = true;
     8  
     9  import "common/serial/typed_message.proto";
    10  
    11  enum TransportProtocol {
    12    TCP = 0;
    13    UDP = 1;
    14    MKCP = 2;
    15    WebSocket = 3;
    16    HTTP = 4;
    17    DomainSocket = 5;
    18  }
    19  
    20  message TransportConfig {
    21    // Type of network that this settings supports.
    22    // Deprecated. Use the string form below.
    23    TransportProtocol protocol = 1;
    24  
    25    // Type of network that this settings supports.
    26    string protocol_name = 3;
    27  
    28    // Specific settings. Must be of the transports.
    29    v2ray.core.common.serial.TypedMessage settings = 2;
    30  }
    31  
    32  message StreamConfig {
    33    // Effective network. Deprecated. Use the string form below.
    34    TransportProtocol protocol = 1 [deprecated = true];
    35  
    36    // Effective network.
    37    string protocol_name = 5;
    38  
    39    repeated TransportConfig transport_settings = 2;
    40  
    41    // Type of security. Must be a message name of the settings proto.
    42    string security_type = 3;
    43  
    44    // Settings for transport security. For now the only choice is TLS.
    45    repeated v2ray.core.common.serial.TypedMessage security_settings = 4;
    46  
    47    SocketConfig socket_settings = 6;
    48  }
    49  
    50  message ProxyConfig {
    51    string tag = 1;
    52  }
    53  
    54  // SocketConfig is options to be applied on network sockets.
    55  message SocketConfig {
    56    // Mark of the connection. If non-zero, the value will be set to SO_MARK.
    57    int32 mark = 1;
    58  
    59    enum TCPFastOpenState {
    60      // AsIs is to leave the current TFO state as is, unmodified.
    61      AsIs = 0;
    62      // Enable is for enabling TFO explictly.
    63      Enable = 1;
    64      // Disable is for disabling TFO explictly.
    65      Disable = 2;
    66    }
    67  
    68    // TFO is the state of TFO settings.
    69    TCPFastOpenState tfo = 2;
    70  
    71    enum TProxyMode {
    72      // TProxy is off.
    73      Off = 0;
    74      // TProxy mode.
    75      TProxy = 1;
    76      // Redirect mode.
    77      Redirect = 2;
    78    }
    79  
    80    // TProxy is for enabling TProxy socket option.
    81    TProxyMode tproxy = 3;
    82  
    83    // ReceiveOriginalDestAddress is for enabling IP_RECVORIGDSTADDR socket
    84    // option. This option is for UDP only.
    85    bool receive_original_dest_address = 4;
    86  
    87    bytes bind_address = 5;
    88  
    89    uint32 bind_port = 6;
    90  }