Add JSON web token (JWT) authentication

We currently expect the use of HMAC SHA-256, although there shouldn't be
anything preventing us from using other algorithms.

(imported from commit 354510a0b7e9e273d062a1ab5b2b03d4a749d6a3)
This commit is contained in:
Zev Benjamin
2014-03-27 19:49:20 -04:00
parent bd20b295e1
commit bd3f1c6a9e
3 changed files with 35 additions and 0 deletions

View File

@@ -23,6 +23,7 @@ urlpatterns = patterns('',
url(r'^accounts/login/openid/done/$', 'zerver.views.process_openid_login', name='openid-complete'),
url(r'^accounts/login/openid/done/$', 'django_openid_auth.views.login_complete', name='openid-complete'),
url(r'^accounts/login/sso/$', 'zerver.views.remote_user_sso', name='login-sso'),
url(r'^accounts/login/jwt/$', 'zerver.views.remote_user_jwt', name='login-jwt'),
# We have two entries for accounts/login to allow reverses on the Django
# view we're wrapping to continue to function.
url(r'^accounts/login/', 'zerver.views.login_page', {'template_name': 'zerver/login.html'}),