toolness/hive-django — pull request #28 by toolness (2014-07-03 15:08:40+00:00)
Title: Add a Discourse SSO endpoint.

This pull request adds an optional `discourse_sso` Django app which adds a `/discourse_sso/` endpoint that implements the specification defined in the [Official Single-Sign-On for Discourse](https://meta.discourse.org/t/official-single-sign-on-for-discourse/13045).

Currently only vouched-for users are allowed to authenticate.

In Discourse, the user's name will be their full name followed by their organization name in parentheses, e.g. "Atul Varma (Hive NYC)". In the future we might change this so that the organization information is dynamically fetched by the Discourse instance, and hyperlinks are created that link back to the appropriate organization and individual profile pages, but this will require writing a Discourse plugin, so for now we'll just do the bare minimum required to make the experience not suck.