Skip to content

Feature request: Token-based auth for REST API #21

Description

@colinskow

Cookie-based auth doesn't work on Phonegap or Chrome packaged apps. It also leaves vulnerability to CSRF attacks.

A better strategy for an Angular-type SPA is to store a token in LocalStorage:
https://auth0.com/blog/2014/01/07/angularjs-authentication-with-cookies-vs-token/

I would like the options to use either json web tokens (which don't require any session store) or a Redis-based token system. This is very easy to implement with Passport.

https://github.com/roblevintennis/passport-api-tokens

If I have some time over the next week I'll send you a pull request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions