util

package
v0.0.0-...-f1e1513 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsPasswordValid

func IsPasswordValid(password string) error

Types

type BycryptProvider

type BycryptProvider interface {
	Hash(password string) (string, error)
	CompareHashAndPassword(hash, password string) error
}

func NewBcryptProvider

func NewBcryptProvider(cost int) BycryptProvider

type JwtProvider

type JwtProvider interface {
	Sign(userID int64) (string, error)
	Parse(tokenString string) (*jwtClaims, error)
}

func NewJwtProvider

func NewJwtProvider(jwtConfig config.JwtConfig) JwtProvider

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL