From e44613411a61e41ce4b1d43bd9a2460b539e366b Mon Sep 17 00:00:00 2001 From: Henrik Grimler Date: Thu, 3 Dec 2020 17:43:00 +0100 Subject: calcurse-caldav: allow non-ascii characters in username and password Signed-off-by: Lukas Fleischer --- contrib/caldav/calcurse-caldav.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/caldav/calcurse-caldav.py b/contrib/caldav/calcurse-caldav.py index 7c9b89b..3644028 100755 --- a/contrib/caldav/calcurse-caldav.py +++ b/contrib/caldav/calcurse-caldav.py @@ -147,8 +147,8 @@ def calcurse_version(): def get_auth_headers(): if not username or not password: return {} - user_password = ('{}:{}'.format(username, password)).encode('ascii') - user_password = base64.b64encode(user_password).decode('ascii') + user_password = ('{}:{}'.format(username, password)).encode('utf-8') + user_password = base64.b64encode(user_password).decode('utf-8') headers = {'Authorization': 'Basic {}'.format(user_password)} return headers -- cgit v1.2.3-70-g09d2