github.com/xraypb/xray-core@v1.6.6/proxy/wireguard/config.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // versions: 3 // protoc-gen-go v1.28.1 4 // protoc v3.21.9 5 // source: proxy/wireguard/config.proto 6 7 package wireguard 8 9 import ( 10 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 11 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 12 reflect "reflect" 13 sync "sync" 14 ) 15 16 const ( 17 // Verify that this generated code is sufficiently up-to-date. 18 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 19 // Verify that runtime/protoimpl is sufficiently up-to-date. 20 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 21 ) 22 23 type PeerConfig struct { 24 state protoimpl.MessageState 25 sizeCache protoimpl.SizeCache 26 unknownFields protoimpl.UnknownFields 27 28 PublicKey string `protobuf:"bytes,1,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` 29 PreSharedKey string `protobuf:"bytes,2,opt,name=pre_shared_key,json=preSharedKey,proto3" json:"pre_shared_key,omitempty"` 30 Endpoint string `protobuf:"bytes,3,opt,name=endpoint,proto3" json:"endpoint,omitempty"` 31 KeepAlive int32 `protobuf:"varint,4,opt,name=keep_alive,json=keepAlive,proto3" json:"keep_alive,omitempty"` 32 AllowedIps []string `protobuf:"bytes,5,rep,name=allowed_ips,json=allowedIps,proto3" json:"allowed_ips,omitempty"` 33 } 34 35 func (x *PeerConfig) Reset() { 36 *x = PeerConfig{} 37 if protoimpl.UnsafeEnabled { 38 mi := &file_proxy_wireguard_config_proto_msgTypes[0] 39 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 40 ms.StoreMessageInfo(mi) 41 } 42 } 43 44 func (x *PeerConfig) String() string { 45 return protoimpl.X.MessageStringOf(x) 46 } 47 48 func (*PeerConfig) ProtoMessage() {} 49 50 func (x *PeerConfig) ProtoReflect() protoreflect.Message { 51 mi := &file_proxy_wireguard_config_proto_msgTypes[0] 52 if protoimpl.UnsafeEnabled && x != nil { 53 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 54 if ms.LoadMessageInfo() == nil { 55 ms.StoreMessageInfo(mi) 56 } 57 return ms 58 } 59 return mi.MessageOf(x) 60 } 61 62 // Deprecated: Use PeerConfig.ProtoReflect.Descriptor instead. 63 func (*PeerConfig) Descriptor() ([]byte, []int) { 64 return file_proxy_wireguard_config_proto_rawDescGZIP(), []int{0} 65 } 66 67 func (x *PeerConfig) GetPublicKey() string { 68 if x != nil { 69 return x.PublicKey 70 } 71 return "" 72 } 73 74 func (x *PeerConfig) GetPreSharedKey() string { 75 if x != nil { 76 return x.PreSharedKey 77 } 78 return "" 79 } 80 81 func (x *PeerConfig) GetEndpoint() string { 82 if x != nil { 83 return x.Endpoint 84 } 85 return "" 86 } 87 88 func (x *PeerConfig) GetKeepAlive() int32 { 89 if x != nil { 90 return x.KeepAlive 91 } 92 return 0 93 } 94 95 func (x *PeerConfig) GetAllowedIps() []string { 96 if x != nil { 97 return x.AllowedIps 98 } 99 return nil 100 } 101 102 type DeviceConfig struct { 103 state protoimpl.MessageState 104 sizeCache protoimpl.SizeCache 105 unknownFields protoimpl.UnknownFields 106 107 SecretKey string `protobuf:"bytes,1,opt,name=secret_key,json=secretKey,proto3" json:"secret_key,omitempty"` 108 Endpoint []string `protobuf:"bytes,2,rep,name=endpoint,proto3" json:"endpoint,omitempty"` 109 Peers []*PeerConfig `protobuf:"bytes,3,rep,name=peers,proto3" json:"peers,omitempty"` 110 Mtu int32 `protobuf:"varint,4,opt,name=mtu,proto3" json:"mtu,omitempty"` 111 NumWorkers int32 `protobuf:"varint,5,opt,name=num_workers,json=numWorkers,proto3" json:"num_workers,omitempty"` 112 } 113 114 func (x *DeviceConfig) Reset() { 115 *x = DeviceConfig{} 116 if protoimpl.UnsafeEnabled { 117 mi := &file_proxy_wireguard_config_proto_msgTypes[1] 118 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 119 ms.StoreMessageInfo(mi) 120 } 121 } 122 123 func (x *DeviceConfig) String() string { 124 return protoimpl.X.MessageStringOf(x) 125 } 126 127 func (*DeviceConfig) ProtoMessage() {} 128 129 func (x *DeviceConfig) ProtoReflect() protoreflect.Message { 130 mi := &file_proxy_wireguard_config_proto_msgTypes[1] 131 if protoimpl.UnsafeEnabled && x != nil { 132 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 133 if ms.LoadMessageInfo() == nil { 134 ms.StoreMessageInfo(mi) 135 } 136 return ms 137 } 138 return mi.MessageOf(x) 139 } 140 141 // Deprecated: Use DeviceConfig.ProtoReflect.Descriptor instead. 142 func (*DeviceConfig) Descriptor() ([]byte, []int) { 143 return file_proxy_wireguard_config_proto_rawDescGZIP(), []int{1} 144 } 145 146 func (x *DeviceConfig) GetSecretKey() string { 147 if x != nil { 148 return x.SecretKey 149 } 150 return "" 151 } 152 153 func (x *DeviceConfig) GetEndpoint() []string { 154 if x != nil { 155 return x.Endpoint 156 } 157 return nil 158 } 159 160 func (x *DeviceConfig) GetPeers() []*PeerConfig { 161 if x != nil { 162 return x.Peers 163 } 164 return nil 165 } 166 167 func (x *DeviceConfig) GetMtu() int32 { 168 if x != nil { 169 return x.Mtu 170 } 171 return 0 172 } 173 174 func (x *DeviceConfig) GetNumWorkers() int32 { 175 if x != nil { 176 return x.NumWorkers 177 } 178 return 0 179 } 180 181 var File_proxy_wireguard_config_proto protoreflect.FileDescriptor 182 183 var file_proxy_wireguard_config_proto_rawDesc = []byte{ 184 0x0a, 0x1c, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x77, 0x69, 0x72, 0x65, 0x67, 0x75, 0x61, 0x72, 185 0x64, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x14, 186 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x77, 0x69, 0x72, 0x65, 0x67, 187 0x75, 0x61, 0x72, 0x64, 0x22, 0xad, 0x01, 0x0a, 0x0a, 0x50, 0x65, 0x65, 0x72, 0x43, 0x6f, 0x6e, 188 0x66, 0x69, 0x67, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 189 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 190 0x65, 0x79, 0x12, 0x24, 0x0a, 0x0e, 0x70, 0x72, 0x65, 0x5f, 0x73, 0x68, 0x61, 0x72, 0x65, 0x64, 191 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x70, 0x72, 0x65, 0x53, 192 0x68, 0x61, 0x72, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x65, 0x6e, 0x64, 0x70, 193 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x65, 0x6e, 0x64, 0x70, 194 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x6b, 0x65, 0x65, 0x70, 0x5f, 0x61, 0x6c, 0x69, 195 0x76, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x6b, 0x65, 0x65, 0x70, 0x41, 0x6c, 196 0x69, 0x76, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x65, 0x64, 0x5f, 0x69, 197 0x70, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x65, 198 0x64, 0x49, 0x70, 0x73, 0x22, 0xb4, 0x01, 0x0a, 0x0c, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x43, 199 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x65, 0x63, 0x72, 0x65, 0x74, 0x5f, 200 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x65, 0x63, 0x72, 0x65, 201 0x74, 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x65, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74, 202 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x65, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74, 203 0x12, 0x36, 0x0a, 0x05, 0x70, 0x65, 0x65, 0x72, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 204 0x20, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x77, 0x69, 0x72, 205 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x2e, 0x50, 0x65, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 206 0x67, 0x52, 0x05, 0x70, 0x65, 0x65, 0x72, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x74, 0x75, 0x18, 207 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6d, 0x74, 0x75, 0x12, 0x1f, 0x0a, 0x0b, 0x6e, 0x75, 208 0x6d, 0x5f, 0x77, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 209 0x0a, 0x6e, 0x75, 0x6d, 0x57, 0x6f, 0x72, 0x6b, 0x65, 0x72, 0x73, 0x42, 0x5e, 0x0a, 0x18, 0x63, 210 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x77, 0x69, 211 0x72, 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x50, 0x01, 0x5a, 0x29, 0x67, 0x69, 0x74, 0x68, 0x75, 212 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x74, 0x6c, 0x73, 0x2f, 0x78, 0x72, 0x61, 0x79, 0x2d, 213 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x77, 0x69, 0x72, 0x65, 0x67, 214 0x75, 0x61, 0x72, 0x64, 0xaa, 0x02, 0x14, 0x58, 0x72, 0x61, 0x79, 0x2e, 0x50, 0x72, 0x6f, 0x78, 215 0x79, 0x2e, 0x57, 0x69, 0x72, 0x65, 0x47, 0x75, 0x61, 0x72, 0x64, 0x62, 0x06, 0x70, 0x72, 0x6f, 216 0x74, 0x6f, 0x33, 217 } 218 219 var ( 220 file_proxy_wireguard_config_proto_rawDescOnce sync.Once 221 file_proxy_wireguard_config_proto_rawDescData = file_proxy_wireguard_config_proto_rawDesc 222 ) 223 224 func file_proxy_wireguard_config_proto_rawDescGZIP() []byte { 225 file_proxy_wireguard_config_proto_rawDescOnce.Do(func() { 226 file_proxy_wireguard_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_proxy_wireguard_config_proto_rawDescData) 227 }) 228 return file_proxy_wireguard_config_proto_rawDescData 229 } 230 231 var file_proxy_wireguard_config_proto_msgTypes = make([]protoimpl.MessageInfo, 2) 232 var file_proxy_wireguard_config_proto_goTypes = []interface{}{ 233 (*PeerConfig)(nil), // 0: xray.proxy.wireguard.PeerConfig 234 (*DeviceConfig)(nil), // 1: xray.proxy.wireguard.DeviceConfig 235 } 236 var file_proxy_wireguard_config_proto_depIdxs = []int32{ 237 0, // 0: xray.proxy.wireguard.DeviceConfig.peers:type_name -> xray.proxy.wireguard.PeerConfig 238 1, // [1:1] is the sub-list for method output_type 239 1, // [1:1] is the sub-list for method input_type 240 1, // [1:1] is the sub-list for extension type_name 241 1, // [1:1] is the sub-list for extension extendee 242 0, // [0:1] is the sub-list for field type_name 243 } 244 245 func init() { file_proxy_wireguard_config_proto_init() } 246 func file_proxy_wireguard_config_proto_init() { 247 if File_proxy_wireguard_config_proto != nil { 248 return 249 } 250 if !protoimpl.UnsafeEnabled { 251 file_proxy_wireguard_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 252 switch v := v.(*PeerConfig); i { 253 case 0: 254 return &v.state 255 case 1: 256 return &v.sizeCache 257 case 2: 258 return &v.unknownFields 259 default: 260 return nil 261 } 262 } 263 file_proxy_wireguard_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 264 switch v := v.(*DeviceConfig); i { 265 case 0: 266 return &v.state 267 case 1: 268 return &v.sizeCache 269 case 2: 270 return &v.unknownFields 271 default: 272 return nil 273 } 274 } 275 } 276 type x struct{} 277 out := protoimpl.TypeBuilder{ 278 File: protoimpl.DescBuilder{ 279 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 280 RawDescriptor: file_proxy_wireguard_config_proto_rawDesc, 281 NumEnums: 0, 282 NumMessages: 2, 283 NumExtensions: 0, 284 NumServices: 0, 285 }, 286 GoTypes: file_proxy_wireguard_config_proto_goTypes, 287 DependencyIndexes: file_proxy_wireguard_config_proto_depIdxs, 288 MessageInfos: file_proxy_wireguard_config_proto_msgTypes, 289 }.Build() 290 File_proxy_wireguard_config_proto = out.File 291 file_proxy_wireguard_config_proto_rawDesc = nil 292 file_proxy_wireguard_config_proto_goTypes = nil 293 file_proxy_wireguard_config_proto_depIdxs = nil 294 }