re-generate code

This commit is contained in:
Darien Raymond 2018-05-25 11:56:01 +02:00
parent 12106cddae
commit 68da956fc4
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
72 changed files with 3496 additions and 956 deletions

View File

@ -3,7 +3,7 @@ package commander
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -21,13 +21,35 @@ type Config struct {
// Tag of the outbound handler that handles grpc connections.
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
// Services that supported by this server. All services must implement Service interface.
Service []*v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,rep,name=service" json:"service,omitempty"`
Service []*serial.TypedMessage `protobuf:"bytes,2,rep,name=service" json:"service,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_81dbee9f112d6327, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetTag() string {
if m != nil {
@ -36,7 +58,7 @@ func (m *Config) GetTag() string {
return ""
}
func (m *Config) GetService() []*v2ray_core_common_serial.TypedMessage {
func (m *Config) GetService() []*serial.TypedMessage {
if m != nil {
return m.Service
}
@ -47,9 +69,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.app.commander.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/app/commander/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/commander/config.proto", fileDescriptor_config_81dbee9f112d6327)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_81dbee9f112d6327 = []byte{
// 212 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2c, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0x2c, 0x28, 0xd0, 0x4f,

View File

@ -2,4 +2,6 @@ package commander
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Commander") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Commander")
}

View File

@ -16,21 +16,65 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type SessionConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SessionConfig) Reset() { *m = SessionConfig{} }
func (m *SessionConfig) String() string { return proto.CompactTextString(m) }
func (*SessionConfig) ProtoMessage() {}
func (*SessionConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *SessionConfig) Reset() { *m = SessionConfig{} }
func (m *SessionConfig) String() string { return proto.CompactTextString(m) }
func (*SessionConfig) ProtoMessage() {}
func (*SessionConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_b04006b660896589, []int{0}
}
func (m *SessionConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SessionConfig.Unmarshal(m, b)
}
func (m *SessionConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SessionConfig.Marshal(b, m, deterministic)
}
func (dst *SessionConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_SessionConfig.Merge(dst, src)
}
func (m *SessionConfig) XXX_Size() int {
return xxx_messageInfo_SessionConfig.Size(m)
}
func (m *SessionConfig) XXX_DiscardUnknown() {
xxx_messageInfo_SessionConfig.DiscardUnknown(m)
}
var xxx_messageInfo_SessionConfig proto.InternalMessageInfo
type Config struct {
Settings *SessionConfig `protobuf:"bytes,1,opt,name=settings" json:"settings,omitempty"`
Settings *SessionConfig `protobuf:"bytes,1,opt,name=settings" json:"settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_b04006b660896589, []int{1}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetSettings() *SessionConfig {
if m != nil {
@ -44,9 +88,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.app.dispatcher.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/app/dispatcher/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/dispatcher/config.proto", fileDescriptor_config_b04006b660896589)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_b04006b660896589 = []byte{
// 176 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2a, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0x2c, 0x28, 0xd0, 0x4f,

View File

@ -2,4 +2,6 @@ package dispatcher
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Dispatcher") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Dispatcher")
}

View File

@ -3,8 +3,7 @@ package dns
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_net2 "v2ray.com/core/common/net"
import net "v2ray.com/core/common/net"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -20,24 +19,46 @@ const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
// Nameservers used by this DNS. Only traditional UDP servers are support at the moment.
// A special value 'localhost' as a domain address can be set to use DNS on local system.
NameServers []*v2ray_core_common_net2.Endpoint `protobuf:"bytes,1,rep,name=NameServers" json:"NameServers,omitempty"`
NameServers []*net.Endpoint `protobuf:"bytes,1,rep,name=NameServers" json:"NameServers,omitempty"`
// Static hosts. Domain to IP.
Hosts map[string]*v2ray_core_common_net.IPOrDomain `protobuf:"bytes,2,rep,name=Hosts" json:"Hosts,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
Hosts map[string]*net.IPOrDomain `protobuf:"bytes,2,rep,name=Hosts" json:"Hosts,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_862435acfeec6b70, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetNameServers() []*v2ray_core_common_net2.Endpoint {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetNameServers() []*net.Endpoint {
if m != nil {
return m.NameServers
}
return nil
}
func (m *Config) GetHosts() map[string]*v2ray_core_common_net.IPOrDomain {
func (m *Config) GetHosts() map[string]*net.IPOrDomain {
if m != nil {
return m.Hosts
}
@ -46,11 +67,14 @@ func (m *Config) GetHosts() map[string]*v2ray_core_common_net.IPOrDomain {
func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.app.dns.Config")
proto.RegisterMapType((map[string]*net.IPOrDomain)(nil), "v2ray.core.app.dns.Config.HostsEntry")
}
func init() { proto.RegisterFile("v2ray.com/core/app/dns/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/dns/config.proto", fileDescriptor_config_862435acfeec6b70)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_862435acfeec6b70 = []byte{
// 286 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x90, 0x41, 0x4b, 0x33, 0x31,
0x10, 0x86, 0xc9, 0x96, 0x16, 0xbe, 0xf4, 0xf2, 0x91, 0x83, 0x2c, 0xbd, 0x58, 0x15, 0xb1, 0x20,

View File

@ -22,28 +22,94 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_1a9c3df5bed276de, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
type RestartLoggerRequest struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RestartLoggerRequest) Reset() { *m = RestartLoggerRequest{} }
func (m *RestartLoggerRequest) String() string { return proto.CompactTextString(m) }
func (*RestartLoggerRequest) ProtoMessage() {}
func (*RestartLoggerRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *RestartLoggerRequest) Reset() { *m = RestartLoggerRequest{} }
func (m *RestartLoggerRequest) String() string { return proto.CompactTextString(m) }
func (*RestartLoggerRequest) ProtoMessage() {}
func (*RestartLoggerRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_config_1a9c3df5bed276de, []int{1}
}
func (m *RestartLoggerRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RestartLoggerRequest.Unmarshal(m, b)
}
func (m *RestartLoggerRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RestartLoggerRequest.Marshal(b, m, deterministic)
}
func (dst *RestartLoggerRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_RestartLoggerRequest.Merge(dst, src)
}
func (m *RestartLoggerRequest) XXX_Size() int {
return xxx_messageInfo_RestartLoggerRequest.Size(m)
}
func (m *RestartLoggerRequest) XXX_DiscardUnknown() {
xxx_messageInfo_RestartLoggerRequest.DiscardUnknown(m)
}
var xxx_messageInfo_RestartLoggerRequest proto.InternalMessageInfo
type RestartLoggerResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RestartLoggerResponse) Reset() { *m = RestartLoggerResponse{} }
func (m *RestartLoggerResponse) String() string { return proto.CompactTextString(m) }
func (*RestartLoggerResponse) ProtoMessage() {}
func (*RestartLoggerResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *RestartLoggerResponse) Reset() { *m = RestartLoggerResponse{} }
func (m *RestartLoggerResponse) String() string { return proto.CompactTextString(m) }
func (*RestartLoggerResponse) ProtoMessage() {}
func (*RestartLoggerResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_config_1a9c3df5bed276de, []int{2}
}
func (m *RestartLoggerResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RestartLoggerResponse.Unmarshal(m, b)
}
func (m *RestartLoggerResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RestartLoggerResponse.Marshal(b, m, deterministic)
}
func (dst *RestartLoggerResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_RestartLoggerResponse.Merge(dst, src)
}
func (m *RestartLoggerResponse) XXX_Size() int {
return xxx_messageInfo_RestartLoggerResponse.Size(m)
}
func (m *RestartLoggerResponse) XXX_DiscardUnknown() {
xxx_messageInfo_RestartLoggerResponse.DiscardUnknown(m)
}
var xxx_messageInfo_RestartLoggerResponse proto.InternalMessageInfo
func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.app.log.command.Config")
@ -59,8 +125,9 @@ var _ grpc.ClientConn
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// Client API for LoggerService service
// LoggerServiceClient is the client API for LoggerService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type LoggerServiceClient interface {
RestartLogger(ctx context.Context, in *RestartLoggerRequest, opts ...grpc.CallOption) (*RestartLoggerResponse, error)
}
@ -75,15 +142,14 @@ func NewLoggerServiceClient(cc *grpc.ClientConn) LoggerServiceClient {
func (c *loggerServiceClient) RestartLogger(ctx context.Context, in *RestartLoggerRequest, opts ...grpc.CallOption) (*RestartLoggerResponse, error) {
out := new(RestartLoggerResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.log.command.LoggerService/RestartLogger", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.log.command.LoggerService/RestartLogger", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// Server API for LoggerService service
// LoggerServiceServer is the server API for LoggerService service.
type LoggerServiceServer interface {
RestartLogger(context.Context, *RestartLoggerRequest) (*RestartLoggerResponse, error)
}
@ -123,9 +189,11 @@ var _LoggerService_serviceDesc = grpc.ServiceDesc{
Metadata: "v2ray.com/core/app/log/command/config.proto",
}
func init() { proto.RegisterFile("v2ray.com/core/app/log/command/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/log/command/config.proto", fileDescriptor_config_1a9c3df5bed276de)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_1a9c3df5bed276de = []byte{
// 210 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0x2c, 0x28, 0xd0, 0xcf,

View File

@ -3,7 +3,7 @@ package log
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_log "v2ray.com/core/common/log"
import log "v2ray.com/core/common/log"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -41,20 +41,44 @@ var LogType_value = map[string]int32{
func (x LogType) String() string {
return proto.EnumName(LogType_name, int32(x))
}
func (LogType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type Config struct {
ErrorLogType LogType `protobuf:"varint,1,opt,name=error_log_type,json=errorLogType,enum=v2ray.core.app.log.LogType" json:"error_log_type,omitempty"`
ErrorLogLevel v2ray_core_common_log.Severity `protobuf:"varint,2,opt,name=error_log_level,json=errorLogLevel,enum=v2ray.core.common.log.Severity" json:"error_log_level,omitempty"`
ErrorLogPath string `protobuf:"bytes,3,opt,name=error_log_path,json=errorLogPath" json:"error_log_path,omitempty"`
AccessLogType LogType `protobuf:"varint,4,opt,name=access_log_type,json=accessLogType,enum=v2ray.core.app.log.LogType" json:"access_log_type,omitempty"`
AccessLogPath string `protobuf:"bytes,5,opt,name=access_log_path,json=accessLogPath" json:"access_log_path,omitempty"`
func (LogType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_a0f33891648538d2, []int{0}
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type Config struct {
ErrorLogType LogType `protobuf:"varint,1,opt,name=error_log_type,json=errorLogType,enum=v2ray.core.app.log.LogType" json:"error_log_type,omitempty"`
ErrorLogLevel log.Severity `protobuf:"varint,2,opt,name=error_log_level,json=errorLogLevel,enum=v2ray.core.common.log.Severity" json:"error_log_level,omitempty"`
ErrorLogPath string `protobuf:"bytes,3,opt,name=error_log_path,json=errorLogPath" json:"error_log_path,omitempty"`
AccessLogType LogType `protobuf:"varint,4,opt,name=access_log_type,json=accessLogType,enum=v2ray.core.app.log.LogType" json:"access_log_type,omitempty"`
AccessLogPath string `protobuf:"bytes,5,opt,name=access_log_path,json=accessLogPath" json:"access_log_path,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a0f33891648538d2, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetErrorLogType() LogType {
if m != nil {
@ -63,11 +87,11 @@ func (m *Config) GetErrorLogType() LogType {
return LogType_None
}
func (m *Config) GetErrorLogLevel() v2ray_core_common_log.Severity {
func (m *Config) GetErrorLogLevel() log.Severity {
if m != nil {
return m.ErrorLogLevel
}
return v2ray_core_common_log.Severity_Unknown
return log.Severity_Unknown
}
func (m *Config) GetErrorLogPath() string {
@ -96,9 +120,11 @@ func init() {
proto.RegisterEnum("v2ray.core.app.log.LogType", LogType_name, LogType_value)
}
func init() { proto.RegisterFile("v2ray.com/core/app/log/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/log/config.proto", fileDescriptor_config_a0f33891648538d2)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_a0f33891648538d2 = []byte{
// 306 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x91, 0xcd, 0x4a, 0xfb, 0x40,
0x14, 0x47, 0xff, 0x49, 0xbf, 0xfe, 0x1d, 0x6d, 0x1b, 0x66, 0x21, 0x45, 0x17, 0x16, 0x15, 0x29,

View File

@ -3,9 +3,9 @@ package command
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_protocol "v2ray.com/core/common/protocol"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import v2ray_core "v2ray.com/core"
import core "v2ray.com/core"
import protocol "v2ray.com/core/common/protocol"
import serial "v2ray.com/core/common/serial"
import (
"context"
@ -25,15 +25,37 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type AddUserOperation struct {
User *v2ray_core_common_protocol.User `protobuf:"bytes,1,opt,name=user" json:"user,omitempty"`
User *protocol.User `protobuf:"bytes,1,opt,name=user" json:"user,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AddUserOperation) Reset() { *m = AddUserOperation{} }
func (m *AddUserOperation) String() string { return proto.CompactTextString(m) }
func (*AddUserOperation) ProtoMessage() {}
func (*AddUserOperation) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *AddUserOperation) Reset() { *m = AddUserOperation{} }
func (m *AddUserOperation) String() string { return proto.CompactTextString(m) }
func (*AddUserOperation) ProtoMessage() {}
func (*AddUserOperation) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{0}
}
func (m *AddUserOperation) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AddUserOperation.Unmarshal(m, b)
}
func (m *AddUserOperation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AddUserOperation.Marshal(b, m, deterministic)
}
func (dst *AddUserOperation) XXX_Merge(src proto.Message) {
xxx_messageInfo_AddUserOperation.Merge(dst, src)
}
func (m *AddUserOperation) XXX_Size() int {
return xxx_messageInfo_AddUserOperation.Size(m)
}
func (m *AddUserOperation) XXX_DiscardUnknown() {
xxx_messageInfo_AddUserOperation.DiscardUnknown(m)
}
func (m *AddUserOperation) GetUser() *v2ray_core_common_protocol.User {
var xxx_messageInfo_AddUserOperation proto.InternalMessageInfo
func (m *AddUserOperation) GetUser() *protocol.User {
if m != nil {
return m.User
}
@ -41,13 +63,35 @@ func (m *AddUserOperation) GetUser() *v2ray_core_common_protocol.User {
}
type RemoveUserOperation struct {
Email string `protobuf:"bytes,1,opt,name=email" json:"email,omitempty"`
Email string `protobuf:"bytes,1,opt,name=email" json:"email,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RemoveUserOperation) Reset() { *m = RemoveUserOperation{} }
func (m *RemoveUserOperation) String() string { return proto.CompactTextString(m) }
func (*RemoveUserOperation) ProtoMessage() {}
func (*RemoveUserOperation) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *RemoveUserOperation) Reset() { *m = RemoveUserOperation{} }
func (m *RemoveUserOperation) String() string { return proto.CompactTextString(m) }
func (*RemoveUserOperation) ProtoMessage() {}
func (*RemoveUserOperation) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{1}
}
func (m *RemoveUserOperation) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RemoveUserOperation.Unmarshal(m, b)
}
func (m *RemoveUserOperation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RemoveUserOperation.Marshal(b, m, deterministic)
}
func (dst *RemoveUserOperation) XXX_Merge(src proto.Message) {
xxx_messageInfo_RemoveUserOperation.Merge(dst, src)
}
func (m *RemoveUserOperation) XXX_Size() int {
return xxx_messageInfo_RemoveUserOperation.Size(m)
}
func (m *RemoveUserOperation) XXX_DiscardUnknown() {
xxx_messageInfo_RemoveUserOperation.DiscardUnknown(m)
}
var xxx_messageInfo_RemoveUserOperation proto.InternalMessageInfo
func (m *RemoveUserOperation) GetEmail() string {
if m != nil {
@ -57,15 +101,37 @@ func (m *RemoveUserOperation) GetEmail() string {
}
type AddInboundRequest struct {
Inbound *v2ray_core.InboundHandlerConfig `protobuf:"bytes,1,opt,name=inbound" json:"inbound,omitempty"`
Inbound *core.InboundHandlerConfig `protobuf:"bytes,1,opt,name=inbound" json:"inbound,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AddInboundRequest) Reset() { *m = AddInboundRequest{} }
func (m *AddInboundRequest) String() string { return proto.CompactTextString(m) }
func (*AddInboundRequest) ProtoMessage() {}
func (*AddInboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *AddInboundRequest) Reset() { *m = AddInboundRequest{} }
func (m *AddInboundRequest) String() string { return proto.CompactTextString(m) }
func (*AddInboundRequest) ProtoMessage() {}
func (*AddInboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{2}
}
func (m *AddInboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AddInboundRequest.Unmarshal(m, b)
}
func (m *AddInboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AddInboundRequest.Marshal(b, m, deterministic)
}
func (dst *AddInboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_AddInboundRequest.Merge(dst, src)
}
func (m *AddInboundRequest) XXX_Size() int {
return xxx_messageInfo_AddInboundRequest.Size(m)
}
func (m *AddInboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_AddInboundRequest.DiscardUnknown(m)
}
func (m *AddInboundRequest) GetInbound() *v2ray_core.InboundHandlerConfig {
var xxx_messageInfo_AddInboundRequest proto.InternalMessageInfo
func (m *AddInboundRequest) GetInbound() *core.InboundHandlerConfig {
if m != nil {
return m.Inbound
}
@ -73,21 +139,65 @@ func (m *AddInboundRequest) GetInbound() *v2ray_core.InboundHandlerConfig {
}
type AddInboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AddInboundResponse) Reset() { *m = AddInboundResponse{} }
func (m *AddInboundResponse) String() string { return proto.CompactTextString(m) }
func (*AddInboundResponse) ProtoMessage() {}
func (*AddInboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *AddInboundResponse) Reset() { *m = AddInboundResponse{} }
func (m *AddInboundResponse) String() string { return proto.CompactTextString(m) }
func (*AddInboundResponse) ProtoMessage() {}
func (*AddInboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{3}
}
func (m *AddInboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AddInboundResponse.Unmarshal(m, b)
}
func (m *AddInboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AddInboundResponse.Marshal(b, m, deterministic)
}
func (dst *AddInboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_AddInboundResponse.Merge(dst, src)
}
func (m *AddInboundResponse) XXX_Size() int {
return xxx_messageInfo_AddInboundResponse.Size(m)
}
func (m *AddInboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_AddInboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_AddInboundResponse proto.InternalMessageInfo
type RemoveInboundRequest struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RemoveInboundRequest) Reset() { *m = RemoveInboundRequest{} }
func (m *RemoveInboundRequest) String() string { return proto.CompactTextString(m) }
func (*RemoveInboundRequest) ProtoMessage() {}
func (*RemoveInboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (m *RemoveInboundRequest) Reset() { *m = RemoveInboundRequest{} }
func (m *RemoveInboundRequest) String() string { return proto.CompactTextString(m) }
func (*RemoveInboundRequest) ProtoMessage() {}
func (*RemoveInboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{4}
}
func (m *RemoveInboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RemoveInboundRequest.Unmarshal(m, b)
}
func (m *RemoveInboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RemoveInboundRequest.Marshal(b, m, deterministic)
}
func (dst *RemoveInboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_RemoveInboundRequest.Merge(dst, src)
}
func (m *RemoveInboundRequest) XXX_Size() int {
return xxx_messageInfo_RemoveInboundRequest.Size(m)
}
func (m *RemoveInboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_RemoveInboundRequest.DiscardUnknown(m)
}
var xxx_messageInfo_RemoveInboundRequest proto.InternalMessageInfo
func (m *RemoveInboundRequest) GetTag() string {
if m != nil {
@ -97,22 +207,66 @@ func (m *RemoveInboundRequest) GetTag() string {
}
type RemoveInboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RemoveInboundResponse) Reset() { *m = RemoveInboundResponse{} }
func (m *RemoveInboundResponse) String() string { return proto.CompactTextString(m) }
func (*RemoveInboundResponse) ProtoMessage() {}
func (*RemoveInboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (m *RemoveInboundResponse) Reset() { *m = RemoveInboundResponse{} }
func (m *RemoveInboundResponse) String() string { return proto.CompactTextString(m) }
func (*RemoveInboundResponse) ProtoMessage() {}
func (*RemoveInboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{5}
}
func (m *RemoveInboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RemoveInboundResponse.Unmarshal(m, b)
}
func (m *RemoveInboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RemoveInboundResponse.Marshal(b, m, deterministic)
}
func (dst *RemoveInboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_RemoveInboundResponse.Merge(dst, src)
}
func (m *RemoveInboundResponse) XXX_Size() int {
return xxx_messageInfo_RemoveInboundResponse.Size(m)
}
func (m *RemoveInboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_RemoveInboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_RemoveInboundResponse proto.InternalMessageInfo
type AlterInboundRequest struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Operation *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=operation" json:"operation,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Operation *serial.TypedMessage `protobuf:"bytes,2,opt,name=operation" json:"operation,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AlterInboundRequest) Reset() { *m = AlterInboundRequest{} }
func (m *AlterInboundRequest) String() string { return proto.CompactTextString(m) }
func (*AlterInboundRequest) ProtoMessage() {}
func (*AlterInboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *AlterInboundRequest) Reset() { *m = AlterInboundRequest{} }
func (m *AlterInboundRequest) String() string { return proto.CompactTextString(m) }
func (*AlterInboundRequest) ProtoMessage() {}
func (*AlterInboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{6}
}
func (m *AlterInboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AlterInboundRequest.Unmarshal(m, b)
}
func (m *AlterInboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AlterInboundRequest.Marshal(b, m, deterministic)
}
func (dst *AlterInboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_AlterInboundRequest.Merge(dst, src)
}
func (m *AlterInboundRequest) XXX_Size() int {
return xxx_messageInfo_AlterInboundRequest.Size(m)
}
func (m *AlterInboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_AlterInboundRequest.DiscardUnknown(m)
}
var xxx_messageInfo_AlterInboundRequest proto.InternalMessageInfo
func (m *AlterInboundRequest) GetTag() string {
if m != nil {
@ -121,7 +275,7 @@ func (m *AlterInboundRequest) GetTag() string {
return ""
}
func (m *AlterInboundRequest) GetOperation() *v2ray_core_common_serial.TypedMessage {
func (m *AlterInboundRequest) GetOperation() *serial.TypedMessage {
if m != nil {
return m.Operation
}
@ -129,23 +283,67 @@ func (m *AlterInboundRequest) GetOperation() *v2ray_core_common_serial.TypedMess
}
type AlterInboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AlterInboundResponse) Reset() { *m = AlterInboundResponse{} }
func (m *AlterInboundResponse) String() string { return proto.CompactTextString(m) }
func (*AlterInboundResponse) ProtoMessage() {}
func (*AlterInboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (m *AlterInboundResponse) Reset() { *m = AlterInboundResponse{} }
func (m *AlterInboundResponse) String() string { return proto.CompactTextString(m) }
func (*AlterInboundResponse) ProtoMessage() {}
func (*AlterInboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{7}
}
func (m *AlterInboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AlterInboundResponse.Unmarshal(m, b)
}
func (m *AlterInboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AlterInboundResponse.Marshal(b, m, deterministic)
}
func (dst *AlterInboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_AlterInboundResponse.Merge(dst, src)
}
func (m *AlterInboundResponse) XXX_Size() int {
return xxx_messageInfo_AlterInboundResponse.Size(m)
}
func (m *AlterInboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_AlterInboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_AlterInboundResponse proto.InternalMessageInfo
type AddOutboundRequest struct {
Outbound *v2ray_core.OutboundHandlerConfig `protobuf:"bytes,1,opt,name=outbound" json:"outbound,omitempty"`
Outbound *core.OutboundHandlerConfig `protobuf:"bytes,1,opt,name=outbound" json:"outbound,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AddOutboundRequest) Reset() { *m = AddOutboundRequest{} }
func (m *AddOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*AddOutboundRequest) ProtoMessage() {}
func (*AddOutboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{8} }
func (m *AddOutboundRequest) Reset() { *m = AddOutboundRequest{} }
func (m *AddOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*AddOutboundRequest) ProtoMessage() {}
func (*AddOutboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{8}
}
func (m *AddOutboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AddOutboundRequest.Unmarshal(m, b)
}
func (m *AddOutboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AddOutboundRequest.Marshal(b, m, deterministic)
}
func (dst *AddOutboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_AddOutboundRequest.Merge(dst, src)
}
func (m *AddOutboundRequest) XXX_Size() int {
return xxx_messageInfo_AddOutboundRequest.Size(m)
}
func (m *AddOutboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_AddOutboundRequest.DiscardUnknown(m)
}
func (m *AddOutboundRequest) GetOutbound() *v2ray_core.OutboundHandlerConfig {
var xxx_messageInfo_AddOutboundRequest proto.InternalMessageInfo
func (m *AddOutboundRequest) GetOutbound() *core.OutboundHandlerConfig {
if m != nil {
return m.Outbound
}
@ -153,21 +351,65 @@ func (m *AddOutboundRequest) GetOutbound() *v2ray_core.OutboundHandlerConfig {
}
type AddOutboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AddOutboundResponse) Reset() { *m = AddOutboundResponse{} }
func (m *AddOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*AddOutboundResponse) ProtoMessage() {}
func (*AddOutboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{9} }
func (m *AddOutboundResponse) Reset() { *m = AddOutboundResponse{} }
func (m *AddOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*AddOutboundResponse) ProtoMessage() {}
func (*AddOutboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{9}
}
func (m *AddOutboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AddOutboundResponse.Unmarshal(m, b)
}
func (m *AddOutboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AddOutboundResponse.Marshal(b, m, deterministic)
}
func (dst *AddOutboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_AddOutboundResponse.Merge(dst, src)
}
func (m *AddOutboundResponse) XXX_Size() int {
return xxx_messageInfo_AddOutboundResponse.Size(m)
}
func (m *AddOutboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_AddOutboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_AddOutboundResponse proto.InternalMessageInfo
type RemoveOutboundRequest struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RemoveOutboundRequest) Reset() { *m = RemoveOutboundRequest{} }
func (m *RemoveOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*RemoveOutboundRequest) ProtoMessage() {}
func (*RemoveOutboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{10} }
func (m *RemoveOutboundRequest) Reset() { *m = RemoveOutboundRequest{} }
func (m *RemoveOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*RemoveOutboundRequest) ProtoMessage() {}
func (*RemoveOutboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{10}
}
func (m *RemoveOutboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RemoveOutboundRequest.Unmarshal(m, b)
}
func (m *RemoveOutboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RemoveOutboundRequest.Marshal(b, m, deterministic)
}
func (dst *RemoveOutboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_RemoveOutboundRequest.Merge(dst, src)
}
func (m *RemoveOutboundRequest) XXX_Size() int {
return xxx_messageInfo_RemoveOutboundRequest.Size(m)
}
func (m *RemoveOutboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_RemoveOutboundRequest.DiscardUnknown(m)
}
var xxx_messageInfo_RemoveOutboundRequest proto.InternalMessageInfo
func (m *RemoveOutboundRequest) GetTag() string {
if m != nil {
@ -177,22 +419,66 @@ func (m *RemoveOutboundRequest) GetTag() string {
}
type RemoveOutboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RemoveOutboundResponse) Reset() { *m = RemoveOutboundResponse{} }
func (m *RemoveOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*RemoveOutboundResponse) ProtoMessage() {}
func (*RemoveOutboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{11} }
func (m *RemoveOutboundResponse) Reset() { *m = RemoveOutboundResponse{} }
func (m *RemoveOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*RemoveOutboundResponse) ProtoMessage() {}
func (*RemoveOutboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{11}
}
func (m *RemoveOutboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RemoveOutboundResponse.Unmarshal(m, b)
}
func (m *RemoveOutboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RemoveOutboundResponse.Marshal(b, m, deterministic)
}
func (dst *RemoveOutboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_RemoveOutboundResponse.Merge(dst, src)
}
func (m *RemoveOutboundResponse) XXX_Size() int {
return xxx_messageInfo_RemoveOutboundResponse.Size(m)
}
func (m *RemoveOutboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_RemoveOutboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_RemoveOutboundResponse proto.InternalMessageInfo
type AlterOutboundRequest struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Operation *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=operation" json:"operation,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Operation *serial.TypedMessage `protobuf:"bytes,2,opt,name=operation" json:"operation,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AlterOutboundRequest) Reset() { *m = AlterOutboundRequest{} }
func (m *AlterOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*AlterOutboundRequest) ProtoMessage() {}
func (*AlterOutboundRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{12} }
func (m *AlterOutboundRequest) Reset() { *m = AlterOutboundRequest{} }
func (m *AlterOutboundRequest) String() string { return proto.CompactTextString(m) }
func (*AlterOutboundRequest) ProtoMessage() {}
func (*AlterOutboundRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{12}
}
func (m *AlterOutboundRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AlterOutboundRequest.Unmarshal(m, b)
}
func (m *AlterOutboundRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AlterOutboundRequest.Marshal(b, m, deterministic)
}
func (dst *AlterOutboundRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_AlterOutboundRequest.Merge(dst, src)
}
func (m *AlterOutboundRequest) XXX_Size() int {
return xxx_messageInfo_AlterOutboundRequest.Size(m)
}
func (m *AlterOutboundRequest) XXX_DiscardUnknown() {
xxx_messageInfo_AlterOutboundRequest.DiscardUnknown(m)
}
var xxx_messageInfo_AlterOutboundRequest proto.InternalMessageInfo
func (m *AlterOutboundRequest) GetTag() string {
if m != nil {
@ -201,7 +487,7 @@ func (m *AlterOutboundRequest) GetTag() string {
return ""
}
func (m *AlterOutboundRequest) GetOperation() *v2ray_core_common_serial.TypedMessage {
func (m *AlterOutboundRequest) GetOperation() *serial.TypedMessage {
if m != nil {
return m.Operation
}
@ -209,20 +495,64 @@ func (m *AlterOutboundRequest) GetOperation() *v2ray_core_common_serial.TypedMes
}
type AlterOutboundResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AlterOutboundResponse) Reset() { *m = AlterOutboundResponse{} }
func (m *AlterOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*AlterOutboundResponse) ProtoMessage() {}
func (*AlterOutboundResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{13} }
func (m *AlterOutboundResponse) Reset() { *m = AlterOutboundResponse{} }
func (m *AlterOutboundResponse) String() string { return proto.CompactTextString(m) }
func (*AlterOutboundResponse) ProtoMessage() {}
func (*AlterOutboundResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{13}
}
func (m *AlterOutboundResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AlterOutboundResponse.Unmarshal(m, b)
}
func (m *AlterOutboundResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AlterOutboundResponse.Marshal(b, m, deterministic)
}
func (dst *AlterOutboundResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_AlterOutboundResponse.Merge(dst, src)
}
func (m *AlterOutboundResponse) XXX_Size() int {
return xxx_messageInfo_AlterOutboundResponse.Size(m)
}
func (m *AlterOutboundResponse) XXX_DiscardUnknown() {
xxx_messageInfo_AlterOutboundResponse.DiscardUnknown(m)
}
var xxx_messageInfo_AlterOutboundResponse proto.InternalMessageInfo
type Config struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{14} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_command_9f3931e07157223e, []int{14}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func init() {
proto.RegisterType((*AddUserOperation)(nil), "v2ray.core.app.proxyman.command.AddUserOperation")
@ -250,8 +580,9 @@ var _ grpc.ClientConn
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// Client API for HandlerService service
// HandlerServiceClient is the client API for HandlerService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type HandlerServiceClient interface {
AddInbound(ctx context.Context, in *AddInboundRequest, opts ...grpc.CallOption) (*AddInboundResponse, error)
RemoveInbound(ctx context.Context, in *RemoveInboundRequest, opts ...grpc.CallOption) (*RemoveInboundResponse, error)
@ -271,7 +602,7 @@ func NewHandlerServiceClient(cc *grpc.ClientConn) HandlerServiceClient {
func (c *handlerServiceClient) AddInbound(ctx context.Context, in *AddInboundRequest, opts ...grpc.CallOption) (*AddInboundResponse, error) {
out := new(AddInboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AddInbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AddInbound", in, out, opts...)
if err != nil {
return nil, err
}
@ -280,7 +611,7 @@ func (c *handlerServiceClient) AddInbound(ctx context.Context, in *AddInboundReq
func (c *handlerServiceClient) RemoveInbound(ctx context.Context, in *RemoveInboundRequest, opts ...grpc.CallOption) (*RemoveInboundResponse, error) {
out := new(RemoveInboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/RemoveInbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/RemoveInbound", in, out, opts...)
if err != nil {
return nil, err
}
@ -289,7 +620,7 @@ func (c *handlerServiceClient) RemoveInbound(ctx context.Context, in *RemoveInbo
func (c *handlerServiceClient) AlterInbound(ctx context.Context, in *AlterInboundRequest, opts ...grpc.CallOption) (*AlterInboundResponse, error) {
out := new(AlterInboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AlterInbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AlterInbound", in, out, opts...)
if err != nil {
return nil, err
}
@ -298,7 +629,7 @@ func (c *handlerServiceClient) AlterInbound(ctx context.Context, in *AlterInboun
func (c *handlerServiceClient) AddOutbound(ctx context.Context, in *AddOutboundRequest, opts ...grpc.CallOption) (*AddOutboundResponse, error) {
out := new(AddOutboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AddOutbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AddOutbound", in, out, opts...)
if err != nil {
return nil, err
}
@ -307,7 +638,7 @@ func (c *handlerServiceClient) AddOutbound(ctx context.Context, in *AddOutboundR
func (c *handlerServiceClient) RemoveOutbound(ctx context.Context, in *RemoveOutboundRequest, opts ...grpc.CallOption) (*RemoveOutboundResponse, error) {
out := new(RemoveOutboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/RemoveOutbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/RemoveOutbound", in, out, opts...)
if err != nil {
return nil, err
}
@ -316,15 +647,14 @@ func (c *handlerServiceClient) RemoveOutbound(ctx context.Context, in *RemoveOut
func (c *handlerServiceClient) AlterOutbound(ctx context.Context, in *AlterOutboundRequest, opts ...grpc.CallOption) (*AlterOutboundResponse, error) {
out := new(AlterOutboundResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AlterOutbound", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.proxyman.command.HandlerService/AlterOutbound", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// Server API for HandlerService service
// HandlerServiceServer is the server API for HandlerService service.
type HandlerServiceServer interface {
AddInbound(context.Context, *AddInboundRequest) (*AddInboundResponse, error)
RemoveInbound(context.Context, *RemoveInboundRequest) (*RemoveInboundResponse, error)
@ -479,9 +809,11 @@ var _HandlerService_serviceDesc = grpc.ServiceDesc{
Metadata: "v2ray.com/core/app/proxyman/command/command.proto",
}
func init() { proto.RegisterFile("v2ray.com/core/app/proxyman/command/command.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/proxyman/command/command.proto", fileDescriptor_command_9f3931e07157223e)
}
var fileDescriptor0 = []byte{
var fileDescriptor_command_9f3931e07157223e = []byte{
// 557 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x55, 0xdf, 0x6b, 0xd3, 0x40,
0x1c, 0xb7, 0x53, 0xbb, 0xed, 0x3b, 0x1d, 0xf3, 0xda, 0x6e, 0x25, 0x3e, 0x6c, 0x46, 0x90, 0x0d,

View File

@ -2,4 +2,6 @@ package command
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Proxyman", "Command") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Proxyman", "Command")
}

View File

@ -3,10 +3,9 @@ package proxyman
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_net1 "v2ray.com/core/common/net"
import v2ray_core_transport_internet "v2ray.com/core/transport/internet"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import net "v2ray.com/core/common/net"
import serial "v2ray.com/core/common/serial"
import internet "v2ray.com/core/transport/internet"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -38,7 +37,9 @@ var KnownProtocols_value = map[string]int32{
func (x KnownProtocols) String() string {
return proto.EnumName(KnownProtocols_name, int32(x))
}
func (KnownProtocols) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (KnownProtocols) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{0}
}
type AllocationStrategy_Type int32
@ -65,15 +66,39 @@ var AllocationStrategy_Type_value = map[string]int32{
func (x AllocationStrategy_Type) String() string {
return proto.EnumName(AllocationStrategy_Type_name, int32(x))
}
func (AllocationStrategy_Type) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{1, 0} }
type InboundConfig struct {
func (AllocationStrategy_Type) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{1, 0}
}
func (m *InboundConfig) Reset() { *m = InboundConfig{} }
func (m *InboundConfig) String() string { return proto.CompactTextString(m) }
func (*InboundConfig) ProtoMessage() {}
func (*InboundConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type InboundConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *InboundConfig) Reset() { *m = InboundConfig{} }
func (m *InboundConfig) String() string { return proto.CompactTextString(m) }
func (*InboundConfig) ProtoMessage() {}
func (*InboundConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{0}
}
func (m *InboundConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_InboundConfig.Unmarshal(m, b)
}
func (m *InboundConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_InboundConfig.Marshal(b, m, deterministic)
}
func (dst *InboundConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_InboundConfig.Merge(dst, src)
}
func (m *InboundConfig) XXX_Size() int {
return xxx_messageInfo_InboundConfig.Size(m)
}
func (m *InboundConfig) XXX_DiscardUnknown() {
xxx_messageInfo_InboundConfig.DiscardUnknown(m)
}
var xxx_messageInfo_InboundConfig proto.InternalMessageInfo
type AllocationStrategy struct {
Type AllocationStrategy_Type `protobuf:"varint,1,opt,name=type,enum=v2ray.core.app.proxyman.AllocationStrategy_Type" json:"type,omitempty"`
@ -82,13 +107,35 @@ type AllocationStrategy struct {
Concurrency *AllocationStrategy_AllocationStrategyConcurrency `protobuf:"bytes,2,opt,name=concurrency" json:"concurrency,omitempty"`
// Number of minutes before a handler is regenerated.
// Default value is 5 if unset.
Refresh *AllocationStrategy_AllocationStrategyRefresh `protobuf:"bytes,3,opt,name=refresh" json:"refresh,omitempty"`
Refresh *AllocationStrategy_AllocationStrategyRefresh `protobuf:"bytes,3,opt,name=refresh" json:"refresh,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AllocationStrategy) Reset() { *m = AllocationStrategy{} }
func (m *AllocationStrategy) String() string { return proto.CompactTextString(m) }
func (*AllocationStrategy) ProtoMessage() {}
func (*AllocationStrategy) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *AllocationStrategy) Reset() { *m = AllocationStrategy{} }
func (m *AllocationStrategy) String() string { return proto.CompactTextString(m) }
func (*AllocationStrategy) ProtoMessage() {}
func (*AllocationStrategy) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{1}
}
func (m *AllocationStrategy) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AllocationStrategy.Unmarshal(m, b)
}
func (m *AllocationStrategy) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AllocationStrategy.Marshal(b, m, deterministic)
}
func (dst *AllocationStrategy) XXX_Merge(src proto.Message) {
xxx_messageInfo_AllocationStrategy.Merge(dst, src)
}
func (m *AllocationStrategy) XXX_Size() int {
return xxx_messageInfo_AllocationStrategy.Size(m)
}
func (m *AllocationStrategy) XXX_DiscardUnknown() {
xxx_messageInfo_AllocationStrategy.DiscardUnknown(m)
}
var xxx_messageInfo_AllocationStrategy proto.InternalMessageInfo
func (m *AllocationStrategy) GetType() AllocationStrategy_Type {
if m != nil {
@ -112,7 +159,10 @@ func (m *AllocationStrategy) GetRefresh() *AllocationStrategy_AllocationStrategy
}
type AllocationStrategy_AllocationStrategyConcurrency struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AllocationStrategy_AllocationStrategyConcurrency) Reset() {
@ -123,8 +173,25 @@ func (m *AllocationStrategy_AllocationStrategyConcurrency) String() string {
}
func (*AllocationStrategy_AllocationStrategyConcurrency) ProtoMessage() {}
func (*AllocationStrategy_AllocationStrategyConcurrency) Descriptor() ([]byte, []int) {
return fileDescriptor0, []int{1, 0}
return fileDescriptor_config_8038bf3f86761ebe, []int{1, 0}
}
func (m *AllocationStrategy_AllocationStrategyConcurrency) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency.Unmarshal(m, b)
}
func (m *AllocationStrategy_AllocationStrategyConcurrency) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency.Marshal(b, m, deterministic)
}
func (dst *AllocationStrategy_AllocationStrategyConcurrency) XXX_Merge(src proto.Message) {
xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency.Merge(dst, src)
}
func (m *AllocationStrategy_AllocationStrategyConcurrency) XXX_Size() int {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency.Size(m)
}
func (m *AllocationStrategy_AllocationStrategyConcurrency) XXX_DiscardUnknown() {
xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency.DiscardUnknown(m)
}
var xxx_messageInfo_AllocationStrategy_AllocationStrategyConcurrency proto.InternalMessageInfo
func (m *AllocationStrategy_AllocationStrategyConcurrency) GetValue() uint32 {
if m != nil {
@ -134,7 +201,10 @@ func (m *AllocationStrategy_AllocationStrategyConcurrency) GetValue() uint32 {
}
type AllocationStrategy_AllocationStrategyRefresh struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AllocationStrategy_AllocationStrategyRefresh) Reset() {
@ -145,8 +215,25 @@ func (m *AllocationStrategy_AllocationStrategyRefresh) String() string {
}
func (*AllocationStrategy_AllocationStrategyRefresh) ProtoMessage() {}
func (*AllocationStrategy_AllocationStrategyRefresh) Descriptor() ([]byte, []int) {
return fileDescriptor0, []int{1, 1}
return fileDescriptor_config_8038bf3f86761ebe, []int{1, 1}
}
func (m *AllocationStrategy_AllocationStrategyRefresh) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh.Unmarshal(m, b)
}
func (m *AllocationStrategy_AllocationStrategyRefresh) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh.Marshal(b, m, deterministic)
}
func (dst *AllocationStrategy_AllocationStrategyRefresh) XXX_Merge(src proto.Message) {
xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh.Merge(dst, src)
}
func (m *AllocationStrategy_AllocationStrategyRefresh) XXX_Size() int {
return xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh.Size(m)
}
func (m *AllocationStrategy_AllocationStrategyRefresh) XXX_DiscardUnknown() {
xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh.DiscardUnknown(m)
}
var xxx_messageInfo_AllocationStrategy_AllocationStrategyRefresh proto.InternalMessageInfo
func (m *AllocationStrategy_AllocationStrategyRefresh) GetValue() uint32 {
if m != nil {
@ -157,28 +244,50 @@ func (m *AllocationStrategy_AllocationStrategyRefresh) GetValue() uint32 {
type ReceiverConfig struct {
// PortRange specifies the ports which the Receiver should listen on.
PortRange *v2ray_core_common_net1.PortRange `protobuf:"bytes,1,opt,name=port_range,json=portRange" json:"port_range,omitempty"`
PortRange *net.PortRange `protobuf:"bytes,1,opt,name=port_range,json=portRange" json:"port_range,omitempty"`
// Listen specifies the IP address that the Receiver should listen on.
Listen *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,2,opt,name=listen" json:"listen,omitempty"`
AllocationStrategy *AllocationStrategy `protobuf:"bytes,3,opt,name=allocation_strategy,json=allocationStrategy" json:"allocation_strategy,omitempty"`
StreamSettings *v2ray_core_transport_internet.StreamConfig `protobuf:"bytes,4,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
ReceiveOriginalDestination bool `protobuf:"varint,5,opt,name=receive_original_destination,json=receiveOriginalDestination" json:"receive_original_destination,omitempty"`
DomainOverride []KnownProtocols `protobuf:"varint,7,rep,packed,name=domain_override,json=domainOverride,enum=v2ray.core.app.proxyman.KnownProtocols" json:"domain_override,omitempty"`
Listen *net.IPOrDomain `protobuf:"bytes,2,opt,name=listen" json:"listen,omitempty"`
AllocationStrategy *AllocationStrategy `protobuf:"bytes,3,opt,name=allocation_strategy,json=allocationStrategy" json:"allocation_strategy,omitempty"`
StreamSettings *internet.StreamConfig `protobuf:"bytes,4,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
ReceiveOriginalDestination bool `protobuf:"varint,5,opt,name=receive_original_destination,json=receiveOriginalDestination" json:"receive_original_destination,omitempty"`
DomainOverride []KnownProtocols `protobuf:"varint,7,rep,packed,name=domain_override,json=domainOverride,enum=v2ray.core.app.proxyman.KnownProtocols" json:"domain_override,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ReceiverConfig) Reset() { *m = ReceiverConfig{} }
func (m *ReceiverConfig) String() string { return proto.CompactTextString(m) }
func (*ReceiverConfig) ProtoMessage() {}
func (*ReceiverConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *ReceiverConfig) Reset() { *m = ReceiverConfig{} }
func (m *ReceiverConfig) String() string { return proto.CompactTextString(m) }
func (*ReceiverConfig) ProtoMessage() {}
func (*ReceiverConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{2}
}
func (m *ReceiverConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ReceiverConfig.Unmarshal(m, b)
}
func (m *ReceiverConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ReceiverConfig.Marshal(b, m, deterministic)
}
func (dst *ReceiverConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ReceiverConfig.Merge(dst, src)
}
func (m *ReceiverConfig) XXX_Size() int {
return xxx_messageInfo_ReceiverConfig.Size(m)
}
func (m *ReceiverConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ReceiverConfig.DiscardUnknown(m)
}
func (m *ReceiverConfig) GetPortRange() *v2ray_core_common_net1.PortRange {
var xxx_messageInfo_ReceiverConfig proto.InternalMessageInfo
func (m *ReceiverConfig) GetPortRange() *net.PortRange {
if m != nil {
return m.PortRange
}
return nil
}
func (m *ReceiverConfig) GetListen() *v2ray_core_common_net.IPOrDomain {
func (m *ReceiverConfig) GetListen() *net.IPOrDomain {
if m != nil {
return m.Listen
}
@ -192,7 +301,7 @@ func (m *ReceiverConfig) GetAllocationStrategy() *AllocationStrategy {
return nil
}
func (m *ReceiverConfig) GetStreamSettings() *v2ray_core_transport_internet.StreamConfig {
func (m *ReceiverConfig) GetStreamSettings() *internet.StreamConfig {
if m != nil {
return m.StreamSettings
}
@ -214,15 +323,37 @@ func (m *ReceiverConfig) GetDomainOverride() []KnownProtocols {
}
type InboundHandlerConfig struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
ReceiverSettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=receiver_settings,json=receiverSettings" json:"receiver_settings,omitempty"`
ProxySettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
ReceiverSettings *serial.TypedMessage `protobuf:"bytes,2,opt,name=receiver_settings,json=receiverSettings" json:"receiver_settings,omitempty"`
ProxySettings *serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *InboundHandlerConfig) Reset() { *m = InboundHandlerConfig{} }
func (m *InboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*InboundHandlerConfig) ProtoMessage() {}
func (*InboundHandlerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *InboundHandlerConfig) Reset() { *m = InboundHandlerConfig{} }
func (m *InboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*InboundHandlerConfig) ProtoMessage() {}
func (*InboundHandlerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{3}
}
func (m *InboundHandlerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_InboundHandlerConfig.Unmarshal(m, b)
}
func (m *InboundHandlerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_InboundHandlerConfig.Marshal(b, m, deterministic)
}
func (dst *InboundHandlerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_InboundHandlerConfig.Merge(dst, src)
}
func (m *InboundHandlerConfig) XXX_Size() int {
return xxx_messageInfo_InboundHandlerConfig.Size(m)
}
func (m *InboundHandlerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_InboundHandlerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_InboundHandlerConfig proto.InternalMessageInfo
func (m *InboundHandlerConfig) GetTag() string {
if m != nil {
@ -231,14 +362,14 @@ func (m *InboundHandlerConfig) GetTag() string {
return ""
}
func (m *InboundHandlerConfig) GetReceiverSettings() *v2ray_core_common_serial.TypedMessage {
func (m *InboundHandlerConfig) GetReceiverSettings() *serial.TypedMessage {
if m != nil {
return m.ReceiverSettings
}
return nil
}
func (m *InboundHandlerConfig) GetProxySettings() *v2ray_core_common_serial.TypedMessage {
func (m *InboundHandlerConfig) GetProxySettings() *serial.TypedMessage {
if m != nil {
return m.ProxySettings
}
@ -246,41 +377,85 @@ func (m *InboundHandlerConfig) GetProxySettings() *v2ray_core_common_serial.Type
}
type OutboundConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *OutboundConfig) Reset() { *m = OutboundConfig{} }
func (m *OutboundConfig) String() string { return proto.CompactTextString(m) }
func (*OutboundConfig) ProtoMessage() {}
func (*OutboundConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (m *OutboundConfig) Reset() { *m = OutboundConfig{} }
func (m *OutboundConfig) String() string { return proto.CompactTextString(m) }
func (*OutboundConfig) ProtoMessage() {}
func (*OutboundConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{4}
}
func (m *OutboundConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OutboundConfig.Unmarshal(m, b)
}
func (m *OutboundConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_OutboundConfig.Marshal(b, m, deterministic)
}
func (dst *OutboundConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_OutboundConfig.Merge(dst, src)
}
func (m *OutboundConfig) XXX_Size() int {
return xxx_messageInfo_OutboundConfig.Size(m)
}
func (m *OutboundConfig) XXX_DiscardUnknown() {
xxx_messageInfo_OutboundConfig.DiscardUnknown(m)
}
var xxx_messageInfo_OutboundConfig proto.InternalMessageInfo
type SenderConfig struct {
// Send traffic through the given IP. Only IP is allowed.
Via *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,1,opt,name=via" json:"via,omitempty"`
StreamSettings *v2ray_core_transport_internet.StreamConfig `protobuf:"bytes,2,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
ProxySettings *v2ray_core_transport_internet.ProxyConfig `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
MultiplexSettings *MultiplexingConfig `protobuf:"bytes,4,opt,name=multiplex_settings,json=multiplexSettings" json:"multiplex_settings,omitempty"`
Via *net.IPOrDomain `protobuf:"bytes,1,opt,name=via" json:"via,omitempty"`
StreamSettings *internet.StreamConfig `protobuf:"bytes,2,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
ProxySettings *internet.ProxyConfig `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
MultiplexSettings *MultiplexingConfig `protobuf:"bytes,4,opt,name=multiplex_settings,json=multiplexSettings" json:"multiplex_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SenderConfig) Reset() { *m = SenderConfig{} }
func (m *SenderConfig) String() string { return proto.CompactTextString(m) }
func (*SenderConfig) ProtoMessage() {}
func (*SenderConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (m *SenderConfig) Reset() { *m = SenderConfig{} }
func (m *SenderConfig) String() string { return proto.CompactTextString(m) }
func (*SenderConfig) ProtoMessage() {}
func (*SenderConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{5}
}
func (m *SenderConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SenderConfig.Unmarshal(m, b)
}
func (m *SenderConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SenderConfig.Marshal(b, m, deterministic)
}
func (dst *SenderConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_SenderConfig.Merge(dst, src)
}
func (m *SenderConfig) XXX_Size() int {
return xxx_messageInfo_SenderConfig.Size(m)
}
func (m *SenderConfig) XXX_DiscardUnknown() {
xxx_messageInfo_SenderConfig.DiscardUnknown(m)
}
func (m *SenderConfig) GetVia() *v2ray_core_common_net.IPOrDomain {
var xxx_messageInfo_SenderConfig proto.InternalMessageInfo
func (m *SenderConfig) GetVia() *net.IPOrDomain {
if m != nil {
return m.Via
}
return nil
}
func (m *SenderConfig) GetStreamSettings() *v2ray_core_transport_internet.StreamConfig {
func (m *SenderConfig) GetStreamSettings() *internet.StreamConfig {
if m != nil {
return m.StreamSettings
}
return nil
}
func (m *SenderConfig) GetProxySettings() *v2ray_core_transport_internet.ProxyConfig {
func (m *SenderConfig) GetProxySettings() *internet.ProxyConfig {
if m != nil {
return m.ProxySettings
}
@ -298,13 +473,35 @@ type MultiplexingConfig struct {
// Whether or not Mux is enabled.
Enabled bool `protobuf:"varint,1,opt,name=enabled" json:"enabled,omitempty"`
// Max number of concurrent connections that one Mux connection can handle.
Concurrency uint32 `protobuf:"varint,2,opt,name=concurrency" json:"concurrency,omitempty"`
Concurrency uint32 `protobuf:"varint,2,opt,name=concurrency" json:"concurrency,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *MultiplexingConfig) Reset() { *m = MultiplexingConfig{} }
func (m *MultiplexingConfig) String() string { return proto.CompactTextString(m) }
func (*MultiplexingConfig) ProtoMessage() {}
func (*MultiplexingConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *MultiplexingConfig) Reset() { *m = MultiplexingConfig{} }
func (m *MultiplexingConfig) String() string { return proto.CompactTextString(m) }
func (*MultiplexingConfig) ProtoMessage() {}
func (*MultiplexingConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8038bf3f86761ebe, []int{6}
}
func (m *MultiplexingConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_MultiplexingConfig.Unmarshal(m, b)
}
func (m *MultiplexingConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_MultiplexingConfig.Marshal(b, m, deterministic)
}
func (dst *MultiplexingConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_MultiplexingConfig.Merge(dst, src)
}
func (m *MultiplexingConfig) XXX_Size() int {
return xxx_messageInfo_MultiplexingConfig.Size(m)
}
func (m *MultiplexingConfig) XXX_DiscardUnknown() {
xxx_messageInfo_MultiplexingConfig.DiscardUnknown(m)
}
var xxx_messageInfo_MultiplexingConfig proto.InternalMessageInfo
func (m *MultiplexingConfig) GetEnabled() bool {
if m != nil {
@ -334,9 +531,11 @@ func init() {
proto.RegisterEnum("v2ray.core.app.proxyman.AllocationStrategy_Type", AllocationStrategy_Type_name, AllocationStrategy_Type_value)
}
func init() { proto.RegisterFile("v2ray.com/core/app/proxyman/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/proxyman/config.proto", fileDescriptor_config_8038bf3f86761ebe)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_8038bf3f86761ebe = []byte{
// 772 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x95, 0x5f, 0x6f, 0xeb, 0x34,
0x18, 0xc6, 0x4f, 0x9a, 0x9e, 0xb6, 0xe7, 0xdd, 0x69, 0x96, 0x63, 0x26, 0xad, 0x14, 0x90, 0x4a,

View File

@ -2,4 +2,6 @@ package proxyman
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Proxyman") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Proxyman")
}

View File

@ -2,4 +2,6 @@ package inbound
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Proxyman", "Inbound") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Proxyman", "Inbound")
}

View File

@ -2,4 +2,6 @@ package mux
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Proxyman", "Mux") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Proxyman", "Mux")
}

View File

@ -2,4 +2,6 @@ package outbound
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("App", "Proxyman", "Outbound") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("App", "Proxyman", "Outbound")
}

View File

@ -3,8 +3,7 @@ package router
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_net1 "v2ray.com/core/common/net"
import net "v2ray.com/core/common/net"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -43,7 +42,9 @@ var Domain_Type_value = map[string]int32{
func (x Domain_Type) String() string {
return proto.EnumName(Domain_Type_name, int32(x))
}
func (Domain_Type) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
func (Domain_Type) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{0, 0}
}
type Config_DomainStrategy int32
@ -74,20 +75,44 @@ var Config_DomainStrategy_value = map[string]int32{
func (x Config_DomainStrategy) String() string {
return proto.EnumName(Config_DomainStrategy_name, int32(x))
}
func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{7, 0} }
func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{7, 0}
}
// Domain for routing decision.
type Domain struct {
// Domain matching type.
Type Domain_Type `protobuf:"varint,1,opt,name=type,enum=v2ray.core.app.router.Domain_Type" json:"type,omitempty"`
// Domain value.
Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Domain) Reset() { *m = Domain{} }
func (m *Domain) String() string { return proto.CompactTextString(m) }
func (*Domain) ProtoMessage() {}
func (*Domain) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Domain) Reset() { *m = Domain{} }
func (m *Domain) String() string { return proto.CompactTextString(m) }
func (*Domain) ProtoMessage() {}
func (*Domain) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{0}
}
func (m *Domain) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Domain.Unmarshal(m, b)
}
func (m *Domain) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Domain.Marshal(b, m, deterministic)
}
func (dst *Domain) XXX_Merge(src proto.Message) {
xxx_messageInfo_Domain.Merge(dst, src)
}
func (m *Domain) XXX_Size() int {
return xxx_messageInfo_Domain.Size(m)
}
func (m *Domain) XXX_DiscardUnknown() {
xxx_messageInfo_Domain.DiscardUnknown(m)
}
var xxx_messageInfo_Domain proto.InternalMessageInfo
func (m *Domain) GetType() Domain_Type {
if m != nil {
@ -108,13 +133,35 @@ type CIDR struct {
// IP address, should be either 4 or 16 bytes.
Ip []byte `protobuf:"bytes,1,opt,name=ip,proto3" json:"ip,omitempty"`
// Number of leading ones in the network mask.
Prefix uint32 `protobuf:"varint,2,opt,name=prefix" json:"prefix,omitempty"`
Prefix uint32 `protobuf:"varint,2,opt,name=prefix" json:"prefix,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CIDR) Reset() { *m = CIDR{} }
func (m *CIDR) String() string { return proto.CompactTextString(m) }
func (*CIDR) ProtoMessage() {}
func (*CIDR) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *CIDR) Reset() { *m = CIDR{} }
func (m *CIDR) String() string { return proto.CompactTextString(m) }
func (*CIDR) ProtoMessage() {}
func (*CIDR) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{1}
}
func (m *CIDR) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CIDR.Unmarshal(m, b)
}
func (m *CIDR) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CIDR.Marshal(b, m, deterministic)
}
func (dst *CIDR) XXX_Merge(src proto.Message) {
xxx_messageInfo_CIDR.Merge(dst, src)
}
func (m *CIDR) XXX_Size() int {
return xxx_messageInfo_CIDR.Size(m)
}
func (m *CIDR) XXX_DiscardUnknown() {
xxx_messageInfo_CIDR.DiscardUnknown(m)
}
var xxx_messageInfo_CIDR proto.InternalMessageInfo
func (m *CIDR) GetIp() []byte {
if m != nil {
@ -131,14 +178,36 @@ func (m *CIDR) GetPrefix() uint32 {
}
type GeoIP struct {
CountryCode string `protobuf:"bytes,1,opt,name=country_code,json=countryCode" json:"country_code,omitempty"`
Cidr []*CIDR `protobuf:"bytes,2,rep,name=cidr" json:"cidr,omitempty"`
CountryCode string `protobuf:"bytes,1,opt,name=country_code,json=countryCode" json:"country_code,omitempty"`
Cidr []*CIDR `protobuf:"bytes,2,rep,name=cidr" json:"cidr,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GeoIP) Reset() { *m = GeoIP{} }
func (m *GeoIP) String() string { return proto.CompactTextString(m) }
func (*GeoIP) ProtoMessage() {}
func (*GeoIP) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *GeoIP) Reset() { *m = GeoIP{} }
func (m *GeoIP) String() string { return proto.CompactTextString(m) }
func (*GeoIP) ProtoMessage() {}
func (*GeoIP) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{2}
}
func (m *GeoIP) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeoIP.Unmarshal(m, b)
}
func (m *GeoIP) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeoIP.Marshal(b, m, deterministic)
}
func (dst *GeoIP) XXX_Merge(src proto.Message) {
xxx_messageInfo_GeoIP.Merge(dst, src)
}
func (m *GeoIP) XXX_Size() int {
return xxx_messageInfo_GeoIP.Size(m)
}
func (m *GeoIP) XXX_DiscardUnknown() {
xxx_messageInfo_GeoIP.DiscardUnknown(m)
}
var xxx_messageInfo_GeoIP proto.InternalMessageInfo
func (m *GeoIP) GetCountryCode() string {
if m != nil {
@ -155,13 +224,35 @@ func (m *GeoIP) GetCidr() []*CIDR {
}
type GeoIPList struct {
Entry []*GeoIP `protobuf:"bytes,1,rep,name=entry" json:"entry,omitempty"`
Entry []*GeoIP `protobuf:"bytes,1,rep,name=entry" json:"entry,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GeoIPList) Reset() { *m = GeoIPList{} }
func (m *GeoIPList) String() string { return proto.CompactTextString(m) }
func (*GeoIPList) ProtoMessage() {}
func (*GeoIPList) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *GeoIPList) Reset() { *m = GeoIPList{} }
func (m *GeoIPList) String() string { return proto.CompactTextString(m) }
func (*GeoIPList) ProtoMessage() {}
func (*GeoIPList) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{3}
}
func (m *GeoIPList) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeoIPList.Unmarshal(m, b)
}
func (m *GeoIPList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeoIPList.Marshal(b, m, deterministic)
}
func (dst *GeoIPList) XXX_Merge(src proto.Message) {
xxx_messageInfo_GeoIPList.Merge(dst, src)
}
func (m *GeoIPList) XXX_Size() int {
return xxx_messageInfo_GeoIPList.Size(m)
}
func (m *GeoIPList) XXX_DiscardUnknown() {
xxx_messageInfo_GeoIPList.DiscardUnknown(m)
}
var xxx_messageInfo_GeoIPList proto.InternalMessageInfo
func (m *GeoIPList) GetEntry() []*GeoIP {
if m != nil {
@ -171,14 +262,36 @@ func (m *GeoIPList) GetEntry() []*GeoIP {
}
type GeoSite struct {
CountryCode string `protobuf:"bytes,1,opt,name=country_code,json=countryCode" json:"country_code,omitempty"`
Domain []*Domain `protobuf:"bytes,2,rep,name=domain" json:"domain,omitempty"`
CountryCode string `protobuf:"bytes,1,opt,name=country_code,json=countryCode" json:"country_code,omitempty"`
Domain []*Domain `protobuf:"bytes,2,rep,name=domain" json:"domain,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GeoSite) Reset() { *m = GeoSite{} }
func (m *GeoSite) String() string { return proto.CompactTextString(m) }
func (*GeoSite) ProtoMessage() {}
func (*GeoSite) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (m *GeoSite) Reset() { *m = GeoSite{} }
func (m *GeoSite) String() string { return proto.CompactTextString(m) }
func (*GeoSite) ProtoMessage() {}
func (*GeoSite) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{4}
}
func (m *GeoSite) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeoSite.Unmarshal(m, b)
}
func (m *GeoSite) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeoSite.Marshal(b, m, deterministic)
}
func (dst *GeoSite) XXX_Merge(src proto.Message) {
xxx_messageInfo_GeoSite.Merge(dst, src)
}
func (m *GeoSite) XXX_Size() int {
return xxx_messageInfo_GeoSite.Size(m)
}
func (m *GeoSite) XXX_DiscardUnknown() {
xxx_messageInfo_GeoSite.DiscardUnknown(m)
}
var xxx_messageInfo_GeoSite proto.InternalMessageInfo
func (m *GeoSite) GetCountryCode() string {
if m != nil {
@ -195,13 +308,35 @@ func (m *GeoSite) GetDomain() []*Domain {
}
type GeoSiteList struct {
Entry []*GeoSite `protobuf:"bytes,1,rep,name=entry" json:"entry,omitempty"`
Entry []*GeoSite `protobuf:"bytes,1,rep,name=entry" json:"entry,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GeoSiteList) Reset() { *m = GeoSiteList{} }
func (m *GeoSiteList) String() string { return proto.CompactTextString(m) }
func (*GeoSiteList) ProtoMessage() {}
func (*GeoSiteList) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (m *GeoSiteList) Reset() { *m = GeoSiteList{} }
func (m *GeoSiteList) String() string { return proto.CompactTextString(m) }
func (*GeoSiteList) ProtoMessage() {}
func (*GeoSiteList) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{5}
}
func (m *GeoSiteList) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeoSiteList.Unmarshal(m, b)
}
func (m *GeoSiteList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeoSiteList.Marshal(b, m, deterministic)
}
func (dst *GeoSiteList) XXX_Merge(src proto.Message) {
xxx_messageInfo_GeoSiteList.Merge(dst, src)
}
func (m *GeoSiteList) XXX_Size() int {
return xxx_messageInfo_GeoSiteList.Size(m)
}
func (m *GeoSiteList) XXX_DiscardUnknown() {
xxx_messageInfo_GeoSiteList.DiscardUnknown(m)
}
var xxx_messageInfo_GeoSiteList proto.InternalMessageInfo
func (m *GeoSiteList) GetEntry() []*GeoSite {
if m != nil {
@ -211,20 +346,42 @@ func (m *GeoSiteList) GetEntry() []*GeoSite {
}
type RoutingRule struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Domain []*Domain `protobuf:"bytes,2,rep,name=domain" json:"domain,omitempty"`
Cidr []*CIDR `protobuf:"bytes,3,rep,name=cidr" json:"cidr,omitempty"`
PortRange *v2ray_core_common_net.PortRange `protobuf:"bytes,4,opt,name=port_range,json=portRange" json:"port_range,omitempty"`
NetworkList *v2ray_core_common_net1.NetworkList `protobuf:"bytes,5,opt,name=network_list,json=networkList" json:"network_list,omitempty"`
SourceCidr []*CIDR `protobuf:"bytes,6,rep,name=source_cidr,json=sourceCidr" json:"source_cidr,omitempty"`
UserEmail []string `protobuf:"bytes,7,rep,name=user_email,json=userEmail" json:"user_email,omitempty"`
InboundTag []string `protobuf:"bytes,8,rep,name=inbound_tag,json=inboundTag" json:"inbound_tag,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Domain []*Domain `protobuf:"bytes,2,rep,name=domain" json:"domain,omitempty"`
Cidr []*CIDR `protobuf:"bytes,3,rep,name=cidr" json:"cidr,omitempty"`
PortRange *net.PortRange `protobuf:"bytes,4,opt,name=port_range,json=portRange" json:"port_range,omitempty"`
NetworkList *net.NetworkList `protobuf:"bytes,5,opt,name=network_list,json=networkList" json:"network_list,omitempty"`
SourceCidr []*CIDR `protobuf:"bytes,6,rep,name=source_cidr,json=sourceCidr" json:"source_cidr,omitempty"`
UserEmail []string `protobuf:"bytes,7,rep,name=user_email,json=userEmail" json:"user_email,omitempty"`
InboundTag []string `protobuf:"bytes,8,rep,name=inbound_tag,json=inboundTag" json:"inbound_tag,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RoutingRule) Reset() { *m = RoutingRule{} }
func (m *RoutingRule) String() string { return proto.CompactTextString(m) }
func (*RoutingRule) ProtoMessage() {}
func (*RoutingRule) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *RoutingRule) Reset() { *m = RoutingRule{} }
func (m *RoutingRule) String() string { return proto.CompactTextString(m) }
func (*RoutingRule) ProtoMessage() {}
func (*RoutingRule) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{6}
}
func (m *RoutingRule) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RoutingRule.Unmarshal(m, b)
}
func (m *RoutingRule) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RoutingRule.Marshal(b, m, deterministic)
}
func (dst *RoutingRule) XXX_Merge(src proto.Message) {
xxx_messageInfo_RoutingRule.Merge(dst, src)
}
func (m *RoutingRule) XXX_Size() int {
return xxx_messageInfo_RoutingRule.Size(m)
}
func (m *RoutingRule) XXX_DiscardUnknown() {
xxx_messageInfo_RoutingRule.DiscardUnknown(m)
}
var xxx_messageInfo_RoutingRule proto.InternalMessageInfo
func (m *RoutingRule) GetTag() string {
if m != nil {
@ -247,14 +404,14 @@ func (m *RoutingRule) GetCidr() []*CIDR {
return nil
}
func (m *RoutingRule) GetPortRange() *v2ray_core_common_net.PortRange {
func (m *RoutingRule) GetPortRange() *net.PortRange {
if m != nil {
return m.PortRange
}
return nil
}
func (m *RoutingRule) GetNetworkList() *v2ray_core_common_net1.NetworkList {
func (m *RoutingRule) GetNetworkList() *net.NetworkList {
if m != nil {
return m.NetworkList
}
@ -283,14 +440,36 @@ func (m *RoutingRule) GetInboundTag() []string {
}
type Config struct {
DomainStrategy Config_DomainStrategy `protobuf:"varint,1,opt,name=domain_strategy,json=domainStrategy,enum=v2ray.core.app.router.Config_DomainStrategy" json:"domain_strategy,omitempty"`
Rule []*RoutingRule `protobuf:"bytes,2,rep,name=rule" json:"rule,omitempty"`
DomainStrategy Config_DomainStrategy `protobuf:"varint,1,opt,name=domain_strategy,json=domainStrategy,enum=v2ray.core.app.router.Config_DomainStrategy" json:"domain_strategy,omitempty"`
Rule []*RoutingRule `protobuf:"bytes,2,rep,name=rule" json:"rule,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_bdac2d1c90ceb42f, []int{7}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetDomainStrategy() Config_DomainStrategy {
if m != nil {
@ -319,9 +498,11 @@ func init() {
proto.RegisterEnum("v2ray.core.app.router.Config_DomainStrategy", Config_DomainStrategy_name, Config_DomainStrategy_value)
}
func init() { proto.RegisterFile("v2ray.com/core/app/router/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/router/config.proto", fileDescriptor_config_bdac2d1c90ceb42f)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_bdac2d1c90ceb42f = []byte{
// 640 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0xcd, 0x6e, 0xd4, 0x3a,
0x14, 0xc7, 0x6f, 0xe6, 0xab, 0x9d, 0x93, 0xb9, 0x73, 0x23, 0xeb, 0x16, 0x0d, 0x85, 0xc2, 0x10,

View File

@ -5,7 +5,8 @@ import fmt "fmt"
import math "math"
import (
context "golang.org/x/net/context"
"context"
grpc "google.golang.org/grpc"
)
@ -24,13 +25,35 @@ type GetStatsRequest struct {
// Name of the stat counter.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// Whether or not to reset the counter to fetching its value.
Reset_ bool `protobuf:"varint,2,opt,name=reset" json:"reset,omitempty"`
Reset_ bool `protobuf:"varint,2,opt,name=reset" json:"reset,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GetStatsRequest) Reset() { *m = GetStatsRequest{} }
func (m *GetStatsRequest) String() string { return proto.CompactTextString(m) }
func (*GetStatsRequest) ProtoMessage() {}
func (*GetStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *GetStatsRequest) Reset() { *m = GetStatsRequest{} }
func (m *GetStatsRequest) String() string { return proto.CompactTextString(m) }
func (*GetStatsRequest) ProtoMessage() {}
func (*GetStatsRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_command_a956deb495595f76, []int{0}
}
func (m *GetStatsRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetStatsRequest.Unmarshal(m, b)
}
func (m *GetStatsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GetStatsRequest.Marshal(b, m, deterministic)
}
func (dst *GetStatsRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_GetStatsRequest.Merge(dst, src)
}
func (m *GetStatsRequest) XXX_Size() int {
return xxx_messageInfo_GetStatsRequest.Size(m)
}
func (m *GetStatsRequest) XXX_DiscardUnknown() {
xxx_messageInfo_GetStatsRequest.DiscardUnknown(m)
}
var xxx_messageInfo_GetStatsRequest proto.InternalMessageInfo
func (m *GetStatsRequest) GetName() string {
if m != nil {
@ -47,14 +70,36 @@ func (m *GetStatsRequest) GetReset_() bool {
}
type Stat struct {
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
Value int64 `protobuf:"varint,2,opt,name=value" json:"value,omitempty"`
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
Value int64 `protobuf:"varint,2,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Stat) Reset() { *m = Stat{} }
func (m *Stat) String() string { return proto.CompactTextString(m) }
func (*Stat) ProtoMessage() {}
func (*Stat) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Stat) Reset() { *m = Stat{} }
func (m *Stat) String() string { return proto.CompactTextString(m) }
func (*Stat) ProtoMessage() {}
func (*Stat) Descriptor() ([]byte, []int) {
return fileDescriptor_command_a956deb495595f76, []int{1}
}
func (m *Stat) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Stat.Unmarshal(m, b)
}
func (m *Stat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Stat.Marshal(b, m, deterministic)
}
func (dst *Stat) XXX_Merge(src proto.Message) {
xxx_messageInfo_Stat.Merge(dst, src)
}
func (m *Stat) XXX_Size() int {
return xxx_messageInfo_Stat.Size(m)
}
func (m *Stat) XXX_DiscardUnknown() {
xxx_messageInfo_Stat.DiscardUnknown(m)
}
var xxx_messageInfo_Stat proto.InternalMessageInfo
func (m *Stat) GetName() string {
if m != nil {
@ -71,13 +116,35 @@ func (m *Stat) GetValue() int64 {
}
type GetStatsResponse struct {
Stat *Stat `protobuf:"bytes,1,opt,name=stat" json:"stat,omitempty"`
Stat *Stat `protobuf:"bytes,1,opt,name=stat" json:"stat,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *GetStatsResponse) Reset() { *m = GetStatsResponse{} }
func (m *GetStatsResponse) String() string { return proto.CompactTextString(m) }
func (*GetStatsResponse) ProtoMessage() {}
func (*GetStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *GetStatsResponse) Reset() { *m = GetStatsResponse{} }
func (m *GetStatsResponse) String() string { return proto.CompactTextString(m) }
func (*GetStatsResponse) ProtoMessage() {}
func (*GetStatsResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_command_a956deb495595f76, []int{2}
}
func (m *GetStatsResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetStatsResponse.Unmarshal(m, b)
}
func (m *GetStatsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GetStatsResponse.Marshal(b, m, deterministic)
}
func (dst *GetStatsResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_GetStatsResponse.Merge(dst, src)
}
func (m *GetStatsResponse) XXX_Size() int {
return xxx_messageInfo_GetStatsResponse.Size(m)
}
func (m *GetStatsResponse) XXX_DiscardUnknown() {
xxx_messageInfo_GetStatsResponse.DiscardUnknown(m)
}
var xxx_messageInfo_GetStatsResponse proto.InternalMessageInfo
func (m *GetStatsResponse) GetStat() *Stat {
if m != nil {
@ -87,12 +154,34 @@ func (m *GetStatsResponse) GetStat() *Stat {
}
type Config struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_command_a956deb495595f76, []int{3}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func init() {
proto.RegisterType((*GetStatsRequest)(nil), "v2ray.core.app.stats.command.GetStatsRequest")
@ -109,8 +198,9 @@ var _ grpc.ClientConn
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// Client API for StatsService service
// StatsServiceClient is the client API for StatsService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type StatsServiceClient interface {
GetStats(ctx context.Context, in *GetStatsRequest, opts ...grpc.CallOption) (*GetStatsResponse, error)
}
@ -125,15 +215,14 @@ func NewStatsServiceClient(cc *grpc.ClientConn) StatsServiceClient {
func (c *statsServiceClient) GetStats(ctx context.Context, in *GetStatsRequest, opts ...grpc.CallOption) (*GetStatsResponse, error) {
out := new(GetStatsResponse)
err := grpc.Invoke(ctx, "/v2ray.core.app.stats.command.StatsService/GetStats", in, out, c.cc, opts...)
err := c.cc.Invoke(ctx, "/v2ray.core.app.stats.command.StatsService/GetStats", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// Server API for StatsService service
// StatsServiceServer is the server API for StatsService service.
type StatsServiceServer interface {
GetStats(context.Context, *GetStatsRequest) (*GetStatsResponse, error)
}
@ -173,9 +262,11 @@ var _StatsService_serviceDesc = grpc.ServiceDesc{
Metadata: "v2ray.com/core/app/stats/command/command.proto",
}
func init() { proto.RegisterFile("v2ray.com/core/app/stats/command/command.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/stats/command/command.proto", fileDescriptor_command_a956deb495595f76)
}
var fileDescriptor0 = []byte{
var fileDescriptor_command_a956deb495595f76 = []byte{
// 267 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0x3f, 0x4b, 0x03, 0x31,
0x14, 0xc0, 0xbd, 0x5a, 0xeb, 0xf9, 0x14, 0x94, 0xe0, 0x50, 0xa4, 0xc3, 0x91, 0xa9, 0x8b, 0xef,

View File

@ -16,20 +16,44 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a5d12c4e58a7c4a0, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.app.stats.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/app/stats/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/app/stats/config.proto", fileDescriptor_config_a5d12c4e58a7c4a0)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_a5d12c4e58a7c4a0 = []byte{
// 123 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0x2c, 0x28, 0xd0, 0x2f,

View File

@ -2,124 +2,122 @@ package internal
import "encoding/binary"
func ChaCha20Block(s *[16]uint32, out []byte, rounds int) {
var x0,x1,x2,x3,x4,x5,x6,x7,x8,x9,x10,x11,x12,x13,x14,x15 = s[0],s[1],s[2],s[3],s[4],s[5],s[6],s[7],s[8],s[9],s[10],s[11],s[12],s[13],s[14],s[15]
for i := 0; i < rounds; i+=2 {
var x uint32
x0+=x4
x=x12^x0
x12=(x << 16) | (x >> (32 - 16))
x8+=x12
x=x4^x8
x4=(x << 12) | (x >> (32 - 12))
x0+=x4
x=x12^x0
x12=(x << 8) | (x >> (32 - 8))
x8+=x12
x=x4^x8
x4=(x << 7) | (x >> (32 - 7))
x1+=x5
x=x13^x1
x13=(x << 16) | (x >> (32 - 16))
x9+=x13
x=x5^x9
x5=(x << 12) | (x >> (32 - 12))
x1+=x5
x=x13^x1
x13=(x << 8) | (x >> (32 - 8))
x9+=x13
x=x5^x9
x5=(x << 7) | (x >> (32 - 7))
x2+=x6
x=x14^x2
x14=(x << 16) | (x >> (32 - 16))
x10+=x14
x=x6^x10
x6=(x << 12) | (x >> (32 - 12))
x2+=x6
x=x14^x2
x14=(x << 8) | (x >> (32 - 8))
x10+=x14
x=x6^x10
x6=(x << 7) | (x >> (32 - 7))
x3+=x7
x=x15^x3
x15=(x << 16) | (x >> (32 - 16))
x11+=x15
x=x7^x11
x7=(x << 12) | (x >> (32 - 12))
x3+=x7
x=x15^x3
x15=(x << 8) | (x >> (32 - 8))
x11+=x15
x=x7^x11
x7=(x << 7) | (x >> (32 - 7))
x0+=x5
x=x15^x0
x15=(x << 16) | (x >> (32 - 16))
x10+=x15
x=x5^x10
x5=(x << 12) | (x >> (32 - 12))
x0+=x5
x=x15^x0
x15=(x << 8) | (x >> (32 - 8))
x10+=x15
x=x5^x10
x5=(x << 7) | (x >> (32 - 7))
x1+=x6
x=x12^x1
x12=(x << 16) | (x >> (32 - 16))
x11+=x12
x=x6^x11
x6=(x << 12) | (x >> (32 - 12))
x1+=x6
x=x12^x1
x12=(x << 8) | (x >> (32 - 8))
x11+=x12
x=x6^x11
x6=(x << 7) | (x >> (32 - 7))
x2+=x7
x=x13^x2
x13=(x << 16) | (x >> (32 - 16))
x8+=x13
x=x7^x8
x7=(x << 12) | (x >> (32 - 12))
x2+=x7
x=x13^x2
x13=(x << 8) | (x >> (32 - 8))
x8+=x13
x=x7^x8
x7=(x << 7) | (x >> (32 - 7))
x3+=x4
x=x14^x3
x14=(x << 16) | (x >> (32 - 16))
x9+=x14
x=x4^x9
x4=(x << 12) | (x >> (32 - 12))
x3+=x4
x=x14^x3
x14=(x << 8) | (x >> (32 - 8))
x9+=x14
x=x4^x9
x4=(x << 7) | (x >> (32 - 7))
}
binary.LittleEndian.PutUint32(out[0:4], s[0]+x0)
binary.LittleEndian.PutUint32(out[4:8], s[1]+x1)
binary.LittleEndian.PutUint32(out[8:12], s[2]+x2)
binary.LittleEndian.PutUint32(out[12:16], s[3]+x3)
binary.LittleEndian.PutUint32(out[16:20], s[4]+x4)
binary.LittleEndian.PutUint32(out[20:24], s[5]+x5)
binary.LittleEndian.PutUint32(out[24:28], s[6]+x6)
binary.LittleEndian.PutUint32(out[28:32], s[7]+x7)
binary.LittleEndian.PutUint32(out[32:36], s[8]+x8)
binary.LittleEndian.PutUint32(out[36:40], s[9]+x9)
binary.LittleEndian.PutUint32(out[40:44], s[10]+x10)
binary.LittleEndian.PutUint32(out[44:48], s[11]+x11)
binary.LittleEndian.PutUint32(out[48:52], s[12]+x12)
binary.LittleEndian.PutUint32(out[52:56], s[13]+x13)
binary.LittleEndian.PutUint32(out[56:60], s[14]+x14)
binary.LittleEndian.PutUint32(out[60:64], s[15]+x15)
}
var x0, x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15 = s[0], s[1], s[2], s[3], s[4], s[5], s[6], s[7], s[8], s[9], s[10], s[11], s[12], s[13], s[14], s[15]
for i := 0; i < rounds; i += 2 {
var x uint32
x0 += x4
x = x12 ^ x0
x12 = (x << 16) | (x >> (32 - 16))
x8 += x12
x = x4 ^ x8
x4 = (x << 12) | (x >> (32 - 12))
x0 += x4
x = x12 ^ x0
x12 = (x << 8) | (x >> (32 - 8))
x8 += x12
x = x4 ^ x8
x4 = (x << 7) | (x >> (32 - 7))
x1 += x5
x = x13 ^ x1
x13 = (x << 16) | (x >> (32 - 16))
x9 += x13
x = x5 ^ x9
x5 = (x << 12) | (x >> (32 - 12))
x1 += x5
x = x13 ^ x1
x13 = (x << 8) | (x >> (32 - 8))
x9 += x13
x = x5 ^ x9
x5 = (x << 7) | (x >> (32 - 7))
x2 += x6
x = x14 ^ x2
x14 = (x << 16) | (x >> (32 - 16))
x10 += x14
x = x6 ^ x10
x6 = (x << 12) | (x >> (32 - 12))
x2 += x6
x = x14 ^ x2
x14 = (x << 8) | (x >> (32 - 8))
x10 += x14
x = x6 ^ x10
x6 = (x << 7) | (x >> (32 - 7))
x3 += x7
x = x15 ^ x3
x15 = (x << 16) | (x >> (32 - 16))
x11 += x15
x = x7 ^ x11
x7 = (x << 12) | (x >> (32 - 12))
x3 += x7
x = x15 ^ x3
x15 = (x << 8) | (x >> (32 - 8))
x11 += x15
x = x7 ^ x11
x7 = (x << 7) | (x >> (32 - 7))
x0 += x5
x = x15 ^ x0
x15 = (x << 16) | (x >> (32 - 16))
x10 += x15
x = x5 ^ x10
x5 = (x << 12) | (x >> (32 - 12))
x0 += x5
x = x15 ^ x0
x15 = (x << 8) | (x >> (32 - 8))
x10 += x15
x = x5 ^ x10
x5 = (x << 7) | (x >> (32 - 7))
x1 += x6
x = x12 ^ x1
x12 = (x << 16) | (x >> (32 - 16))
x11 += x12
x = x6 ^ x11
x6 = (x << 12) | (x >> (32 - 12))
x1 += x6
x = x12 ^ x1
x12 = (x << 8) | (x >> (32 - 8))
x11 += x12
x = x6 ^ x11
x6 = (x << 7) | (x >> (32 - 7))
x2 += x7
x = x13 ^ x2
x13 = (x << 16) | (x >> (32 - 16))
x8 += x13
x = x7 ^ x8
x7 = (x << 12) | (x >> (32 - 12))
x2 += x7
x = x13 ^ x2
x13 = (x << 8) | (x >> (32 - 8))
x8 += x13
x = x7 ^ x8
x7 = (x << 7) | (x >> (32 - 7))
x3 += x4
x = x14 ^ x3
x14 = (x << 16) | (x >> (32 - 16))
x9 += x14
x = x4 ^ x9
x4 = (x << 12) | (x >> (32 - 12))
x3 += x4
x = x14 ^ x3
x14 = (x << 8) | (x >> (32 - 8))
x9 += x14
x = x4 ^ x9
x4 = (x << 7) | (x >> (32 - 7))
}
binary.LittleEndian.PutUint32(out[0:4], s[0]+x0)
binary.LittleEndian.PutUint32(out[4:8], s[1]+x1)
binary.LittleEndian.PutUint32(out[8:12], s[2]+x2)
binary.LittleEndian.PutUint32(out[12:16], s[3]+x3)
binary.LittleEndian.PutUint32(out[16:20], s[4]+x4)
binary.LittleEndian.PutUint32(out[20:24], s[5]+x5)
binary.LittleEndian.PutUint32(out[24:28], s[6]+x6)
binary.LittleEndian.PutUint32(out[28:32], s[7]+x7)
binary.LittleEndian.PutUint32(out[32:36], s[8]+x8)
binary.LittleEndian.PutUint32(out[36:40], s[9]+x9)
binary.LittleEndian.PutUint32(out[40:44], s[10]+x10)
binary.LittleEndian.PutUint32(out[44:48], s[11]+x11)
binary.LittleEndian.PutUint32(out[48:52], s[12]+x12)
binary.LittleEndian.PutUint32(out[52:56], s[13]+x13)
binary.LittleEndian.PutUint32(out[56:60], s[14]+x14)
binary.LittleEndian.PutUint32(out[60:64], s[15]+x15)
}

View File

@ -43,15 +43,19 @@ var Severity_value = map[string]int32{
func (x Severity) String() string {
return proto.EnumName(Severity_name, int32(x))
}
func (Severity) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (Severity) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_log_0a94e6c3ab74e541, []int{0}
}
func init() {
proto.RegisterEnum("v2ray.core.common.log.Severity", Severity_name, Severity_value)
}
func init() { proto.RegisterFile("v2ray.com/core/common/log/log.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/common/log/log.proto", fileDescriptor_log_0a94e6c3ab74e541)
}
var fileDescriptor0 = []byte{
var fileDescriptor_log_0a94e6c3ab74e541 = []byte{
// 178 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -20,13 +20,35 @@ type IPOrDomain struct {
// Types that are valid to be assigned to Address:
// *IPOrDomain_Ip
// *IPOrDomain_Domain
Address isIPOrDomain_Address `protobuf_oneof:"address"`
Address isIPOrDomain_Address `protobuf_oneof:"address"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *IPOrDomain) Reset() { *m = IPOrDomain{} }
func (m *IPOrDomain) String() string { return proto.CompactTextString(m) }
func (*IPOrDomain) ProtoMessage() {}
func (*IPOrDomain) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *IPOrDomain) Reset() { *m = IPOrDomain{} }
func (m *IPOrDomain) String() string { return proto.CompactTextString(m) }
func (*IPOrDomain) ProtoMessage() {}
func (*IPOrDomain) Descriptor() ([]byte, []int) {
return fileDescriptor_address_13498f847d6a1fae, []int{0}
}
func (m *IPOrDomain) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_IPOrDomain.Unmarshal(m, b)
}
func (m *IPOrDomain) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_IPOrDomain.Marshal(b, m, deterministic)
}
func (dst *IPOrDomain) XXX_Merge(src proto.Message) {
xxx_messageInfo_IPOrDomain.Merge(dst, src)
}
func (m *IPOrDomain) XXX_Size() int {
return xxx_messageInfo_IPOrDomain.Size(m)
}
func (m *IPOrDomain) XXX_DiscardUnknown() {
xxx_messageInfo_IPOrDomain.DiscardUnknown(m)
}
var xxx_messageInfo_IPOrDomain proto.InternalMessageInfo
type isIPOrDomain_Address interface {
isIPOrDomain_Address()
@ -115,11 +137,11 @@ func _IPOrDomain_OneofSizer(msg proto.Message) (n int) {
// address
switch x := m.Address.(type) {
case *IPOrDomain_Ip:
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(len(x.Ip)))
n += len(x.Ip)
case *IPOrDomain_Domain:
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(len(x.Domain)))
n += len(x.Domain)
case nil:
@ -133,9 +155,11 @@ func init() {
proto.RegisterType((*IPOrDomain)(nil), "v2ray.core.common.net.IPOrDomain")
}
func init() { proto.RegisterFile("v2ray.com/core/common/net/address.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/common/net/address.proto", fileDescriptor_address_13498f847d6a1fae)
}
var fileDescriptor0 = []byte{
var fileDescriptor_address_13498f847d6a1fae = []byte{
// 174 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2f, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -9,17 +9,45 @@ var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// Endpoint of a network connection.
type Endpoint struct {
Network Network `protobuf:"varint,1,opt,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
Address *IPOrDomain `protobuf:"bytes,2,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,3,opt,name=port" json:"port,omitempty"`
Network Network `protobuf:"varint,1,opt,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
Address *IPOrDomain `protobuf:"bytes,2,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,3,opt,name=port" json:"port,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Endpoint) Reset() { *m = Endpoint{} }
func (m *Endpoint) String() string { return proto.CompactTextString(m) }
func (*Endpoint) ProtoMessage() {}
func (*Endpoint) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{0} }
func (m *Endpoint) Reset() { *m = Endpoint{} }
func (m *Endpoint) String() string { return proto.CompactTextString(m) }
func (*Endpoint) ProtoMessage() {}
func (*Endpoint) Descriptor() ([]byte, []int) {
return fileDescriptor_destination_8cb120f3026d561e, []int{0}
}
func (m *Endpoint) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Endpoint.Unmarshal(m, b)
}
func (m *Endpoint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Endpoint.Marshal(b, m, deterministic)
}
func (dst *Endpoint) XXX_Merge(src proto.Message) {
xxx_messageInfo_Endpoint.Merge(dst, src)
}
func (m *Endpoint) XXX_Size() int {
return xxx_messageInfo_Endpoint.Size(m)
}
func (m *Endpoint) XXX_DiscardUnknown() {
xxx_messageInfo_Endpoint.DiscardUnknown(m)
}
var xxx_messageInfo_Endpoint proto.InternalMessageInfo
func (m *Endpoint) GetNetwork() Network {
if m != nil {
@ -46,9 +74,11 @@ func init() {
proto.RegisterType((*Endpoint)(nil), "v2ray.core.common.net.Endpoint")
}
func init() { proto.RegisterFile("v2ray.com/core/common/net/destination.proto", fileDescriptor1) }
func init() {
proto.RegisterFile("v2ray.com/core/common/net/destination.proto", fileDescriptor_destination_8cb120f3026d561e)
}
var fileDescriptor1 = []byte{
var fileDescriptor_destination_8cb120f3026d561e = []byte{
// 230 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -9,11 +9,17 @@ var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Network int32
const (
Network_Unknown Network = 0
Network_RawTCP Network = 1
Network_RawTCP Network = 1 // Deprecated: Do not use.
Network_TCP Network = 2
Network_UDP Network = 3
)
@ -34,17 +40,41 @@ var Network_value = map[string]int32{
func (x Network) String() string {
return proto.EnumName(Network_name, int32(x))
}
func (Network) EnumDescriptor() ([]byte, []int) { return fileDescriptor2, []int{0} }
func (Network) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_network_3556f7530e19df1d, []int{0}
}
// NetworkList is a list of Networks.
type NetworkList struct {
Network []Network `protobuf:"varint,1,rep,packed,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
Network []Network `protobuf:"varint,1,rep,packed,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *NetworkList) Reset() { *m = NetworkList{} }
func (m *NetworkList) String() string { return proto.CompactTextString(m) }
func (*NetworkList) ProtoMessage() {}
func (*NetworkList) Descriptor() ([]byte, []int) { return fileDescriptor2, []int{0} }
func (m *NetworkList) Reset() { *m = NetworkList{} }
func (m *NetworkList) String() string { return proto.CompactTextString(m) }
func (*NetworkList) ProtoMessage() {}
func (*NetworkList) Descriptor() ([]byte, []int) {
return fileDescriptor_network_3556f7530e19df1d, []int{0}
}
func (m *NetworkList) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_NetworkList.Unmarshal(m, b)
}
func (m *NetworkList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_NetworkList.Marshal(b, m, deterministic)
}
func (dst *NetworkList) XXX_Merge(src proto.Message) {
xxx_messageInfo_NetworkList.Merge(dst, src)
}
func (m *NetworkList) XXX_Size() int {
return xxx_messageInfo_NetworkList.Size(m)
}
func (m *NetworkList) XXX_DiscardUnknown() {
xxx_messageInfo_NetworkList.DiscardUnknown(m)
}
var xxx_messageInfo_NetworkList proto.InternalMessageInfo
func (m *NetworkList) GetNetwork() []Network {
if m != nil {
@ -58,9 +88,11 @@ func init() {
proto.RegisterEnum("v2ray.core.common.net.Network", Network_name, Network_value)
}
func init() { proto.RegisterFile("v2ray.com/core/common/net/network.proto", fileDescriptor2) }
func init() {
proto.RegisterFile("v2ray.com/core/common/net/network.proto", fileDescriptor_network_3556f7530e19df1d)
}
var fileDescriptor2 = []byte{
var fileDescriptor_network_3556f7530e19df1d = []byte{
// 198 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2f, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -9,18 +9,46 @@ var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// PortRange represents a range of ports.
type PortRange struct {
// The port that this range starts from.
From uint32 `protobuf:"varint,1,opt,name=From" json:"From,omitempty"`
// The port that this range ends with (inclusive).
To uint32 `protobuf:"varint,2,opt,name=To" json:"To,omitempty"`
To uint32 `protobuf:"varint,2,opt,name=To" json:"To,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *PortRange) Reset() { *m = PortRange{} }
func (m *PortRange) String() string { return proto.CompactTextString(m) }
func (*PortRange) ProtoMessage() {}
func (*PortRange) Descriptor() ([]byte, []int) { return fileDescriptor3, []int{0} }
func (m *PortRange) Reset() { *m = PortRange{} }
func (m *PortRange) String() string { return proto.CompactTextString(m) }
func (*PortRange) ProtoMessage() {}
func (*PortRange) Descriptor() ([]byte, []int) {
return fileDescriptor_port_8c6b320a9a741caa, []int{0}
}
func (m *PortRange) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_PortRange.Unmarshal(m, b)
}
func (m *PortRange) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_PortRange.Marshal(b, m, deterministic)
}
func (dst *PortRange) XXX_Merge(src proto.Message) {
xxx_messageInfo_PortRange.Merge(dst, src)
}
func (m *PortRange) XXX_Size() int {
return xxx_messageInfo_PortRange.Size(m)
}
func (m *PortRange) XXX_DiscardUnknown() {
xxx_messageInfo_PortRange.DiscardUnknown(m)
}
var xxx_messageInfo_PortRange proto.InternalMessageInfo
func (m *PortRange) GetFrom() uint32 {
if m != nil {
@ -40,9 +68,11 @@ func init() {
proto.RegisterType((*PortRange)(nil), "v2ray.core.common.net.PortRange")
}
func init() { proto.RegisterFile("v2ray.com/core/common/net/port.proto", fileDescriptor3) }
func init() {
proto.RegisterFile("v2ray.com/core/common/net/port.proto", fileDescriptor_port_8c6b320a9a741caa)
}
var fileDescriptor3 = []byte{
var fileDescriptor_port_8c6b320a9a741caa = []byte{
// 158 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -2,4 +2,6 @@ package ctlcmd
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Command", "Platform", "CtlCmd") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Command", "Platform", "CtlCmd")
}

View File

@ -3,8 +3,8 @@ package protocol
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import v2ray_core_transport_internet "v2ray.com/core/transport/internet"
import serial "v2ray.com/core/common/serial"
import internet "v2ray.com/core/transport/internet"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -18,23 +18,45 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type AlternativeOutboundConfig struct {
Settings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,1,opt,name=settings" json:"settings,omitempty"`
StreamSettings *v2ray_core_transport_internet.StreamConfig `protobuf:"bytes,3,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
Settings *serial.TypedMessage `protobuf:"bytes,1,opt,name=settings" json:"settings,omitempty"`
StreamSettings *internet.StreamConfig `protobuf:"bytes,3,opt,name=stream_settings,json=streamSettings" json:"stream_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *AlternativeOutboundConfig) Reset() { *m = AlternativeOutboundConfig{} }
func (m *AlternativeOutboundConfig) String() string { return proto.CompactTextString(m) }
func (*AlternativeOutboundConfig) ProtoMessage() {}
func (*AlternativeOutboundConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *AlternativeOutboundConfig) Reset() { *m = AlternativeOutboundConfig{} }
func (m *AlternativeOutboundConfig) String() string { return proto.CompactTextString(m) }
func (*AlternativeOutboundConfig) ProtoMessage() {}
func (*AlternativeOutboundConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_command_686d086a4af8406c, []int{0}
}
func (m *AlternativeOutboundConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_AlternativeOutboundConfig.Unmarshal(m, b)
}
func (m *AlternativeOutboundConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_AlternativeOutboundConfig.Marshal(b, m, deterministic)
}
func (dst *AlternativeOutboundConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_AlternativeOutboundConfig.Merge(dst, src)
}
func (m *AlternativeOutboundConfig) XXX_Size() int {
return xxx_messageInfo_AlternativeOutboundConfig.Size(m)
}
func (m *AlternativeOutboundConfig) XXX_DiscardUnknown() {
xxx_messageInfo_AlternativeOutboundConfig.DiscardUnknown(m)
}
func (m *AlternativeOutboundConfig) GetSettings() *v2ray_core_common_serial.TypedMessage {
var xxx_messageInfo_AlternativeOutboundConfig proto.InternalMessageInfo
func (m *AlternativeOutboundConfig) GetSettings() *serial.TypedMessage {
if m != nil {
return m.Settings
}
return nil
}
func (m *AlternativeOutboundConfig) GetStreamSettings() *v2ray_core_transport_internet.StreamConfig {
func (m *AlternativeOutboundConfig) GetStreamSettings() *internet.StreamConfig {
if m != nil {
return m.StreamSettings
}
@ -45,9 +67,11 @@ func init() {
proto.RegisterType((*AlternativeOutboundConfig)(nil), "v2ray.core.common.protocol.AlternativeOutboundConfig")
}
func init() { proto.RegisterFile("v2ray.com/core/common/protocol/command.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/common/protocol/command.proto", fileDescriptor_command_686d086a4af8406c)
}
var fileDescriptor0 = []byte{
var fileDescriptor_command_686d086a4af8406c = []byte{
// 262 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x90, 0xcf, 0x4a, 0xc3, 0x40,
0x10, 0x87, 0x89, 0x82, 0x94, 0x08, 0x0a, 0x39, 0x69, 0x0e, 0x22, 0x1e, 0x44, 0x50, 0x66, 0x25,

View File

@ -9,6 +9,12 @@ var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type SecurityType int32
const (
@ -40,16 +46,40 @@ var SecurityType_value = map[string]int32{
func (x SecurityType) String() string {
return proto.EnumName(SecurityType_name, int32(x))
}
func (SecurityType) EnumDescriptor() ([]byte, []int) { return fileDescriptor1, []int{0} }
type SecurityConfig struct {
Type SecurityType `protobuf:"varint,1,opt,name=type,enum=v2ray.core.common.protocol.SecurityType" json:"type,omitempty"`
func (SecurityType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_headers_22aa312cf9baa01e, []int{0}
}
func (m *SecurityConfig) Reset() { *m = SecurityConfig{} }
func (m *SecurityConfig) String() string { return proto.CompactTextString(m) }
func (*SecurityConfig) ProtoMessage() {}
func (*SecurityConfig) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{0} }
type SecurityConfig struct {
Type SecurityType `protobuf:"varint,1,opt,name=type,enum=v2ray.core.common.protocol.SecurityType" json:"type,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SecurityConfig) Reset() { *m = SecurityConfig{} }
func (m *SecurityConfig) String() string { return proto.CompactTextString(m) }
func (*SecurityConfig) ProtoMessage() {}
func (*SecurityConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_headers_22aa312cf9baa01e, []int{0}
}
func (m *SecurityConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SecurityConfig.Unmarshal(m, b)
}
func (m *SecurityConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SecurityConfig.Marshal(b, m, deterministic)
}
func (dst *SecurityConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_SecurityConfig.Merge(dst, src)
}
func (m *SecurityConfig) XXX_Size() int {
return xxx_messageInfo_SecurityConfig.Size(m)
}
func (m *SecurityConfig) XXX_DiscardUnknown() {
xxx_messageInfo_SecurityConfig.DiscardUnknown(m)
}
var xxx_messageInfo_SecurityConfig proto.InternalMessageInfo
func (m *SecurityConfig) GetType() SecurityType {
if m != nil {
@ -63,9 +93,11 @@ func init() {
proto.RegisterEnum("v2ray.core.common.protocol.SecurityType", SecurityType_name, SecurityType_value)
}
func init() { proto.RegisterFile("v2ray.com/core/common/protocol/headers.proto", fileDescriptor1) }
func init() {
proto.RegisterFile("v2ray.com/core/common/protocol/headers.proto", fileDescriptor_headers_22aa312cf9baa01e)
}
var fileDescriptor1 = []byte{
var fileDescriptor_headers_22aa312cf9baa01e = []byte{
// 252 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x29, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -3,25 +3,53 @@ package protocol
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import net "v2ray.com/core/common/net"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type ServerEndpoint struct {
Address *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,2,opt,name=port" json:"port,omitempty"`
User []*User `protobuf:"bytes,3,rep,name=user" json:"user,omitempty"`
Address *net.IPOrDomain `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,2,opt,name=port" json:"port,omitempty"`
User []*User `protobuf:"bytes,3,rep,name=user" json:"user,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ServerEndpoint) Reset() { *m = ServerEndpoint{} }
func (m *ServerEndpoint) String() string { return proto.CompactTextString(m) }
func (*ServerEndpoint) ProtoMessage() {}
func (*ServerEndpoint) Descriptor() ([]byte, []int) { return fileDescriptor2, []int{0} }
func (m *ServerEndpoint) Reset() { *m = ServerEndpoint{} }
func (m *ServerEndpoint) String() string { return proto.CompactTextString(m) }
func (*ServerEndpoint) ProtoMessage() {}
func (*ServerEndpoint) Descriptor() ([]byte, []int) {
return fileDescriptor_server_spec_67a074b27d9006d6, []int{0}
}
func (m *ServerEndpoint) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServerEndpoint.Unmarshal(m, b)
}
func (m *ServerEndpoint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServerEndpoint.Marshal(b, m, deterministic)
}
func (dst *ServerEndpoint) XXX_Merge(src proto.Message) {
xxx_messageInfo_ServerEndpoint.Merge(dst, src)
}
func (m *ServerEndpoint) XXX_Size() int {
return xxx_messageInfo_ServerEndpoint.Size(m)
}
func (m *ServerEndpoint) XXX_DiscardUnknown() {
xxx_messageInfo_ServerEndpoint.DiscardUnknown(m)
}
func (m *ServerEndpoint) GetAddress() *v2ray_core_common_net.IPOrDomain {
var xxx_messageInfo_ServerEndpoint proto.InternalMessageInfo
func (m *ServerEndpoint) GetAddress() *net.IPOrDomain {
if m != nil {
return m.Address
}
@ -46,9 +74,11 @@ func init() {
proto.RegisterType((*ServerEndpoint)(nil), "v2ray.core.common.protocol.ServerEndpoint")
}
func init() { proto.RegisterFile("v2ray.com/core/common/protocol/server_spec.proto", fileDescriptor2) }
func init() {
proto.RegisterFile("v2ray.com/core/common/protocol/server_spec.proto", fileDescriptor_server_spec_67a074b27d9006d6)
}
var fileDescriptor2 = []byte{
var fileDescriptor_server_spec_67a074b27d9006d6 = []byte{
// 241 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0xcf, 0xbd, 0x4e, 0xc3, 0x30,
0x10, 0x07, 0x70, 0xb9, 0xad, 0x00, 0xb9, 0x82, 0xc1, 0x53, 0x94, 0x01, 0x05, 0x16, 0xc2, 0x72,

View File

@ -2,4 +2,6 @@ package cert
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Protocol", "TLS", "Cert") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Protocol", "TLS", "Cert")
}

View File

@ -3,25 +3,53 @@ package protocol
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// User is a generic user for all procotols.
type User struct {
Level uint32 `protobuf:"varint,1,opt,name=level" json:"level,omitempty"`
Email string `protobuf:"bytes,2,opt,name=email" json:"email,omitempty"`
// Protocol specific account information. Must be the account proto in one of the proxies.
Account *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,3,opt,name=account" json:"account,omitempty"`
Account *serial.TypedMessage `protobuf:"bytes,3,opt,name=account" json:"account,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *User) Reset() { *m = User{} }
func (m *User) String() string { return proto.CompactTextString(m) }
func (*User) ProtoMessage() {}
func (*User) Descriptor() ([]byte, []int) { return fileDescriptor3, []int{0} }
func (m *User) Reset() { *m = User{} }
func (m *User) String() string { return proto.CompactTextString(m) }
func (*User) ProtoMessage() {}
func (*User) Descriptor() ([]byte, []int) {
return fileDescriptor_user_a061b86ad22f3a1c, []int{0}
}
func (m *User) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_User.Unmarshal(m, b)
}
func (m *User) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_User.Marshal(b, m, deterministic)
}
func (dst *User) XXX_Merge(src proto.Message) {
xxx_messageInfo_User.Merge(dst, src)
}
func (m *User) XXX_Size() int {
return xxx_messageInfo_User.Size(m)
}
func (m *User) XXX_DiscardUnknown() {
xxx_messageInfo_User.DiscardUnknown(m)
}
var xxx_messageInfo_User proto.InternalMessageInfo
func (m *User) GetLevel() uint32 {
if m != nil {
@ -37,7 +65,7 @@ func (m *User) GetEmail() string {
return ""
}
func (m *User) GetAccount() *v2ray_core_common_serial.TypedMessage {
func (m *User) GetAccount() *serial.TypedMessage {
if m != nil {
return m.Account
}
@ -48,9 +76,11 @@ func init() {
proto.RegisterType((*User)(nil), "v2ray.core.common.protocol.User")
}
func init() { proto.RegisterFile("v2ray.com/core/common/protocol/user.proto", fileDescriptor3) }
func init() {
proto.RegisterFile("v2ray.com/core/common/protocol/user.proto", fileDescriptor_user_a061b86ad22f3a1c)
}
var fileDescriptor3 = []byte{
var fileDescriptor_user_a061b86ad22f3a1c = []byte{
// 218 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2c, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -20,13 +20,35 @@ type TypedMessage struct {
// The name of the message type, retrieved from protobuf API.
Type string `protobuf:"bytes,1,opt,name=type" json:"type,omitempty"`
// Serialized proto message.
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TypedMessage) Reset() { *m = TypedMessage{} }
func (m *TypedMessage) String() string { return proto.CompactTextString(m) }
func (*TypedMessage) ProtoMessage() {}
func (*TypedMessage) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *TypedMessage) Reset() { *m = TypedMessage{} }
func (m *TypedMessage) String() string { return proto.CompactTextString(m) }
func (*TypedMessage) ProtoMessage() {}
func (*TypedMessage) Descriptor() ([]byte, []int) {
return fileDescriptor_typed_message_aa5625c6172fb59b, []int{0}
}
func (m *TypedMessage) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TypedMessage.Unmarshal(m, b)
}
func (m *TypedMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TypedMessage.Marshal(b, m, deterministic)
}
func (dst *TypedMessage) XXX_Merge(src proto.Message) {
xxx_messageInfo_TypedMessage.Merge(dst, src)
}
func (m *TypedMessage) XXX_Size() int {
return xxx_messageInfo_TypedMessage.Size(m)
}
func (m *TypedMessage) XXX_DiscardUnknown() {
xxx_messageInfo_TypedMessage.DiscardUnknown(m)
}
var xxx_messageInfo_TypedMessage proto.InternalMessageInfo
func (m *TypedMessage) GetType() string {
if m != nil {
@ -46,9 +68,11 @@ func init() {
proto.RegisterType((*TypedMessage)(nil), "v2ray.core.common.serial.TypedMessage")
}
func init() { proto.RegisterFile("v2ray.com/core/common/serial/typed_message.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/common/serial/typed_message.proto", fileDescriptor_typed_message_aa5625c6172fb59b)
}
var fileDescriptor0 = []byte{
var fileDescriptor_typed_message_aa5625c6172fb59b = []byte{
// 168 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x32, 0x28, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,

View File

@ -3,8 +3,8 @@ package core
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import v2ray_core_transport "v2ray.com/core/transport"
import serial "v2ray.com/core/common/serial"
import transport "v2ray.com/core/transport"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -24,18 +24,40 @@ type Config struct {
// Outbound handler configurations. Must have at least one item. The first item is used as default for routing.
Outbound []*OutboundHandlerConfig `protobuf:"bytes,2,rep,name=outbound" json:"outbound,omitempty"`
// App is for configurations of all features in V2Ray. A feature must implement the Feature interface, and its config type must be registered through common.RegisterConfig.
App []*v2ray_core_common_serial.TypedMessage `protobuf:"bytes,4,rep,name=app" json:"app,omitempty"`
App []*serial.TypedMessage `protobuf:"bytes,4,rep,name=app" json:"app,omitempty"`
// Transport settings.
Transport *v2ray_core_transport.Config `protobuf:"bytes,5,opt,name=transport" json:"transport,omitempty"`
Transport *transport.Config `protobuf:"bytes,5,opt,name=transport" json:"transport,omitempty"`
// Configuration for extensions. The config may not work if corresponding extension is not loaded into V2Ray.
// V2Ray will ignore such config during initialization.
Extension []*v2ray_core_common_serial.TypedMessage `protobuf:"bytes,6,rep,name=extension" json:"extension,omitempty"`
Extension []*serial.TypedMessage `protobuf:"bytes,6,rep,name=extension" json:"extension,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_aee233fb2b85ca90, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetInbound() []*InboundHandlerConfig {
if m != nil {
@ -51,21 +73,21 @@ func (m *Config) GetOutbound() []*OutboundHandlerConfig {
return nil
}
func (m *Config) GetApp() []*v2ray_core_common_serial.TypedMessage {
func (m *Config) GetApp() []*serial.TypedMessage {
if m != nil {
return m.App
}
return nil
}
func (m *Config) GetTransport() *v2ray_core_transport.Config {
func (m *Config) GetTransport() *transport.Config {
if m != nil {
return m.Transport
}
return nil
}
func (m *Config) GetExtension() []*v2ray_core_common_serial.TypedMessage {
func (m *Config) GetExtension() []*serial.TypedMessage {
if m != nil {
return m.Extension
}
@ -77,15 +99,37 @@ type InboundHandlerConfig struct {
// Tag of the inbound handler. The tag must be unique among all inbound handlers
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
// Settings for how this inbound proxy is handled.
ReceiverSettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=receiver_settings,json=receiverSettings" json:"receiver_settings,omitempty"`
ReceiverSettings *serial.TypedMessage `protobuf:"bytes,2,opt,name=receiver_settings,json=receiverSettings" json:"receiver_settings,omitempty"`
// Settings for inbound proxy. Must be one of the inbound proxies.
ProxySettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
ProxySettings *serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *InboundHandlerConfig) Reset() { *m = InboundHandlerConfig{} }
func (m *InboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*InboundHandlerConfig) ProtoMessage() {}
func (*InboundHandlerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *InboundHandlerConfig) Reset() { *m = InboundHandlerConfig{} }
func (m *InboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*InboundHandlerConfig) ProtoMessage() {}
func (*InboundHandlerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_aee233fb2b85ca90, []int{1}
}
func (m *InboundHandlerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_InboundHandlerConfig.Unmarshal(m, b)
}
func (m *InboundHandlerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_InboundHandlerConfig.Marshal(b, m, deterministic)
}
func (dst *InboundHandlerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_InboundHandlerConfig.Merge(dst, src)
}
func (m *InboundHandlerConfig) XXX_Size() int {
return xxx_messageInfo_InboundHandlerConfig.Size(m)
}
func (m *InboundHandlerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_InboundHandlerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_InboundHandlerConfig proto.InternalMessageInfo
func (m *InboundHandlerConfig) GetTag() string {
if m != nil {
@ -94,14 +138,14 @@ func (m *InboundHandlerConfig) GetTag() string {
return ""
}
func (m *InboundHandlerConfig) GetReceiverSettings() *v2ray_core_common_serial.TypedMessage {
func (m *InboundHandlerConfig) GetReceiverSettings() *serial.TypedMessage {
if m != nil {
return m.ReceiverSettings
}
return nil
}
func (m *InboundHandlerConfig) GetProxySettings() *v2ray_core_common_serial.TypedMessage {
func (m *InboundHandlerConfig) GetProxySettings() *serial.TypedMessage {
if m != nil {
return m.ProxySettings
}
@ -113,19 +157,41 @@ type OutboundHandlerConfig struct {
// Tag of this outbound handler.
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
// Settings for how to dial connection for this outbound handler.
SenderSettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=sender_settings,json=senderSettings" json:"sender_settings,omitempty"`
SenderSettings *serial.TypedMessage `protobuf:"bytes,2,opt,name=sender_settings,json=senderSettings" json:"sender_settings,omitempty"`
// Settings for this outbound proxy. Must be one of the outbound proxies.
ProxySettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
ProxySettings *serial.TypedMessage `protobuf:"bytes,3,opt,name=proxy_settings,json=proxySettings" json:"proxy_settings,omitempty"`
// If not zero, this outbound will be expired in seconds. Not used for now.
Expire int64 `protobuf:"varint,4,opt,name=expire" json:"expire,omitempty"`
// Comment of this outbound handler. Not used for now.
Comment string `protobuf:"bytes,5,opt,name=comment" json:"comment,omitempty"`
Comment string `protobuf:"bytes,5,opt,name=comment" json:"comment,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *OutboundHandlerConfig) Reset() { *m = OutboundHandlerConfig{} }
func (m *OutboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*OutboundHandlerConfig) ProtoMessage() {}
func (*OutboundHandlerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *OutboundHandlerConfig) Reset() { *m = OutboundHandlerConfig{} }
func (m *OutboundHandlerConfig) String() string { return proto.CompactTextString(m) }
func (*OutboundHandlerConfig) ProtoMessage() {}
func (*OutboundHandlerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_aee233fb2b85ca90, []int{2}
}
func (m *OutboundHandlerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OutboundHandlerConfig.Unmarshal(m, b)
}
func (m *OutboundHandlerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_OutboundHandlerConfig.Marshal(b, m, deterministic)
}
func (dst *OutboundHandlerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_OutboundHandlerConfig.Merge(dst, src)
}
func (m *OutboundHandlerConfig) XXX_Size() int {
return xxx_messageInfo_OutboundHandlerConfig.Size(m)
}
func (m *OutboundHandlerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_OutboundHandlerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_OutboundHandlerConfig proto.InternalMessageInfo
func (m *OutboundHandlerConfig) GetTag() string {
if m != nil {
@ -134,14 +200,14 @@ func (m *OutboundHandlerConfig) GetTag() string {
return ""
}
func (m *OutboundHandlerConfig) GetSenderSettings() *v2ray_core_common_serial.TypedMessage {
func (m *OutboundHandlerConfig) GetSenderSettings() *serial.TypedMessage {
if m != nil {
return m.SenderSettings
}
return nil
}
func (m *OutboundHandlerConfig) GetProxySettings() *v2ray_core_common_serial.TypedMessage {
func (m *OutboundHandlerConfig) GetProxySettings() *serial.TypedMessage {
if m != nil {
return m.ProxySettings
}
@ -168,9 +234,9 @@ func init() {
proto.RegisterType((*OutboundHandlerConfig)(nil), "v2ray.core.OutboundHandlerConfig")
}
func init() { proto.RegisterFile("v2ray.com/core/config.proto", fileDescriptor0) }
func init() { proto.RegisterFile("v2ray.com/core/config.proto", fileDescriptor_config_aee233fb2b85ca90) }
var fileDescriptor0 = []byte{
var fileDescriptor_config_aee233fb2b85ca90 = []byte{
// 405 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x93, 0x41, 0x6f, 0x94, 0x40,
0x1c, 0xc5, 0x33, 0x0b, 0x6e, 0xcb, 0xbf, 0x71, 0x5d, 0x27, 0x6a, 0x26, 0xd5, 0x03, 0x6e, 0x52,

View File

@ -2,4 +2,6 @@ package confloader
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Main", "ConfLoader") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Main", "ConfLoader")
}

View File

@ -2,4 +2,6 @@ package external
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Main", "ConfLoader", "External") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Main", "ConfLoader", "External")
}

View File

@ -3,7 +3,7 @@ package blackhole
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -17,31 +17,97 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type NoneResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *NoneResponse) Reset() { *m = NoneResponse{} }
func (m *NoneResponse) String() string { return proto.CompactTextString(m) }
func (*NoneResponse) ProtoMessage() {}
func (*NoneResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *NoneResponse) Reset() { *m = NoneResponse{} }
func (m *NoneResponse) String() string { return proto.CompactTextString(m) }
func (*NoneResponse) ProtoMessage() {}
func (*NoneResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9e2968d90a4a62fe, []int{0}
}
func (m *NoneResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_NoneResponse.Unmarshal(m, b)
}
func (m *NoneResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_NoneResponse.Marshal(b, m, deterministic)
}
func (dst *NoneResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_NoneResponse.Merge(dst, src)
}
func (m *NoneResponse) XXX_Size() int {
return xxx_messageInfo_NoneResponse.Size(m)
}
func (m *NoneResponse) XXX_DiscardUnknown() {
xxx_messageInfo_NoneResponse.DiscardUnknown(m)
}
var xxx_messageInfo_NoneResponse proto.InternalMessageInfo
type HTTPResponse struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *HTTPResponse) Reset() { *m = HTTPResponse{} }
func (m *HTTPResponse) String() string { return proto.CompactTextString(m) }
func (*HTTPResponse) ProtoMessage() {}
func (*HTTPResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *HTTPResponse) Reset() { *m = HTTPResponse{} }
func (m *HTTPResponse) String() string { return proto.CompactTextString(m) }
func (*HTTPResponse) ProtoMessage() {}
func (*HTTPResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9e2968d90a4a62fe, []int{1}
}
func (m *HTTPResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_HTTPResponse.Unmarshal(m, b)
}
func (m *HTTPResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_HTTPResponse.Marshal(b, m, deterministic)
}
func (dst *HTTPResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_HTTPResponse.Merge(dst, src)
}
func (m *HTTPResponse) XXX_Size() int {
return xxx_messageInfo_HTTPResponse.Size(m)
}
func (m *HTTPResponse) XXX_DiscardUnknown() {
xxx_messageInfo_HTTPResponse.DiscardUnknown(m)
}
var xxx_messageInfo_HTTPResponse proto.InternalMessageInfo
type Config struct {
Response *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,1,opt,name=response" json:"response,omitempty"`
Response *serial.TypedMessage `protobuf:"bytes,1,opt,name=response" json:"response,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9e2968d90a4a62fe, []int{2}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetResponse() *v2ray_core_common_serial.TypedMessage {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetResponse() *serial.TypedMessage {
if m != nil {
return m.Response
}
@ -54,9 +120,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.proxy.blackhole.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/blackhole/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/blackhole/config.proto", fileDescriptor_config_9e2968d90a4a62fe)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_9e2968d90a4a62fe = []byte{
// 217 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x28, 0xca, 0xaf, 0xa8,

View File

@ -2,4 +2,6 @@ package blackhole
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "Blackhole") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "Blackhole")
}

View File

@ -3,8 +3,7 @@ package dokodemo
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_net1 "v2ray.com/core/common/net"
import net "v2ray.com/core/common/net"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -18,20 +17,42 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
Address *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,2,opt,name=port" json:"port,omitempty"`
NetworkList *v2ray_core_common_net1.NetworkList `protobuf:"bytes,3,opt,name=network_list,json=networkList" json:"network_list,omitempty"`
Timeout uint32 `protobuf:"varint,4,opt,name=timeout" json:"timeout,omitempty"`
FollowRedirect bool `protobuf:"varint,5,opt,name=follow_redirect,json=followRedirect" json:"follow_redirect,omitempty"`
UserLevel uint32 `protobuf:"varint,6,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
Address *net.IPOrDomain `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
Port uint32 `protobuf:"varint,2,opt,name=port" json:"port,omitempty"`
NetworkList *net.NetworkList `protobuf:"bytes,3,opt,name=network_list,json=networkList" json:"network_list,omitempty"`
Timeout uint32 `protobuf:"varint,4,opt,name=timeout" json:"timeout,omitempty"` // Deprecated: Do not use.
FollowRedirect bool `protobuf:"varint,5,opt,name=follow_redirect,json=followRedirect" json:"follow_redirect,omitempty"`
UserLevel uint32 `protobuf:"varint,6,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_3c1cd7fe1501fc6c, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetAddress() *v2ray_core_common_net.IPOrDomain {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetAddress() *net.IPOrDomain {
if m != nil {
return m.Address
}
@ -45,13 +66,14 @@ func (m *Config) GetPort() uint32 {
return 0
}
func (m *Config) GetNetworkList() *v2ray_core_common_net1.NetworkList {
func (m *Config) GetNetworkList() *net.NetworkList {
if m != nil {
return m.NetworkList
}
return nil
}
// Deprecated: Do not use.
func (m *Config) GetTimeout() uint32 {
if m != nil {
return m.Timeout
@ -77,9 +99,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.proxy.dokodemo.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/dokodemo/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/dokodemo/config.proto", fileDescriptor_config_3c1cd7fe1501fc6c)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_3c1cd7fe1501fc6c = []byte{
// 310 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x90, 0xcf, 0x4e, 0xc2, 0x40,
0x10, 0x87, 0xd3, 0x8a, 0x80, 0x8b, 0x7f, 0x92, 0x3d, 0x2d, 0x46, 0x12, 0xe4, 0x02, 0xf1, 0xb0,

View File

@ -2,4 +2,6 @@ package dokodemo
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "Dokodemo") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "Dokodemo")
}

View File

@ -3,7 +3,7 @@ package freedom
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_protocol1 "v2ray.com/core/common/protocol"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -35,18 +35,42 @@ var Config_DomainStrategy_value = map[string]int32{
func (x Config_DomainStrategy) String() string {
return proto.EnumName(Config_DomainStrategy_name, int32(x))
}
func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{1, 0} }
type DestinationOverride struct {
Server *v2ray_core_common_protocol1.ServerEndpoint `protobuf:"bytes,1,opt,name=server" json:"server,omitempty"`
func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_9714d01f3d402353, []int{1, 0}
}
func (m *DestinationOverride) Reset() { *m = DestinationOverride{} }
func (m *DestinationOverride) String() string { return proto.CompactTextString(m) }
func (*DestinationOverride) ProtoMessage() {}
func (*DestinationOverride) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type DestinationOverride struct {
Server *protocol.ServerEndpoint `protobuf:"bytes,1,opt,name=server" json:"server,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *DestinationOverride) GetServer() *v2ray_core_common_protocol1.ServerEndpoint {
func (m *DestinationOverride) Reset() { *m = DestinationOverride{} }
func (m *DestinationOverride) String() string { return proto.CompactTextString(m) }
func (*DestinationOverride) ProtoMessage() {}
func (*DestinationOverride) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9714d01f3d402353, []int{0}
}
func (m *DestinationOverride) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DestinationOverride.Unmarshal(m, b)
}
func (m *DestinationOverride) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DestinationOverride.Marshal(b, m, deterministic)
}
func (dst *DestinationOverride) XXX_Merge(src proto.Message) {
xxx_messageInfo_DestinationOverride.Merge(dst, src)
}
func (m *DestinationOverride) XXX_Size() int {
return xxx_messageInfo_DestinationOverride.Size(m)
}
func (m *DestinationOverride) XXX_DiscardUnknown() {
xxx_messageInfo_DestinationOverride.DiscardUnknown(m)
}
var xxx_messageInfo_DestinationOverride proto.InternalMessageInfo
func (m *DestinationOverride) GetServer() *protocol.ServerEndpoint {
if m != nil {
return m.Server
}
@ -54,16 +78,38 @@ func (m *DestinationOverride) GetServer() *v2ray_core_common_protocol1.ServerEnd
}
type Config struct {
DomainStrategy Config_DomainStrategy `protobuf:"varint,1,opt,name=domain_strategy,json=domainStrategy,enum=v2ray.core.proxy.freedom.Config_DomainStrategy" json:"domain_strategy,omitempty"`
Timeout uint32 `protobuf:"varint,2,opt,name=timeout" json:"timeout,omitempty"`
DestinationOverride *DestinationOverride `protobuf:"bytes,3,opt,name=destination_override,json=destinationOverride" json:"destination_override,omitempty"`
UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
DomainStrategy Config_DomainStrategy `protobuf:"varint,1,opt,name=domain_strategy,json=domainStrategy,enum=v2ray.core.proxy.freedom.Config_DomainStrategy" json:"domain_strategy,omitempty"`
Timeout uint32 `protobuf:"varint,2,opt,name=timeout" json:"timeout,omitempty"` // Deprecated: Do not use.
DestinationOverride *DestinationOverride `protobuf:"bytes,3,opt,name=destination_override,json=destinationOverride" json:"destination_override,omitempty"`
UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9714d01f3d402353, []int{1}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetDomainStrategy() Config_DomainStrategy {
if m != nil {
@ -72,6 +118,7 @@ func (m *Config) GetDomainStrategy() Config_DomainStrategy {
return Config_AS_IS
}
// Deprecated: Do not use.
func (m *Config) GetTimeout() uint32 {
if m != nil {
return m.Timeout
@ -99,9 +146,11 @@ func init() {
proto.RegisterEnum("v2ray.core.proxy.freedom.Config_DomainStrategy", Config_DomainStrategy_name, Config_DomainStrategy_value)
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/freedom/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/freedom/config.proto", fileDescriptor_config_9714d01f3d402353)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_9714d01f3d402353 = []byte{
// 340 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0x6f, 0x4b, 0x83, 0x50,
0x14, 0xc6, 0xd3, 0xca, 0xb1, 0x13, 0xad, 0xe1, 0x7a, 0x21, 0xb1, 0x60, 0xec, 0x4d, 0x2b, 0xe8,

View File

@ -2,4 +2,6 @@ package freedom
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "Freedom") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "Freedom")
}

View File

@ -17,17 +17,40 @@ const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// Config for HTTP proxy server.
type ServerConfig struct {
Timeout uint32 `protobuf:"varint,1,opt,name=timeout" json:"timeout,omitempty"`
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"`
AllowTransparent bool `protobuf:"varint,3,opt,name=allow_transparent,json=allowTransparent" json:"allow_transparent,omitempty"`
UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
Timeout uint32 `protobuf:"varint,1,opt,name=timeout" json:"timeout,omitempty"` // Deprecated: Do not use.
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"`
AllowTransparent bool `protobuf:"varint,3,opt,name=allow_transparent,json=allowTransparent" json:"allow_transparent,omitempty"`
UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_593308a66adc1606, []int{0}
}
func (m *ServerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServerConfig.Unmarshal(m, b)
}
func (m *ServerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServerConfig.Marshal(b, m, deterministic)
}
func (dst *ServerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ServerConfig.Merge(dst, src)
}
func (m *ServerConfig) XXX_Size() int {
return xxx_messageInfo_ServerConfig.Size(m)
}
func (m *ServerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ServerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ServerConfig proto.InternalMessageInfo
// Deprecated: Do not use.
func (m *ServerConfig) GetTimeout() uint32 {
if m != nil {
return m.Timeout
@ -58,21 +81,46 @@ func (m *ServerConfig) GetUserLevel() uint32 {
// ClientConfig for HTTP proxy client.
type ClientConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_593308a66adc1606, []int{1}
}
func (m *ClientConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ClientConfig.Unmarshal(m, b)
}
func (m *ClientConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ClientConfig.Marshal(b, m, deterministic)
}
func (dst *ClientConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ClientConfig.Merge(dst, src)
}
func (m *ClientConfig) XXX_Size() int {
return xxx_messageInfo_ClientConfig.Size(m)
}
func (m *ClientConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ClientConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ClientConfig proto.InternalMessageInfo
func init() {
proto.RegisterType((*ServerConfig)(nil), "v2ray.core.proxy.http.ServerConfig")
proto.RegisterMapType((map[string]string)(nil), "v2ray.core.proxy.http.ServerConfig.AccountsEntry")
proto.RegisterType((*ClientConfig)(nil), "v2ray.core.proxy.http.ClientConfig")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/http/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/http/config.proto", fileDescriptor_config_593308a66adc1606)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_593308a66adc1606 = []byte{
// 296 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0xcf, 0x4a, 0x33, 0x31,
0x14, 0xc5, 0x99, 0x69, 0xbf, 0xcf, 0xf6, 0xda, 0x4a, 0x0d, 0x16, 0x46, 0x51, 0x28, 0x5d, 0x48,

View File

@ -3,9 +3,8 @@ package shadowsocks
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_protocol "v2ray.com/core/common/protocol"
import v2ray_core_common_protocol1 "v2ray.com/core/common/protocol"
import net "v2ray.com/core/common/net"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -58,7 +57,9 @@ var CipherType_value = map[string]int32{
func (x CipherType) String() string {
return proto.EnumName(CipherType_name, int32(x))
}
func (CipherType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (CipherType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_655e5edd5746da74, []int{0}
}
type Account_OneTimeAuth int32
@ -82,18 +83,42 @@ var Account_OneTimeAuth_value = map[string]int32{
func (x Account_OneTimeAuth) String() string {
return proto.EnumName(Account_OneTimeAuth_name, int32(x))
}
func (Account_OneTimeAuth) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
type Account struct {
Password string `protobuf:"bytes,1,opt,name=password" json:"password,omitempty"`
CipherType CipherType `protobuf:"varint,2,opt,name=cipher_type,json=cipherType,enum=v2ray.core.proxy.shadowsocks.CipherType" json:"cipher_type,omitempty"`
Ota Account_OneTimeAuth `protobuf:"varint,3,opt,name=ota,enum=v2ray.core.proxy.shadowsocks.Account_OneTimeAuth" json:"ota,omitempty"`
func (Account_OneTimeAuth) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_655e5edd5746da74, []int{0, 0}
}
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type Account struct {
Password string `protobuf:"bytes,1,opt,name=password" json:"password,omitempty"`
CipherType CipherType `protobuf:"varint,2,opt,name=cipher_type,json=cipherType,enum=v2ray.core.proxy.shadowsocks.CipherType" json:"cipher_type,omitempty"`
Ota Account_OneTimeAuth `protobuf:"varint,3,opt,name=ota,enum=v2ray.core.proxy.shadowsocks.Account_OneTimeAuth" json:"ota,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) {
return fileDescriptor_config_655e5edd5746da74, []int{0}
}
func (m *Account) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Account.Unmarshal(m, b)
}
func (m *Account) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Account.Marshal(b, m, deterministic)
}
func (dst *Account) XXX_Merge(src proto.Message) {
xxx_messageInfo_Account.Merge(dst, src)
}
func (m *Account) XXX_Size() int {
return xxx_messageInfo_Account.Size(m)
}
func (m *Account) XXX_DiscardUnknown() {
xxx_messageInfo_Account.DiscardUnknown(m)
}
var xxx_messageInfo_Account proto.InternalMessageInfo
func (m *Account) GetPassword() string {
if m != nil {
@ -119,16 +144,39 @@ func (m *Account) GetOta() Account_OneTimeAuth {
type ServerConfig struct {
// UdpEnabled specified whether or not to enable UDP for Shadowsocks.
// Deprecated. Use 'network' field.
UdpEnabled bool `protobuf:"varint,1,opt,name=udp_enabled,json=udpEnabled" json:"udp_enabled,omitempty"`
User *v2ray_core_common_protocol.User `protobuf:"bytes,2,opt,name=user" json:"user,omitempty"`
Network []v2ray_core_common_net.Network `protobuf:"varint,3,rep,packed,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
UdpEnabled bool `protobuf:"varint,1,opt,name=udp_enabled,json=udpEnabled" json:"udp_enabled,omitempty"` // Deprecated: Do not use.
User *protocol.User `protobuf:"bytes,2,opt,name=user" json:"user,omitempty"`
Network []net.Network `protobuf:"varint,3,rep,packed,name=network,enum=v2ray.core.common.net.Network" json:"network,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_655e5edd5746da74, []int{1}
}
func (m *ServerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServerConfig.Unmarshal(m, b)
}
func (m *ServerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServerConfig.Marshal(b, m, deterministic)
}
func (dst *ServerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ServerConfig.Merge(dst, src)
}
func (m *ServerConfig) XXX_Size() int {
return xxx_messageInfo_ServerConfig.Size(m)
}
func (m *ServerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ServerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ServerConfig proto.InternalMessageInfo
// Deprecated: Do not use.
func (m *ServerConfig) GetUdpEnabled() bool {
if m != nil {
return m.UdpEnabled
@ -136,14 +184,14 @@ func (m *ServerConfig) GetUdpEnabled() bool {
return false
}
func (m *ServerConfig) GetUser() *v2ray_core_common_protocol.User {
func (m *ServerConfig) GetUser() *protocol.User {
if m != nil {
return m.User
}
return nil
}
func (m *ServerConfig) GetNetwork() []v2ray_core_common_net.Network {
func (m *ServerConfig) GetNetwork() []net.Network {
if m != nil {
return m.Network
}
@ -151,15 +199,37 @@ func (m *ServerConfig) GetNetwork() []v2ray_core_common_net.Network {
}
type ClientConfig struct {
Server []*v2ray_core_common_protocol1.ServerEndpoint `protobuf:"bytes,1,rep,name=server" json:"server,omitempty"`
Server []*protocol.ServerEndpoint `protobuf:"bytes,1,rep,name=server" json:"server,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_655e5edd5746da74, []int{2}
}
func (m *ClientConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ClientConfig.Unmarshal(m, b)
}
func (m *ClientConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ClientConfig.Marshal(b, m, deterministic)
}
func (dst *ClientConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ClientConfig.Merge(dst, src)
}
func (m *ClientConfig) XXX_Size() int {
return xxx_messageInfo_ClientConfig.Size(m)
}
func (m *ClientConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ClientConfig.DiscardUnknown(m)
}
func (m *ClientConfig) GetServer() []*v2ray_core_common_protocol1.ServerEndpoint {
var xxx_messageInfo_ClientConfig proto.InternalMessageInfo
func (m *ClientConfig) GetServer() []*protocol.ServerEndpoint {
if m != nil {
return m.Server
}
@ -174,9 +244,11 @@ func init() {
proto.RegisterEnum("v2ray.core.proxy.shadowsocks.Account_OneTimeAuth", Account_OneTimeAuth_name, Account_OneTimeAuth_value)
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/shadowsocks/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/shadowsocks/config.proto", fileDescriptor_config_655e5edd5746da74)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_655e5edd5746da74 = []byte{
// 522 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0xc1, 0x6e, 0xd3, 0x4e,
0x10, 0xc6, 0xbb, 0x71, 0xff, 0x4d, 0xfe, 0xe3, 0x50, 0xdc, 0x95, 0x90, 0xac, 0xa8, 0x42, 0x56,

View File

@ -2,4 +2,6 @@ package shadowsocks
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "Shadowsocks") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "Shadowsocks")
}

View File

@ -3,8 +3,8 @@ package socks
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_net "v2ray.com/core/common/net"
import v2ray_core_common_protocol1 "v2ray.com/core/common/protocol"
import net "v2ray.com/core/common/net"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -36,17 +36,41 @@ var AuthType_value = map[string]int32{
func (x AuthType) String() string {
return proto.EnumName(AuthType_name, int32(x))
}
func (AuthType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type Account struct {
Username string `protobuf:"bytes,1,opt,name=username" json:"username,omitempty"`
Password string `protobuf:"bytes,2,opt,name=password" json:"password,omitempty"`
func (AuthType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_45beb3f2ac36b2a3, []int{0}
}
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type Account struct {
Username string `protobuf:"bytes,1,opt,name=username" json:"username,omitempty"`
Password string `protobuf:"bytes,2,opt,name=password" json:"password,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) {
return fileDescriptor_config_45beb3f2ac36b2a3, []int{0}
}
func (m *Account) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Account.Unmarshal(m, b)
}
func (m *Account) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Account.Marshal(b, m, deterministic)
}
func (dst *Account) XXX_Merge(src proto.Message) {
xxx_messageInfo_Account.Merge(dst, src)
}
func (m *Account) XXX_Size() int {
return xxx_messageInfo_Account.Size(m)
}
func (m *Account) XXX_DiscardUnknown() {
xxx_messageInfo_Account.DiscardUnknown(m)
}
var xxx_messageInfo_Account proto.InternalMessageInfo
func (m *Account) GetUsername() string {
if m != nil {
@ -63,18 +87,40 @@ func (m *Account) GetPassword() string {
}
type ServerConfig struct {
AuthType AuthType `protobuf:"varint,1,opt,name=auth_type,json=authType,enum=v2ray.core.proxy.socks.AuthType" json:"auth_type,omitempty"`
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"`
Address *v2ray_core_common_net.IPOrDomain `protobuf:"bytes,3,opt,name=address" json:"address,omitempty"`
UdpEnabled bool `protobuf:"varint,4,opt,name=udp_enabled,json=udpEnabled" json:"udp_enabled,omitempty"`
Timeout uint32 `protobuf:"varint,5,opt,name=timeout" json:"timeout,omitempty"`
UserLevel uint32 `protobuf:"varint,6,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
AuthType AuthType `protobuf:"varint,1,opt,name=auth_type,json=authType,enum=v2ray.core.proxy.socks.AuthType" json:"auth_type,omitempty"`
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"`
Address *net.IPOrDomain `protobuf:"bytes,3,opt,name=address" json:"address,omitempty"`
UdpEnabled bool `protobuf:"varint,4,opt,name=udp_enabled,json=udpEnabled" json:"udp_enabled,omitempty"`
Timeout uint32 `protobuf:"varint,5,opt,name=timeout" json:"timeout,omitempty"` // Deprecated: Do not use.
UserLevel uint32 `protobuf:"varint,6,opt,name=user_level,json=userLevel" json:"user_level,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_45beb3f2ac36b2a3, []int{1}
}
func (m *ServerConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServerConfig.Unmarshal(m, b)
}
func (m *ServerConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServerConfig.Marshal(b, m, deterministic)
}
func (dst *ServerConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ServerConfig.Merge(dst, src)
}
func (m *ServerConfig) XXX_Size() int {
return xxx_messageInfo_ServerConfig.Size(m)
}
func (m *ServerConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ServerConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ServerConfig proto.InternalMessageInfo
func (m *ServerConfig) GetAuthType() AuthType {
if m != nil {
@ -90,7 +136,7 @@ func (m *ServerConfig) GetAccounts() map[string]string {
return nil
}
func (m *ServerConfig) GetAddress() *v2ray_core_common_net.IPOrDomain {
func (m *ServerConfig) GetAddress() *net.IPOrDomain {
if m != nil {
return m.Address
}
@ -104,6 +150,7 @@ func (m *ServerConfig) GetUdpEnabled() bool {
return false
}
// Deprecated: Do not use.
func (m *ServerConfig) GetTimeout() uint32 {
if m != nil {
return m.Timeout
@ -119,15 +166,37 @@ func (m *ServerConfig) GetUserLevel() uint32 {
}
type ClientConfig struct {
Server []*v2ray_core_common_protocol1.ServerEndpoint `protobuf:"bytes,1,rep,name=server" json:"server,omitempty"`
Server []*protocol.ServerEndpoint `protobuf:"bytes,1,rep,name=server" json:"server,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_45beb3f2ac36b2a3, []int{2}
}
func (m *ClientConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ClientConfig.Unmarshal(m, b)
}
func (m *ClientConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ClientConfig.Marshal(b, m, deterministic)
}
func (dst *ClientConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ClientConfig.Merge(dst, src)
}
func (m *ClientConfig) XXX_Size() int {
return xxx_messageInfo_ClientConfig.Size(m)
}
func (m *ClientConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ClientConfig.DiscardUnknown(m)
}
func (m *ClientConfig) GetServer() []*v2ray_core_common_protocol1.ServerEndpoint {
var xxx_messageInfo_ClientConfig proto.InternalMessageInfo
func (m *ClientConfig) GetServer() []*protocol.ServerEndpoint {
if m != nil {
return m.Server
}
@ -137,13 +206,16 @@ func (m *ClientConfig) GetServer() []*v2ray_core_common_protocol1.ServerEndpoint
func init() {
proto.RegisterType((*Account)(nil), "v2ray.core.proxy.socks.Account")
proto.RegisterType((*ServerConfig)(nil), "v2ray.core.proxy.socks.ServerConfig")
proto.RegisterMapType((map[string]string)(nil), "v2ray.core.proxy.socks.ServerConfig.AccountsEntry")
proto.RegisterType((*ClientConfig)(nil), "v2ray.core.proxy.socks.ClientConfig")
proto.RegisterEnum("v2ray.core.proxy.socks.AuthType", AuthType_name, AuthType_value)
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/socks/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/socks/config.proto", fileDescriptor_config_45beb3f2ac36b2a3)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_45beb3f2ac36b2a3 = []byte{
// 470 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x52, 0x5d, 0x8b, 0xd3, 0x40,
0x14, 0x75, 0xb2, 0xb6, 0x4d, 0x6f, 0xbb, 0x52, 0x06, 0x59, 0x42, 0x51, 0x8c, 0x05, 0xb1, 0xec,

View File

@ -2,4 +2,6 @@ package socks
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "Socks") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "Socks")
}

View File

@ -3,7 +3,7 @@ package vmess
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_protocol "v2ray.com/core/common/protocol"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -22,13 +22,35 @@ type Account struct {
// Number of alternative IDs. Client and server must share the same number.
AlterId uint32 `protobuf:"varint,2,opt,name=alter_id,json=alterId" json:"alter_id,omitempty"`
// Security settings. Only applies to client side.
SecuritySettings *v2ray_core_common_protocol.SecurityConfig `protobuf:"bytes,3,opt,name=security_settings,json=securitySettings" json:"security_settings,omitempty"`
SecuritySettings *protocol.SecurityConfig `protobuf:"bytes,3,opt,name=security_settings,json=securitySettings" json:"security_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Account) Reset() { *m = Account{} }
func (m *Account) String() string { return proto.CompactTextString(m) }
func (*Account) ProtoMessage() {}
func (*Account) Descriptor() ([]byte, []int) {
return fileDescriptor_account_c0bcd79d652bbf86, []int{0}
}
func (m *Account) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Account.Unmarshal(m, b)
}
func (m *Account) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Account.Marshal(b, m, deterministic)
}
func (dst *Account) XXX_Merge(src proto.Message) {
xxx_messageInfo_Account.Merge(dst, src)
}
func (m *Account) XXX_Size() int {
return xxx_messageInfo_Account.Size(m)
}
func (m *Account) XXX_DiscardUnknown() {
xxx_messageInfo_Account.DiscardUnknown(m)
}
var xxx_messageInfo_Account proto.InternalMessageInfo
func (m *Account) GetId() string {
if m != nil {
@ -44,7 +66,7 @@ func (m *Account) GetAlterId() uint32 {
return 0
}
func (m *Account) GetSecuritySettings() *v2ray_core_common_protocol.SecurityConfig {
func (m *Account) GetSecuritySettings() *protocol.SecurityConfig {
if m != nil {
return m.SecuritySettings
}
@ -55,9 +77,11 @@ func init() {
proto.RegisterType((*Account)(nil), "v2ray.core.proxy.vmess.Account")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/vmess/account.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/vmess/account.proto", fileDescriptor_account_c0bcd79d652bbf86)
}
var fileDescriptor0 = []byte{
var fileDescriptor_account_c0bcd79d652bbf86 = []byte{
// 244 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x8f, 0xc1, 0x4a, 0x03, 0x31,
0x10, 0x86, 0xc9, 0x8a, 0x56, 0x23, 0x8a, 0xee, 0xa1, 0xac, 0x3d, 0x2d, 0x9e, 0x16, 0x91, 0x09,

View File

@ -2,4 +2,6 @@ package encoding
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "VMess", "Encoding") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "VMess", "Encoding")
}

View File

@ -2,4 +2,6 @@ package vmess
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "VMess") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "VMess")
}

View File

@ -3,7 +3,7 @@ package inbound
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_protocol "v2ray.com/core/common/protocol"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -17,13 +17,35 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type DetourConfig struct {
To string `protobuf:"bytes,1,opt,name=to" json:"to,omitempty"`
To string `protobuf:"bytes,1,opt,name=to" json:"to,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *DetourConfig) Reset() { *m = DetourConfig{} }
func (m *DetourConfig) String() string { return proto.CompactTextString(m) }
func (*DetourConfig) ProtoMessage() {}
func (*DetourConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *DetourConfig) Reset() { *m = DetourConfig{} }
func (m *DetourConfig) String() string { return proto.CompactTextString(m) }
func (*DetourConfig) ProtoMessage() {}
func (*DetourConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_72992bea2627a574, []int{0}
}
func (m *DetourConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DetourConfig.Unmarshal(m, b)
}
func (m *DetourConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DetourConfig.Marshal(b, m, deterministic)
}
func (dst *DetourConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_DetourConfig.Merge(dst, src)
}
func (m *DetourConfig) XXX_Size() int {
return xxx_messageInfo_DetourConfig.Size(m)
}
func (m *DetourConfig) XXX_DiscardUnknown() {
xxx_messageInfo_DetourConfig.DiscardUnknown(m)
}
var xxx_messageInfo_DetourConfig proto.InternalMessageInfo
func (m *DetourConfig) GetTo() string {
if m != nil {
@ -33,14 +55,36 @@ func (m *DetourConfig) GetTo() string {
}
type DefaultConfig struct {
AlterId uint32 `protobuf:"varint,1,opt,name=alter_id,json=alterId" json:"alter_id,omitempty"`
Level uint32 `protobuf:"varint,2,opt,name=level" json:"level,omitempty"`
AlterId uint32 `protobuf:"varint,1,opt,name=alter_id,json=alterId" json:"alter_id,omitempty"`
Level uint32 `protobuf:"varint,2,opt,name=level" json:"level,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *DefaultConfig) Reset() { *m = DefaultConfig{} }
func (m *DefaultConfig) String() string { return proto.CompactTextString(m) }
func (*DefaultConfig) ProtoMessage() {}
func (*DefaultConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *DefaultConfig) Reset() { *m = DefaultConfig{} }
func (m *DefaultConfig) String() string { return proto.CompactTextString(m) }
func (*DefaultConfig) ProtoMessage() {}
func (*DefaultConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_72992bea2627a574, []int{1}
}
func (m *DefaultConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DefaultConfig.Unmarshal(m, b)
}
func (m *DefaultConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DefaultConfig.Marshal(b, m, deterministic)
}
func (dst *DefaultConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_DefaultConfig.Merge(dst, src)
}
func (m *DefaultConfig) XXX_Size() int {
return xxx_messageInfo_DefaultConfig.Size(m)
}
func (m *DefaultConfig) XXX_DiscardUnknown() {
xxx_messageInfo_DefaultConfig.DiscardUnknown(m)
}
var xxx_messageInfo_DefaultConfig proto.InternalMessageInfo
func (m *DefaultConfig) GetAlterId() uint32 {
if m != nil {
@ -57,18 +101,40 @@ func (m *DefaultConfig) GetLevel() uint32 {
}
type Config struct {
User []*v2ray_core_common_protocol.User `protobuf:"bytes,1,rep,name=user" json:"user,omitempty"`
Default *DefaultConfig `protobuf:"bytes,2,opt,name=default" json:"default,omitempty"`
Detour *DetourConfig `protobuf:"bytes,3,opt,name=detour" json:"detour,omitempty"`
SecureEncryptionOnly bool `protobuf:"varint,4,opt,name=secure_encryption_only,json=secureEncryptionOnly" json:"secure_encryption_only,omitempty"`
User []*protocol.User `protobuf:"bytes,1,rep,name=user" json:"user,omitempty"`
Default *DefaultConfig `protobuf:"bytes,2,opt,name=default" json:"default,omitempty"`
Detour *DetourConfig `protobuf:"bytes,3,opt,name=detour" json:"detour,omitempty"`
SecureEncryptionOnly bool `protobuf:"varint,4,opt,name=secure_encryption_only,json=secureEncryptionOnly" json:"secure_encryption_only,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_72992bea2627a574, []int{2}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetUser() []*v2ray_core_common_protocol.User {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetUser() []*protocol.User {
if m != nil {
return m.User
}
@ -102,9 +168,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.proxy.vmess.inbound.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/vmess/inbound/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/vmess/inbound/config.proto", fileDescriptor_config_72992bea2627a574)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_72992bea2627a574 = []byte{
// 333 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x90, 0x4f, 0x4f, 0xf2, 0x40,
0x10, 0xc6, 0xd3, 0xc2, 0x0b, 0xbc, 0x8b, 0x78, 0x68, 0x88, 0xa9, 0x1e, 0x48, 0xd3, 0x13, 0x26,

View File

@ -2,4 +2,6 @@ package inbound
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "VMess", "Inbound") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "VMess", "Inbound")
}

View File

@ -3,7 +3,7 @@ package outbound
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_protocol1 "v2ray.com/core/common/protocol"
import protocol "v2ray.com/core/common/protocol"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -17,15 +17,37 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
Receiver []*v2ray_core_common_protocol1.ServerEndpoint `protobuf:"bytes,1,rep,name=Receiver" json:"Receiver,omitempty"`
Receiver []*protocol.ServerEndpoint `protobuf:"bytes,1,rep,name=Receiver" json:"Receiver,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_455d861941cfa0c2, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetReceiver() []*v2ray_core_common_protocol1.ServerEndpoint {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetReceiver() []*protocol.ServerEndpoint {
if m != nil {
return m.Receiver
}
@ -36,9 +58,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.proxy.vmess.outbound.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/proxy/vmess/outbound/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/proxy/vmess/outbound/config.proto", fileDescriptor_config_455d861941cfa0c2)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_455d861941cfa0c2 = []byte{
// 208 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x8e, 0xb1, 0x4a, 0xc4, 0x40,
0x10, 0x86, 0x39, 0x85, 0xe3, 0x58, 0xbb, 0xab, 0xc4, 0xe6, 0x44, 0x1b, 0xb1, 0x98, 0x95, 0xf8,

View File

@ -2,4 +2,6 @@ package outbound
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Proxy", "VMess", "Outbound") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Proxy", "VMess", "Outbound")
}

View File

@ -3,7 +3,7 @@ package transport
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_transport_internet "v2ray.com/core/transport/internet"
import internet "v2ray.com/core/transport/internet"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -18,15 +18,37 @@ const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// Global transport settings. This affects all type of connections that go through V2Ray.
type Config struct {
TransportSettings []*v2ray_core_transport_internet.TransportConfig `protobuf:"bytes,1,rep,name=transport_settings,json=transportSettings" json:"transport_settings,omitempty"`
TransportSettings []*internet.TransportConfig `protobuf:"bytes,1,rep,name=transport_settings,json=transportSettings" json:"transport_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_d0511d399edb49e4, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetTransportSettings() []*v2ray_core_transport_internet.TransportConfig {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetTransportSettings() []*internet.TransportConfig {
if m != nil {
return m.TransportSettings
}
@ -37,9 +59,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.transport.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/transport/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/transport/config.proto", fileDescriptor_config_d0511d399edb49e4)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_d0511d399edb49e4 = []byte{
// 170 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -3,7 +3,7 @@ package internet
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -47,19 +47,43 @@ var TransportProtocol_value = map[string]int32{
func (x TransportProtocol) String() string {
return proto.EnumName(TransportProtocol_name, int32(x))
}
func (TransportProtocol) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (TransportProtocol) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_6493eeef2ca10012, []int{0}
}
type TransportConfig struct {
// Type of network that this settings supports.
Protocol TransportProtocol `protobuf:"varint,1,opt,name=protocol,enum=v2ray.core.transport.internet.TransportProtocol" json:"protocol,omitempty"`
// Specific settings. Must be of the transports.
Settings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=settings" json:"settings,omitempty"`
Settings *serial.TypedMessage `protobuf:"bytes,2,opt,name=settings" json:"settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransportConfig) Reset() { *m = TransportConfig{} }
func (m *TransportConfig) String() string { return proto.CompactTextString(m) }
func (*TransportConfig) ProtoMessage() {}
func (*TransportConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *TransportConfig) Reset() { *m = TransportConfig{} }
func (m *TransportConfig) String() string { return proto.CompactTextString(m) }
func (*TransportConfig) ProtoMessage() {}
func (*TransportConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_6493eeef2ca10012, []int{0}
}
func (m *TransportConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransportConfig.Unmarshal(m, b)
}
func (m *TransportConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransportConfig.Marshal(b, m, deterministic)
}
func (dst *TransportConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransportConfig.Merge(dst, src)
}
func (m *TransportConfig) XXX_Size() int {
return xxx_messageInfo_TransportConfig.Size(m)
}
func (m *TransportConfig) XXX_DiscardUnknown() {
xxx_messageInfo_TransportConfig.DiscardUnknown(m)
}
var xxx_messageInfo_TransportConfig proto.InternalMessageInfo
func (m *TransportConfig) GetProtocol() TransportProtocol {
if m != nil {
@ -68,7 +92,7 @@ func (m *TransportConfig) GetProtocol() TransportProtocol {
return TransportProtocol_TCP
}
func (m *TransportConfig) GetSettings() *v2ray_core_common_serial.TypedMessage {
func (m *TransportConfig) GetSettings() *serial.TypedMessage {
if m != nil {
return m.Settings
}
@ -82,13 +106,35 @@ type StreamConfig struct {
// Type of security. Must be a message name of the settings proto.
SecurityType string `protobuf:"bytes,3,opt,name=security_type,json=securityType" json:"security_type,omitempty"`
// Settings for transport security. For now the only choice is TLS.
SecuritySettings []*v2ray_core_common_serial.TypedMessage `protobuf:"bytes,4,rep,name=security_settings,json=securitySettings" json:"security_settings,omitempty"`
SecuritySettings []*serial.TypedMessage `protobuf:"bytes,4,rep,name=security_settings,json=securitySettings" json:"security_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *StreamConfig) Reset() { *m = StreamConfig{} }
func (m *StreamConfig) String() string { return proto.CompactTextString(m) }
func (*StreamConfig) ProtoMessage() {}
func (*StreamConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *StreamConfig) Reset() { *m = StreamConfig{} }
func (m *StreamConfig) String() string { return proto.CompactTextString(m) }
func (*StreamConfig) ProtoMessage() {}
func (*StreamConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_6493eeef2ca10012, []int{1}
}
func (m *StreamConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_StreamConfig.Unmarshal(m, b)
}
func (m *StreamConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_StreamConfig.Marshal(b, m, deterministic)
}
func (dst *StreamConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_StreamConfig.Merge(dst, src)
}
func (m *StreamConfig) XXX_Size() int {
return xxx_messageInfo_StreamConfig.Size(m)
}
func (m *StreamConfig) XXX_DiscardUnknown() {
xxx_messageInfo_StreamConfig.DiscardUnknown(m)
}
var xxx_messageInfo_StreamConfig proto.InternalMessageInfo
func (m *StreamConfig) GetProtocol() TransportProtocol {
if m != nil {
@ -111,7 +157,7 @@ func (m *StreamConfig) GetSecurityType() string {
return ""
}
func (m *StreamConfig) GetSecuritySettings() []*v2ray_core_common_serial.TypedMessage {
func (m *StreamConfig) GetSecuritySettings() []*serial.TypedMessage {
if m != nil {
return m.SecuritySettings
}
@ -119,13 +165,35 @@ func (m *StreamConfig) GetSecuritySettings() []*v2ray_core_common_serial.TypedMe
}
type ProxyConfig struct {
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
Tag string `protobuf:"bytes,1,opt,name=tag" json:"tag,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ProxyConfig) Reset() { *m = ProxyConfig{} }
func (m *ProxyConfig) String() string { return proto.CompactTextString(m) }
func (*ProxyConfig) ProtoMessage() {}
func (*ProxyConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *ProxyConfig) Reset() { *m = ProxyConfig{} }
func (m *ProxyConfig) String() string { return proto.CompactTextString(m) }
func (*ProxyConfig) ProtoMessage() {}
func (*ProxyConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_6493eeef2ca10012, []int{2}
}
func (m *ProxyConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ProxyConfig.Unmarshal(m, b)
}
func (m *ProxyConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ProxyConfig.Marshal(b, m, deterministic)
}
func (dst *ProxyConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ProxyConfig.Merge(dst, src)
}
func (m *ProxyConfig) XXX_Size() int {
return xxx_messageInfo_ProxyConfig.Size(m)
}
func (m *ProxyConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ProxyConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ProxyConfig proto.InternalMessageInfo
func (m *ProxyConfig) GetTag() string {
if m != nil {
@ -141,9 +209,11 @@ func init() {
proto.RegisterEnum("v2ray.core.transport.internet.TransportProtocol", TransportProtocol_name, TransportProtocol_value)
}
func init() { proto.RegisterFile("v2ray.com/core/transport/internet/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/config.proto", fileDescriptor_config_6493eeef2ca10012)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_6493eeef2ca10012 = []byte{
// 393 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x91, 0xcf, 0x6a, 0xdb, 0x40,
0x10, 0x87, 0x2b, 0xc9, 0x6d, 0xe5, 0xb1, 0xdd, 0xae, 0xf7, 0x64, 0x0a, 0xa6, 0xae, 0x0b, 0x45,

View File

@ -20,13 +20,35 @@ type Config struct {
Path string `protobuf:"bytes,1,opt,name=path" json:"path,omitempty"`
// Abstract speicifies whether to use abstract namespace or not.
// Traditionally Unix domain socket is file system based. Abstract domain socket can be used without acquiring file lock.
Abstract bool `protobuf:"varint,2,opt,name=abstract" json:"abstract,omitempty"`
Abstract bool `protobuf:"varint,2,opt,name=abstract" json:"abstract,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_66b14c087c0230f8, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetPath() string {
if m != nil {
@ -47,10 +69,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/domainsocket/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/domainsocket/config.proto", fileDescriptor_config_66b14c087c0230f8)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_66b14c087c0230f8 = []byte{
// 189 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xb2, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -2,4 +2,6 @@ package domainsocket
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "DomainSocket") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "DomainSocket")
}

View File

@ -2,4 +2,6 @@ package internet
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet")
}

View File

@ -19,13 +19,35 @@ type Header struct {
// "Accept", "Cookie", etc
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// Each entry must be valid in one piece. Random entry will be chosen if multiple entries present.
Value []string `protobuf:"bytes,2,rep,name=value" json:"value,omitempty"`
Value []string `protobuf:"bytes,2,rep,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Header) Reset() { *m = Header{} }
func (m *Header) String() string { return proto.CompactTextString(m) }
func (*Header) ProtoMessage() {}
func (*Header) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Header) Reset() { *m = Header{} }
func (m *Header) String() string { return proto.CompactTextString(m) }
func (*Header) ProtoMessage() {}
func (*Header) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{0}
}
func (m *Header) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Header.Unmarshal(m, b)
}
func (m *Header) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Header.Marshal(b, m, deterministic)
}
func (dst *Header) XXX_Merge(src proto.Message) {
xxx_messageInfo_Header.Merge(dst, src)
}
func (m *Header) XXX_Size() int {
return xxx_messageInfo_Header.Size(m)
}
func (m *Header) XXX_DiscardUnknown() {
xxx_messageInfo_Header.DiscardUnknown(m)
}
var xxx_messageInfo_Header proto.InternalMessageInfo
func (m *Header) GetName() string {
if m != nil {
@ -43,13 +65,35 @@ func (m *Header) GetValue() []string {
// HTTP version. Default value "1.1".
type Version struct {
Value string `protobuf:"bytes,1,opt,name=value" json:"value,omitempty"`
Value string `protobuf:"bytes,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Version) Reset() { *m = Version{} }
func (m *Version) String() string { return proto.CompactTextString(m) }
func (*Version) ProtoMessage() {}
func (*Version) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Version) Reset() { *m = Version{} }
func (m *Version) String() string { return proto.CompactTextString(m) }
func (*Version) ProtoMessage() {}
func (*Version) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{1}
}
func (m *Version) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Version.Unmarshal(m, b)
}
func (m *Version) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Version.Marshal(b, m, deterministic)
}
func (dst *Version) XXX_Merge(src proto.Message) {
xxx_messageInfo_Version.Merge(dst, src)
}
func (m *Version) XXX_Size() int {
return xxx_messageInfo_Version.Size(m)
}
func (m *Version) XXX_DiscardUnknown() {
xxx_messageInfo_Version.DiscardUnknown(m)
}
var xxx_messageInfo_Version proto.InternalMessageInfo
func (m *Version) GetValue() string {
if m != nil {
@ -60,13 +104,35 @@ func (m *Version) GetValue() string {
// HTTP method. Default value "GET".
type Method struct {
Value string `protobuf:"bytes,1,opt,name=value" json:"value,omitempty"`
Value string `protobuf:"bytes,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Method) Reset() { *m = Method{} }
func (m *Method) String() string { return proto.CompactTextString(m) }
func (*Method) ProtoMessage() {}
func (*Method) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *Method) Reset() { *m = Method{} }
func (m *Method) String() string { return proto.CompactTextString(m) }
func (*Method) ProtoMessage() {}
func (*Method) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{2}
}
func (m *Method) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Method.Unmarshal(m, b)
}
func (m *Method) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Method.Marshal(b, m, deterministic)
}
func (dst *Method) XXX_Merge(src proto.Message) {
xxx_messageInfo_Method.Merge(dst, src)
}
func (m *Method) XXX_Size() int {
return xxx_messageInfo_Method.Size(m)
}
func (m *Method) XXX_DiscardUnknown() {
xxx_messageInfo_Method.DiscardUnknown(m)
}
var xxx_messageInfo_Method proto.InternalMessageInfo
func (m *Method) GetValue() string {
if m != nil {
@ -81,14 +147,36 @@ type RequestConfig struct {
// GET, POST, CONNECT etc
Method *Method `protobuf:"bytes,2,opt,name=method" json:"method,omitempty"`
// URI like "/login.php"
Uri []string `protobuf:"bytes,3,rep,name=uri" json:"uri,omitempty"`
Header []*Header `protobuf:"bytes,4,rep,name=header" json:"header,omitempty"`
Uri []string `protobuf:"bytes,3,rep,name=uri" json:"uri,omitempty"`
Header []*Header `protobuf:"bytes,4,rep,name=header" json:"header,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RequestConfig) Reset() { *m = RequestConfig{} }
func (m *RequestConfig) String() string { return proto.CompactTextString(m) }
func (*RequestConfig) ProtoMessage() {}
func (*RequestConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *RequestConfig) Reset() { *m = RequestConfig{} }
func (m *RequestConfig) String() string { return proto.CompactTextString(m) }
func (*RequestConfig) ProtoMessage() {}
func (*RequestConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{3}
}
func (m *RequestConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_RequestConfig.Unmarshal(m, b)
}
func (m *RequestConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_RequestConfig.Marshal(b, m, deterministic)
}
func (dst *RequestConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_RequestConfig.Merge(dst, src)
}
func (m *RequestConfig) XXX_Size() int {
return xxx_messageInfo_RequestConfig.Size(m)
}
func (m *RequestConfig) XXX_DiscardUnknown() {
xxx_messageInfo_RequestConfig.DiscardUnknown(m)
}
var xxx_messageInfo_RequestConfig proto.InternalMessageInfo
func (m *RequestConfig) GetVersion() *Version {
if m != nil {
@ -122,13 +210,35 @@ type Status struct {
// Status code. Default "200".
Code string `protobuf:"bytes,1,opt,name=code" json:"code,omitempty"`
// Statue reason. Default "OK".
Reason string `protobuf:"bytes,2,opt,name=reason" json:"reason,omitempty"`
Reason string `protobuf:"bytes,2,opt,name=reason" json:"reason,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Status) Reset() { *m = Status{} }
func (m *Status) String() string { return proto.CompactTextString(m) }
func (*Status) ProtoMessage() {}
func (*Status) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (m *Status) Reset() { *m = Status{} }
func (m *Status) String() string { return proto.CompactTextString(m) }
func (*Status) ProtoMessage() {}
func (*Status) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{4}
}
func (m *Status) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Status.Unmarshal(m, b)
}
func (m *Status) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Status.Marshal(b, m, deterministic)
}
func (dst *Status) XXX_Merge(src proto.Message) {
xxx_messageInfo_Status.Merge(dst, src)
}
func (m *Status) XXX_Size() int {
return xxx_messageInfo_Status.Size(m)
}
func (m *Status) XXX_DiscardUnknown() {
xxx_messageInfo_Status.DiscardUnknown(m)
}
var xxx_messageInfo_Status proto.InternalMessageInfo
func (m *Status) GetCode() string {
if m != nil {
@ -145,15 +255,37 @@ func (m *Status) GetReason() string {
}
type ResponseConfig struct {
Version *Version `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
Status *Status `protobuf:"bytes,2,opt,name=status" json:"status,omitempty"`
Header []*Header `protobuf:"bytes,3,rep,name=header" json:"header,omitempty"`
Version *Version `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
Status *Status `protobuf:"bytes,2,opt,name=status" json:"status,omitempty"`
Header []*Header `protobuf:"bytes,3,rep,name=header" json:"header,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResponseConfig) Reset() { *m = ResponseConfig{} }
func (m *ResponseConfig) String() string { return proto.CompactTextString(m) }
func (*ResponseConfig) ProtoMessage() {}
func (*ResponseConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (m *ResponseConfig) Reset() { *m = ResponseConfig{} }
func (m *ResponseConfig) String() string { return proto.CompactTextString(m) }
func (*ResponseConfig) ProtoMessage() {}
func (*ResponseConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{5}
}
func (m *ResponseConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResponseConfig.Unmarshal(m, b)
}
func (m *ResponseConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResponseConfig.Marshal(b, m, deterministic)
}
func (dst *ResponseConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResponseConfig.Merge(dst, src)
}
func (m *ResponseConfig) XXX_Size() int {
return xxx_messageInfo_ResponseConfig.Size(m)
}
func (m *ResponseConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ResponseConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ResponseConfig proto.InternalMessageInfo
func (m *ResponseConfig) GetVersion() *Version {
if m != nil {
@ -180,13 +312,35 @@ type Config struct {
// Settings for authenticating requests. If not set, client side will not send authenication header, and server side will bypass authentication.
Request *RequestConfig `protobuf:"bytes,1,opt,name=request" json:"request,omitempty"`
// Settings for authenticating responses. If not set, client side will bypass authentication, and server side will not send authentication header.
Response *ResponseConfig `protobuf:"bytes,2,opt,name=response" json:"response,omitempty"`
Response *ResponseConfig `protobuf:"bytes,2,opt,name=response" json:"response,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_a2d5bfee7e39acaf, []int{6}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetRequest() *RequestConfig {
if m != nil {
@ -213,10 +367,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/headers/http/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/headers/http/config.proto", fileDescriptor_config_a2d5bfee7e39acaf)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_a2d5bfee7e39acaf = []byte{
// 394 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x94, 0xbf, 0x8a, 0xdb, 0x40,
0x10, 0xc6, 0x91, 0xe4, 0xc8, 0xf1, 0x84, 0x84, 0xb0, 0x84, 0xa0, 0x2a, 0x31, 0xaa, 0x8c, 0x8b,

View File

@ -2,4 +2,6 @@ package http
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "Headers", "HTTP") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "Headers", "HTTP")
}

View File

@ -16,20 +16,64 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_682f76ee5345392b, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
type ConnectionConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ConnectionConfig) Reset() { *m = ConnectionConfig{} }
func (m *ConnectionConfig) String() string { return proto.CompactTextString(m) }
func (*ConnectionConfig) ProtoMessage() {}
func (*ConnectionConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *ConnectionConfig) Reset() { *m = ConnectionConfig{} }
func (m *ConnectionConfig) String() string { return proto.CompactTextString(m) }
func (*ConnectionConfig) ProtoMessage() {}
func (*ConnectionConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_682f76ee5345392b, []int{1}
}
func (m *ConnectionConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ConnectionConfig.Unmarshal(m, b)
}
func (m *ConnectionConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ConnectionConfig.Marshal(b, m, deterministic)
}
func (dst *ConnectionConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_ConnectionConfig.Merge(dst, src)
}
func (m *ConnectionConfig) XXX_Size() int {
return xxx_messageInfo_ConnectionConfig.Size(m)
}
func (m *ConnectionConfig) XXX_DiscardUnknown() {
xxx_messageInfo_ConnectionConfig.DiscardUnknown(m)
}
var xxx_messageInfo_ConnectionConfig proto.InternalMessageInfo
func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.transport.internet.headers.noop.Config")
@ -37,10 +81,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/headers/noop/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/headers/noop/config.proto", fileDescriptor_config_682f76ee5345392b)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_682f76ee5345392b = []byte{
// 170 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0xce, 0xb1, 0xaa, 0xc2, 0x40,
0x10, 0x85, 0x61, 0xee, 0x45, 0x82, 0x6c, 0x25, 0x79, 0x84, 0x94, 0x29, 0x66, 0x21, 0x96, 0x76,

View File

@ -16,18 +16,40 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
Version uint32 `protobuf:"varint,1,opt,name=version" json:"version,omitempty"`
Padding bool `protobuf:"varint,2,opt,name=padding" json:"padding,omitempty"`
Extension bool `protobuf:"varint,3,opt,name=extension" json:"extension,omitempty"`
CsrcCount uint32 `protobuf:"varint,4,opt,name=csrc_count,json=csrcCount" json:"csrc_count,omitempty"`
Marker bool `protobuf:"varint,5,opt,name=marker" json:"marker,omitempty"`
PayloadType uint32 `protobuf:"varint,6,opt,name=payload_type,json=payloadType" json:"payload_type,omitempty"`
Version uint32 `protobuf:"varint,1,opt,name=version" json:"version,omitempty"`
Padding bool `protobuf:"varint,2,opt,name=padding" json:"padding,omitempty"`
Extension bool `protobuf:"varint,3,opt,name=extension" json:"extension,omitempty"`
CsrcCount uint32 `protobuf:"varint,4,opt,name=csrc_count,json=csrcCount" json:"csrc_count,omitempty"`
Marker bool `protobuf:"varint,5,opt,name=marker" json:"marker,omitempty"`
PayloadType uint32 `protobuf:"varint,6,opt,name=payload_type,json=payloadType" json:"payload_type,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_9106a6ec918b6911, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetVersion() uint32 {
if m != nil {
@ -76,10 +98,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/headers/srtp/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/headers/srtp/config.proto", fileDescriptor_config_9106a6ec918b6911)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_9106a6ec918b6911 = []byte{
// 260 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0xd0, 0x31, 0x4b, 0x03, 0x31,
0x14, 0x07, 0x70, 0xae, 0xd6, 0xd3, 0x46, 0x5d, 0x32, 0x48, 0x06, 0x85, 0xea, 0x54, 0x3a, 0x24,

View File

@ -16,13 +16,35 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
Version uint32 `protobuf:"varint,1,opt,name=version" json:"version,omitempty"`
Version uint32 `protobuf:"varint,1,opt,name=version" json:"version,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_f9dc3b419a43dc8e, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetVersion() uint32 {
if m != nil {
@ -36,10 +58,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/headers/utp/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/headers/utp/config.proto", fileDescriptor_config_f9dc3b419a43dc8e)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_f9dc3b419a43dc8e = []byte{
// 177 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xb2, 0x2a, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -16,22 +16,44 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type VideoConfig struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *VideoConfig) Reset() { *m = VideoConfig{} }
func (m *VideoConfig) String() string { return proto.CompactTextString(m) }
func (*VideoConfig) ProtoMessage() {}
func (*VideoConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *VideoConfig) Reset() { *m = VideoConfig{} }
func (m *VideoConfig) String() string { return proto.CompactTextString(m) }
func (*VideoConfig) ProtoMessage() {}
func (*VideoConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_config_2f1af10d1ad0257a, []int{0}
}
func (m *VideoConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_VideoConfig.Unmarshal(m, b)
}
func (m *VideoConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_VideoConfig.Marshal(b, m, deterministic)
}
func (dst *VideoConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_VideoConfig.Merge(dst, src)
}
func (m *VideoConfig) XXX_Size() int {
return xxx_messageInfo_VideoConfig.Size(m)
}
func (m *VideoConfig) XXX_DiscardUnknown() {
xxx_messageInfo_VideoConfig.DiscardUnknown(m)
}
var xxx_messageInfo_VideoConfig proto.InternalMessageInfo
func init() {
proto.RegisterType((*VideoConfig)(nil), "v2ray.core.transport.internet.headers.wechat.VideoConfig")
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/headers/wechat/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/headers/wechat/config.proto", fileDescriptor_config_2f1af10d1ad0257a)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_2f1af10d1ad0257a = []byte{
// 163 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xb2, 0x2d, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -16,14 +16,36 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
Host []string `protobuf:"bytes,1,rep,name=host" json:"host,omitempty"`
Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"`
Host []string `protobuf:"bytes,1,rep,name=host" json:"host,omitempty"`
Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_93ae84938c3897ac, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetHost() []string {
if m != nil {
@ -44,10 +66,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/http/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/http/config.proto", fileDescriptor_config_93ae84938c3897ac)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_93ae84938c3897ac = []byte{
// 173 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x32, 0x2e, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -3,7 +3,7 @@ package kcp
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -18,13 +18,35 @@ const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// Maximum Transmission Unit, in bytes.
type MTU struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *MTU) Reset() { *m = MTU{} }
func (m *MTU) String() string { return proto.CompactTextString(m) }
func (*MTU) ProtoMessage() {}
func (*MTU) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *MTU) Reset() { *m = MTU{} }
func (m *MTU) String() string { return proto.CompactTextString(m) }
func (*MTU) ProtoMessage() {}
func (*MTU) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{0}
}
func (m *MTU) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_MTU.Unmarshal(m, b)
}
func (m *MTU) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_MTU.Marshal(b, m, deterministic)
}
func (dst *MTU) XXX_Merge(src proto.Message) {
xxx_messageInfo_MTU.Merge(dst, src)
}
func (m *MTU) XXX_Size() int {
return xxx_messageInfo_MTU.Size(m)
}
func (m *MTU) XXX_DiscardUnknown() {
xxx_messageInfo_MTU.DiscardUnknown(m)
}
var xxx_messageInfo_MTU proto.InternalMessageInfo
func (m *MTU) GetValue() uint32 {
if m != nil {
@ -35,13 +57,35 @@ func (m *MTU) GetValue() uint32 {
// Transmission Time Interview, in milli-sec.
type TTI struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TTI) Reset() { *m = TTI{} }
func (m *TTI) String() string { return proto.CompactTextString(m) }
func (*TTI) ProtoMessage() {}
func (*TTI) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *TTI) Reset() { *m = TTI{} }
func (m *TTI) String() string { return proto.CompactTextString(m) }
func (*TTI) ProtoMessage() {}
func (*TTI) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{1}
}
func (m *TTI) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TTI.Unmarshal(m, b)
}
func (m *TTI) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TTI.Marshal(b, m, deterministic)
}
func (dst *TTI) XXX_Merge(src proto.Message) {
xxx_messageInfo_TTI.Merge(dst, src)
}
func (m *TTI) XXX_Size() int {
return xxx_messageInfo_TTI.Size(m)
}
func (m *TTI) XXX_DiscardUnknown() {
xxx_messageInfo_TTI.DiscardUnknown(m)
}
var xxx_messageInfo_TTI proto.InternalMessageInfo
func (m *TTI) GetValue() uint32 {
if m != nil {
@ -52,13 +96,35 @@ func (m *TTI) GetValue() uint32 {
// Uplink capacity, in MB.
type UplinkCapacity struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *UplinkCapacity) Reset() { *m = UplinkCapacity{} }
func (m *UplinkCapacity) String() string { return proto.CompactTextString(m) }
func (*UplinkCapacity) ProtoMessage() {}
func (*UplinkCapacity) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *UplinkCapacity) Reset() { *m = UplinkCapacity{} }
func (m *UplinkCapacity) String() string { return proto.CompactTextString(m) }
func (*UplinkCapacity) ProtoMessage() {}
func (*UplinkCapacity) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{2}
}
func (m *UplinkCapacity) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_UplinkCapacity.Unmarshal(m, b)
}
func (m *UplinkCapacity) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_UplinkCapacity.Marshal(b, m, deterministic)
}
func (dst *UplinkCapacity) XXX_Merge(src proto.Message) {
xxx_messageInfo_UplinkCapacity.Merge(dst, src)
}
func (m *UplinkCapacity) XXX_Size() int {
return xxx_messageInfo_UplinkCapacity.Size(m)
}
func (m *UplinkCapacity) XXX_DiscardUnknown() {
xxx_messageInfo_UplinkCapacity.DiscardUnknown(m)
}
var xxx_messageInfo_UplinkCapacity proto.InternalMessageInfo
func (m *UplinkCapacity) GetValue() uint32 {
if m != nil {
@ -69,13 +135,35 @@ func (m *UplinkCapacity) GetValue() uint32 {
// Downlink capacity, in MB.
type DownlinkCapacity struct {
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
Value uint32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *DownlinkCapacity) Reset() { *m = DownlinkCapacity{} }
func (m *DownlinkCapacity) String() string { return proto.CompactTextString(m) }
func (*DownlinkCapacity) ProtoMessage() {}
func (*DownlinkCapacity) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *DownlinkCapacity) Reset() { *m = DownlinkCapacity{} }
func (m *DownlinkCapacity) String() string { return proto.CompactTextString(m) }
func (*DownlinkCapacity) ProtoMessage() {}
func (*DownlinkCapacity) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{3}
}
func (m *DownlinkCapacity) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DownlinkCapacity.Unmarshal(m, b)
}
func (m *DownlinkCapacity) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DownlinkCapacity.Marshal(b, m, deterministic)
}
func (dst *DownlinkCapacity) XXX_Merge(src proto.Message) {
xxx_messageInfo_DownlinkCapacity.Merge(dst, src)
}
func (m *DownlinkCapacity) XXX_Size() int {
return xxx_messageInfo_DownlinkCapacity.Size(m)
}
func (m *DownlinkCapacity) XXX_DiscardUnknown() {
xxx_messageInfo_DownlinkCapacity.DiscardUnknown(m)
}
var xxx_messageInfo_DownlinkCapacity proto.InternalMessageInfo
func (m *DownlinkCapacity) GetValue() uint32 {
if m != nil {
@ -86,13 +174,35 @@ func (m *DownlinkCapacity) GetValue() uint32 {
type WriteBuffer struct {
// Buffer size in bytes.
Size uint32 `protobuf:"varint,1,opt,name=size" json:"size,omitempty"`
Size uint32 `protobuf:"varint,1,opt,name=size" json:"size,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *WriteBuffer) Reset() { *m = WriteBuffer{} }
func (m *WriteBuffer) String() string { return proto.CompactTextString(m) }
func (*WriteBuffer) ProtoMessage() {}
func (*WriteBuffer) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
func (m *WriteBuffer) Reset() { *m = WriteBuffer{} }
func (m *WriteBuffer) String() string { return proto.CompactTextString(m) }
func (*WriteBuffer) ProtoMessage() {}
func (*WriteBuffer) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{4}
}
func (m *WriteBuffer) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_WriteBuffer.Unmarshal(m, b)
}
func (m *WriteBuffer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_WriteBuffer.Marshal(b, m, deterministic)
}
func (dst *WriteBuffer) XXX_Merge(src proto.Message) {
xxx_messageInfo_WriteBuffer.Merge(dst, src)
}
func (m *WriteBuffer) XXX_Size() int {
return xxx_messageInfo_WriteBuffer.Size(m)
}
func (m *WriteBuffer) XXX_DiscardUnknown() {
xxx_messageInfo_WriteBuffer.DiscardUnknown(m)
}
var xxx_messageInfo_WriteBuffer proto.InternalMessageInfo
func (m *WriteBuffer) GetSize() uint32 {
if m != nil {
@ -103,13 +213,35 @@ func (m *WriteBuffer) GetSize() uint32 {
type ReadBuffer struct {
// Buffer size in bytes.
Size uint32 `protobuf:"varint,1,opt,name=size" json:"size,omitempty"`
Size uint32 `protobuf:"varint,1,opt,name=size" json:"size,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ReadBuffer) Reset() { *m = ReadBuffer{} }
func (m *ReadBuffer) String() string { return proto.CompactTextString(m) }
func (*ReadBuffer) ProtoMessage() {}
func (*ReadBuffer) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
func (m *ReadBuffer) Reset() { *m = ReadBuffer{} }
func (m *ReadBuffer) String() string { return proto.CompactTextString(m) }
func (*ReadBuffer) ProtoMessage() {}
func (*ReadBuffer) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{5}
}
func (m *ReadBuffer) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ReadBuffer.Unmarshal(m, b)
}
func (m *ReadBuffer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ReadBuffer.Marshal(b, m, deterministic)
}
func (dst *ReadBuffer) XXX_Merge(src proto.Message) {
xxx_messageInfo_ReadBuffer.Merge(dst, src)
}
func (m *ReadBuffer) XXX_Size() int {
return xxx_messageInfo_ReadBuffer.Size(m)
}
func (m *ReadBuffer) XXX_DiscardUnknown() {
xxx_messageInfo_ReadBuffer.DiscardUnknown(m)
}
var xxx_messageInfo_ReadBuffer proto.InternalMessageInfo
func (m *ReadBuffer) GetSize() uint32 {
if m != nil {
@ -119,13 +251,35 @@ func (m *ReadBuffer) GetSize() uint32 {
}
type ConnectionReuse struct {
Enable bool `protobuf:"varint,1,opt,name=enable" json:"enable,omitempty"`
Enable bool `protobuf:"varint,1,opt,name=enable" json:"enable,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ConnectionReuse) Reset() { *m = ConnectionReuse{} }
func (m *ConnectionReuse) String() string { return proto.CompactTextString(m) }
func (*ConnectionReuse) ProtoMessage() {}
func (*ConnectionReuse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *ConnectionReuse) Reset() { *m = ConnectionReuse{} }
func (m *ConnectionReuse) String() string { return proto.CompactTextString(m) }
func (*ConnectionReuse) ProtoMessage() {}
func (*ConnectionReuse) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{6}
}
func (m *ConnectionReuse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ConnectionReuse.Unmarshal(m, b)
}
func (m *ConnectionReuse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ConnectionReuse.Marshal(b, m, deterministic)
}
func (dst *ConnectionReuse) XXX_Merge(src proto.Message) {
xxx_messageInfo_ConnectionReuse.Merge(dst, src)
}
func (m *ConnectionReuse) XXX_Size() int {
return xxx_messageInfo_ConnectionReuse.Size(m)
}
func (m *ConnectionReuse) XXX_DiscardUnknown() {
xxx_messageInfo_ConnectionReuse.DiscardUnknown(m)
}
var xxx_messageInfo_ConnectionReuse proto.InternalMessageInfo
func (m *ConnectionReuse) GetEnable() bool {
if m != nil {
@ -135,20 +289,42 @@ func (m *ConnectionReuse) GetEnable() bool {
}
type Config struct {
Mtu *MTU `protobuf:"bytes,1,opt,name=mtu" json:"mtu,omitempty"`
Tti *TTI `protobuf:"bytes,2,opt,name=tti" json:"tti,omitempty"`
UplinkCapacity *UplinkCapacity `protobuf:"bytes,3,opt,name=uplink_capacity,json=uplinkCapacity" json:"uplink_capacity,omitempty"`
DownlinkCapacity *DownlinkCapacity `protobuf:"bytes,4,opt,name=downlink_capacity,json=downlinkCapacity" json:"downlink_capacity,omitempty"`
Congestion bool `protobuf:"varint,5,opt,name=congestion" json:"congestion,omitempty"`
WriteBuffer *WriteBuffer `protobuf:"bytes,6,opt,name=write_buffer,json=writeBuffer" json:"write_buffer,omitempty"`
ReadBuffer *ReadBuffer `protobuf:"bytes,7,opt,name=read_buffer,json=readBuffer" json:"read_buffer,omitempty"`
HeaderConfig *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,8,opt,name=header_config,json=headerConfig" json:"header_config,omitempty"`
Mtu *MTU `protobuf:"bytes,1,opt,name=mtu" json:"mtu,omitempty"`
Tti *TTI `protobuf:"bytes,2,opt,name=tti" json:"tti,omitempty"`
UplinkCapacity *UplinkCapacity `protobuf:"bytes,3,opt,name=uplink_capacity,json=uplinkCapacity" json:"uplink_capacity,omitempty"`
DownlinkCapacity *DownlinkCapacity `protobuf:"bytes,4,opt,name=downlink_capacity,json=downlinkCapacity" json:"downlink_capacity,omitempty"`
Congestion bool `protobuf:"varint,5,opt,name=congestion" json:"congestion,omitempty"`
WriteBuffer *WriteBuffer `protobuf:"bytes,6,opt,name=write_buffer,json=writeBuffer" json:"write_buffer,omitempty"`
ReadBuffer *ReadBuffer `protobuf:"bytes,7,opt,name=read_buffer,json=readBuffer" json:"read_buffer,omitempty"`
HeaderConfig *serial.TypedMessage `protobuf:"bytes,8,opt,name=header_config,json=headerConfig" json:"header_config,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_8c4538da0fc2252f, []int{7}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetMtu() *MTU {
if m != nil {
@ -199,7 +375,7 @@ func (m *Config) GetReadBuffer() *ReadBuffer {
return nil
}
func (m *Config) GetHeaderConfig() *v2ray_core_common_serial.TypedMessage {
func (m *Config) GetHeaderConfig() *serial.TypedMessage {
if m != nil {
return m.HeaderConfig
}
@ -217,9 +393,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.transport.internet.kcp.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/transport/internet/kcp/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/kcp/config.proto", fileDescriptor_config_8c4538da0fc2252f)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_8c4538da0fc2252f = []byte{
// 471 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x53, 0x5f, 0x6f, 0xd3, 0x3e,
0x14, 0x55, 0xd7, 0xae, 0xbf, 0xfe, 0x6e, 0xf7, 0xa7, 0x44, 0x08, 0x45, 0x20, 0xa1, 0xb5, 0x12,

View File

@ -2,4 +2,6 @@ package kcp
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "mKCP") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "mKCP")
}

View File

@ -3,7 +3,7 @@ package tcp
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import v2ray_core_common_serial "v2ray.com/core/common/serial"
import serial "v2ray.com/core/common/serial"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@ -17,15 +17,37 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Config struct {
HeaderSettings *v2ray_core_common_serial.TypedMessage `protobuf:"bytes,2,opt,name=header_settings,json=headerSettings" json:"header_settings,omitempty"`
HeaderSettings *serial.TypedMessage `protobuf:"bytes,2,opt,name=header_settings,json=headerSettings" json:"header_settings,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_61f4b2c61d528fb0, []int{0}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
func (m *Config) GetHeaderSettings() *v2ray_core_common_serial.TypedMessage {
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetHeaderSettings() *serial.TypedMessage {
if m != nil {
return m.HeaderSettings
}
@ -36,9 +58,11 @@ func init() {
proto.RegisterType((*Config)(nil), "v2ray.core.transport.internet.tcp.Config")
}
func init() { proto.RegisterFile("v2ray.com/core/transport/internet/tcp/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/tcp/config.proto", fileDescriptor_config_61f4b2c61d528fb0)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_61f4b2c61d528fb0 = []byte{
// 223 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x8e, 0xc1, 0x4a, 0xc4, 0x30,
0x10, 0x86, 0x69, 0x95, 0x45, 0x2a, 0xa8, 0xec, 0x49, 0x3c, 0xb9, 0x82, 0xe2, 0x69, 0x22, 0xf1,

View File

@ -2,4 +2,6 @@ package tcp
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "TCP") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "TCP")
}

View File

@ -37,20 +37,44 @@ var Certificate_Usage_value = map[string]int32{
func (x Certificate_Usage) String() string {
return proto.EnumName(Certificate_Usage_name, int32(x))
}
func (Certificate_Usage) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
func (Certificate_Usage) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_config_094edd58cf826f66, []int{0, 0}
}
type Certificate struct {
// TLS certificate in x509 format.
Certificate []byte `protobuf:"bytes,1,opt,name=Certificate,proto3" json:"Certificate,omitempty"`
// TLS key in x509 format.
Key []byte `protobuf:"bytes,2,opt,name=Key,proto3" json:"Key,omitempty"`
Usage Certificate_Usage `protobuf:"varint,3,opt,name=usage,enum=v2ray.core.transport.internet.tls.Certificate_Usage" json:"usage,omitempty"`
Key []byte `protobuf:"bytes,2,opt,name=Key,proto3" json:"Key,omitempty"`
Usage Certificate_Usage `protobuf:"varint,3,opt,name=usage,enum=v2ray.core.transport.internet.tls.Certificate_Usage" json:"usage,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Certificate) Reset() { *m = Certificate{} }
func (m *Certificate) String() string { return proto.CompactTextString(m) }
func (*Certificate) ProtoMessage() {}
func (*Certificate) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Certificate) Reset() { *m = Certificate{} }
func (m *Certificate) String() string { return proto.CompactTextString(m) }
func (*Certificate) ProtoMessage() {}
func (*Certificate) Descriptor() ([]byte, []int) {
return fileDescriptor_config_094edd58cf826f66, []int{0}
}
func (m *Certificate) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Certificate.Unmarshal(m, b)
}
func (m *Certificate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Certificate.Marshal(b, m, deterministic)
}
func (dst *Certificate) XXX_Merge(src proto.Message) {
xxx_messageInfo_Certificate.Merge(dst, src)
}
func (m *Certificate) XXX_Size() int {
return xxx_messageInfo_Certificate.Size(m)
}
func (m *Certificate) XXX_DiscardUnknown() {
xxx_messageInfo_Certificate.DiscardUnknown(m)
}
var xxx_messageInfo_Certificate proto.InternalMessageInfo
func (m *Certificate) GetCertificate() []byte {
if m != nil {
@ -81,13 +105,35 @@ type Config struct {
// Override server name.
ServerName string `protobuf:"bytes,3,opt,name=server_name,json=serverName" json:"server_name,omitempty"`
// Lists of string as ALPN values.
NextProtocol []string `protobuf:"bytes,4,rep,name=next_protocol,json=nextProtocol" json:"next_protocol,omitempty"`
NextProtocol []string `protobuf:"bytes,4,rep,name=next_protocol,json=nextProtocol" json:"next_protocol,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_094edd58cf826f66, []int{1}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetAllowInsecure() bool {
if m != nil {
@ -123,9 +169,11 @@ func init() {
proto.RegisterEnum("v2ray.core.transport.internet.tls.Certificate_Usage", Certificate_Usage_name, Certificate_Usage_value)
}
func init() { proto.RegisterFile("v2ray.com/core/transport/internet/tls/config.proto", fileDescriptor0) }
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/tls/config.proto", fileDescriptor_config_094edd58cf826f66)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_094edd58cf826f66 = []byte{
// 358 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x91, 0xd1, 0x6e, 0xda, 0x30,
0x14, 0x40, 0x97, 0x64, 0xa0, 0xe1, 0x00, 0x8b, 0xbc, 0x3d, 0xe4, 0x6d, 0x81, 0x09, 0x29, 0x4f,

View File

@ -2,4 +2,6 @@ package tls
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "TLS") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "TLS")
}

View File

@ -2,4 +2,6 @@ package udp
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "UDP") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "UDP")
}

View File

@ -16,14 +16,36 @@ var _ = math.Inf
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type Header struct {
Key string `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"`
Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
Key string `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"`
Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Header) Reset() { *m = Header{} }
func (m *Header) String() string { return proto.CompactTextString(m) }
func (*Header) ProtoMessage() {}
func (*Header) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *Header) Reset() { *m = Header{} }
func (m *Header) String() string { return proto.CompactTextString(m) }
func (*Header) ProtoMessage() {}
func (*Header) Descriptor() ([]byte, []int) {
return fileDescriptor_config_0ec5fa9e0dc0ba05, []int{0}
}
func (m *Header) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Header.Unmarshal(m, b)
}
func (m *Header) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Header.Marshal(b, m, deterministic)
}
func (dst *Header) XXX_Merge(src proto.Message) {
xxx_messageInfo_Header.Merge(dst, src)
}
func (m *Header) XXX_Size() int {
return xxx_messageInfo_Header.Size(m)
}
func (m *Header) XXX_DiscardUnknown() {
xxx_messageInfo_Header.DiscardUnknown(m)
}
var xxx_messageInfo_Header proto.InternalMessageInfo
func (m *Header) GetKey() string {
if m != nil {
@ -41,14 +63,36 @@ func (m *Header) GetValue() string {
type Config struct {
// URL path to the WebSocket service. Empty value means root(/).
Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"`
Header []*Header `protobuf:"bytes,3,rep,name=header" json:"header,omitempty"`
Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"`
Header []*Header `protobuf:"bytes,3,rep,name=header" json:"header,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *Config) Reset() { *m = Config{} }
func (m *Config) String() string { return proto.CompactTextString(m) }
func (*Config) ProtoMessage() {}
func (*Config) Descriptor() ([]byte, []int) {
return fileDescriptor_config_0ec5fa9e0dc0ba05, []int{1}
}
func (m *Config) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Config.Unmarshal(m, b)
}
func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Config.Marshal(b, m, deterministic)
}
func (dst *Config) XXX_Merge(src proto.Message) {
xxx_messageInfo_Config.Merge(dst, src)
}
func (m *Config) XXX_Size() int {
return xxx_messageInfo_Config.Size(m)
}
func (m *Config) XXX_DiscardUnknown() {
xxx_messageInfo_Config.DiscardUnknown(m)
}
var xxx_messageInfo_Config proto.InternalMessageInfo
func (m *Config) GetPath() string {
if m != nil {
@ -70,10 +114,10 @@ func init() {
}
func init() {
proto.RegisterFile("v2ray.com/core/transport/internet/websocket/config.proto", fileDescriptor0)
proto.RegisterFile("v2ray.com/core/transport/internet/websocket/config.proto", fileDescriptor_config_0ec5fa9e0dc0ba05)
}
var fileDescriptor0 = []byte{
var fileDescriptor_config_0ec5fa9e0dc0ba05 = []byte{
// 229 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xb2, 0x28, 0x33, 0x2a, 0x4a,
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x29, 0x4a, 0xcc, 0x2b,

View File

@ -2,4 +2,6 @@ package websocket
import "v2ray.com/core/common/errors"
func newError(values ...interface{}) *errors.Error { return errors.New(values...).Path("Transport", "Internet", "WebSocket") }
func newError(values ...interface{}) *errors.Error {
return errors.New(values...).Path("Transport", "Internet", "WebSocket")
}