1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-06-20 22:45:24 +00:00

add bind to device, socket buf size setting to socket options: auto generated

This commit is contained in:
Shelikhoo 2022-01-16 21:47:11 +00:00 committed by Xiaokang Wang (Shelikhoo)
parent 84f2d47c74
commit 434d8a49a0

View File

@ -423,6 +423,9 @@ type SocketConfig struct {
TcpKeepAliveInterval int32 `protobuf:"varint,8,opt,name=tcp_keep_alive_interval,json=tcpKeepAliveInterval,proto3" json:"tcp_keep_alive_interval,omitempty"`
TfoQueueLength uint32 `protobuf:"varint,9,opt,name=tfo_queue_length,json=tfoQueueLength,proto3" json:"tfo_queue_length,omitempty"`
TcpKeepAliveIdle int32 `protobuf:"varint,10,opt,name=tcp_keep_alive_idle,json=tcpKeepAliveIdle,proto3" json:"tcp_keep_alive_idle,omitempty"`
BindToDevice string `protobuf:"bytes,11,opt,name=bind_to_device,json=bindToDevice,proto3" json:"bind_to_device,omitempty"`
SocketRxBufSize int64 `protobuf:"varint,12,opt,name=socket_rx_buf_size,json=socketRxBufSize,proto3" json:"socket_rx_buf_size,omitempty"`
SocketTxBufSize int64 `protobuf:"varint,13,opt,name=socket_tx_buf_size,json=socketTxBufSize,proto3" json:"socket_tx_buf_size,omitempty"`
}
func (x *SocketConfig) Reset() {
@ -527,6 +530,27 @@ func (x *SocketConfig) GetTcpKeepAliveIdle() int32 {
return 0
}
func (x *SocketConfig) GetBindToDevice() string {
if x != nil {
return x.BindToDevice
}
return ""
}
func (x *SocketConfig) GetSocketRxBufSize() int64 {
if x != nil {
return x.SocketRxBufSize
}
return 0
}
func (x *SocketConfig) GetSocketTxBufSize() int64 {
if x != nil {
return x.SocketTxBufSize
}
return 0
}
var File_transport_internet_config_proto protoreflect.FileDescriptor
var file_transport_internet_config_proto_rawDesc = []byte{
@ -579,7 +603,7 @@ var file_transport_internet_config_proto_rawDesc = []byte{
0x0a, 0x13, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x4c, 0x61, 0x79, 0x65, 0x72,
0x50, 0x72, 0x6f, 0x78, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x13, 0x74, 0x72, 0x61,
0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x78, 0x79,
0x22, 0xf1, 0x04, 0x0a, 0x0c, 0x53, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69,
0x22, 0xf1, 0x05, 0x0a, 0x0c, 0x53, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69,
0x67, 0x12, 0x12, 0x0a, 0x04, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52,
0x04, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x4e, 0x0a, 0x03, 0x74, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01,
0x28, 0x0e, 0x32, 0x3c, 0x2e, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e,
@ -611,7 +635,15 @@ var file_transport_internet_config_proto_rawDesc = []byte{
0x66, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x2d, 0x0a,
0x13, 0x74, 0x63, 0x70, 0x5f, 0x6b, 0x65, 0x65, 0x70, 0x5f, 0x61, 0x6c, 0x69, 0x76, 0x65, 0x5f,
0x69, 0x64, 0x6c, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x10, 0x74, 0x63, 0x70, 0x4b,
0x65, 0x65, 0x70, 0x41, 0x6c, 0x69, 0x76, 0x65, 0x49, 0x64, 0x6c, 0x65, 0x22, 0x35, 0x0a, 0x10,
0x65, 0x65, 0x70, 0x41, 0x6c, 0x69, 0x76, 0x65, 0x49, 0x64, 0x6c, 0x65, 0x12, 0x24, 0x0a, 0x0e,
0x62, 0x69, 0x6e, 0x64, 0x5f, 0x74, 0x6f, 0x5f, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x18, 0x0b,
0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x62, 0x69, 0x6e, 0x64, 0x54, 0x6f, 0x44, 0x65, 0x76, 0x69,
0x63, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x72, 0x78, 0x5f,
0x62, 0x75, 0x66, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f,
0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x78, 0x42, 0x75, 0x66, 0x53, 0x69, 0x7a, 0x65, 0x12,
0x2b, 0x0a, 0x12, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x74, 0x78, 0x5f, 0x62, 0x75, 0x66,
0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x73, 0x6f, 0x63,
0x6b, 0x65, 0x74, 0x54, 0x78, 0x42, 0x75, 0x66, 0x53, 0x69, 0x7a, 0x65, 0x22, 0x35, 0x0a, 0x10,
0x54, 0x43, 0x50, 0x46, 0x61, 0x73, 0x74, 0x4f, 0x70, 0x65, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65,
0x12, 0x08, 0x0a, 0x04, 0x41, 0x73, 0x49, 0x73, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x45, 0x6e,
0x61, 0x62, 0x6c, 0x65, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x69, 0x73, 0x61, 0x62, 0x6c,