obfs2

package module
v3.0.12 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2020 License: BSD-2-Clause, BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Overview

Package obfs2 provides an implementation of the Tor Project's obfs2 obfuscation protocol. This protocol is considered trivially broken by most sophisticated adversaries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config added in v3.0.10

type Config struct {
	Address string `json:"address"`
}

type OptimizerTransport

type OptimizerTransport struct {
	Address string
	Dialer  proxy.Dialer
}

OptimizerTransport contains params needed for Optimizer

func New

func New(address string, dialer proxy.Dialer) *OptimizerTransport

New initializes obfs2 for Optimizer

func (OptimizerTransport) Dial

func (transport OptimizerTransport) Dial() (net.Conn, error)

Dial connects to a specified address. this dial function is made to be Optimizer compatible

func (OptimizerTransport) Listen added in v3.0.3

func (transport OptimizerTransport) Listen() (net.Listener, error)

type Transport

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

Transport is the obfs2 implementation of the base.Transport interface.

func NewObfs2Transport

func NewObfs2Transport() *Transport

NewObfs2Transport is the initializer for obfs2 without a dialer

func NewObfs2TransportWithDialer

func NewObfs2TransportWithDialer(dialer proxy.Dialer) *Transport

NewObfs2Transport is the initializer for obfs2 with a dialer

func (*Transport) Dial

func (transport *Transport) Dial(address string) (net.Conn, error)

Dial creates outgoing transport connection

func (*Transport) Listen

func (transport *Transport) Listen(address string) (net.Listener, error)

Listen creates listener for incoming transport connection

Jump to

Keyboard shortcuts

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