mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
* AuthN: add interface for password clients * AuthN: Extract grafana password client * AuthN: Rewrite basic client tests * AuthN: Add Ldap client and rename method of PasswordClient * AuthN: Configure multiple password clients * AuthN: create ldap service and add tests
15 lines
444 B
Go
15 lines
444 B
Go
package clients
|
|
|
|
import "github.com/grafana/grafana/pkg/util/errutil"
|
|
|
|
const (
|
|
basicPrefix = "Basic "
|
|
bearerPrefix = "Bearer "
|
|
authorizationHeaderName = "Authorization"
|
|
)
|
|
|
|
var (
|
|
errIdentityNotFound = errutil.NewBase(errutil.StatusNotFound, "identity.not-found")
|
|
errInvalidPassword = errutil.NewBase(errutil.StatusBadRequest, "identity.invalid-password", errutil.WithPublicMessage("Invalid password or username"))
|
|
)
|