rsck

package module
v0.0.0-...-30b4fa7 Latest Latest
Warning

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

Go to latest
Published: May 19, 2018 License: GPL-3.0 Imports: 27 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CMD_CTRL_C = []byte{255, 244, 255, 253, 6}
View Source
var ChannelByteClose = []byte{40}
View Source
var ChannelByteDail = []byte{20}
View Source
var ChannelByteData = []byte{30}
View Source
var ChannelByteHeartbeat = []byte{0}
View Source
var ChannelByteLogin = []byte{10}
View Source
var ShowLog int

Functions

This section is empty.

Types

type Channel

type Channel struct {
	Name   string
	Online bool
	FS     []*Forward
	Remote string
}

type ChannelRunner

type ChannelRunner struct {
	R *netw.NConRunner

	Name  string
	Token string

	Dailers []Dailer
	// contains filtered or unexported fields
}

func NewChannelRunner

func NewChannelRunner(addr, name, token string) (runner *ChannelRunner)

func (*ChannelRunner) AddDailer

func (c *ChannelRunner) AddDailer(dailer Dailer) error

func (*ChannelRunner) OnClose

func (c *ChannelRunner) OnClose(con netw.Con)

func (*ChannelRunner) OnConn

func (c *ChannelRunner) OnConn(con netw.Con) bool

func (*ChannelRunner) OnDailF

func (c *ChannelRunner) OnDailF(con netw.Cmd) int

func (*ChannelRunner) OnDataF

func (c *ChannelRunner) OnDataF(con netw.Cmd) int

func (*ChannelRunner) OnRawCloseF

func (c *ChannelRunner) OnRawCloseF(con netw.Cmd) int

func (*ChannelRunner) Start

func (c *ChannelRunner) Start()

func (*ChannelRunner) Stop

func (c *ChannelRunner) Stop()

func (*ChannelRunner) String

func (c *ChannelRunner) String() string

type ChannelServer

type ChannelServer struct {
	L *netw.Listener

	ACL map[string]string

	HbDelay int64

	WebSuffix string
	WebAuth   string
	// contains filtered or unexported fields
}

func NewChannelServer

func NewChannelServer(port string, n string) (server *ChannelServer)

func (*ChannelServer) AddForward

func (c *ChannelServer) AddForward(forward *Forward) (err error)

func (*ChannelServer) AddUriForward

func (c *ChannelServer) AddUriForward(uri string) (err error)

func (*ChannelServer) AllForwards

func (c *ChannelServer) AllForwards() (ns []string, fs map[string]*Channel)

func (*ChannelServer) Close

func (c *ChannelServer) Close()

func (*ChannelServer) Dail

func (c *ChannelServer) Dail(raw net.Conn, name string, remote *url.URL) (err error)

func (*ChannelServer) OnClose

func (c *ChannelServer) OnClose(con netw.Con)

func (*ChannelServer) OnConn

func (c *ChannelServer) OnConn(con netw.Con) bool

func (*ChannelServer) OnDailBackF

func (c *ChannelServer) OnDailBackF(con netw.Cmd) int

func (*ChannelServer) OnDataF

func (c *ChannelServer) OnDataF(con netw.Cmd) int

func (*ChannelServer) OnHeartbeatF

func (c *ChannelServer) OnHeartbeatF(con netw.Cmd) int

func (*ChannelServer) OnLoginF

func (c *ChannelServer) OnLoginF(con netw.Cmd) int

func (*ChannelServer) OnRawCloseF

func (c *ChannelServer) OnRawCloseF(con netw.Cmd) int

func (*ChannelServer) ProcWebForward

func (c *ChannelServer) ProcWebForward(hs *routing.HTTPSession) routing.HResult

func (*ChannelServer) RemoveForward

func (c *ChannelServer) RemoveForward(local string) (err error)

func (*ChannelServer) Start

func (c *ChannelServer) Start() error

func (*ChannelServer) String

func (c *ChannelServer) String() string

type CmdDailer

type CmdDailer struct {
	Replace  []byte
	CloseTag []byte
}

func NewCmdDailer

func NewCmdDailer() *CmdDailer

func (*CmdDailer) Bootstrap

func (c *CmdDailer) Bootstrap() error

func (*CmdDailer) Dail

func (c *CmdDailer) Dail(cid uint32, uri string) (raw io.ReadWriteCloser, err error)

func (*CmdDailer) Matched

func (c *CmdDailer) Matched(uri string) bool

func (*CmdDailer) String

func (t *CmdDailer) String() string

type CmdStdinWriter

type CmdStdinWriter struct {
	io.Writer
	Replace  []byte
	CloseTag []byte
}

func (*CmdStdinWriter) Write

func (c *CmdStdinWriter) Write(p []byte) (n int, err error)

type CombinedReadWriterCloser

type CombinedReadWriterCloser struct {
	io.Reader
	io.Writer
	Closer func() error
	// contains filtered or unexported fields
}

func (*CombinedReadWriterCloser) Close

func (c *CombinedReadWriterCloser) Close() (err error)

type Dailer

type Dailer interface {
	Bootstrap() error
	Matched(uri string) bool
	Dail(cid uint32, uri string) (r io.ReadWriteCloser, err error)
}

type DuplexPiped

type DuplexPiped struct {
	UpReader   *os.File
	UpWriter   *os.File
	DownReader *os.File
	DownWriter *os.File
	// contains filtered or unexported fields
}

func (*DuplexPiped) Close

func (d *DuplexPiped) Close() error

type EchoServer

type EchoServer struct {
	L net.Listener
}

func NewEchoServer

func NewEchoServer(network, address string) (echo *EchoServer, err error)

func (*EchoServer) Start

func (e *EchoServer) Start()

type Forward

type Forward struct {
	Name   string
	Local  *url.URL
	Remote *url.URL
}

func NewForward

func NewForward(uri string) (forward *Forward, err error)

func (*Forward) LocalValidF

func (f *Forward) LocalValidF(format string, args ...interface{}) error

func (*Forward) RemoteValidF

func (f *Forward) RemoteValidF(format string, args ...interface{}) error

func (*Forward) String

func (f *Forward) String() string

type ForwardListener

type ForwardListener struct {
	*Forward
	L net.Listener
}

func (*ForwardListener) String

func (f *ForwardListener) String() string

type ForwardSorter

type ForwardSorter []*Forward

func (ForwardSorter) Len

func (f ForwardSorter) Len() int

func (ForwardSorter) Less

func (f ForwardSorter) Less(i, j int) bool

func (ForwardSorter) Swap

func (f ForwardSorter) Swap(i, j int)

type PipedConn

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

func CreatePipedConn

func CreatePipedConn() (a, b *PipedConn, err error)

func (*PipedConn) Close

func (p *PipedConn) Close() error

func (*PipedConn) LocalAddr

func (p *PipedConn) LocalAddr() net.Addr

func (*PipedConn) Network

func (p *PipedConn) Network() string

func (*PipedConn) Read

func (p *PipedConn) Read(b []byte) (n int, err error)

func (*PipedConn) RemoteAddr

func (p *PipedConn) RemoteAddr() net.Addr

func (*PipedConn) SetDeadline

func (p *PipedConn) SetDeadline(t time.Time) error

func (*PipedConn) SetReadDeadline

func (p *PipedConn) SetReadDeadline(t time.Time) error

func (*PipedConn) SetWriteDeadline

func (p *PipedConn) SetWriteDeadline(t time.Time) error

func (*PipedConn) String

func (p *PipedConn) String() string

func (*PipedConn) Write

func (p *PipedConn) Write(b []byte) (n int, err error)

type TCPDailer

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

func NewTCPDailer

func NewTCPDailer() *TCPDailer

func (*TCPDailer) Bootstrap

func (t *TCPDailer) Bootstrap() error

func (*TCPDailer) Dail

func (t *TCPDailer) Dail(cid uint32, uri string) (raw io.ReadWriteCloser, err error)

func (*TCPDailer) Matched

func (t *TCPDailer) Matched(uri string) bool

func (*TCPDailer) String

func (t *TCPDailer) String() string

type WebDailer

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

func NewWebDailer

func NewWebDailer() (dailer *WebDailer)

func (*WebDailer) Accept

func (web *WebDailer) Accept() (conn net.Conn, err error)

for net.Listener

func (*WebDailer) Addr

func (web *WebDailer) Addr() net.Addr

func (*WebDailer) Bootstrap

func (web *WebDailer) Bootstrap() error

func (*WebDailer) Close

func (web *WebDailer) Close() error

func (*WebDailer) Dail

func (web *WebDailer) Dail(cid uint32, uri string) (raw io.ReadWriteCloser, err error)

func (*WebDailer) Matched

func (web *WebDailer) Matched(uri string) bool

func (*WebDailer) Network

func (web *WebDailer) Network() string

func (*WebDailer) ServeHTTP

func (web *WebDailer) ServeHTTP(resp http.ResponseWriter, req *http.Request)

for http.Handler

func (*WebDailer) Shutdown

func (web *WebDailer) Shutdown() error

func (*WebDailer) String

func (web *WebDailer) String() string

type WebDailerConn

type WebDailerConn struct {
	*PipedConn
	CID uint32
	URI string
	DIR string
}

func PipeWebDailerConn

func PipeWebDailerConn(cid uint32, uri string) (conn *WebDailerConn, raw io.ReadWriteCloser, err error)

func (*WebDailerConn) LocalAddr

func (w *WebDailerConn) LocalAddr() net.Addr

func (*WebDailerConn) Network

func (w *WebDailerConn) Network() string

func (*WebDailerConn) RemoteAddr

func (w *WebDailerConn) RemoteAddr() net.Addr

func (*WebDailerConn) String

func (w *WebDailerConn) String() string

type WebdavHandler

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

func NewWebdavHandler

func NewWebdavHandler(dir string) *WebdavHandler

func (*WebdavHandler) ServeHTTP

func (w *WebdavHandler) ServeHTTP(resp http.ResponseWriter, req *http.Request)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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