Documentation
¶
Index ¶
- func NewAccountService(config *models.Config, accountRepo repositories.AccountRepository, ...) services.AccountService
- func NewSessionService(repo repositories.SessionRepository, signer security.TokenSigner, ...) services.SessionService
- func NewTokenService(tokenRepo repositories.TokenRepository) services.TokenService
- func NewUserService(repo repositories.UserRepository, dbHooks *models.CoreDatabaseHooksConfig) services.UserService
- func NewVerificationService(repo repositories.VerificationRepository, signer security.TokenSigner, ...) services.VerificationService
- type TokenServiceImpl
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAccountService ¶
func NewAccountService( config *models.Config, accountRepo repositories.AccountRepository, tokenRepo repositories.TokenRepository, dbHooks *models.CoreDatabaseHooksConfig, ) services.AccountService
func NewSessionService ¶
func NewSessionService( repo repositories.SessionRepository, signer security.TokenSigner, dbHooks *models.CoreDatabaseHooksConfig, ) services.SessionService
func NewTokenService ¶
func NewTokenService(tokenRepo repositories.TokenRepository) services.TokenService
NewTokenService creates a new instance of TokenServiceImpl
func NewUserService ¶
func NewUserService(repo repositories.UserRepository, dbHooks *models.CoreDatabaseHooksConfig) services.UserService
func NewVerificationService ¶
func NewVerificationService( repo repositories.VerificationRepository, signer security.TokenSigner, dbHooks *models.CoreDatabaseHooksConfig, ) services.VerificationService
Types ¶
type TokenServiceImpl ¶
type TokenServiceImpl struct {
// contains filtered or unexported fields
}
TokenServiceImpl implements TokenService
func (*TokenServiceImpl) Decrypt ¶
func (t *TokenServiceImpl) Decrypt(encryptedToken string) (string, error)
Decrypt decrypts the token by delegating to the repository
func (*TokenServiceImpl) Encrypt ¶
func (t *TokenServiceImpl) Encrypt(token string) (string, error)
Encrypt encrypts the token by delegating to the repository
func (*TokenServiceImpl) Generate ¶
func (t *TokenServiceImpl) Generate() (string, error)
Generate generates a new token by delegating to the repository
func (*TokenServiceImpl) Hash ¶
func (t *TokenServiceImpl) Hash(token string) string
Hash hashes the token by delegating to the repository
Click to show internal directories.
Click to hide internal directories.