diff --git a/oidc_provider/views.py b/oidc_provider/views.py index d8d2dd3..ea1108a 100644 --- a/oidc_provider/views.py +++ b/oidc_provider/views.py @@ -167,8 +167,8 @@ class JwksView(View): 'alg': 'RS256', 'use': 'sig', 'kid': md5(key).hexdigest(), - 'n': long_to_base64(public_key.n).encode('utf-8'), - 'e': long_to_base64(public_key.e).encode('utf-8'), + 'n': long_to_base64(public_key.n).decode('utf-8'), + 'e': long_to_base64(public_key.e).decode('utf-8'), }) return JsonResponse(dic)