3 ms·
As far as I know, there's no official way of using Devise over a REST API. It is designed with a server-side Rails app in mind. There's devise_token_auth and re
by rashkov 8y ago
As far as I know, there's no official way of using Devise over a REST API. It is designed with a server-side Rails app in mind. There's devise_token_auth and related client libraries, but I wish there was an official way for handling authentication for single-page apps. Every time I look into this issue, it seems like there isn't much going on in this space. Then again, maybe the entire authentication protocols space is like that, and it's actually Devise which is in the unusual position of being a de-facto standardized way to do auth in the Rails world.
- rohan404 8y agoIt's true that there isn't an official way to use Devise over REST, but then again Devise isn't even the official way to manage auth in Rails apps - it just happens to be the de facto one due to community support. That being said, by using something like devise_token_auth/simple_token_authentication and devise-two-factor you can have a token based auth system with MFA ready in a matter of minutes. Personally, I don't think there are really any back-end frameworks that have an official way to handle auth as it's always based more on community consensus.
- james_s_tayler 8y agoASPNET Identity and Spring Security to name a few.
- chasd00 8y agoI'd just like to say Spring Security has come a LONG way. It use to be a maze of madness and frustration but now is fairly straightforward. Also, Spring Boot saved that whole organization from irrelevance. It took a huge amount of effort to just get hello world on the screen prior to Spring Boot.