2017-01-02 14:52:45 -05:00
|
|
|
package protocol
|
|
|
|
|
|
|
|
import proto "github.com/golang/protobuf/proto"
|
|
|
|
import fmt "fmt"
|
|
|
|
import math "math"
|
|
|
|
|
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
|
|
var _ = proto.Marshal
|
|
|
|
var _ = fmt.Errorf
|
|
|
|
var _ = math.Inf
|
|
|
|
|
2018-05-25 05:56:01 -04:00
|
|
|
// 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
|
|
|
|
|
2017-01-02 14:52:45 -05:00
|
|
|
type SecurityType int32
|
|
|
|
|
|
|
|
const (
|
|
|
|
SecurityType_UNKNOWN SecurityType = 0
|
|
|
|
SecurityType_LEGACY SecurityType = 1
|
|
|
|
SecurityType_AUTO SecurityType = 2
|
|
|
|
SecurityType_AES128_GCM SecurityType = 3
|
|
|
|
SecurityType_CHACHA20_POLY1305 SecurityType = 4
|
|
|
|
SecurityType_NONE SecurityType = 5
|
|
|
|
)
|
|
|
|
|
|
|
|
var SecurityType_name = map[int32]string{
|
|
|
|
0: "UNKNOWN",
|
|
|
|
1: "LEGACY",
|
|
|
|
2: "AUTO",
|
|
|
|
3: "AES128_GCM",
|
|
|
|
4: "CHACHA20_POLY1305",
|
|
|
|
5: "NONE",
|
|
|
|
}
|
|
|
|
var SecurityType_value = map[string]int32{
|
|
|
|
"UNKNOWN": 0,
|
|
|
|
"LEGACY": 1,
|
|
|
|
"AUTO": 2,
|
|
|
|
"AES128_GCM": 3,
|
|
|
|
"CHACHA20_POLY1305": 4,
|
|
|
|
"NONE": 5,
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x SecurityType) String() string {
|
|
|
|
return proto.EnumName(SecurityType_name, int32(x))
|
|
|
|
}
|
2018-05-25 05:56:01 -04:00
|
|
|
func (SecurityType) EnumDescriptor() ([]byte, []int) {
|
|
|
|
return fileDescriptor_headers_22aa312cf9baa01e, []int{0}
|
|
|
|
}
|
2017-01-02 14:52:45 -05:00
|
|
|
|
|
|
|
type SecurityConfig struct {
|
2018-06-26 10:28:54 -04:00
|
|
|
Type SecurityType `protobuf:"varint,1,opt,name=type,proto3,enum=v2ray.core.common.protocol.SecurityType" json:"type,omitempty"`
|
2018-05-25 05:56:01 -04:00
|
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
|
|
XXX_unrecognized []byte `json:"-"`
|
|
|
|
XXX_sizecache int32 `json:"-"`
|
2017-01-02 14:52:45 -05:00
|
|
|
}
|
|
|
|
|
2018-05-25 05:56:01 -04:00
|
|
|
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
|
2017-01-02 14:52:45 -05:00
|
|
|
|
|
|
|
func (m *SecurityConfig) GetType() SecurityType {
|
|
|
|
if m != nil {
|
|
|
|
return m.Type
|
|
|
|
}
|
|
|
|
return SecurityType_UNKNOWN
|
|
|
|
}
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
proto.RegisterType((*SecurityConfig)(nil), "v2ray.core.common.protocol.SecurityConfig")
|
|
|
|
proto.RegisterEnum("v2ray.core.common.protocol.SecurityType", SecurityType_name, SecurityType_value)
|
|
|
|
}
|
|
|
|
|
2018-05-25 05:56:01 -04:00
|
|
|
func init() {
|
|
|
|
proto.RegisterFile("v2ray.com/core/common/protocol/headers.proto", fileDescriptor_headers_22aa312cf9baa01e)
|
|
|
|
}
|
2017-01-02 14:52:45 -05:00
|
|
|
|
2018-05-25 05:56:01 -04:00
|
|
|
var fileDescriptor_headers_22aa312cf9baa01e = []byte{
|
2017-02-03 17:15:10 -05:00
|
|
|
// 252 bytes of a gzipped FileDescriptorProto
|
2017-04-04 06:28:14 -04:00
|
|
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x29, 0x33, 0x2a, 0x4a,
|
2017-01-02 14:52:45 -05:00
|
|
|
0xac, 0xd4, 0x4b, 0xce, 0xcf, 0xd5, 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xcf, 0xcd, 0xcd,
|
|
|
|
0xcf, 0xd3, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0xce, 0xcf, 0xd1, 0xcf, 0x48, 0x4d, 0x4c, 0x49,
|
|
|
|
0x2d, 0x2a, 0xd6, 0x03, 0x0b, 0x08, 0x49, 0xc1, 0x54, 0x17, 0xa5, 0xea, 0x41, 0x54, 0xea, 0xc1,
|
|
|
|
0x54, 0x2a, 0xf9, 0x71, 0xf1, 0x05, 0xa7, 0x26, 0x97, 0x16, 0x65, 0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