@@ -4,13 +4,9 @@ from passlib.context import CryptContext
|
|||||||
from typing import Optional, Dict
|
from typing import Optional, Dict
|
||||||
from core.config import ConfSettings
|
from core.config import ConfSettings
|
||||||
|
|
||||||
# Configurar contexto para hashing de contraseñas
|
# Configurar contexto para hashing de contraseñas con argon2
|
||||||
# Soporta argon2 (nuevo) y bcrypt (antiguo) para compatibilidad hacia atrás
|
# argon2 es más moderno y más seguro que bcrypt
|
||||||
pwd_context = CryptContext(
|
pwd_context = CryptContext(schemes=["argon2"])
|
||||||
schemes=["argon2"],
|
|
||||||
deprecated=["bcrypt"],
|
|
||||||
argon2__rounds=3
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
class AuthService:
|
class AuthService:
|
||||||
|
|||||||
Reference in New Issue
Block a user