From 0ff3f0f426bc51e7445ad49550e73832455a3eb9 Mon Sep 17 00:00:00 2001 From: Ozzie Isaacs Date: Tue, 30 Jul 2024 18:51:52 +0200 Subject: [PATCH] Fix for (#3111) exception on python 3.8/3.9 during storing of remember me cookie --- cps/cw_login/login_manager.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cps/cw_login/login_manager.py b/cps/cw_login/login_manager.py index bf0efbc7..21dc803d 100644 --- a/cps/cw_login/login_manager.py +++ b/cps/cw_login/login_manager.py @@ -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(