Documentation ¶
Index ¶
- Variables
- func AuthFunc(am *AuthManager, f1 func(w http.ResponseWriter, r *http.Request)) func(w http.ResponseWriter, r *http.Request)
- func InitAuthHandler(am *AuthManager, h http.Handler) http.Handler
- func ListenAndServeLetsEncrypt(addr string, certFile string, keyFile string, handler http.Handler) error
- func ListenAndServeLetsEncryptServer(addr string, certFile string, keyFile string, srv *http.Server) error
- func ListenAndServeTLS(addr string, certFile, keyFile string, handler http.Handler) error
- func LoginHandler(w http.ResponseWriter, r *http.Request)
- type AuthHandler
- type AuthManager
- type StoppableListener
Constants ¶
This section is empty.
Variables ¶
View Source
var ReloadError = errors.New("Listener stopped")
Functions ¶
func AuthFunc ¶
func AuthFunc(am *AuthManager, f1 func(w http.ResponseWriter, r *http.Request)) func(w http.ResponseWriter, r *http.Request)
func InitAuthHandler ¶
func InitAuthHandler(am *AuthManager, h http.Handler) http.Handler
func ListenAndServeTLS ¶
func LoginHandler ¶
func LoginHandler(w http.ResponseWriter, r *http.Request)
Types ¶
type AuthHandler ¶
type AuthHandler struct {
// contains filtered or unexported fields
}
func (AuthHandler) ServeHTTP ¶
func (h AuthHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type AuthManager ¶
type AuthManager struct {
// contains filtered or unexported fields
}
func InitAuthManager ¶
func InitAuthManager(filename string) *AuthManager
func (*AuthManager) Key ¶
func (am *AuthManager) Key() string
type StoppableListener ¶
type StoppableListener struct { *net.TCPListener //Wrapped listener // contains filtered or unexported fields }
https://github.com/hydrogen18/stoppableListener/blob/master/listener.go
func New ¶
func New(l net.Listener, tcpL *net.TCPListener, certFile string, keyFile string) (*StoppableListener, error)
Click to show internal directories.
Click to hide internal directories.