Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Argon2IdHasher ¶
type Argon2IdHasher struct {
// contains filtered or unexported fields
}
func NewArgon2IdHasher ¶
func NewArgon2IdHasher() *Argon2IdHasher
func (*Argon2IdHasher) Hash ¶
func (h *Argon2IdHasher) Hash(data string) (string, error)
Hash generates a secure Argon2id hash of the given password.
func (*Argon2IdHasher) Verify ¶
func (h *Argon2IdHasher) Verify(data, storedHash string) bool
Verify verifies if the given data matches the stored hash.
type SimpleTokenHasher ¶
type SimpleTokenHasher struct {
// contains filtered or unexported fields
}
func NewSimpleTokenHasher ¶
func NewSimpleTokenHasher(secretKey string) *SimpleTokenHasher
func (*SimpleTokenHasher) Verify ¶
func (h *SimpleTokenHasher) Verify(data, originalHash string) bool
Click to show internal directories.
Click to hide internal directories.