Spaces:
Sleeping
Sleeping
some updates
Browse files123 unmodified lines124125126127128129130131132133134135136123 unmodified linesdef get_password_hash(password: str) -> str:# Hash password with SHA256 first to handle any length, then use bcryptpassword_hash = hashlib.sha256(password.encode('utf-8')).hexdigest()return pwd_context.hash(password_hash)def verify_password(plain_password: str, hashed_password: str) -> bool:# Apply same SHA256 transformation before verifyingpassword_hash = hashlib.sha256(plain_password.encode('utf-8')).hexdigest()return pwd_context.verify(password_hash, hashed_password)123 unmodified lines124125126127128129130131132133134135136123 unmodified linesdef get_password_hash(password: str) -> str:# Hash password with SHA256 first to handle any length, then use bcryptpassword_hash = hashlib.sha256(password.encode('utf-8')).digest()return pwd_context.hash(password_hash)def verify_password(plain_password: str, hashed_password: str) -> bool:# Apply same SHA256 transformation before verifyingpassword_hash = hashlib.sha256(plain_password.encode('utf-8')).digest()return pwd_context.verify(password_hash, hashed_password)
.DS_Store
server.py+2-2