- Backend: FastAPI app with all models, services, schemas, routes - Admin Panel: Next.js dashboard with all modules (CRM, POS, repairs, warranties, billing, notifications, etc.) - Ecommerce: storefront (submodule) + product catalog - AI Agents: .agents/ skill library for Antigravity IDE - Docs: architecture, billing, notification gateway markdown - Submodules: Backend/OpenWA, Ecommerce/File 2/storefront
13 lines
375 B
Python
13 lines
375 B
Python
from passlib.context import CryptContext
|
|
import hashlib
|
|
|
|
pwd_context = CryptContext(schemes=["argon2"], deprecated="auto")
|
|
|
|
def hash_password(pwd: str) -> str:
|
|
return pwd_context.hash(pwd)
|
|
|
|
def verify_password(pwd: str, hash: str) -> bool:
|
|
return pwd_context.verify(pwd, hash)
|
|
|
|
def hash_token(token: str) -> str:
|
|
return hashlib.sha256(token.encode()).hexdigest()
|