Versions in this module Expand all Collapse all v1 v1.0.0 Mar 9, 2026 Changes in this version + var ErrInvalidCredentials = core.ErrInvalidCredentials + var ErrInvalidEmail = core.ErrInvalidEmail + var ErrInvalidToken = core.ErrInvalidToken + var ErrPasswordNoLower = core.ErrPasswordNoLower + var ErrPasswordNoNumber = core.ErrPasswordNoNumber + var ErrPasswordNoUpper = core.ErrPasswordNoUpper + var ErrPasswordTooLong = core.ErrPasswordTooLong + var ErrPasswordTooShort = core.ErrPasswordTooShort + var ErrSessionNotFound = core.ErrSessionNotFound + var ErrTooManyAttempts = core.ErrTooManyAttempts + var ErrUserExists = core.ErrUserExists + var ErrUserNotFound = core.ErrUserNotFound + func ChangeEmail(ctx context.Context, engine *Engine, userID, newEmail string) error + func ChangePassword(ctx context.Context, engine *Engine, userID, oldPassword, newPassword string) error + func DeleteAccount(ctx context.Context, engine *Engine, userID string) error + func Login(ctx context.Context, engine *Engine, email, password string) (*TokenPair, *LimitResult, error) + func Logout(ctx context.Context, engine *Engine, refreshToken string) error + func LogoutAll(ctx context.Context, engine *Engine, userID string) error + func RevokeSession(ctx context.Context, engine *Engine, sessionID string) error + func VerifyToken(engine *Engine, tokenString string) (string, error) + type AuditEntry = core.AuditEntry + type AuditLogger = core.AuditLogger + type Claims = core.Claims + type Engine = core.Engine + func New() *Engine + func WithAuditLogger(engine *Engine, logger AuditLogger) *Engine + func WithHasher(engine *Engine, hasher Hasher) *Engine + func WithJWTSecret(engine *Engine, secret string) *Engine + func WithRateLimiter(engine *Engine, limiter RateLimiter) *Engine + func WithSQLite(dbPath string) (*Engine, error) + type Hasher = core.Hasher + type LimitResult = core.LimitResult + type RateLimiter = core.RateLimiter + type Session = core.Session + func ListSessions(ctx context.Context, engine *Engine, userID string) ([]Session, error) + type SessionStore = core.SessionStore + type TokenPair = core.TokenPair + func RefreshToken(ctx context.Context, engine *Engine, refreshToken string) (*TokenPair, error) + type User = core.User + func GetUser(ctx context.Context, engine *Engine, userID string) (*User, error) + func GetUserByEmail(ctx context.Context, engine *Engine, email string) (*User, error) + func SignUp(ctx context.Context, engine *Engine, email, password string) (*User, error) + type UserStore = core.UserStore