13 lines
188 B
Go
13 lines
188 B
Go
package auth
|
|
|
|
import "context"
|
|
|
|
type Principal struct {
|
|
UserID int64
|
|
DeviceID uint64
|
|
}
|
|
|
|
type Service interface {
|
|
Authenticate(ctx context.Context, token string) (*Principal, error)
|
|
}
|