tdproto

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2021 License: GPL-3.0, Apache-2.0 Imports: 5 Imported by: 0

README

Protobuf messages for TapDance

godoc

Rebuild

protoc --go_out=import_path=tdproto:. signalling.proto

Documentation

Index

Constants

This section is empty.

Variables

View Source
var C2S_Transition_name = map[int32]string{
	0:   "C2S_NO_CHANGE",
	1:   "C2S_SESSION_INIT",
	11:  "C2S_SESSION_COVERT_INIT",
	2:   "C2S_EXPECT_RECONNECT",
	3:   "C2S_SESSION_CLOSE",
	4:   "C2S_YIELD_UPLOAD",
	5:   "C2S_ACQUIRE_UPLOAD",
	6:   "C2S_EXPECT_UPLOADONLY_RECONN",
	255: "C2S_ERROR",
}
View Source
var C2S_Transition_value = map[string]int32{
	"C2S_NO_CHANGE":                0,
	"C2S_SESSION_INIT":             1,
	"C2S_SESSION_COVERT_INIT":      11,
	"C2S_EXPECT_RECONNECT":         2,
	"C2S_SESSION_CLOSE":            3,
	"C2S_YIELD_UPLOAD":             4,
	"C2S_ACQUIRE_UPLOAD":           5,
	"C2S_EXPECT_UPLOADONLY_RECONN": 6,
	"C2S_ERROR":                    255,
}
View Source
var ErrorReasonS2C_name = map[int32]string{
	0:   "NO_ERROR",
	1:   "COVERT_STREAM",
	2:   "CLIENT_REPORTED",
	3:   "CLIENT_PROTOCOL",
	4:   "STATION_INTERNAL",
	5:   "DECOY_OVERLOAD",
	100: "CLIENT_STREAM",
	101: "CLIENT_TIMEOUT",
}
View Source
var ErrorReasonS2C_value = map[string]int32{
	"NO_ERROR":         0,
	"COVERT_STREAM":    1,
	"CLIENT_REPORTED":  2,
	"CLIENT_PROTOCOL":  3,
	"STATION_INTERNAL": 4,
	"DECOY_OVERLOAD":   5,
	"CLIENT_STREAM":    100,
	"CLIENT_TIMEOUT":   101,
}
View Source
var KeyType_name = map[int32]string{
	90: "AES_GCM_128",
	91: "AES_GCM_256",
}
View Source
var KeyType_value = map[string]int32{
	"AES_GCM_128": 90,
	"AES_GCM_256": 91,
}
View Source
var RegistrationSource_name = map[int32]string{
	0: "Unspecified",
	1: "Detector",
	2: "API",
	3: "DetectorPrescan",
}
View Source
var RegistrationSource_value = map[string]int32{
	"Unspecified":     0,
	"Detector":        1,
	"API":             2,
	"DetectorPrescan": 3,
}
View Source
var S2C_Transition_name = map[int32]string{
	0:   "S2C_NO_CHANGE",
	1:   "S2C_SESSION_INIT",
	11:  "S2C_SESSION_COVERT_INIT",
	2:   "S2C_CONFIRM_RECONNECT",
	3:   "S2C_SESSION_CLOSE",
	255: "S2C_ERROR",
}
View Source
var S2C_Transition_value = map[string]int32{
	"S2C_NO_CHANGE":           0,
	"S2C_SESSION_INIT":        1,
	"S2C_SESSION_COVERT_INIT": 11,
	"S2C_CONFIRM_RECONNECT":   2,
	"S2C_SESSION_CLOSE":       3,
	"S2C_ERROR":               255,
}
View Source
var TransportType_name = map[int32]string{
	0: "Null",
	1: "Min",
	2: "Obfs4",
}
View Source
var TransportType_value = map[string]int32{
	"Null":  0,
	"Min":   1,
	"Obfs4": 2,
}

Functions

This section is empty.

Types

type C2SWrapper

type C2SWrapper struct {
	SharedSecret        []byte              `protobuf:"bytes,1,opt,name=shared_secret,json=sharedSecret" json:"shared_secret,omitempty"`
	RegistrationPayload *ClientToStation    `protobuf:"bytes,3,opt,name=registration_payload,json=registrationPayload" json:"registration_payload,omitempty"`
	RegistrationSource  *RegistrationSource `` /* 142-byte string literal not displayed */
	// client source address when receiving a registration
	RegistrationAddress []byte `protobuf:"bytes,6,opt,name=registration_address,json=registrationAddress" json:"registration_address,omitempty"`
	// Decoy address used when registering over Decoy registrar
	DecoyAddress         []byte   `protobuf:"bytes,7,opt,name=decoy_address,json=decoyAddress" json:"decoy_address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*C2SWrapper) Descriptor

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

func (*C2SWrapper) GetDecoyAddress

func (m *C2SWrapper) GetDecoyAddress() []byte

func (*C2SWrapper) GetRegistrationAddress

func (m *C2SWrapper) GetRegistrationAddress() []byte

func (*C2SWrapper) GetRegistrationPayload

func (m *C2SWrapper) GetRegistrationPayload() *ClientToStation

func (*C2SWrapper) GetRegistrationSource

func (m *C2SWrapper) GetRegistrationSource() RegistrationSource

func (*C2SWrapper) GetSharedSecret

func (m *C2SWrapper) GetSharedSecret() []byte

func (*C2SWrapper) ProtoMessage

func (*C2SWrapper) ProtoMessage()

func (*C2SWrapper) Reset

func (m *C2SWrapper) Reset()

func (*C2SWrapper) String

func (m *C2SWrapper) String() string

func (*C2SWrapper) XXX_DiscardUnknown

func (m *C2SWrapper) XXX_DiscardUnknown()

func (*C2SWrapper) XXX_Marshal

func (m *C2SWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*C2SWrapper) XXX_Merge

func (m *C2SWrapper) XXX_Merge(src proto.Message)

func (*C2SWrapper) XXX_Size

func (m *C2SWrapper) XXX_Size() int

func (*C2SWrapper) XXX_Unmarshal

func (m *C2SWrapper) XXX_Unmarshal(b []byte) error

type C2S_Transition

type C2S_Transition int32

State transitions of the client

const (
	C2S_Transition_C2S_NO_CHANGE                C2S_Transition = 0
	C2S_Transition_C2S_SESSION_INIT             C2S_Transition = 1
	C2S_Transition_C2S_SESSION_COVERT_INIT      C2S_Transition = 11
	C2S_Transition_C2S_EXPECT_RECONNECT         C2S_Transition = 2
	C2S_Transition_C2S_SESSION_CLOSE            C2S_Transition = 3
	C2S_Transition_C2S_YIELD_UPLOAD             C2S_Transition = 4
	C2S_Transition_C2S_ACQUIRE_UPLOAD           C2S_Transition = 5
	C2S_Transition_C2S_EXPECT_UPLOADONLY_RECONN C2S_Transition = 6
	C2S_Transition_C2S_ERROR                    C2S_Transition = 255
)

func (C2S_Transition) Enum

func (x C2S_Transition) Enum() *C2S_Transition

func (C2S_Transition) EnumDescriptor

func (C2S_Transition) EnumDescriptor() ([]byte, []int)

func (C2S_Transition) String

func (x C2S_Transition) String() string

func (*C2S_Transition) UnmarshalJSON

func (x *C2S_Transition) UnmarshalJSON(data []byte) error

type ClientConf

type ClientConf struct {
	DecoyList            *DecoyList          `protobuf:"bytes,1,opt,name=decoy_list,json=decoyList" json:"decoy_list,omitempty"`
	Generation           *uint32             `protobuf:"varint,2,opt,name=generation" json:"generation,omitempty"`
	DefaultPubkey        *PubKey             `protobuf:"bytes,3,opt,name=default_pubkey,json=defaultPubkey" json:"default_pubkey,omitempty"`
	PhantomSubnetsList   *PhantomSubnetsList `protobuf:"bytes,4,opt,name=phantom_subnets_list,json=phantomSubnetsList" json:"phantom_subnets_list,omitempty"`
	ConjurePubkey        *PubKey             `protobuf:"bytes,5,opt,name=conjure_pubkey,json=conjurePubkey" json:"conjure_pubkey,omitempty"`
	XXX_NoUnkeyedLiteral struct{}            `json:"-"`
	XXX_unrecognized     []byte              `json:"-"`
	XXX_sizecache        int32               `json:"-"`
}

func (*ClientConf) Descriptor

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

func (*ClientConf) GetConjurePubkey

func (m *ClientConf) GetConjurePubkey() *PubKey

func (*ClientConf) GetDecoyList

func (m *ClientConf) GetDecoyList() *DecoyList

func (*ClientConf) GetDefaultPubkey

func (m *ClientConf) GetDefaultPubkey() *PubKey

func (*ClientConf) GetGeneration

func (m *ClientConf) GetGeneration() uint32

func (*ClientConf) GetPhantomSubnetsList

func (m *ClientConf) GetPhantomSubnetsList() *PhantomSubnetsList

func (*ClientConf) ProtoMessage

func (*ClientConf) ProtoMessage()

func (*ClientConf) Reset

func (m *ClientConf) Reset()

func (*ClientConf) String

func (m *ClientConf) String() string

func (*ClientConf) XXX_DiscardUnknown

func (m *ClientConf) XXX_DiscardUnknown()

func (*ClientConf) XXX_Marshal

func (m *ClientConf) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ClientConf) XXX_Merge

func (m *ClientConf) XXX_Merge(src proto.Message)

func (*ClientConf) XXX_Size

func (m *ClientConf) XXX_Size() int

func (*ClientConf) XXX_Unmarshal

func (m *ClientConf) XXX_Unmarshal(b []byte) error

type ClientToStation

type ClientToStation struct {
	ProtocolVersion *uint32 `protobuf:"varint,1,opt,name=protocol_version,json=protocolVersion" json:"protocol_version,omitempty"`
	// The client reports its decoy list's version number here, which the
	// station can use to decide whether to send an updated one. The station
	// should always send a list if this field is set to 0.
	DecoyListGeneration *uint32         `protobuf:"varint,2,opt,name=decoy_list_generation,json=decoyListGeneration" json:"decoy_list_generation,omitempty"`
	StateTransition     *C2S_Transition `` /* 129-byte string literal not displayed */
	// The position in the overall session's upload sequence where the current
	// YIELD=>ACQUIRE switchover is happening.
	UploadSync *uint64 `protobuf:"varint,4,opt,name=upload_sync,json=uploadSync" json:"upload_sync,omitempty"`
	// List of decoys that client have unsuccessfully tried in current session.
	// Could be sent in chunks
	FailedDecoys []string      `protobuf:"bytes,10,rep,name=failed_decoys,json=failedDecoys" json:"failed_decoys,omitempty"`
	Stats        *SessionStats `protobuf:"bytes,11,opt,name=stats" json:"stats,omitempty"`
	// NullTransport, MinTransport, Obfs4Transport, etc. Transport type we want from phantom proxy
	Transport *TransportType `protobuf:"varint,12,opt,name=transport,enum=tapdance.TransportType" json:"transport,omitempty"`
	// Station is only required to check this variable during session initialization.
	// If set, station must facilitate connection to said target by itself, i.e. write into squid
	// socket an HTTP/SOCKS/any other connection request.
	// covert_address must have exactly one ':' colon, that separates host (literal IP address or
	// resolvable hostname) and port
	// TODO: make it required for initialization, and stop connecting any client straight to squid?
	CovertAddress *string `protobuf:"bytes,20,opt,name=covert_address,json=covertAddress" json:"covert_address,omitempty"`
	// Used in dark decoys to signal which dark decoy it will connect to.
	MaskedDecoyServerName *string `protobuf:"bytes,21,opt,name=masked_decoy_server_name,json=maskedDecoyServerName" json:"masked_decoy_server_name,omitempty"`
	// Used to indicate to server if client is registering v4, v6 or both
	V6Support *bool `protobuf:"varint,22,opt,name=v6_support,json=v6Support" json:"v6_support,omitempty"`
	V4Support *bool `protobuf:"varint,23,opt,name=v4_support,json=v4Support" json:"v4_support,omitempty"`
	// A collection of optional flags for the registration.
	Flags *RegistrationFlags `protobuf:"bytes,24,opt,name=flags" json:"flags,omitempty"`
	// Random-sized junk to defeat packet size fingerprinting.
	Padding              []byte   `protobuf:"bytes,100,opt,name=padding" json:"padding,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ClientToStation) Descriptor

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

func (*ClientToStation) GetCovertAddress

func (m *ClientToStation) GetCovertAddress() string

func (*ClientToStation) GetDecoyListGeneration

func (m *ClientToStation) GetDecoyListGeneration() uint32

func (*ClientToStation) GetFailedDecoys

func (m *ClientToStation) GetFailedDecoys() []string

func (*ClientToStation) GetFlags

func (m *ClientToStation) GetFlags() *RegistrationFlags

func (*ClientToStation) GetMaskedDecoyServerName

func (m *ClientToStation) GetMaskedDecoyServerName() string

func (*ClientToStation) GetPadding

func (m *ClientToStation) GetPadding() []byte

func (*ClientToStation) GetProtocolVersion

func (m *ClientToStation) GetProtocolVersion() uint32

func (*ClientToStation) GetStateTransition

func (m *ClientToStation) GetStateTransition() C2S_Transition

func (*ClientToStation) GetStats

func (m *ClientToStation) GetStats() *SessionStats

func (*ClientToStation) GetTransport

func (m *ClientToStation) GetTransport() TransportType

func (*ClientToStation) GetUploadSync

func (m *ClientToStation) GetUploadSync() uint64

func (*ClientToStation) GetV4Support

func (m *ClientToStation) GetV4Support() bool

func (*ClientToStation) GetV6Support

func (m *ClientToStation) GetV6Support() bool

func (*ClientToStation) ProtoMessage

func (*ClientToStation) ProtoMessage()

func (*ClientToStation) Reset

func (m *ClientToStation) Reset()

func (*ClientToStation) String

func (m *ClientToStation) String() string

func (*ClientToStation) XXX_DiscardUnknown

func (m *ClientToStation) XXX_DiscardUnknown()

func (*ClientToStation) XXX_Marshal

func (m *ClientToStation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ClientToStation) XXX_Merge

func (m *ClientToStation) XXX_Merge(src proto.Message)

func (*ClientToStation) XXX_Size

func (m *ClientToStation) XXX_Size() int

func (*ClientToStation) XXX_Unmarshal

func (m *ClientToStation) XXX_Unmarshal(b []byte) error

type DecoyList

type DecoyList struct {
	TlsDecoys            []*TLSDecoySpec `protobuf:"bytes,1,rep,name=tls_decoys,json=tlsDecoys" json:"tls_decoys,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

func (*DecoyList) Descriptor

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

func (*DecoyList) GetTlsDecoys

func (m *DecoyList) GetTlsDecoys() []*TLSDecoySpec

func (*DecoyList) ProtoMessage

func (*DecoyList) ProtoMessage()

func (*DecoyList) Reset

func (m *DecoyList) Reset()

func (*DecoyList) String

func (m *DecoyList) String() string

func (*DecoyList) XXX_DiscardUnknown

func (m *DecoyList) XXX_DiscardUnknown()

func (*DecoyList) XXX_Marshal

func (m *DecoyList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DecoyList) XXX_Merge

func (m *DecoyList) XXX_Merge(src proto.Message)

func (*DecoyList) XXX_Size

func (m *DecoyList) XXX_Size() int

func (*DecoyList) XXX_Unmarshal

func (m *DecoyList) XXX_Unmarshal(b []byte) error

type ErrorReasonS2C

type ErrorReasonS2C int32

Should accompany all S2C_ERROR messages.

const (
	ErrorReasonS2C_NO_ERROR         ErrorReasonS2C = 0
	ErrorReasonS2C_COVERT_STREAM    ErrorReasonS2C = 1
	ErrorReasonS2C_CLIENT_REPORTED  ErrorReasonS2C = 2
	ErrorReasonS2C_CLIENT_PROTOCOL  ErrorReasonS2C = 3
	ErrorReasonS2C_STATION_INTERNAL ErrorReasonS2C = 4
	ErrorReasonS2C_DECOY_OVERLOAD   ErrorReasonS2C = 5
	ErrorReasonS2C_CLIENT_STREAM    ErrorReasonS2C = 100
	ErrorReasonS2C_CLIENT_TIMEOUT   ErrorReasonS2C = 101
)

func (ErrorReasonS2C) Enum

func (x ErrorReasonS2C) Enum() *ErrorReasonS2C

func (ErrorReasonS2C) EnumDescriptor

func (ErrorReasonS2C) EnumDescriptor() ([]byte, []int)

func (ErrorReasonS2C) String

func (x ErrorReasonS2C) String() string

func (*ErrorReasonS2C) UnmarshalJSON

func (x *ErrorReasonS2C) UnmarshalJSON(data []byte) error

type KeyType

type KeyType int32
const (
	KeyType_AES_GCM_128 KeyType = 90
	KeyType_AES_GCM_256 KeyType = 91
)

func (KeyType) Enum

func (x KeyType) Enum() *KeyType

func (KeyType) EnumDescriptor

func (KeyType) EnumDescriptor() ([]byte, []int)

func (KeyType) String

func (x KeyType) String() string

func (*KeyType) UnmarshalJSON

func (x *KeyType) UnmarshalJSON(data []byte) error

type PhantomSubnets

type PhantomSubnets struct {
	Weight               *uint32  `protobuf:"varint,1,opt,name=weight" json:"weight,omitempty"`
	Subnets              []string `protobuf:"bytes,2,rep,name=subnets" json:"subnets,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PhantomSubnets) Descriptor

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

func (*PhantomSubnets) GetSubnets

func (m *PhantomSubnets) GetSubnets() []string

func (*PhantomSubnets) GetWeight

func (m *PhantomSubnets) GetWeight() uint32

func (*PhantomSubnets) ProtoMessage

func (*PhantomSubnets) ProtoMessage()

func (*PhantomSubnets) Reset

func (m *PhantomSubnets) Reset()

func (*PhantomSubnets) String

func (m *PhantomSubnets) String() string

func (*PhantomSubnets) XXX_DiscardUnknown

func (m *PhantomSubnets) XXX_DiscardUnknown()

func (*PhantomSubnets) XXX_Marshal

func (m *PhantomSubnets) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PhantomSubnets) XXX_Merge

func (m *PhantomSubnets) XXX_Merge(src proto.Message)

func (*PhantomSubnets) XXX_Size

func (m *PhantomSubnets) XXX_Size() int

func (*PhantomSubnets) XXX_Unmarshal

func (m *PhantomSubnets) XXX_Unmarshal(b []byte) error

type PhantomSubnetsList

type PhantomSubnetsList struct {
	WeightedSubnets      []*PhantomSubnets `protobuf:"bytes,1,rep,name=weighted_subnets,json=weightedSubnets" json:"weighted_subnets,omitempty"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*PhantomSubnetsList) Descriptor

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

func (*PhantomSubnetsList) GetWeightedSubnets

func (m *PhantomSubnetsList) GetWeightedSubnets() []*PhantomSubnets

func (*PhantomSubnetsList) ProtoMessage

func (*PhantomSubnetsList) ProtoMessage()

func (*PhantomSubnetsList) Reset

func (m *PhantomSubnetsList) Reset()

func (*PhantomSubnetsList) String

func (m *PhantomSubnetsList) String() string

func (*PhantomSubnetsList) XXX_DiscardUnknown

func (m *PhantomSubnetsList) XXX_DiscardUnknown()

func (*PhantomSubnetsList) XXX_Marshal

func (m *PhantomSubnetsList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PhantomSubnetsList) XXX_Merge

func (m *PhantomSubnetsList) XXX_Merge(src proto.Message)

func (*PhantomSubnetsList) XXX_Size

func (m *PhantomSubnetsList) XXX_Size() int

func (*PhantomSubnetsList) XXX_Unmarshal

func (m *PhantomSubnetsList) XXX_Unmarshal(b []byte) error

type PubKey

type PubKey struct {
	// A public key, as used by the station.
	Key                  []byte   `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"`
	Type                 *KeyType `protobuf:"varint,2,opt,name=type,enum=tapdance.KeyType" json:"type,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PubKey) Descriptor

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

func (*PubKey) GetKey

func (m *PubKey) GetKey() []byte

func (*PubKey) GetType

func (m *PubKey) GetType() KeyType

func (*PubKey) ProtoMessage

func (*PubKey) ProtoMessage()

func (*PubKey) Reset

func (m *PubKey) Reset()

func (*PubKey) String

func (m *PubKey) String() string

func (*PubKey) XXX_DiscardUnknown

func (m *PubKey) XXX_DiscardUnknown()

func (*PubKey) XXX_Marshal

func (m *PubKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PubKey) XXX_Merge

func (m *PubKey) XXX_Merge(src proto.Message)

func (*PubKey) XXX_Size

func (m *PubKey) XXX_Size() int

func (*PubKey) XXX_Unmarshal

func (m *PubKey) XXX_Unmarshal(b []byte) error

type RegistrationFlags

type RegistrationFlags struct {
	UploadOnly           *bool    `protobuf:"varint,1,opt,name=upload_only,json=uploadOnly" json:"upload_only,omitempty"`
	DarkDecoy            *bool    `protobuf:"varint,2,opt,name=dark_decoy,json=darkDecoy" json:"dark_decoy,omitempty"`
	ProxyHeader          *bool    `protobuf:"varint,3,opt,name=proxy_header,json=proxyHeader" json:"proxy_header,omitempty"`
	Use_TIL              *bool    `protobuf:"varint,4,opt,name=use_TIL,json=useTIL" json:"use_TIL,omitempty"`
	Prescanned           *bool    `protobuf:"varint,5,opt,name=prescanned" json:"prescanned,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RegistrationFlags) Descriptor

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

func (*RegistrationFlags) GetDarkDecoy

func (m *RegistrationFlags) GetDarkDecoy() bool

func (*RegistrationFlags) GetPrescanned

func (m *RegistrationFlags) GetPrescanned() bool

func (*RegistrationFlags) GetProxyHeader

func (m *RegistrationFlags) GetProxyHeader() bool

func (*RegistrationFlags) GetUploadOnly

func (m *RegistrationFlags) GetUploadOnly() bool

func (*RegistrationFlags) GetUse_TIL

func (m *RegistrationFlags) GetUse_TIL() bool

func (*RegistrationFlags) ProtoMessage

func (*RegistrationFlags) ProtoMessage()

func (*RegistrationFlags) Reset

func (m *RegistrationFlags) Reset()

func (*RegistrationFlags) String

func (m *RegistrationFlags) String() string

func (*RegistrationFlags) XXX_DiscardUnknown

func (m *RegistrationFlags) XXX_DiscardUnknown()

func (*RegistrationFlags) XXX_Marshal

func (m *RegistrationFlags) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RegistrationFlags) XXX_Merge

func (m *RegistrationFlags) XXX_Merge(src proto.Message)

func (*RegistrationFlags) XXX_Size

func (m *RegistrationFlags) XXX_Size() int

func (*RegistrationFlags) XXX_Unmarshal

func (m *RegistrationFlags) XXX_Unmarshal(b []byte) error

type RegistrationSource

type RegistrationSource int32
const (
	RegistrationSource_Unspecified     RegistrationSource = 0
	RegistrationSource_Detector        RegistrationSource = 1
	RegistrationSource_API             RegistrationSource = 2
	RegistrationSource_DetectorPrescan RegistrationSource = 3
)

func (RegistrationSource) Enum

func (RegistrationSource) EnumDescriptor

func (RegistrationSource) EnumDescriptor() ([]byte, []int)

func (RegistrationSource) String

func (x RegistrationSource) String() string

func (*RegistrationSource) UnmarshalJSON

func (x *RegistrationSource) UnmarshalJSON(data []byte) error

type S2C_Transition

type S2C_Transition int32

State transitions of the server

const (
	S2C_Transition_S2C_NO_CHANGE           S2C_Transition = 0
	S2C_Transition_S2C_SESSION_INIT        S2C_Transition = 1
	S2C_Transition_S2C_SESSION_COVERT_INIT S2C_Transition = 11
	S2C_Transition_S2C_CONFIRM_RECONNECT   S2C_Transition = 2
	S2C_Transition_S2C_SESSION_CLOSE       S2C_Transition = 3
	// TODO should probably also allow EXPECT_RECONNECT here, for DittoTap
	S2C_Transition_S2C_ERROR S2C_Transition = 255
)

func (S2C_Transition) Enum

func (x S2C_Transition) Enum() *S2C_Transition

func (S2C_Transition) EnumDescriptor

func (S2C_Transition) EnumDescriptor() ([]byte, []int)

func (S2C_Transition) String

func (x S2C_Transition) String() string

func (*S2C_Transition) UnmarshalJSON

func (x *S2C_Transition) UnmarshalJSON(data []byte) error

type SessionStats

type SessionStats struct {
	FailedDecoysAmount *uint32 `protobuf:"varint,20,opt,name=failed_decoys_amount,json=failedDecoysAmount" json:"failed_decoys_amount,omitempty"`
	// Applicable to whole session:
	TotalTimeToConnect *uint32 `protobuf:"varint,31,opt,name=total_time_to_connect,json=totalTimeToConnect" json:"total_time_to_connect,omitempty"`
	// Last (i.e. successful) decoy:
	RttToStation         *uint32  `protobuf:"varint,33,opt,name=rtt_to_station,json=rttToStation" json:"rtt_to_station,omitempty"`
	TlsToDecoy           *uint32  `protobuf:"varint,38,opt,name=tls_to_decoy,json=tlsToDecoy" json:"tls_to_decoy,omitempty"`
	TcpToDecoy           *uint32  `protobuf:"varint,39,opt,name=tcp_to_decoy,json=tcpToDecoy" json:"tcp_to_decoy,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SessionStats) Descriptor

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

func (*SessionStats) GetFailedDecoysAmount

func (m *SessionStats) GetFailedDecoysAmount() uint32

func (*SessionStats) GetRttToStation

func (m *SessionStats) GetRttToStation() uint32

func (*SessionStats) GetTcpToDecoy

func (m *SessionStats) GetTcpToDecoy() uint32

func (*SessionStats) GetTlsToDecoy

func (m *SessionStats) GetTlsToDecoy() uint32

func (*SessionStats) GetTotalTimeToConnect

func (m *SessionStats) GetTotalTimeToConnect() uint32

func (*SessionStats) ProtoMessage

func (*SessionStats) ProtoMessage()

func (*SessionStats) Reset

func (m *SessionStats) Reset()

func (*SessionStats) String

func (m *SessionStats) String() string

func (*SessionStats) XXX_DiscardUnknown

func (m *SessionStats) XXX_DiscardUnknown()

func (*SessionStats) XXX_Marshal

func (m *SessionStats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SessionStats) XXX_Merge

func (m *SessionStats) XXX_Merge(src proto.Message)

func (*SessionStats) XXX_Size

func (m *SessionStats) XXX_Size() int

func (*SessionStats) XXX_Unmarshal

func (m *SessionStats) XXX_Unmarshal(b []byte) error

type StationToClient

type StationToClient struct {
	// Should accompany (at least) SESSION_INIT and CONFIRM_RECONNECT.
	ProtocolVersion *uint32 `protobuf:"varint,1,opt,name=protocol_version,json=protocolVersion" json:"protocol_version,omitempty"`
	// There might be a state transition. May be absent; absence should be
	// treated identically to NO_CHANGE.
	StateTransition *S2C_Transition `` /* 129-byte string literal not displayed */
	// The station can send client config info piggybacked
	// on any message, as it sees fit
	ConfigInfo *ClientConf `protobuf:"bytes,3,opt,name=config_info,json=configInfo" json:"config_info,omitempty"`
	// If state_transition == S2C_ERROR, this field is the explanation.
	ErrReason *ErrorReasonS2C `protobuf:"varint,4,opt,name=err_reason,json=errReason,enum=tapdance.ErrorReasonS2C" json:"err_reason,omitempty"`
	// Signals client to stop connecting for following amount of seconds
	TmpBackoff *uint32 `protobuf:"varint,5,opt,name=tmp_backoff,json=tmpBackoff" json:"tmp_backoff,omitempty"`
	// Sent in SESSION_INIT, identifies the station that picked up
	StationId *string `protobuf:"bytes,6,opt,name=station_id,json=stationId" json:"station_id,omitempty"`
	// Random-sized junk to defeat packet size fingerprinting.
	Padding              []byte   `protobuf:"bytes,100,opt,name=padding" json:"padding,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*StationToClient) Descriptor

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

func (*StationToClient) GetConfigInfo

func (m *StationToClient) GetConfigInfo() *ClientConf

func (*StationToClient) GetErrReason

func (m *StationToClient) GetErrReason() ErrorReasonS2C

func (*StationToClient) GetPadding

func (m *StationToClient) GetPadding() []byte

func (*StationToClient) GetProtocolVersion

func (m *StationToClient) GetProtocolVersion() uint32

func (*StationToClient) GetStateTransition

func (m *StationToClient) GetStateTransition() S2C_Transition

func (*StationToClient) GetStationId

func (m *StationToClient) GetStationId() string

func (*StationToClient) GetTmpBackoff

func (m *StationToClient) GetTmpBackoff() uint32

func (*StationToClient) ProtoMessage

func (*StationToClient) ProtoMessage()

func (*StationToClient) Reset

func (m *StationToClient) Reset()

func (*StationToClient) String

func (m *StationToClient) String() string

func (*StationToClient) XXX_DiscardUnknown

func (m *StationToClient) XXX_DiscardUnknown()

func (*StationToClient) XXX_Marshal

func (m *StationToClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StationToClient) XXX_Merge

func (m *StationToClient) XXX_Merge(src proto.Message)

func (*StationToClient) XXX_Size

func (m *StationToClient) XXX_Size() int

func (*StationToClient) XXX_Unmarshal

func (m *StationToClient) XXX_Unmarshal(b []byte) error

type StationToDetector

type StationToDetector struct {
	PhantomIp            *string  `protobuf:"bytes,1,opt,name=phantom_ip,json=phantomIp" json:"phantom_ip,omitempty"`
	ClientIp             *string  `protobuf:"bytes,2,opt,name=client_ip,json=clientIp" json:"client_ip,omitempty"`
	TimeoutNs            *uint64  `protobuf:"varint,3,opt,name=timeout_ns,json=timeoutNs" json:"timeout_ns,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*StationToDetector) Descriptor

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

func (*StationToDetector) GetClientIp

func (m *StationToDetector) GetClientIp() string

func (*StationToDetector) GetPhantomIp

func (m *StationToDetector) GetPhantomIp() string

func (*StationToDetector) GetTimeoutNs

func (m *StationToDetector) GetTimeoutNs() uint64

func (*StationToDetector) ProtoMessage

func (*StationToDetector) ProtoMessage()

func (*StationToDetector) Reset

func (m *StationToDetector) Reset()

func (*StationToDetector) String

func (m *StationToDetector) String() string

func (*StationToDetector) XXX_DiscardUnknown

func (m *StationToDetector) XXX_DiscardUnknown()

func (*StationToDetector) XXX_Marshal

func (m *StationToDetector) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StationToDetector) XXX_Merge

func (m *StationToDetector) XXX_Merge(src proto.Message)

func (*StationToDetector) XXX_Size

func (m *StationToDetector) XXX_Size() int

func (*StationToDetector) XXX_Unmarshal

func (m *StationToDetector) XXX_Unmarshal(b []byte) error

type TLSDecoySpec

type TLSDecoySpec struct {
	// The hostname/SNI to use for this host
	//
	// The hostname is the only required field, although other
	// fields are expected to be present in most cases.
	Hostname *string `protobuf:"bytes,1,opt,name=hostname" json:"hostname,omitempty"`
	// The 32-bit ipv4 address, in network byte order
	//
	// If the IPv4 address is absent, then it may be resolved via
	// DNS by the client, or the client may discard this decoy spec
	// if local DNS is untrusted, or the service may be multihomed.
	Ipv4Addr *uint32 `protobuf:"fixed32,2,opt,name=ipv4addr" json:"ipv4addr,omitempty"`
	// The 128-bit ipv6 address, in network byte order
	Ipv6Addr []byte `protobuf:"bytes,6,opt,name=ipv6addr" json:"ipv6addr,omitempty"`
	// The Tapdance station public key to use when contacting this
	// decoy
	//
	// If omitted, the default station public key (if any) is used.
	Pubkey *PubKey `protobuf:"bytes,3,opt,name=pubkey" json:"pubkey,omitempty"`
	// The maximum duration, in milliseconds, to maintain an open
	// connection to this decoy (because the decoy may close the
	// connection itself after this length of time)
	//
	// If omitted, a default of 30,000 milliseconds is assumed.
	Timeout *uint32 `protobuf:"varint,4,opt,name=timeout" json:"timeout,omitempty"`
	// The maximum TCP window size to attempt to use for this decoy.
	//
	// If omitted, a default of 15360 is assumed.
	//
	// TODO: the default is based on the current heuristic of only
	// using decoys that permit windows of 15KB or larger.  If this
	// heuristic changes, then this default doesn't make sense.
	Tcpwin               *uint32  `protobuf:"varint,5,opt,name=tcpwin" json:"tcpwin,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func InitTLSDecoySpec

func InitTLSDecoySpec(ip string, sni string) *TLSDecoySpec

InitTLSDecoySpec creates TLSDecoySpec from ip address and server name. Other feilds, such as Pubkey, Timeout and Tcpwin are left unset.

func (*TLSDecoySpec) Descriptor

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

func (*TLSDecoySpec) GetHostname

func (m *TLSDecoySpec) GetHostname() string

func (*TLSDecoySpec) GetIpAddrStr

func (ds *TLSDecoySpec) GetIpAddrStr() string

GetIpAddrStr returns IP address of TLSDecoySpec as a string.

func (*TLSDecoySpec) GetIpv4Addr

func (m *TLSDecoySpec) GetIpv4Addr() uint32

func (*TLSDecoySpec) GetIpv6Addr

func (m *TLSDecoySpec) GetIpv6Addr() []byte

func (*TLSDecoySpec) GetPubkey

func (m *TLSDecoySpec) GetPubkey() *PubKey

func (*TLSDecoySpec) GetTcpwin

func (m *TLSDecoySpec) GetTcpwin() uint32

func (*TLSDecoySpec) GetTimeout

func (m *TLSDecoySpec) GetTimeout() uint32

func (*TLSDecoySpec) ProtoMessage

func (*TLSDecoySpec) ProtoMessage()

func (*TLSDecoySpec) Reset

func (m *TLSDecoySpec) Reset()

func (*TLSDecoySpec) String

func (m *TLSDecoySpec) String() string

func (*TLSDecoySpec) XXX_DiscardUnknown

func (m *TLSDecoySpec) XXX_DiscardUnknown()

func (*TLSDecoySpec) XXX_Marshal

func (m *TLSDecoySpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TLSDecoySpec) XXX_Merge

func (m *TLSDecoySpec) XXX_Merge(src proto.Message)

func (*TLSDecoySpec) XXX_Size

func (m *TLSDecoySpec) XXX_Size() int

func (*TLSDecoySpec) XXX_Unmarshal

func (m *TLSDecoySpec) XXX_Unmarshal(b []byte) error

type TransportType

type TransportType int32
const (
	TransportType_Null  TransportType = 0
	TransportType_Min   TransportType = 1
	TransportType_Obfs4 TransportType = 2
)

func (TransportType) Enum

func (x TransportType) Enum() *TransportType

func (TransportType) EnumDescriptor

func (TransportType) EnumDescriptor() ([]byte, []int)

func (TransportType) String

func (x TransportType) String() string

func (*TransportType) UnmarshalJSON

func (x *TransportType) UnmarshalJSON(data []byte) error

Jump to

Keyboard shortcuts

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