core

package
v0.5.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenP256 added in v0.2.2

func GenP256(hosts []string) (key, cert []byte, err error)

Modified https://github.com/Shyp/generate-tls-cert

func GenRSA2048 added in v0.3.0

func GenRSA2048(hosts []string) (key, cert []byte, err error)

Types

type Client added in v0.2.1

type Client struct {
	LogLevel     loggo.Level
	ListenAddr   *net.TCPAddr
	URL          *url.URL
	Origin       string
	ServerName   string
	InsecureCert bool
	WSConfig     websocket.Config
}

func (*Client) Listen added in v0.2.1

func (client *Client) Listen() (err error)

type Server

type Server struct {
	LogLevel   loggo.Level
	Pattern    string
	ListenAddr string
	TLS        bool
	CertPath   string
	KeyPath    string
	Proxy      string

	CreatedAt time.Time

	Opened     uint64
	Closed     uint64
	Uploaded   uint64
	Downloaded uint64
}

func (*Server) HandleWebSocket added in v0.4.0

func (server *Server) HandleWebSocket(ws *websocket.Conn)

func (*Server) Listen

func (server *Server) Listen() (err error)

func (*Server) Status added in v0.4.0

func (server *Server) Status(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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