Documentation ¶
Overview ¶
Package vmess contains the implementation of VMess protocol and transportation.
VMess contains both inbound and outbound connections. VMess inbound is usually used on servers together with 'freedom' to talk to final destination, while VMess outbound is usually used on clients with 'socks' for proxying.
Index ¶
- Variables
- type Account
- func (a *Account) AsAccount() (protocol.Account, error)
- func (*Account) Descriptor() ([]byte, []int)deprecated
- func (x *Account) GetId() string
- func (x *Account) GetSecuritySettings() *protocol.SecurityConfig
- func (x *Account) GetTestsEnabled() string
- func (*Account) ProtoMessage()
- func (x *Account) ProtoReflect() protoreflect.Message
- func (x *Account) Reset()
- func (x *Account) String() string
- type MemoryAccount
- type TimedUserValidator
- func (v *TimedUserValidator) Add(u *protocol.MemoryUser) error
- func (v *TimedUserValidator) GetAEAD(userHash []byte) (*protocol.MemoryUser, bool, error)
- func (v *TimedUserValidator) GetBehaviorSeed() uint64
- func (v *TimedUserValidator) GetCount() int64
- func (v *TimedUserValidator) GetUsers() []*protocol.MemoryUser
- func (v *TimedUserValidator) Remove(email string) bool
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("Not Found")
View Source
var ErrTainted = errors.New("ErrTainted")
View Source
var File_proxy_vmess_account_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { // ID of the account, in the form of a UUID, e.g., // "66ad4540-b58c-4ad2-9926-ea63445a9b57". Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // Security settings. Only applies to client side. SecuritySettings *protocol.SecurityConfig `protobuf:"bytes,3,opt,name=security_settings,json=securitySettings,proto3" json:"security_settings,omitempty"` // Define tests enabled for this account TestsEnabled string `protobuf:"bytes,4,opt,name=tests_enabled,json=testsEnabled,proto3" json:"tests_enabled,omitempty"` // contains filtered or unexported fields }
func (*Account) Descriptor
deprecated
func (*Account) GetSecuritySettings ¶
func (x *Account) GetSecuritySettings() *protocol.SecurityConfig
func (*Account) GetTestsEnabled ¶
func (*Account) ProtoMessage ¶
func (*Account) ProtoMessage()
func (*Account) ProtoReflect ¶
func (x *Account) ProtoReflect() protoreflect.Message
type MemoryAccount ¶
type MemoryAccount struct { // ID is the main ID of the account. ID *protocol.ID // Security type of the account. Used for client connections. Security protocol.SecurityType AuthenticatedLengthExperiment bool NoTerminationSignal bool }
MemoryAccount is an in-memory form of VMess account.
func (*MemoryAccount) Equals ¶
func (a *MemoryAccount) Equals(account protocol.Account) bool
Equals implements protocol.Account.
func (*MemoryAccount) ToProto ¶
func (a *MemoryAccount) ToProto() proto.Message
type TimedUserValidator ¶
TimedUserValidator is a user Validator based on time.
func NewTimedUserValidator ¶
func NewTimedUserValidator() *TimedUserValidator
NewTimedUserValidator creates a new TimedUserValidator.
func (*TimedUserValidator) Add ¶
func (v *TimedUserValidator) Add(u *protocol.MemoryUser) error
func (*TimedUserValidator) GetAEAD ¶
func (v *TimedUserValidator) GetAEAD(userHash []byte) (*protocol.MemoryUser, bool, error)
func (*TimedUserValidator) GetBehaviorSeed ¶
func (v *TimedUserValidator) GetBehaviorSeed() uint64
func (*TimedUserValidator) GetCount ¶
func (v *TimedUserValidator) GetCount() int64
func (*TimedUserValidator) GetUsers ¶
func (v *TimedUserValidator) GetUsers() []*protocol.MemoryUser
func (*TimedUserValidator) Remove ¶
func (v *TimedUserValidator) Remove(email string) bool
Click to show internal directories.
Click to hide internal directories.