feat(auth): add BasicVerifier, BasicAuthenticator, and BasicPrinciple for interfaces without implementation dependency

This commit is contained in:
AJ ONeal 2026-02-26 17:22:15 -07:00
parent d756f205b0
commit ff8cdec1d7
No known key found for this signature in database
2 changed files with 17 additions and 0 deletions

14
auth/auth.go Normal file
View File

@ -0,0 +1,14 @@
package auth
type BasicVerifier interface {
Verify(string, string) error
}
type BasicAuthenticator interface {
Authenticate(string, string) (BasicPrinciple, error)
}
type BasicPrinciple interface {
ID() string
Permissions() []string
}

3
auth/go.mod Normal file
View File

@ -0,0 +1,3 @@
module github.com/therootcompany/golib/auth
go 1.25.0