added new basic auth endpoint

This commit is contained in:
ston1th 2022-08-21 14:59:31 +02:00
commit 8c9ab3b8d2
10 changed files with 249 additions and 51 deletions

View file

@ -16,6 +16,7 @@ const (
consent = root + "consent"
users = root + "users"
logout = root + "logout"
auth = root + "auth/"
uroot = root + "user/"
userNew = uroot + "new"
@ -24,6 +25,8 @@ const (
userTotp = uroot + "totp/{user:[a-zA-Z0-9]+$}"
userSessions = uroot + "sessions/{user:[a-zA-Z0-9]+$}"
userUnlock = uroot + "unlock/{user:[a-zA-Z0-9]+$}"
authBasic = auth + "basic"
)
var routes = []route{
@ -115,4 +118,9 @@ var routes = []route{
userUnlockHandler)),
[]string{"POST"},
},
{
authBasic,
authBasicHandler,
[]string{"GET"},
},
}