Utilities
Helper functions for password validation and security.
Overview
Provides the calculatePasswordStrength function that analyzes password strength based on length, character diversity, common patterns, and entropy. Returns a score (0-4), strength label, feedback, and suggestions.
Basic Usage
import { calculatePasswordStrength } from 'authsafe-ts';
const result = calculatePasswordStrength('MySecureP@ssw0rd!');
console.log(result.score); // 4
console.log(result.strength); // 'very-strong'