EIP712 TODO
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
||||
|
||||
type AuthService interface {
|
||||
GenerateChallenge(ctx context.Context, pubKey string) (*domain.Challenge, error)
|
||||
Authenticate(ctx context.Context, pubKey string, signature string, challenge *domain.Challenge, chainID uint) (*UserToken, error)
|
||||
}
|
||||
|
||||
type authService struct {
|
||||
@@ -21,6 +22,12 @@ type authService struct {
|
||||
refreshTokenExp uint
|
||||
}
|
||||
|
||||
type UserToken struct {
|
||||
AuthorizationToken string
|
||||
RefreshToken string
|
||||
ExpiresAt int64
|
||||
}
|
||||
|
||||
func NewAuthService(
|
||||
userRepo *domain.UserRepo,
|
||||
sessionRepo *domain.SessionRepo,
|
||||
@@ -47,3 +54,7 @@ func (s *authService) GenerateChallenge(ctx context.Context, pubKey string) (*do
|
||||
}
|
||||
return challenge, nil
|
||||
}
|
||||
|
||||
func (s *authService) Authenticate(ctx context.Context, pubKey string, signature string, challenge *domain.Challenge, chainID uint) (*UserToken, error) {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user