Documentation ¶
Index ¶
- Variables
- func GenerateRandomBytes(n int64) ([]byte, error)
- func NewPacketReader(conn net.Conn, UDPOverride net.Destination) buf.Reader
- func NewPacketWriter(conn net.Conn, h *Handler, ctx context.Context, UDPOverride net.Destination) buf.Writer
- type Config
- func (*Config) Descriptor() ([]byte, []int)deprecated
- func (x *Config) GetDestinationOverride() *DestinationOverride
- func (x *Config) GetDomainStrategy() Config_DomainStrategy
- func (x *Config) GetFragment() *Fragment
- func (x *Config) GetNoises() []*Noise
- func (x *Config) GetProxyProtocol() uint32
- func (x *Config) GetUserLevel() uint32
- func (*Config) ProtoMessage()
- func (x *Config) ProtoReflect() protoreflect.Message
- func (x *Config) Reset()
- func (x *Config) String() string
- type Config_DomainStrategy
- func (Config_DomainStrategy) Descriptor() protoreflect.EnumDescriptor
- func (x Config_DomainStrategy) Enum() *Config_DomainStrategy
- func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int)deprecated
- func (x Config_DomainStrategy) Number() protoreflect.EnumNumber
- func (x Config_DomainStrategy) String() string
- func (Config_DomainStrategy) Type() protoreflect.EnumType
- type DestinationOverride
- func (*DestinationOverride) Descriptor() ([]byte, []int)deprecated
- func (x *DestinationOverride) GetServer() *protocol.ServerEndpoint
- func (*DestinationOverride) ProtoMessage()
- func (x *DestinationOverride) ProtoReflect() protoreflect.Message
- func (x *DestinationOverride) Reset()
- func (x *DestinationOverride) String() string
- type Fragment
- func (*Fragment) Descriptor() ([]byte, []int)deprecated
- func (x *Fragment) GetIntervalMax() uint64
- func (x *Fragment) GetIntervalMin() uint64
- func (x *Fragment) GetLengthMax() uint64
- func (x *Fragment) GetLengthMin() uint64
- func (x *Fragment) GetPacketsFrom() uint64
- func (x *Fragment) GetPacketsTo() uint64
- func (*Fragment) ProtoMessage()
- func (x *Fragment) ProtoReflect() protoreflect.Message
- func (x *Fragment) Reset()
- func (x *Fragment) String() string
- type FragmentWriter
- type Handler
- type Noise
- func (*Noise) Descriptor() ([]byte, []int)deprecated
- func (x *Noise) GetDelayMax() uint64
- func (x *Noise) GetDelayMin() uint64
- func (x *Noise) GetLengthMax() uint64
- func (x *Noise) GetLengthMin() uint64
- func (x *Noise) GetStrNoise() []byte
- func (*Noise) ProtoMessage()
- func (x *Noise) ProtoReflect() protoreflect.Message
- func (x *Noise) Reset()
- func (x *Noise) String() string
- type NoisePacketWriter
- type PacketReader
- type PacketWriter
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Config_DomainStrategy_name = map[int32]string{ 0: "AS_IS", 1: "USE_IP", 2: "USE_IP4", 3: "USE_IP6", 4: "USE_IP46", 5: "USE_IP64", 6: "FORCE_IP", 7: "FORCE_IP4", 8: "FORCE_IP6", 9: "FORCE_IP46", 10: "FORCE_IP64", } Config_DomainStrategy_value = map[string]int32{ "AS_IS": 0, "USE_IP": 1, "USE_IP4": 2, "USE_IP6": 3, "USE_IP46": 4, "USE_IP64": 5, "FORCE_IP": 6, "FORCE_IP4": 7, "FORCE_IP6": 8, "FORCE_IP46": 9, "FORCE_IP64": 10, } )
Enum value maps for Config_DomainStrategy.
View Source
var File_proxy_freedom_config_proto protoreflect.FileDescriptor
Functions ¶
func GenerateRandomBytes ¶
func NewPacketReader ¶
Types ¶
type Config ¶
type Config struct { DomainStrategy Config_DomainStrategy `` /* 150-byte string literal not displayed */ DestinationOverride *DestinationOverride `protobuf:"bytes,3,opt,name=destination_override,json=destinationOverride,proto3" json:"destination_override,omitempty"` UserLevel uint32 `protobuf:"varint,4,opt,name=user_level,json=userLevel,proto3" json:"user_level,omitempty"` Fragment *Fragment `protobuf:"bytes,5,opt,name=fragment,proto3" json:"fragment,omitempty"` ProxyProtocol uint32 `protobuf:"varint,6,opt,name=proxy_protocol,json=proxyProtocol,proto3" json:"proxy_protocol,omitempty"` Noises []*Noise `protobuf:"bytes,7,rep,name=noises,proto3" json:"noises,omitempty"` // contains filtered or unexported fields }
func (*Config) Descriptor
deprecated
func (*Config) GetDestinationOverride ¶
func (x *Config) GetDestinationOverride() *DestinationOverride
func (*Config) GetDomainStrategy ¶
func (x *Config) GetDomainStrategy() Config_DomainStrategy
func (*Config) GetFragment ¶
func (*Config) GetProxyProtocol ¶
func (*Config) GetUserLevel ¶
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
type Config_DomainStrategy ¶
type Config_DomainStrategy int32
const ( Config_AS_IS Config_DomainStrategy = 0 Config_USE_IP Config_DomainStrategy = 1 Config_USE_IP4 Config_DomainStrategy = 2 Config_USE_IP6 Config_DomainStrategy = 3 Config_USE_IP46 Config_DomainStrategy = 4 Config_USE_IP64 Config_DomainStrategy = 5 Config_FORCE_IP Config_DomainStrategy = 6 Config_FORCE_IP4 Config_DomainStrategy = 7 Config_FORCE_IP6 Config_DomainStrategy = 8 Config_FORCE_IP46 Config_DomainStrategy = 9 Config_FORCE_IP64 Config_DomainStrategy = 10 )
func (Config_DomainStrategy) Descriptor ¶
func (Config_DomainStrategy) Descriptor() protoreflect.EnumDescriptor
func (Config_DomainStrategy) Enum ¶
func (x Config_DomainStrategy) Enum() *Config_DomainStrategy
func (Config_DomainStrategy) EnumDescriptor
deprecated
func (Config_DomainStrategy) EnumDescriptor() ([]byte, []int)
Deprecated: Use Config_DomainStrategy.Descriptor instead.
func (Config_DomainStrategy) Number ¶
func (x Config_DomainStrategy) Number() protoreflect.EnumNumber
func (Config_DomainStrategy) String ¶
func (x Config_DomainStrategy) String() string
func (Config_DomainStrategy) Type ¶
func (Config_DomainStrategy) Type() protoreflect.EnumType
type DestinationOverride ¶
type DestinationOverride struct { Server *protocol.ServerEndpoint `protobuf:"bytes,1,opt,name=server,proto3" json:"server,omitempty"` // contains filtered or unexported fields }
func (*DestinationOverride) Descriptor
deprecated
func (*DestinationOverride) Descriptor() ([]byte, []int)
Deprecated: Use DestinationOverride.ProtoReflect.Descriptor instead.
func (*DestinationOverride) GetServer ¶
func (x *DestinationOverride) GetServer() *protocol.ServerEndpoint
func (*DestinationOverride) ProtoMessage ¶
func (*DestinationOverride) ProtoMessage()
func (*DestinationOverride) ProtoReflect ¶
func (x *DestinationOverride) ProtoReflect() protoreflect.Message
func (*DestinationOverride) Reset ¶
func (x *DestinationOverride) Reset()
func (*DestinationOverride) String ¶
func (x *DestinationOverride) String() string
type Fragment ¶
type Fragment struct { PacketsFrom uint64 `protobuf:"varint,1,opt,name=packets_from,json=packetsFrom,proto3" json:"packets_from,omitempty"` PacketsTo uint64 `protobuf:"varint,2,opt,name=packets_to,json=packetsTo,proto3" json:"packets_to,omitempty"` LengthMin uint64 `protobuf:"varint,3,opt,name=length_min,json=lengthMin,proto3" json:"length_min,omitempty"` LengthMax uint64 `protobuf:"varint,4,opt,name=length_max,json=lengthMax,proto3" json:"length_max,omitempty"` IntervalMin uint64 `protobuf:"varint,5,opt,name=interval_min,json=intervalMin,proto3" json:"interval_min,omitempty"` IntervalMax uint64 `protobuf:"varint,6,opt,name=interval_max,json=intervalMax,proto3" json:"interval_max,omitempty"` // contains filtered or unexported fields }
func (*Fragment) Descriptor
deprecated
func (*Fragment) GetIntervalMax ¶
func (*Fragment) GetIntervalMin ¶
func (*Fragment) GetLengthMax ¶
func (*Fragment) GetLengthMin ¶
func (*Fragment) GetPacketsFrom ¶
func (*Fragment) GetPacketsTo ¶
func (*Fragment) ProtoMessage ¶
func (*Fragment) ProtoMessage()
func (*Fragment) ProtoReflect ¶
func (x *Fragment) ProtoReflect() protoreflect.Message
type FragmentWriter ¶
type FragmentWriter struct {
// contains filtered or unexported fields
}
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler handles Freedom connections.
type Noise ¶
type Noise struct { LengthMin uint64 `protobuf:"varint,1,opt,name=length_min,json=lengthMin,proto3" json:"length_min,omitempty"` LengthMax uint64 `protobuf:"varint,2,opt,name=length_max,json=lengthMax,proto3" json:"length_max,omitempty"` DelayMin uint64 `protobuf:"varint,3,opt,name=delay_min,json=delayMin,proto3" json:"delay_min,omitempty"` DelayMax uint64 `protobuf:"varint,4,opt,name=delay_max,json=delayMax,proto3" json:"delay_max,omitempty"` StrNoise []byte `protobuf:"bytes,5,opt,name=str_noise,json=strNoise,proto3" json:"str_noise,omitempty"` // contains filtered or unexported fields }
func (*Noise) Descriptor
deprecated
func (*Noise) GetDelayMax ¶
func (*Noise) GetDelayMin ¶
func (*Noise) GetLengthMax ¶
func (*Noise) GetLengthMin ¶
func (*Noise) GetStrNoise ¶
func (*Noise) ProtoMessage ¶
func (*Noise) ProtoMessage()
func (*Noise) ProtoReflect ¶
func (x *Noise) ProtoReflect() protoreflect.Message
type NoisePacketWriter ¶
type NoisePacketWriter struct { buf.Writer UDPOverride net.Destination // contains filtered or unexported fields }
func (*NoisePacketWriter) WriteMultiBuffer ¶
func (w *NoisePacketWriter) WriteMultiBuffer(mb buf.MultiBuffer) error
MultiBuffer writer with Noise before first packet
type PacketReader ¶
type PacketReader struct { *internet.PacketConnWrapper stats.Counter }
func (*PacketReader) ReadMultiBuffer ¶
func (r *PacketReader) ReadMultiBuffer() (buf.MultiBuffer, error)
type PacketWriter ¶
type PacketWriter struct { *internet.PacketConnWrapper stats.Counter *Handler context.Context UDPOverride net.Destination }
func (*PacketWriter) WriteMultiBuffer ¶
func (w *PacketWriter) WriteMultiBuffer(mb buf.MultiBuffer) error
Click to show internal directories.
Click to hide internal directories.