inbound

package
v1.260206.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 6, 2026 License: MPL-2.0 Imports: 42 Imported by: 66

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proxy_vless_inbound_config_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Config

type Config struct {
	Clients     []*protocol.User `protobuf:"bytes,1,rep,name=clients,proto3" json:"clients,omitempty"`
	Fallbacks   []*Fallback      `protobuf:"bytes,2,rep,name=fallbacks,proto3" json:"fallbacks,omitempty"`
	Decryption  string           `protobuf:"bytes,3,opt,name=decryption,proto3" json:"decryption,omitempty"`
	XorMode     uint32           `protobuf:"varint,4,opt,name=xorMode,proto3" json:"xorMode,omitempty"`
	SecondsFrom int64            `protobuf:"varint,5,opt,name=seconds_from,json=secondsFrom,proto3" json:"seconds_from,omitempty"`
	SecondsTo   int64            `protobuf:"varint,6,opt,name=seconds_to,json=secondsTo,proto3" json:"seconds_to,omitempty"`
	Padding     string           `protobuf:"bytes,7,opt,name=padding,proto3" json:"padding,omitempty"`
	// contains filtered or unexported fields
}

func (*Config) Descriptor deprecated

func (*Config) Descriptor() ([]byte, []int)

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetClients

func (x *Config) GetClients() []*protocol.User

func (*Config) GetDecryption

func (x *Config) GetDecryption() string

func (*Config) GetFallbacks

func (x *Config) GetFallbacks() []*Fallback

func (*Config) GetPadding added in v1.250831.0

func (x *Config) GetPadding() string

func (*Config) GetSecondsFrom added in v1.250905.0

func (x *Config) GetSecondsFrom() int64

func (*Config) GetSecondsTo added in v1.250905.0

func (x *Config) GetSecondsTo() int64

func (*Config) GetXorMode added in v1.250831.0

func (x *Config) GetXorMode() uint32

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) ProtoReflect

func (x *Config) ProtoReflect() protoreflect.Message

func (*Config) Reset

func (x *Config) Reset()

func (*Config) String

func (x *Config) String() string

type Fallback

type Fallback struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Alpn string `protobuf:"bytes,2,opt,name=alpn,proto3" json:"alpn,omitempty"`
	Path string `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
	Type string `protobuf:"bytes,4,opt,name=type,proto3" json:"type,omitempty"`
	Dest string `protobuf:"bytes,5,opt,name=dest,proto3" json:"dest,omitempty"`
	Xver uint64 `protobuf:"varint,6,opt,name=xver,proto3" json:"xver,omitempty"`
	// contains filtered or unexported fields
}

func (*Fallback) Descriptor deprecated

func (*Fallback) Descriptor() ([]byte, []int)

Deprecated: Use Fallback.ProtoReflect.Descriptor instead.

func (*Fallback) GetAlpn

func (x *Fallback) GetAlpn() string

func (*Fallback) GetDest

func (x *Fallback) GetDest() string

func (*Fallback) GetName added in v1.2.2

func (x *Fallback) GetName() string

func (*Fallback) GetPath

func (x *Fallback) GetPath() string

func (*Fallback) GetType

func (x *Fallback) GetType() string

func (*Fallback) GetXver

func (x *Fallback) GetXver() uint64

func (*Fallback) ProtoMessage

func (*Fallback) ProtoMessage()

func (*Fallback) ProtoReflect

func (x *Fallback) ProtoReflect() protoreflect.Message

func (*Fallback) Reset

func (x *Fallback) Reset()

func (*Fallback) String

func (x *Fallback) String() string

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler is an inbound connection handler that handles messages in VLess protocol.

func New

func New(ctx context.Context, config *Config, dc dns.Client, validator vless.Validator) (*Handler, error)

New creates a new VLess inbound handler.

func (*Handler) AddUser

func (h *Handler) AddUser(ctx context.Context, u *protocol.MemoryUser) error

AddUser implements proxy.UserManager.AddUser().

func (*Handler) Close

func (h *Handler) Close() error

Close implements common.Closable.Close().

func (*Handler) GetReverse added in v1.250910.0

func (h *Handler) GetReverse(a *vless.MemoryAccount) (*Reverse, error)

func (*Handler) GetUser added in v1.250306.0

func (h *Handler) GetUser(ctx context.Context, email string) *protocol.MemoryUser

GetUser implements proxy.UserManager.GetUser().

func (*Handler) GetUsers added in v1.250306.0

func (h *Handler) GetUsers(ctx context.Context) []*protocol.MemoryUser

GetUsers implements proxy.UserManager.GetUsers().

func (*Handler) GetUsersCount added in v1.250306.0

func (h *Handler) GetUsersCount(context.Context) int64

GetUsersCount implements proxy.UserManager.GetUsersCount().

func (*Handler) Network

func (*Handler) Network() []net.Network

Network implements proxy.Inbound.Network().

func (*Handler) Process

func (h *Handler) Process(ctx context.Context, network net.Network, connection stat.Connection, dispatch routing.Dispatcher) error

Process implements proxy.Inbound.Process().

func (*Handler) RemoveReverse added in v1.250910.0

func (h *Handler) RemoveReverse(u *protocol.MemoryUser)

func (*Handler) RemoveUser

func (h *Handler) RemoveUser(ctx context.Context, e string) error

RemoveUser implements proxy.UserManager.RemoveUser().

type Reverse added in v1.250910.0

type Reverse struct {
	// contains filtered or unexported fields
}

func (*Reverse) Close added in v1.250910.0

func (r *Reverse) Close() error

func (*Reverse) Dispatch added in v1.250910.0

func (r *Reverse) Dispatch(ctx context.Context, link *transport.Link)

func (*Reverse) NewMux added in v1.250910.0

func (r *Reverse) NewMux(ctx context.Context, link *transport.Link) error

func (*Reverse) ProxySettings added in v1.250910.0

func (r *Reverse) ProxySettings() *serial.TypedMessage

func (*Reverse) SenderSettings added in v1.250910.0

func (r *Reverse) SenderSettings() *serial.TypedMessage

func (*Reverse) Start added in v1.250910.0

func (r *Reverse) Start() error

func (*Reverse) Tag added in v1.250910.0

func (r *Reverse) Tag() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL