node package manager
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org ยป


Hapi auth plugin for Firefox Accounts

This is a simple authentication plugin for Hapi applications to become Firefox Accounts OAuth service providers. It accepts FxA bearer tokens in the Authorization header, verifies them against the hosted FxA verifier, and sets the returned user data as the request credentials.

Enable it in your Hapi server configuration like so:

  register: require('hapi-fxa-oauth')

Or customize things like so:

  register: require('hapi-fxa-oauth'),
  options: {
    url: '', // FxA dev server
    keepAlive: false,                         // don't hold connections open