2019-01-06 06:44:33 +08:00
|
|
|
package auth
|
|
|
|
|
|
|
|
import (
|
|
|
|
"net/http"
|
|
|
|
|
|
|
|
"github.com/filebrowser/filebrowser/v2/users"
|
|
|
|
)
|
|
|
|
|
|
|
|
// Auther is the authentication interface.
|
|
|
|
type Auther interface {
|
|
|
|
// Auth is called to authenticate a request.
|
2021-03-02 19:00:18 +08:00
|
|
|
Auth(r *http.Request, s users.Store, root string) (*users.User, error)
|
2019-02-15 20:58:45 +08:00
|
|
|
// LoginPage indicates if this auther needs a login page.
|
|
|
|
LoginPage() bool
|
2019-01-06 06:44:33 +08:00
|
|
|
}
|