mirror of
				https://github.com/janeczku/calibre-web
				synced 2025-10-31 07:13:02 +00:00 
			
		
		
		
	Fix for (#3111) exception on python 3.8/3.9 during storing of remember me cookie
This commit is contained in:
		| @@ -397,7 +397,7 @@ class LoginManager: | ||||
|  | ||||
|     def _load_user_from_remember_cookie(self, cookie): | ||||
|         signer_kwargs = dict( | ||||
|             key_derivation="hmac", digest_method=staticmethod(hashlib.sha1) | ||||
|             key_derivation="hmac", digest_method=hashlib.sha1 | ||||
|         ) | ||||
|         try: | ||||
|             remember_dict = URLSafeSerializer( | ||||
| @@ -482,7 +482,7 @@ class LoginManager: | ||||
|         # prepare data | ||||
|         max_age = int(current_app.permanent_session_lifetime.total_seconds()) | ||||
|         signer_kwargs = dict( | ||||
|             key_derivation="hmac", digest_method=staticmethod(hashlib.sha1) | ||||
|             key_derivation="hmac", digest_method=hashlib.sha1 | ||||
|         ) | ||||
|         # save | ||||
|         data = URLSafeSerializer( | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Ozzie Isaacs
					Ozzie Isaacs