config.pb.go 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. package socks
  2. import proto "github.com/golang/protobuf/proto"
  3. import fmt "fmt"
  4. import math "math"
  5. import v2ray_core_common_net "v2ray.com/core/common/net"
  6. import v2ray_core_common_protocol1 "v2ray.com/core/common/protocol"
  7. // Reference imports to suppress errors if they are not otherwise used.
  8. var _ = proto.Marshal
  9. var _ = fmt.Errorf
  10. var _ = math.Inf
  11. // This is a compile-time assertion to ensure that this generated file
  12. // is compatible with the proto package it is being compiled against.
  13. // A compilation error at this line likely means your copy of the
  14. // proto package needs to be updated.
  15. const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
  16. type AuthType int32
  17. const (
  18. AuthType_NO_AUTH AuthType = 0
  19. AuthType_PASSWORD AuthType = 1
  20. )
  21. var AuthType_name = map[int32]string{
  22. 0: "NO_AUTH",
  23. 1: "PASSWORD",
  24. }
  25. var AuthType_value = map[string]int32{
  26. "NO_AUTH": 0,
  27. "PASSWORD": 1,
  28. }
  29. func (x AuthType) String() string {
  30. return proto.EnumName(AuthType_name, int32(x))
  31. }
  32. func (AuthType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
  33. type Account struct {
  34. Username string `protobuf:"bytes,1,opt,name=username" json:"username,omitempty"`
  35. Password string `protobuf:"bytes,2,opt,name=password" json:"password,omitempty"`
  36. }
  37. func (m *Account) Reset() { *m = Account{} }
  38. func (m *Account) String() string { return proto.CompactTextString(m) }
  39. func (*Account) ProtoMessage() {}
  40. func (*Account) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
  41. func (m *Account) GetUsername() string {
  42. if m != nil {
  43. return m.Username
  44. }
  45. return ""
  46. }
  47. func (m *Account) GetPassword() string {
  48. if m != nil {
  49. return m.Password
  50. }
  51. return ""
  52. }
  53. type ServerConfig struct {
  54. AuthType AuthType `protobuf:"varint,1,opt,name=auth_type,json=authType,enum=v2ray.core.proxy.socks.AuthType" json:"auth_type,omitempty"`
  55. Accounts map[string]string `protobuf:"bytes,2,rep,name=accounts" json:"accounts,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
  56. Address *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,3,opt,name=address" json:"address,omitempty"`
  57. UdpEnabled bool `protobuf:"varint,4,opt,name=udp_enabled,json=udpEnabled" json:"udp_enabled,omitempty"`
  58. Timeout uint32 `protobuf:"varint,5,opt,name=timeout" json:"timeout,omitempty"`
  59. UserLevel uint32 `protobuf:"varint,6,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
  60. }
  61. func (m *ServerConfig) Reset() { *m = ServerConfig{} }
  62. func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
  63. func (*ServerConfig) ProtoMessage() {}
  64. func (*ServerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
  65. func (m *ServerConfig) GetAuthType() AuthType {
  66. if m != nil {
  67. return m.AuthType
  68. }
  69. return AuthType_NO_AUTH
  70. }
  71. func (m *ServerConfig) GetAccounts() map[string]string {
  72. if m != nil {
  73. return m.Accounts
  74. }
  75. return nil
  76. }
  77. func (m *ServerConfig) GetAddress() *v2ray_core_common_net.IPOrDomain {
  78. if m != nil {
  79. return m.Address
  80. }
  81. return nil
  82. }
  83. func (m *ServerConfig) GetUdpEnabled() bool {
  84. if m != nil {
  85. return m.UdpEnabled
  86. }
  87. return false
  88. }
  89. func (m *ServerConfig) GetTimeout() uint32 {
  90. if m != nil {
  91. return m.Timeout
  92. }
  93. return 0
  94. }
  95. func (m *ServerConfig) GetUserLevel() uint32 {
  96. if m != nil {
  97. return m.UserLevel
  98. }
  99. return 0
  100. }
  101. type ClientConfig struct {
  102. Server []*v2ray_core_common_protocol1.ServerEndpoint `protobuf:"bytes,1,rep,name=server" json:"server,omitempty"`
  103. }
  104. func (m *ClientConfig) Reset() { *m = ClientConfig{} }
  105. func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
  106. func (*ClientConfig) ProtoMessage() {}
  107. func (*ClientConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
  108. func (m *ClientConfig) GetServer() []*v2ray_core_common_protocol1.ServerEndpoint {
  109. if m != nil {
  110. return m.Server
  111. }
  112. return nil
  113. }
  114. func init() {
  115. proto.RegisterType((*Account)(nil), "v2ray.core.proxy.socks.Account")
  116. proto.RegisterType((*ServerConfig)(nil), "v2ray.core.proxy.socks.ServerConfig")
  117. proto.RegisterType((*ClientConfig)(nil), "v2ray.core.proxy.socks.ClientConfig")
  118. proto.RegisterEnum("v2ray.core.proxy.socks.AuthType", AuthType_name, AuthType_value)
  119. }
  120. func init() { proto.RegisterFile("v2ray.com/core/proxy/socks/config.proto", fileDescriptor0) }
  121. var fileDescriptor0 = []byte{
  122. // 470 bytes of a gzipped FileDescriptorProto
  123. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x52, 0x5d, 0x8b, 0xd3, 0x40,
  124. 0x14, 0x75, 0xb2, 0xb6, 0x4d, 0x6f, 0xbb, 0x52, 0x06, 0x59, 0x42, 0x51, 0x8c, 0x05, 0xb1, 0xec,
  125. 0xc3, 0x44, 0xe2, 0x8b, 0xb8, 0x28, 0xb4, 0xdd, 0x82, 0x82, 0x6c, 0xcb, 0x74, 0x55, 0xf0, 0x25,
  126. 0xcc, 0x4e, 0x46, 0x37, 0x6c, 0x32, 0x13, 0x66, 0x26, 0xd5, 0xfc, 0x25, 0xff, 0x9f, 0xef, 0x92,
  127. 0xaf, 0x65, 0x95, 0xee, 0xdb, 0xfd, 0x38, 0xf7, 0xcc, 0x3d, 0xe7, 0x0e, 0xbc, 0xdc, 0x87, 0x9a,
  128. 0x95, 0x84, 0xab, 0x2c, 0xe0, 0x4a, 0x8b, 0x20, 0xd7, 0xea, 0x57, 0x19, 0x18, 0xc5, 0x6f, 0x4c,
  129. 0xc0, 0x95, 0xfc, 0x9e, 0xfc, 0x20, 0xb9, 0x56, 0x56, 0xe1, 0x93, 0x0e, 0xa8, 0x05, 0xa9, 0x41,
  130. 0xa4, 0x06, 0x4d, 0xff, 0x27, 0xe0, 0x2a, 0xcb, 0x94, 0x0c, 0xa4, 0xb0, 0x01, 0x8b, 0x63, 0x2d,
  131. 0x8c, 0x69, 0x08, 0xa6, 0xaf, 0x0e, 0x03, 0xeb, 0x26, 0x57, 0x69, 0x60, 0x84, 0xde, 0x0b, 0x1d,
  132. 0x99, 0x5c, 0xf0, 0x66, 0x62, 0xb6, 0x80, 0xc1, 0x82, 0x73, 0x55, 0x48, 0x8b, 0xa7, 0xe0, 0x16,
  133. 0x46, 0x68, 0xc9, 0x32, 0xe1, 0x21, 0x1f, 0xcd, 0x87, 0xf4, 0x36, 0xaf, 0x7a, 0x39, 0x33, 0xe6,
  134. 0xa7, 0xd2, 0xb1, 0xe7, 0x34, 0xbd, 0x2e, 0x9f, 0xfd, 0x71, 0x60, 0xbc, 0xab, 0x89, 0x57, 0xb5,
  135. 0x18, 0xfc, 0x0e, 0x86, 0xac, 0xb0, 0xd7, 0x91, 0x2d, 0xf3, 0x86, 0xe9, 0x51, 0xe8, 0x93, 0xc3,
  136. 0xd2, 0xc8, 0xa2, 0xb0, 0xd7, 0x97, 0x65, 0x2e, 0xa8, 0xcb, 0xda, 0x08, 0x5f, 0x80, 0xcb, 0x9a,
  137. 0x95, 0x8c, 0xe7, 0xf8, 0x47, 0xf3, 0x51, 0x18, 0xde, 0x37, 0x7d, 0xf7, 0x59, 0xd2, 0xea, 0x30,
  138. 0x6b, 0x69, 0x75, 0x49, 0x6f, 0x39, 0xf0, 0x19, 0x0c, 0x5a, 0x97, 0xbc, 0x23, 0x1f, 0xcd, 0x47,
  139. 0xe1, 0xf3, 0xbb, 0x74, 0x8d, 0x45, 0x44, 0x0a, 0x4b, 0x3e, 0x6e, 0x37, 0xfa, 0x5c, 0x65, 0x2c,
  140. 0x91, 0xb4, 0x9b, 0xc0, 0xcf, 0x60, 0x54, 0xc4, 0x79, 0x24, 0x24, 0xbb, 0x4a, 0x45, 0xec, 0x3d,
  141. 0xf4, 0xd1, 0xdc, 0xa5, 0x50, 0xc4, 0xf9, 0xba, 0xa9, 0xe0, 0x27, 0x30, 0xb0, 0x49, 0x26, 0x54,
  142. 0x61, 0xbd, 0x9e, 0x8f, 0xe6, 0xc7, 0x4b, 0xc7, 0x43, 0xb4, 0x2b, 0xe1, 0xa7, 0x00, 0x95, 0x87,
  143. 0x51, 0x2a, 0xf6, 0x22, 0xf5, 0xfa, 0x15, 0x80, 0x0e, 0xab, 0xca, 0xa7, 0xaa, 0x30, 0x3d, 0x83,
  144. 0xe3, 0x7f, 0xb6, 0xc6, 0x13, 0x38, 0xba, 0x11, 0x65, 0x6b, 0x7f, 0x15, 0xe2, 0xc7, 0xd0, 0xdb,
  145. 0xb3, 0xb4, 0x10, 0xad, 0xed, 0x4d, 0xf2, 0xd6, 0x79, 0x83, 0x66, 0x14, 0xc6, 0xab, 0x34, 0x11,
  146. 0xd2, 0xb6, 0xb6, 0x2f, 0xa1, 0xdf, 0xdc, 0xd7, 0x43, 0xb5, 0x6b, 0xa7, 0x07, 0x64, 0x76, 0x3f,
  147. 0xa1, 0x75, 0x6e, 0x2d, 0xe3, 0x5c, 0x25, 0xd2, 0xd2, 0x76, 0xf2, 0xf4, 0x05, 0xb8, 0xdd, 0x45,
  148. 0xf0, 0x08, 0x06, 0x17, 0x9b, 0x68, 0xf1, 0xf9, 0xf2, 0xc3, 0xe4, 0x01, 0x1e, 0x83, 0xbb, 0x5d,
  149. 0xec, 0x76, 0x5f, 0x37, 0xf4, 0x7c, 0x82, 0x96, 0xef, 0x61, 0xca, 0x55, 0x76, 0xcf, 0x55, 0xb6,
  150. 0xe8, 0x5b, 0xaf, 0x0e, 0x7e, 0x3b, 0x27, 0x5f, 0x42, 0xca, 0x4a, 0xb2, 0xaa, 0x10, 0xdb, 0x1a,
  151. 0xb1, 0xab, 0x1a, 0x57, 0xfd, 0x7a, 0x8f, 0xd7, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x23, 0xac,
  152. 0x72, 0x71, 0x1a, 0x03, 0x00, 0x00,
  153. }