From 98fa0b7b3ea1918c63d88cb09c21265834afa1d0 Mon Sep 17 00:00:00 2001
From: Ayub <muhammadayubkhan6@gmail.com>
Date: Fri, 16 Aug 2019 23:48:01 +0500
Subject: [PATCH] py3 bug fix (#21351)

---
 openedx/core/djangoapps/safe_sessions/middleware.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/openedx/core/djangoapps/safe_sessions/middleware.py b/openedx/core/djangoapps/safe_sessions/middleware.py
index b9804cc3f38..36aa883322f 100644
--- a/openedx/core/djangoapps/safe_sessions/middleware.py
+++ b/openedx/core/djangoapps/safe_sessions/middleware.py
@@ -201,7 +201,7 @@ class SafeCookieData(object):
         """
         hash_func = sha256()
         for data_item in [self.version, self.session_id, user_id]:
-            hash_func.update(six.text_type(data_item))
+            hash_func.update(six.b(six.text_type(data_item)))
             hash_func.update('|')
         return hash_func.hexdigest()
 
-- 
GitLab