github.com/v2fly/v2ray-core/v5@v5.16.2-0.20240507031116-8191faa6e095/transport/internet/websocket/config.pb.go (about) 1 package websocket 2 3 import ( 4 _ "github.com/v2fly/v2ray-core/v5/common/protoext" 5 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 6 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 7 reflect "reflect" 8 sync "sync" 9 ) 10 11 const ( 12 // Verify that this generated code is sufficiently up-to-date. 13 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 14 // Verify that runtime/protoimpl is sufficiently up-to-date. 15 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 16 ) 17 18 type Header struct { 19 state protoimpl.MessageState 20 sizeCache protoimpl.SizeCache 21 unknownFields protoimpl.UnknownFields 22 23 Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` 24 Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` 25 } 26 27 func (x *Header) Reset() { 28 *x = Header{} 29 if protoimpl.UnsafeEnabled { 30 mi := &file_transport_internet_websocket_config_proto_msgTypes[0] 31 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 32 ms.StoreMessageInfo(mi) 33 } 34 } 35 36 func (x *Header) String() string { 37 return protoimpl.X.MessageStringOf(x) 38 } 39 40 func (*Header) ProtoMessage() {} 41 42 func (x *Header) ProtoReflect() protoreflect.Message { 43 mi := &file_transport_internet_websocket_config_proto_msgTypes[0] 44 if protoimpl.UnsafeEnabled && x != nil { 45 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 46 if ms.LoadMessageInfo() == nil { 47 ms.StoreMessageInfo(mi) 48 } 49 return ms 50 } 51 return mi.MessageOf(x) 52 } 53 54 // Deprecated: Use Header.ProtoReflect.Descriptor instead. 55 func (*Header) Descriptor() ([]byte, []int) { 56 return file_transport_internet_websocket_config_proto_rawDescGZIP(), []int{0} 57 } 58 59 func (x *Header) GetKey() string { 60 if x != nil { 61 return x.Key 62 } 63 return "" 64 } 65 66 func (x *Header) GetValue() string { 67 if x != nil { 68 return x.Value 69 } 70 return "" 71 } 72 73 type Config struct { 74 state protoimpl.MessageState 75 sizeCache protoimpl.SizeCache 76 unknownFields protoimpl.UnknownFields 77 78 // URL path to the WebSocket service. Empty value means root(/). 79 Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` 80 Header []*Header `protobuf:"bytes,3,rep,name=header,proto3" json:"header,omitempty"` 81 AcceptProxyProtocol bool `protobuf:"varint,4,opt,name=accept_proxy_protocol,json=acceptProxyProtocol,proto3" json:"accept_proxy_protocol,omitempty"` 82 MaxEarlyData int32 `protobuf:"varint,5,opt,name=max_early_data,json=maxEarlyData,proto3" json:"max_early_data,omitempty"` 83 UseBrowserForwarding bool `protobuf:"varint,6,opt,name=use_browser_forwarding,json=useBrowserForwarding,proto3" json:"use_browser_forwarding,omitempty"` 84 EarlyDataHeaderName string `protobuf:"bytes,7,opt,name=early_data_header_name,json=earlyDataHeaderName,proto3" json:"early_data_header_name,omitempty"` 85 } 86 87 func (x *Config) Reset() { 88 *x = Config{} 89 if protoimpl.UnsafeEnabled { 90 mi := &file_transport_internet_websocket_config_proto_msgTypes[1] 91 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 92 ms.StoreMessageInfo(mi) 93 } 94 } 95 96 func (x *Config) String() string { 97 return protoimpl.X.MessageStringOf(x) 98 } 99 100 func (*Config) ProtoMessage() {} 101 102 func (x *Config) ProtoReflect() protoreflect.Message { 103 mi := &file_transport_internet_websocket_config_proto_msgTypes[1] 104 if protoimpl.UnsafeEnabled && x != nil { 105 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 106 if ms.LoadMessageInfo() == nil { 107 ms.StoreMessageInfo(mi) 108 } 109 return ms 110 } 111 return mi.MessageOf(x) 112 } 113 114 // Deprecated: Use Config.ProtoReflect.Descriptor instead. 115 func (*Config) Descriptor() ([]byte, []int) { 116 return file_transport_internet_websocket_config_proto_rawDescGZIP(), []int{1} 117 } 118 119 func (x *Config) GetPath() string { 120 if x != nil { 121 return x.Path 122 } 123 return "" 124 } 125 126 func (x *Config) GetHeader() []*Header { 127 if x != nil { 128 return x.Header 129 } 130 return nil 131 } 132 133 func (x *Config) GetAcceptProxyProtocol() bool { 134 if x != nil { 135 return x.AcceptProxyProtocol 136 } 137 return false 138 } 139 140 func (x *Config) GetMaxEarlyData() int32 { 141 if x != nil { 142 return x.MaxEarlyData 143 } 144 return 0 145 } 146 147 func (x *Config) GetUseBrowserForwarding() bool { 148 if x != nil { 149 return x.UseBrowserForwarding 150 } 151 return false 152 } 153 154 func (x *Config) GetEarlyDataHeaderName() string { 155 if x != nil { 156 return x.EarlyDataHeaderName 157 } 158 return "" 159 } 160 161 var File_transport_internet_websocket_config_proto protoreflect.FileDescriptor 162 163 var file_transport_internet_websocket_config_proto_rawDesc = []byte{ 164 0x0a, 0x29, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2f, 0x69, 0x6e, 0x74, 0x65, 165 0x72, 0x6e, 0x65, 0x74, 0x2f, 0x77, 0x65, 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x2f, 0x63, 166 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x27, 0x76, 0x32, 0x72, 167 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 168 0x74, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x77, 0x65, 0x62, 0x73, 0x6f, 169 0x63, 0x6b, 0x65, 0x74, 0x1a, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 170 0x74, 0x6f, 0x65, 0x78, 0x74, 0x2f, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 171 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x30, 0x0a, 0x06, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 172 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 173 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 174 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xd6, 0x02, 0x0a, 0x06, 0x43, 0x6f, 0x6e, 175 0x66, 0x69, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 176 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x47, 0x0a, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 177 0x72, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 178 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x69, 179 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x77, 0x65, 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 180 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 181 0x12, 0x32, 0x0a, 0x15, 0x61, 0x63, 0x63, 0x65, 0x70, 0x74, 0x5f, 0x70, 0x72, 0x6f, 0x78, 0x79, 182 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 183 0x13, 0x61, 0x63, 0x63, 0x65, 0x70, 0x74, 0x50, 0x72, 0x6f, 0x78, 0x79, 0x50, 0x72, 0x6f, 0x74, 184 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x24, 0x0a, 0x0e, 0x6d, 0x61, 0x78, 0x5f, 0x65, 0x61, 0x72, 0x6c, 185 0x79, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x6d, 0x61, 186 0x78, 0x45, 0x61, 0x72, 0x6c, 0x79, 0x44, 0x61, 0x74, 0x61, 0x12, 0x34, 0x0a, 0x16, 0x75, 0x73, 187 0x65, 0x5f, 0x62, 0x72, 0x6f, 0x77, 0x73, 0x65, 0x72, 0x5f, 0x66, 0x6f, 0x72, 0x77, 0x61, 0x72, 188 0x64, 0x69, 0x6e, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x14, 0x75, 0x73, 0x65, 0x42, 189 0x72, 0x6f, 0x77, 0x73, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x69, 0x6e, 0x67, 190 0x12, 0x33, 0x0a, 0x16, 0x65, 0x61, 0x72, 0x6c, 0x79, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x68, 191 0x65, 0x61, 0x64, 0x65, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 192 0x52, 0x13, 0x65, 0x61, 0x72, 0x6c, 0x79, 0x44, 0x61, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 193 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x3a, 0x24, 0x82, 0xb5, 0x18, 0x20, 0x0a, 0x09, 0x74, 0x72, 0x61, 194 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x02, 0x77, 0x73, 0x8a, 0xff, 0x29, 0x09, 0x77, 0x65, 195 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x90, 0xff, 0x29, 0x01, 0x4a, 0x04, 0x08, 0x01, 0x10, 196 0x02, 0x42, 0x96, 0x01, 0x0a, 0x2b, 0x63, 0x6f, 0x6d, 0x2e, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 197 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x69, 198 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x77, 0x65, 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 199 0x74, 0x50, 0x01, 0x5a, 0x3b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 200 0x76, 0x32, 0x66, 0x6c, 0x79, 0x2f, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65, 201 0x2f, 0x76, 0x35, 0x2f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2f, 0x69, 0x6e, 202 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2f, 0x77, 0x65, 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 203 0xaa, 0x02, 0x27, 0x56, 0x32, 0x52, 0x61, 0x79, 0x2e, 0x43, 0x6f, 0x72, 0x65, 0x2e, 0x54, 0x72, 204 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 205 0x2e, 0x57, 0x65, 0x62, 0x73, 0x6f, 0x63, 0x6b, 0x65, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 206 0x6f, 0x33, 207 } 208 209 var ( 210 file_transport_internet_websocket_config_proto_rawDescOnce sync.Once 211 file_transport_internet_websocket_config_proto_rawDescData = file_transport_internet_websocket_config_proto_rawDesc 212 ) 213 214 func file_transport_internet_websocket_config_proto_rawDescGZIP() []byte { 215 file_transport_internet_websocket_config_proto_rawDescOnce.Do(func() { 216 file_transport_internet_websocket_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_transport_internet_websocket_config_proto_rawDescData) 217 }) 218 return file_transport_internet_websocket_config_proto_rawDescData 219 } 220 221 var file_transport_internet_websocket_config_proto_msgTypes = make([]protoimpl.MessageInfo, 2) 222 var file_transport_internet_websocket_config_proto_goTypes = []interface{}{ 223 (*Header)(nil), // 0: v2ray.core.transport.internet.websocket.Header 224 (*Config)(nil), // 1: v2ray.core.transport.internet.websocket.Config 225 } 226 var file_transport_internet_websocket_config_proto_depIdxs = []int32{ 227 0, // 0: v2ray.core.transport.internet.websocket.Config.header:type_name -> v2ray.core.transport.internet.websocket.Header 228 1, // [1:1] is the sub-list for method output_type 229 1, // [1:1] is the sub-list for method input_type 230 1, // [1:1] is the sub-list for extension type_name 231 1, // [1:1] is the sub-list for extension extendee 232 0, // [0:1] is the sub-list for field type_name 233 } 234 235 func init() { file_transport_internet_websocket_config_proto_init() } 236 func file_transport_internet_websocket_config_proto_init() { 237 if File_transport_internet_websocket_config_proto != nil { 238 return 239 } 240 if !protoimpl.UnsafeEnabled { 241 file_transport_internet_websocket_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 242 switch v := v.(*Header); i { 243 case 0: 244 return &v.state 245 case 1: 246 return &v.sizeCache 247 case 2: 248 return &v.unknownFields 249 default: 250 return nil 251 } 252 } 253 file_transport_internet_websocket_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 254 switch v := v.(*Config); i { 255 case 0: 256 return &v.state 257 case 1: 258 return &v.sizeCache 259 case 2: 260 return &v.unknownFields 261 default: 262 return nil 263 } 264 } 265 } 266 type x struct{} 267 out := protoimpl.TypeBuilder{ 268 File: protoimpl.DescBuilder{ 269 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 270 RawDescriptor: file_transport_internet_websocket_config_proto_rawDesc, 271 NumEnums: 0, 272 NumMessages: 2, 273 NumExtensions: 0, 274 NumServices: 0, 275 }, 276 GoTypes: file_transport_internet_websocket_config_proto_goTypes, 277 DependencyIndexes: file_transport_internet_websocket_config_proto_depIdxs, 278 MessageInfos: file_transport_internet_websocket_config_proto_msgTypes, 279 }.Build() 280 File_transport_internet_websocket_config_proto = out.File 281 file_transport_internet_websocket_config_proto_rawDesc = nil 282 file_transport_internet_websocket_config_proto_goTypes = nil 283 file_transport_internet_websocket_config_proto_depIdxs = nil 284 }