From Sudo Room
Revision as of 23:27, 22 September 2016 by Rcsheets (talk | contribs) (Updated current status of Persona in the contexts of Mozilla and Sudo Room.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

There aren't many decentralized authentication solutions out there. Namely, there are few alternatives to OpenID, and Mozilla Persona seems to be the most modern and most viable. Persona is based on the underlying BrowserID protocol. Further, Mozilla currently runs an Identity Provider (IdP) service at but one can run an IdP themselves, allowing for decentralization.

In terms of practical usage for sudo room, there are a sufficient number of libraries and plugins available for integrating and developing with lots of different applications and environments. This blog post from 2013 explains some more about how these libraries can be used.

In 2014, Mozilla transitioned Persona to community ownership. In January 2016, they announced plans to decommission the Mozilla-operated Persona infrastructure in November 2016. In September 2016, Sudo Room dropped Persona login support.

The browserid standard is still an open standard, and it would still be possible for us to set up an IdP, but this would be a significant undertaking.

Use Case

Our hackerspace community has an opportunity to support an environment for creative expression and new, elegant services. We have basic infrastructure including a wordpress website (with blog and shared calendar system), this mediawiki wiki, a membership application (in the works), and an issue tracker (next on deck). However, a limitation to running 2 or n services is managing more than one user account. Hackerspaces commonly write manual hacks to shim user account generation, and to propogate password updates across multiple systems. These solutions are a pain and very unstable. Persona offers a viable alternative, so at the very least we can use the same shim in each system.

We want to create an environment where members are encouraged to create lots of new apps, rather than bottlenecking on centralized/monolithic apps. With persona, these apps may have a lower barrier to entry since existing users can authenticate without registration.

Identity Provider (IdP)


Interesting, there's a drop-in apache module for persona-based auth:



Using BrowserID plugin.


Using Persona extension.


Persona Auth Module

First-pass (not tested, development version, probably broken):

A dead-simple verification plugin that allows users to authenticate using an email address via persona. Uses MIT-licensed verification library Auth-BrowserID and based on SeltzerCRM's User Module, both are dependencies.

pseudo code
  1. include BrowserID.php verification library class (gpl-compatible Mozilla license)
  2. create alternative Persona-based login form
  3. ensure login form shows up in the right places
  4. write handler to catch the POST login request, perform an assertion, add user id to session data, and respond in affirmative
  5. shouldn't need to write handler to catch the GET logout request, existing logout should simply clear session data

Relevant sections of code:

Helpful thoughts: Confirms idea of how this could work Demonstrated hack example in php

Libraries: Looks like I want to use this: namely: