proxy

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: May 30, 2017 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dump

func Dump(cb bpf.DumpCallback) error

func Dump6 added in v0.9.0

func Dump6(cb bpf.DumpCallback) error

func GC

func GC() int

func GC6 added in v0.9.0

func GC6() int

Types

type LogRecord

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

type Proxy

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

func NewProxy

func NewProxy(minPort uint16, maxPort uint16) *Proxy

func (*Proxy) CreateOrUpdateRedirect

func (p *Proxy) CreateOrUpdateRedirect(l4 *policy.L4Filter, id string, source ProxySource) (*Redirect, error)

func (*Proxy) RemoveRedirect

func (p *Proxy) RemoveRedirect(id string) error

type Proxy4Key

type Proxy4Key struct {
	SAddr   types.IPv4
	DPort   uint16
	SPort   uint16
	Nexthdr uint8
}

func (*Proxy4Key) Convert

func (k *Proxy4Key) Convert() *Proxy4Key

func (*Proxy4Key) GetKeyPtr

func (k *Proxy4Key) GetKeyPtr() unsafe.Pointer

func (*Proxy4Key) HostPort

func (k *Proxy4Key) HostPort() string

func (Proxy4Key) NewValue

func (k Proxy4Key) NewValue() bpf.MapValue

func (*Proxy4Key) String

func (k *Proxy4Key) String() string

type Proxy4Value

type Proxy4Value struct {
	OrigDAddr types.IPv4
	OrigDPort uint16
	Lifetime  uint16
}

func LookupEgress4

func LookupEgress4(key *Proxy4Key) (*Proxy4Value, error)

func (*Proxy4Value) Convert

func (k *Proxy4Value) Convert() *Proxy4Value

func (*Proxy4Value) GetValuePtr

func (v *Proxy4Value) GetValuePtr() unsafe.Pointer

func (*Proxy4Value) HostPort

func (p *Proxy4Value) HostPort() string

func (*Proxy4Value) String

func (v *Proxy4Value) String() string

type Proxy6Key added in v0.9.0

type Proxy6Key struct {
	SAddr   types.IPv6
	DPort   uint16
	SPort   uint16
	Nexthdr uint8
}

func (*Proxy6Key) Convert added in v0.9.0

func (k *Proxy6Key) Convert() *Proxy6Key

func (*Proxy6Key) GetKeyPtr added in v0.9.0

func (k *Proxy6Key) GetKeyPtr() unsafe.Pointer

func (*Proxy6Key) HostPort added in v0.9.0

func (k *Proxy6Key) HostPort() string

func (Proxy6Key) NewValue added in v0.9.0

func (k Proxy6Key) NewValue() bpf.MapValue

func (*Proxy6Key) String added in v0.9.0

func (k *Proxy6Key) String() string

type Proxy6Value added in v0.9.0

type Proxy6Value struct {
	OrigDAddr types.IPv6
	OrigDPort uint16
	Lifetime  uint16
}

func LookupEgress6 added in v0.9.0

func LookupEgress6(key *Proxy6Key) (*Proxy6Value, error)

func (*Proxy6Value) Convert added in v0.9.0

func (k *Proxy6Value) Convert() *Proxy6Value

func (*Proxy6Value) GetValuePtr added in v0.9.0

func (v *Proxy6Value) GetValuePtr() unsafe.Pointer

func (*Proxy6Value) HostPort added in v0.9.0

func (p *Proxy6Value) HostPort() string

func (*Proxy6Value) String added in v0.9.0

func (v *Proxy6Value) String() string

type ProxySource

type ProxySource interface {
}

type Redirect

type Redirect struct {
	FromPort uint16
	ToPort   uint16
	Rules    []policy.AuxRule
	// contains filtered or unexported fields
}

func (*Redirect) Log

func (r *Redirect) Log(l *LogRecord, code int, reason string)

Jump to

Keyboard shortcuts

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