feat: create oauth broker service

This commit is contained in:
Stavros
2025-08-25 19:33:52 +03:00
parent 44f35af3bf
commit dbadb096b4
12 changed files with 184 additions and 683 deletions

View File

@@ -1,7 +1,5 @@
package config
import "time"
type Claims struct {
Name string `json:"name"`
Email string `json:"email"`
@@ -100,7 +98,6 @@ type OAuthServiceConfig struct {
TokenURL string
UserinfoURL string
InsecureSkipVerify bool
Name string
}
type User struct {
@@ -114,8 +111,6 @@ type UserSearch struct {
Type string // local, ldap or unknown
}
type Users []User
type SessionCookie struct {
Username string
Name string
@@ -137,12 +132,6 @@ type UserContext struct {
TotpEnabled bool
}
type LoginAttempt struct {
FailedAttempts int
LastAttempt time.Time
LockedUntil time.Time
}
type UnauthorizedQuery struct {
Username string `url:"username"`
Resource string `url:"resource"`