ehco

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

README

ehco

ehco is a echo proxy and a typo

主要功能

  • tcp/udp relay

TODO

  • tls tunnel
  • benchmark

Documentation

Index

Constants

View Source
const (
	TCP_DEADLINE = 60 * time.Second
	UDP_DEADLINE = 60 * time.Second
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Relay added in v0.0.3

type Relay struct {
	LocalTCPAddr  *net.TCPAddr
	LocalUDPAddr  *net.UDPAddr
	RemoteTCPAddr *net.TCPAddr
	RemoteUDPAddr *net.UDPAddr

	TCPListener *net.TCPListener
	UDPConn     *net.UDPConn
}

func NewRelay added in v0.0.3

func NewRelay(localAddr, remoteAddr string) (*Relay, error)

func (*Relay) ListenAndServe added in v0.0.3

func (relay *Relay) ListenAndServe() error

func (*Relay) RunLocalTCPServer added in v0.0.3

func (relay *Relay) RunLocalTCPServer() error

func (*Relay) RunLocalUDPServer added in v0.0.3

func (relay *Relay) RunLocalUDPServer() error

func (*Relay) Shutdown added in v0.0.3

func (relay *Relay) Shutdown() error

Directories

Path Synopsis
test

Jump to

Keyboard shortcuts

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