Documentation ¶
Index ¶
- Variables
- type BridgeInfo
- type Client
- func (cl *Client) AddBridge(secret string, cookie []byte, host string, allocGroup string) (err error)
- func (cl *Client) GetBridges(ubmsg, ubsig []byte) (bridges []BridgeInfo, err error)
- func (cl *Client) GetClientInfo() (ui ClientInfo, err error)
- func (cl *Client) GetEphBridges(ubmsg []byte, ubsig []byte, exit string) (bridges []BridgeInfo, err error)
- func (cl *Client) GetTicket(username, password string) (ubmsg, ubsig []byte, details TicketResp, err error)
- func (cl *Client) GetTicketKey(tier string) (tkey *rsa.PublicKey, err error)
- func (cl *Client) GetTier(username, password string) (tier string, err error)
- func (cl *Client) GetWarpfronts() (host2front map[string]string, err error)
- func (cl *Client) RedeemTicket(tier string, ubmsg, ubsig []byte) (err error)
- type ClientInfo
- type Multiclient
- type PaymentTx
- type TicketResp
Constants ¶
This section is empty.
Variables ¶
var ErrBadAuth = errors.New("access denied")
ErrBadAuth indicates incorrect credentials
Functions ¶
This section is empty.
Types ¶
type BridgeInfo ¶
BridgeInfo describes a bridge
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client represents a binder client.
func NewClient ¶
NewClient creates a new domain-fronting binder client with the given frontDomain and realDomain. frontDomain should start with `https://`.
func (*Client) AddBridge ¶
func (cl *Client) AddBridge(secret string, cookie []byte, host string, allocGroup string) (err error)
AddBridge uploads some bridge info.
func (*Client) GetBridges ¶
func (cl *Client) GetBridges(ubmsg, ubsig []byte) (bridges []BridgeInfo, err error)
GetBridges obtains a set of bridges.
func (*Client) GetClientInfo ¶
func (cl *Client) GetClientInfo() (ui ClientInfo, err error)
GetClientInfo checks user info
func (*Client) GetEphBridges ¶ added in v0.17.0
func (cl *Client) GetEphBridges(ubmsg []byte, ubsig []byte, exit string) (bridges []BridgeInfo, err error)
GetEphBridges obtains a set of ephemeral e2e bridges.
func (*Client) GetTicket ¶
func (cl *Client) GetTicket(username, password string) (ubmsg, ubsig []byte, details TicketResp, err error)
GetTicket obtains an authentication ticket.
func (*Client) GetTicketKey ¶
GetTicketKey obtains the remote ticketing key. TODO caching, gossip?
func (*Client) GetWarpfronts ¶ added in v0.20.0
GetWarpfronts gets warpfront bridges
type ClientInfo ¶
ClientInfo describes user IP and country.
type Multiclient ¶ added in v0.22.5
type Multiclient struct {
// contains filtered or unexported fields
}
Multiclient wraps around mutliple clients, R/R-ing between them until something works.
func NewMulticlient ¶ added in v0.22.5
func NewMulticlient(clients []*Client) *Multiclient
NewMulticlient creates a Multiclient from multiple clients