apierr

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2025 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrUserLocked is returned when a user's account is temporarily locked due to excessive failed login attempts.
	ErrUserLocked = errors.New("account is temporarily locked")
	// ErrInvalidToken is returned when a provided token is invalid or has expired.
	ErrInvalidToken = errors.New("invalid or expired token")
	// ErrRevokedToken is returned when a token has been explicitly revoked.
	ErrRevokedToken = errors.New("token has been revoked")
	// ErrMaxTokensReached is returned when a user has reached the maximum number of active tokens allowed.
	ErrMaxTokensReached = errors.New("maximum number of active tokens reached")
	// ErrInvalidCredentials is returned when a user provides incorrect authentication credentials.
	ErrInvalidCredentials = errors.New("invalid credentials")
	// ErrUsernameTaken is returned when attempting to create a user with a username that already exists.
	ErrUsernameTaken = errors.New("username already exists")
	// ErrPasswordExpired is returned when a user's password has expired and needs to be changed.
	ErrPasswordExpired = errors.New("password has expired")
	// ErrUserNotFound is returned when a user record is not found in the database.
	ErrUserNotFound = errors.New("user not found")
)

Functions

This section is empty.

Types

This section is empty.

Directories

Path Synopsis
auth/validation/password.go
auth/validation/password.go

Jump to

Keyboard shortcuts

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