Documentation ¶
Index ¶
- Constants
- func GetHttpRequestInfo(c frpNet.Conn) (_ frpNet.Conn, _ map[string]string, err error)
- func GetHttpsHostname(c frpNet.Conn) (sc frpNet.Conn, _ map[string]string, err error)
- func HttpAuthFunc(c frpNet.Conn, userName, passWord, authorization string) (bAccess bool, err error)
- func ModifyHttpRequest(c frpNet.Conn, rewriteHost string) (_ frpNet.Conn, err error)
- type ByLocation
- type HttpMuxer
- type HttpsMuxer
- type Listener
- type VhostMuxer
- type VhostRouteConfig
- type VhostRouter
- type VhostRouters
Constants ¶
View Source
const (
NotFound = `` /* 481-byte string literal not displayed */
)
Variables ¶
This section is empty.
Functions ¶
func GetHttpRequestInfo ¶
func GetHttpsHostname ¶
func HttpAuthFunc ¶
Types ¶
type ByLocation ¶
type ByLocation []*VhostRouter
sort by location
func (ByLocation) Len ¶
func (a ByLocation) Len() int
func (ByLocation) Less ¶
func (a ByLocation) Less(i, j int) bool
func (ByLocation) Swap ¶
func (a ByLocation) Swap(i, j int)
type HttpMuxer ¶
type HttpMuxer struct {
*VhostMuxer
}
type VhostMuxer ¶
type VhostMuxer struct {
// contains filtered or unexported fields
}
func NewVhostMuxer ¶
func (*VhostMuxer) Listen ¶
func (v *VhostMuxer) Listen(cfg *VhostRouteConfig) (l *Listener, err error)
listen for a new domain name, if rewriteHost is not empty and rewriteFunc is not nil then rewrite the host header to rewriteHost
type VhostRouteConfig ¶
type VhostRouter ¶
type VhostRouter struct {
// contains filtered or unexported fields
}
type VhostRouters ¶
type VhostRouters struct { RouterByDomain map[string][]*VhostRouter // contains filtered or unexported fields }
func NewVhostRouters ¶
func NewVhostRouters() *VhostRouters
func (*VhostRouters) Add ¶
func (r *VhostRouters) Add(domain, location string, l *Listener)
func (*VhostRouters) Del ¶
func (r *VhostRouters) Del(domain, location string)
func (*VhostRouters) Exist ¶
func (r *VhostRouters) Exist(host, path string) (vr *VhostRouter, exist bool)
func (*VhostRouters) Get ¶
func (r *VhostRouters) Get(host, path string) (vr *VhostRouter, exist bool)
Click to show internal directories.
Click to hide internal directories.