config.pb.go 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.35.1
  4. // protoc v5.28.2
  5. // source: proxy/shadowsocks/config.proto
  6. package shadowsocks
  7. import (
  8. net "github.com/xtls/xray-core/common/net"
  9. protocol "github.com/xtls/xray-core/common/protocol"
  10. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  11. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  12. reflect "reflect"
  13. sync "sync"
  14. )
  15. const (
  16. // Verify that this generated code is sufficiently up-to-date.
  17. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  18. // Verify that runtime/protoimpl is sufficiently up-to-date.
  19. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  20. )
  21. type CipherType int32
  22. const (
  23. CipherType_UNKNOWN CipherType = 0
  24. CipherType_AES_128_GCM CipherType = 5
  25. CipherType_AES_256_GCM CipherType = 6
  26. CipherType_CHACHA20_POLY1305 CipherType = 7
  27. CipherType_XCHACHA20_POLY1305 CipherType = 8
  28. CipherType_NONE CipherType = 9
  29. )
  30. // Enum value maps for CipherType.
  31. var (
  32. CipherType_name = map[int32]string{
  33. 0: "UNKNOWN",
  34. 5: "AES_128_GCM",
  35. 6: "AES_256_GCM",
  36. 7: "CHACHA20_POLY1305",
  37. 8: "XCHACHA20_POLY1305",
  38. 9: "NONE",
  39. }
  40. CipherType_value = map[string]int32{
  41. "UNKNOWN": 0,
  42. "AES_128_GCM": 5,
  43. "AES_256_GCM": 6,
  44. "CHACHA20_POLY1305": 7,
  45. "XCHACHA20_POLY1305": 8,
  46. "NONE": 9,
  47. }
  48. )
  49. func (x CipherType) Enum() *CipherType {
  50. p := new(CipherType)
  51. *p = x
  52. return p
  53. }
  54. func (x CipherType) String() string {
  55. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  56. }
  57. func (CipherType) Descriptor() protoreflect.EnumDescriptor {
  58. return file_proxy_shadowsocks_config_proto_enumTypes[0].Descriptor()
  59. }
  60. func (CipherType) Type() protoreflect.EnumType {
  61. return &file_proxy_shadowsocks_config_proto_enumTypes[0]
  62. }
  63. func (x CipherType) Number() protoreflect.EnumNumber {
  64. return protoreflect.EnumNumber(x)
  65. }
  66. // Deprecated: Use CipherType.Descriptor instead.
  67. func (CipherType) EnumDescriptor() ([]byte, []int) {
  68. return file_proxy_shadowsocks_config_proto_rawDescGZIP(), []int{0}
  69. }
  70. type Account struct {
  71. state protoimpl.MessageState
  72. sizeCache protoimpl.SizeCache
  73. unknownFields protoimpl.UnknownFields
  74. Password string `protobuf:"bytes,1,opt,name=password,proto3" json:"password,omitempty"`
  75. CipherType CipherType `protobuf:"varint,2,opt,name=cipher_type,json=cipherType,proto3,enum=xray.proxy.shadowsocks.CipherType" json:"cipher_type,omitempty"`
  76. IvCheck bool `protobuf:"varint,3,opt,name=iv_check,json=ivCheck,proto3" json:"iv_check,omitempty"`
  77. }
  78. func (x *Account) Reset() {
  79. *x = Account{}
  80. mi := &file_proxy_shadowsocks_config_proto_msgTypes[0]
  81. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  82. ms.StoreMessageInfo(mi)
  83. }
  84. func (x *Account) String() string {
  85. return protoimpl.X.MessageStringOf(x)
  86. }
  87. func (*Account) ProtoMessage() {}
  88. func (x *Account) ProtoReflect() protoreflect.Message {
  89. mi := &file_proxy_shadowsocks_config_proto_msgTypes[0]
  90. if x != nil {
  91. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  92. if ms.LoadMessageInfo() == nil {
  93. ms.StoreMessageInfo(mi)
  94. }
  95. return ms
  96. }
  97. return mi.MessageOf(x)
  98. }
  99. // Deprecated: Use Account.ProtoReflect.Descriptor instead.
  100. func (*Account) Descriptor() ([]byte, []int) {
  101. return file_proxy_shadowsocks_config_proto_rawDescGZIP(), []int{0}
  102. }
  103. func (x *Account) GetPassword() string {
  104. if x != nil {
  105. return x.Password
  106. }
  107. return ""
  108. }
  109. func (x *Account) GetCipherType() CipherType {
  110. if x != nil {
  111. return x.CipherType
  112. }
  113. return CipherType_UNKNOWN
  114. }
  115. func (x *Account) GetIvCheck() bool {
  116. if x != nil {
  117. return x.IvCheck
  118. }
  119. return false
  120. }
  121. type ServerConfig struct {
  122. state protoimpl.MessageState
  123. sizeCache protoimpl.SizeCache
  124. unknownFields protoimpl.UnknownFields
  125. Users []*protocol.User `protobuf:"bytes,1,rep,name=users,proto3" json:"users,omitempty"`
  126. Network []net.Network `protobuf:"varint,2,rep,packed,name=network,proto3,enum=xray.common.net.Network" json:"network,omitempty"`
  127. }
  128. func (x *ServerConfig) Reset() {
  129. *x = ServerConfig{}
  130. mi := &file_proxy_shadowsocks_config_proto_msgTypes[1]
  131. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  132. ms.StoreMessageInfo(mi)
  133. }
  134. func (x *ServerConfig) String() string {
  135. return protoimpl.X.MessageStringOf(x)
  136. }
  137. func (*ServerConfig) ProtoMessage() {}
  138. func (x *ServerConfig) ProtoReflect() protoreflect.Message {
  139. mi := &file_proxy_shadowsocks_config_proto_msgTypes[1]
  140. if x != nil {
  141. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  142. if ms.LoadMessageInfo() == nil {
  143. ms.StoreMessageInfo(mi)
  144. }
  145. return ms
  146. }
  147. return mi.MessageOf(x)
  148. }
  149. // Deprecated: Use ServerConfig.ProtoReflect.Descriptor instead.
  150. func (*ServerConfig) Descriptor() ([]byte, []int) {
  151. return file_proxy_shadowsocks_config_proto_rawDescGZIP(), []int{1}
  152. }
  153. func (x *ServerConfig) GetUsers() []*protocol.User {
  154. if x != nil {
  155. return x.Users
  156. }
  157. return nil
  158. }
  159. func (x *ServerConfig) GetNetwork() []net.Network {
  160. if x != nil {
  161. return x.Network
  162. }
  163. return nil
  164. }
  165. type ClientConfig struct {
  166. state protoimpl.MessageState
  167. sizeCache protoimpl.SizeCache
  168. unknownFields protoimpl.UnknownFields
  169. Server []*protocol.ServerEndpoint `protobuf:"bytes,1,rep,name=server,proto3" json:"server,omitempty"`
  170. }
  171. func (x *ClientConfig) Reset() {
  172. *x = ClientConfig{}
  173. mi := &file_proxy_shadowsocks_config_proto_msgTypes[2]
  174. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  175. ms.StoreMessageInfo(mi)
  176. }
  177. func (x *ClientConfig) String() string {
  178. return protoimpl.X.MessageStringOf(x)
  179. }
  180. func (*ClientConfig) ProtoMessage() {}
  181. func (x *ClientConfig) ProtoReflect() protoreflect.Message {
  182. mi := &file_proxy_shadowsocks_config_proto_msgTypes[2]
  183. if x != nil {
  184. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  185. if ms.LoadMessageInfo() == nil {
  186. ms.StoreMessageInfo(mi)
  187. }
  188. return ms
  189. }
  190. return mi.MessageOf(x)
  191. }
  192. // Deprecated: Use ClientConfig.ProtoReflect.Descriptor instead.
  193. func (*ClientConfig) Descriptor() ([]byte, []int) {
  194. return file_proxy_shadowsocks_config_proto_rawDescGZIP(), []int{2}
  195. }
  196. func (x *ClientConfig) GetServer() []*protocol.ServerEndpoint {
  197. if x != nil {
  198. return x.Server
  199. }
  200. return nil
  201. }
  202. var File_proxy_shadowsocks_config_proto protoreflect.FileDescriptor
  203. var file_proxy_shadowsocks_config_proto_rawDesc = []byte{
  204. 0x0a, 0x1e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x73, 0x68, 0x61, 0x64, 0x6f, 0x77, 0x73, 0x6f,
  205. 0x63, 0x6b, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  206. 0x12, 0x16, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x73, 0x68, 0x61,
  207. 0x64, 0x6f, 0x77, 0x73, 0x6f, 0x63, 0x6b, 0x73, 0x1a, 0x18, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e,
  208. 0x2f, 0x6e, 0x65, 0x74, 0x2f, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2e, 0x70, 0x72, 0x6f,
  209. 0x74, 0x6f, 0x1a, 0x1a, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  210. 0x63, 0x6f, 0x6c, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x21,
  211. 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f,
  212. 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x73, 0x70, 0x65, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74,
  213. 0x6f, 0x22, 0x85, 0x01, 0x0a, 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1a, 0x0a,
  214. 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
  215. 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x43, 0x0a, 0x0b, 0x63, 0x69, 0x70,
  216. 0x68, 0x65, 0x72, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x22,
  217. 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x73, 0x68, 0x61, 0x64,
  218. 0x6f, 0x77, 0x73, 0x6f, 0x63, 0x6b, 0x73, 0x2e, 0x43, 0x69, 0x70, 0x68, 0x65, 0x72, 0x54, 0x79,
  219. 0x70, 0x65, 0x52, 0x0a, 0x63, 0x69, 0x70, 0x68, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x19,
  220. 0x0a, 0x08, 0x69, 0x76, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08,
  221. 0x52, 0x07, 0x69, 0x76, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x22, 0x74, 0x0a, 0x0c, 0x53, 0x65, 0x72,
  222. 0x76, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x30, 0x0a, 0x05, 0x75, 0x73, 0x65,
  223. 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e,
  224. 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2e,
  225. 0x55, 0x73, 0x65, 0x72, 0x52, 0x05, 0x75, 0x73, 0x65, 0x72, 0x73, 0x12, 0x32, 0x0a, 0x07, 0x6e,
  226. 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x78,
  227. 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2e, 0x4e,
  228. 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x22,
  229. 0x4c, 0x0a, 0x0c, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12,
  230. 0x3c, 0x0a, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
  231. 0x24, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72,
  232. 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x45, 0x6e, 0x64,
  233. 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2a, 0x74, 0x0a,
  234. 0x0a, 0x43, 0x69, 0x70, 0x68, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x55,
  235. 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b, 0x41, 0x45, 0x53, 0x5f,
  236. 0x31, 0x32, 0x38, 0x5f, 0x47, 0x43, 0x4d, 0x10, 0x05, 0x12, 0x0f, 0x0a, 0x0b, 0x41, 0x45, 0x53,
  237. 0x5f, 0x32, 0x35, 0x36, 0x5f, 0x47, 0x43, 0x4d, 0x10, 0x06, 0x12, 0x15, 0x0a, 0x11, 0x43, 0x48,
  238. 0x41, 0x43, 0x48, 0x41, 0x32, 0x30, 0x5f, 0x50, 0x4f, 0x4c, 0x59, 0x31, 0x33, 0x30, 0x35, 0x10,
  239. 0x07, 0x12, 0x16, 0x0a, 0x12, 0x58, 0x43, 0x48, 0x41, 0x43, 0x48, 0x41, 0x32, 0x30, 0x5f, 0x50,
  240. 0x4f, 0x4c, 0x59, 0x31, 0x33, 0x30, 0x35, 0x10, 0x08, 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x4f, 0x4e,
  241. 0x45, 0x10, 0x09, 0x42, 0x64, 0x0a, 0x1a, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e,
  242. 0x70, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x73, 0x68, 0x61, 0x64, 0x6f, 0x77, 0x73, 0x6f, 0x63, 0x6b,
  243. 0x73, 0x50, 0x01, 0x5a, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
  244. 0x78, 0x74, 0x6c, 0x73, 0x2f, 0x78, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x70,
  245. 0x72, 0x6f, 0x78, 0x79, 0x2f, 0x73, 0x68, 0x61, 0x64, 0x6f, 0x77, 0x73, 0x6f, 0x63, 0x6b, 0x73,
  246. 0xaa, 0x02, 0x16, 0x58, 0x72, 0x61, 0x79, 0x2e, 0x50, 0x72, 0x6f, 0x78, 0x79, 0x2e, 0x53, 0x68,
  247. 0x61, 0x64, 0x6f, 0x77, 0x73, 0x6f, 0x63, 0x6b, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  248. 0x33,
  249. }
  250. var (
  251. file_proxy_shadowsocks_config_proto_rawDescOnce sync.Once
  252. file_proxy_shadowsocks_config_proto_rawDescData = file_proxy_shadowsocks_config_proto_rawDesc
  253. )
  254. func file_proxy_shadowsocks_config_proto_rawDescGZIP() []byte {
  255. file_proxy_shadowsocks_config_proto_rawDescOnce.Do(func() {
  256. file_proxy_shadowsocks_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_proxy_shadowsocks_config_proto_rawDescData)
  257. })
  258. return file_proxy_shadowsocks_config_proto_rawDescData
  259. }
  260. var file_proxy_shadowsocks_config_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  261. var file_proxy_shadowsocks_config_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
  262. var file_proxy_shadowsocks_config_proto_goTypes = []any{
  263. (CipherType)(0), // 0: xray.proxy.shadowsocks.CipherType
  264. (*Account)(nil), // 1: xray.proxy.shadowsocks.Account
  265. (*ServerConfig)(nil), // 2: xray.proxy.shadowsocks.ServerConfig
  266. (*ClientConfig)(nil), // 3: xray.proxy.shadowsocks.ClientConfig
  267. (*protocol.User)(nil), // 4: xray.common.protocol.User
  268. (net.Network)(0), // 5: xray.common.net.Network
  269. (*protocol.ServerEndpoint)(nil), // 6: xray.common.protocol.ServerEndpoint
  270. }
  271. var file_proxy_shadowsocks_config_proto_depIdxs = []int32{
  272. 0, // 0: xray.proxy.shadowsocks.Account.cipher_type:type_name -> xray.proxy.shadowsocks.CipherType
  273. 4, // 1: xray.proxy.shadowsocks.ServerConfig.users:type_name -> xray.common.protocol.User
  274. 5, // 2: xray.proxy.shadowsocks.ServerConfig.network:type_name -> xray.common.net.Network
  275. 6, // 3: xray.proxy.shadowsocks.ClientConfig.server:type_name -> xray.common.protocol.ServerEndpoint
  276. 4, // [4:4] is the sub-list for method output_type
  277. 4, // [4:4] is the sub-list for method input_type
  278. 4, // [4:4] is the sub-list for extension type_name
  279. 4, // [4:4] is the sub-list for extension extendee
  280. 0, // [0:4] is the sub-list for field type_name
  281. }
  282. func init() { file_proxy_shadowsocks_config_proto_init() }
  283. func file_proxy_shadowsocks_config_proto_init() {
  284. if File_proxy_shadowsocks_config_proto != nil {
  285. return
  286. }
  287. type x struct{}
  288. out := protoimpl.TypeBuilder{
  289. File: protoimpl.DescBuilder{
  290. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  291. RawDescriptor: file_proxy_shadowsocks_config_proto_rawDesc,
  292. NumEnums: 1,
  293. NumMessages: 3,
  294. NumExtensions: 0,
  295. NumServices: 0,
  296. },
  297. GoTypes: file_proxy_shadowsocks_config_proto_goTypes,
  298. DependencyIndexes: file_proxy_shadowsocks_config_proto_depIdxs,
  299. EnumInfos: file_proxy_shadowsocks_config_proto_enumTypes,
  300. MessageInfos: file_proxy_shadowsocks_config_proto_msgTypes,
  301. }.Build()
  302. File_proxy_shadowsocks_config_proto = out.File
  303. file_proxy_shadowsocks_config_proto_rawDesc = nil
  304. file_proxy_shadowsocks_config_proto_goTypes = nil
  305. file_proxy_shadowsocks_config_proto_depIdxs = nil
  306. }