config.pb.go 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. package dtls
  2. import (
  3. _ "github.com/v2fly/v2ray-core/v5/common/protoext"
  4. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  5. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  6. reflect "reflect"
  7. sync "sync"
  8. )
  9. const (
  10. // Verify that this generated code is sufficiently up-to-date.
  11. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  12. // Verify that runtime/protoimpl is sufficiently up-to-date.
  13. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  14. )
  15. type DTLSMode int32
  16. const (
  17. DTLSMode_INVALID DTLSMode = 0
  18. DTLSMode_PSK DTLSMode = 1
  19. )
  20. // Enum value maps for DTLSMode.
  21. var (
  22. DTLSMode_name = map[int32]string{
  23. 0: "INVALID",
  24. 1: "PSK",
  25. }
  26. DTLSMode_value = map[string]int32{
  27. "INVALID": 0,
  28. "PSK": 1,
  29. }
  30. )
  31. func (x DTLSMode) Enum() *DTLSMode {
  32. p := new(DTLSMode)
  33. *p = x
  34. return p
  35. }
  36. func (x DTLSMode) String() string {
  37. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  38. }
  39. func (DTLSMode) Descriptor() protoreflect.EnumDescriptor {
  40. return file_transport_internet_dtls_config_proto_enumTypes[0].Descriptor()
  41. }
  42. func (DTLSMode) Type() protoreflect.EnumType {
  43. return &file_transport_internet_dtls_config_proto_enumTypes[0]
  44. }
  45. func (x DTLSMode) Number() protoreflect.EnumNumber {
  46. return protoreflect.EnumNumber(x)
  47. }
  48. // Deprecated: Use DTLSMode.Descriptor instead.
  49. func (DTLSMode) EnumDescriptor() ([]byte, []int) {
  50. return file_transport_internet_dtls_config_proto_rawDescGZIP(), []int{0}
  51. }
  52. type Config struct {
  53. state protoimpl.MessageState
  54. sizeCache protoimpl.SizeCache
  55. unknownFields protoimpl.UnknownFields
  56. Mode DTLSMode `protobuf:"varint,1,opt,name=mode,proto3,enum=v2ray.core.transport.internet.dtls.DTLSMode" json:"mode,omitempty"`
  57. Psk []byte `protobuf:"bytes,2,opt,name=psk,proto3" json:"psk,omitempty"`
  58. Mtu uint32 `protobuf:"varint,3,opt,name=mtu,proto3" json:"mtu,omitempty"`
  59. ReplayProtectionWindow uint32 `protobuf:"varint,4,opt,name=replay_protection_window,json=replayProtectionWindow,proto3" json:"replay_protection_window,omitempty"`
  60. }
  61. func (x *Config) Reset() {
  62. *x = Config{}
  63. if protoimpl.UnsafeEnabled {
  64. mi := &file_transport_internet_dtls_config_proto_msgTypes[0]
  65. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  66. ms.StoreMessageInfo(mi)
  67. }
  68. }
  69. func (x *Config) String() string {
  70. return protoimpl.X.MessageStringOf(x)
  71. }
  72. func (*Config) ProtoMessage() {}
  73. func (x *Config) ProtoReflect() protoreflect.Message {
  74. mi := &file_transport_internet_dtls_config_proto_msgTypes[0]
  75. if protoimpl.UnsafeEnabled && x != nil {
  76. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  77. if ms.LoadMessageInfo() == nil {
  78. ms.StoreMessageInfo(mi)
  79. }
  80. return ms
  81. }
  82. return mi.MessageOf(x)
  83. }
  84. // Deprecated: Use Config.ProtoReflect.Descriptor instead.
  85. func (*Config) Descriptor() ([]byte, []int) {
  86. return file_transport_internet_dtls_config_proto_rawDescGZIP(), []int{0}
  87. }
  88. func (x *Config) GetMode() DTLSMode {
  89. if x != nil {
  90. return x.Mode
  91. }
  92. return DTLSMode_INVALID
  93. }
  94. func (x *Config) GetPsk() []byte {
  95. if x != nil {
  96. return x.Psk
  97. }
  98. return nil
  99. }
  100. func (x *Config) GetMtu() uint32 {
  101. if x != nil {
  102. return x.Mtu
  103. }
  104. return 0
  105. }
  106. func (x *Config) GetReplayProtectionWindow() uint32 {
  107. if x != nil {
  108. return x.ReplayProtectionWindow
  109. }
  110. return 0
  111. }
  112. var File_transport_internet_dtls_config_proto protoreflect.FileDescriptor
  113. var file_transport_internet_dtls_config_proto_rawDesc = []byte{
  114. 0x0a, 0x24, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2f, 0x69, 0x6e, 0x74, 0x65,
  115. 0x72, 0x6e, 0x65, 0x74, 0x2f, 0x64, 0x74, 0x6c, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67,
  116. 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x22, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f,
  117. 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x69, 0x6e, 0x74,
  118. 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x64, 0x74, 0x6c, 0x73, 0x1a, 0x20, 0x63, 0x6f, 0x6d, 0x6d,
  119. 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x65, 0x78, 0x74, 0x2f, 0x65, 0x78, 0x74, 0x65,
  120. 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xbf, 0x01, 0x0a,
  121. 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x40, 0x0a, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x18,
  122. 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f,
  123. 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x69, 0x6e, 0x74,
  124. 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x64, 0x74, 0x6c, 0x73, 0x2e, 0x44, 0x54, 0x4c, 0x53, 0x4d,
  125. 0x6f, 0x64, 0x65, 0x52, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x70, 0x73, 0x6b,
  126. 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x70, 0x73, 0x6b, 0x12, 0x10, 0x0a, 0x03, 0x6d,
  127. 0x74, 0x75, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x6d, 0x74, 0x75, 0x12, 0x38, 0x0a,
  128. 0x18, 0x72, 0x65, 0x70, 0x6c, 0x61, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x65, 0x63, 0x74, 0x69,
  129. 0x6f, 0x6e, 0x5f, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52,
  130. 0x16, 0x72, 0x65, 0x70, 0x6c, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x65, 0x63, 0x74, 0x69, 0x6f,
  131. 0x6e, 0x57, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x3a, 0x15, 0x82, 0xb5, 0x18, 0x11, 0x0a, 0x09, 0x74,
  132. 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x04, 0x64, 0x74, 0x6c, 0x73, 0x2a, 0x20,
  133. 0x0a, 0x08, 0x44, 0x54, 0x4c, 0x53, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x49, 0x4e,
  134. 0x56, 0x41, 0x4c, 0x49, 0x44, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x50, 0x53, 0x4b, 0x10, 0x01,
  135. 0x42, 0x87, 0x01, 0x0a, 0x26, 0x63, 0x6f, 0x6d, 0x2e, 0x76, 0x32, 0x72, 0x61, 0x79, 0x2e, 0x63,
  136. 0x6f, 0x72, 0x65, 0x2e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x69, 0x6e,
  137. 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x64, 0x74, 0x6c, 0x73, 0x50, 0x01, 0x5a, 0x36, 0x67,
  138. 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x76, 0x32, 0x66, 0x6c, 0x79, 0x2f,
  139. 0x76, 0x32, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x76, 0x35, 0x2f, 0x74, 0x72,
  140. 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x65, 0x74,
  141. 0x2f, 0x64, 0x74, 0x6c, 0x73, 0xaa, 0x02, 0x22, 0x56, 0x32, 0x52, 0x61, 0x79, 0x2e, 0x43, 0x6f,
  142. 0x72, 0x65, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x49, 0x6e, 0x74,
  143. 0x65, 0x72, 0x6e, 0x65, 0x74, 0x2e, 0x44, 0x74, 0x6c, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
  144. 0x6f, 0x33,
  145. }
  146. var (
  147. file_transport_internet_dtls_config_proto_rawDescOnce sync.Once
  148. file_transport_internet_dtls_config_proto_rawDescData = file_transport_internet_dtls_config_proto_rawDesc
  149. )
  150. func file_transport_internet_dtls_config_proto_rawDescGZIP() []byte {
  151. file_transport_internet_dtls_config_proto_rawDescOnce.Do(func() {
  152. file_transport_internet_dtls_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_transport_internet_dtls_config_proto_rawDescData)
  153. })
  154. return file_transport_internet_dtls_config_proto_rawDescData
  155. }
  156. var file_transport_internet_dtls_config_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  157. var file_transport_internet_dtls_config_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
  158. var file_transport_internet_dtls_config_proto_goTypes = []any{
  159. (DTLSMode)(0), // 0: v2ray.core.transport.internet.dtls.DTLSMode
  160. (*Config)(nil), // 1: v2ray.core.transport.internet.dtls.Config
  161. }
  162. var file_transport_internet_dtls_config_proto_depIdxs = []int32{
  163. 0, // 0: v2ray.core.transport.internet.dtls.Config.mode:type_name -> v2ray.core.transport.internet.dtls.DTLSMode
  164. 1, // [1:1] is the sub-list for method output_type
  165. 1, // [1:1] is the sub-list for method input_type
  166. 1, // [1:1] is the sub-list for extension type_name
  167. 1, // [1:1] is the sub-list for extension extendee
  168. 0, // [0:1] is the sub-list for field type_name
  169. }
  170. func init() { file_transport_internet_dtls_config_proto_init() }
  171. func file_transport_internet_dtls_config_proto_init() {
  172. if File_transport_internet_dtls_config_proto != nil {
  173. return
  174. }
  175. if !protoimpl.UnsafeEnabled {
  176. file_transport_internet_dtls_config_proto_msgTypes[0].Exporter = func(v any, i int) any {
  177. switch v := v.(*Config); i {
  178. case 0:
  179. return &v.state
  180. case 1:
  181. return &v.sizeCache
  182. case 2:
  183. return &v.unknownFields
  184. default:
  185. return nil
  186. }
  187. }
  188. }
  189. type x struct{}
  190. out := protoimpl.TypeBuilder{
  191. File: protoimpl.DescBuilder{
  192. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  193. RawDescriptor: file_transport_internet_dtls_config_proto_rawDesc,
  194. NumEnums: 1,
  195. NumMessages: 1,
  196. NumExtensions: 0,
  197. NumServices: 0,
  198. },
  199. GoTypes: file_transport_internet_dtls_config_proto_goTypes,
  200. DependencyIndexes: file_transport_internet_dtls_config_proto_depIdxs,
  201. EnumInfos: file_transport_internet_dtls_config_proto_enumTypes,
  202. MessageInfos: file_transport_internet_dtls_config_proto_msgTypes,
  203. }.Build()
  204. File_transport_internet_dtls_config_proto = out.File
  205. file_transport_internet_dtls_config_proto_rawDesc = nil
  206. file_transport_internet_dtls_config_proto_goTypes = nil
  207. file_transport_internet_dtls_config_proto_depIdxs = nil
  208. }