passlib: allow password hashes to be None for verify() (#8888)

This commit is contained in:
Stanislav Zmiev
2022-10-14 00:23:37 +04:00
committed by GitHub
parent c88c9dd18d
commit f689a3a93a

View File

@@ -67,10 +67,10 @@ class CryptContext:
def hash(self, secret: str | bytes, scheme: str | None = ..., category: str | None = ..., **kwds: Any) -> str: ...
def encrypt(self, *args, **kwds): ...
def verify(
self, secret: str | bytes, hash: str | bytes, scheme: str | None = ..., category: str | None = ..., **kwds: Any
self, secret: str | bytes, hash: str | bytes | None, scheme: str | None = ..., category: str | None = ..., **kwds: Any
) -> bool: ...
def verify_and_update(
self, secret: str | bytes, hash: str | bytes, scheme: str | None = ..., category: str | None = ..., **kwds: Any
self, secret: str | bytes, hash: str | bytes | None, scheme: str | None = ..., category: str | None = ..., **kwds: Any
) -> tuple[bool, str | None]: ...
def dummy_verify(self, elapsed: int = ...): ...
def is_enabled(self, hash: str | bytes) -> bool: ...