npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

identity-desk

v0.1.0-dev

Published

Authentication, SSO, user management, and overall identity solution for Node.js

Downloads

8

Readme

Identity Desk

Authentication, SSO, user management, and overall identity solution for Node.js

Build Status Greenkeeper badge

Identity Desk is a flexible identity solution for Node.js. It saves you the effort of building a complete user system from various libraries such as Passport. And it is modular, so you can use only what you need.

// Load Identity Desk core and plugins
const authentication = require('identity-desk/authentication')
const identityDesk = require('identity-desk')({
  plugins: [authentication]
})

// Attach as Express middleware
app.use(identityDesk.app)

// Protect any route with `req.isAuthenticated`
app.get('/restricted', (req, res) => {
  if (req.isAuthenticated()) {
    res.send('Hello world')
  } else {
    res.redirect('/login')
  }
})

Modes

Use Identity Desk in either embedded or hub mode, depending on your architecture:

| Embedded mode | Hub mode | | --------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | | Use Identity Desk as a middleware within a single Express-based application | Use Identity Desk as a standalone single sign-on (SSO) server for use with multiple web applications (even non-Node.js applications) |

Why Identity Desk?

  • get security updates
  • on-premise & open source
  • maintain control of your user data
  • use security best-practices instantly
  • sensible defaults, customize almost anything
  • save the time and effort of rolling your own identity solution

Features / Roadmap

Target for version 1.0.0 release

  • Authentication
    • Local: username / password
    • Support for third-party authenticators (similar to Passport strategies)
  • Configuration panel
  • Registration
  • User administration panel

Beyond version 1.0.0

  • Authentication
    • Passwordless / magic links
    • LDAP
    • OAuth
    • Social logins
    • Two-factor / multi-factor
    • ... and other authenticators (similar to Passport strategies)
  • Auditing
  • Role-based access control (RBAC)
  • Account linking (e.g. link a Facebook and LinkedIn login to the same account/identity)
  • Password resets and invalidation
  • Single sign-on
  • User on-boarding experience
  • Account locking / anomaly detection
  • Password hash upgrading

Installation

$ npm install identity-desk

Dependencies

To use Identity Desk, you will need the following modules installed:

  • body-parser
  • [connect-session-sequelize] if you plan to store sessions in the database rather than providing a separate session store
  • express: ^4.0.0
  • express-session

Tests

To run the test suite, first install the dependencies, then run npm test:

$ npm install
$ npm test

Contributing

This project welcomes contributions from the community. Contributions are accepted using GitHub pull requests; for more information, see GitHub documentation - Creating a pull request.

For a good pull request, we ask you provide the following:

  1. Include a clear description of your pull request in the description with the basic "what" and "why"s for the request.
  2. The tests should pass as best as you can. GitHub will automatically run the tests as well, to act as a safety net.
  3. The pull request should include tests for the change. A new feature should have tests for the new feature and bug fixes should include a test that fails without the corresponding code change and passes after they are applied. The command npm run test-cov will generate a coverage/ folder that contains HTML pages of the code coverage, to better understand if everything you're adding is being tested.
  4. If the pull request is a new feature, please include appropriate documentation in the README.md file as well.
  5. To help ensure that your code is similar in style to the existing code, run the command npm run lint and fix any displayed issues.

Bug reports

Create a GitHub issue to report a bug. Please provide sufficient details to reproduce the bug, such as version numbers, error logs, and example code if possible.

If you have discovered a security related bug, please do NOT use the GitHub issue tracker. Send an email to [email protected].

People

The lead author is Faraz Syed.

List of all contributors

Support

Create a GitHub issue to ask a question. Make sure to add [question] to the beginning of your issue's title.

Commercial support is also available.

  • Consulting (install, config, maintain, upgrade, migrate)
  • Sponsored feature development
  • Training
  • Hosted Identity Desk / SaaS

Commercial support contact: [email protected]

License

MIT