added RAG, Multiuser, TG bot
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
import hashlib
|
||||
|
||||
|
||||
def hash_token(token: str) -> str:
|
||||
return hashlib.sha256(token.encode("utf-8")).hexdigest()
|
||||
|
||||
|
||||
def verify_token(plain: str, token_hash: str) -> bool:
|
||||
return hash_token(plain) == token_hash
|
||||
Reference in New Issue
Block a user