Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Node.js and ACL

Tags:

I've chosen for my project Node.js+Express+Mongoose. Until now, I didn´t need to use ACL, but in this phase of project a I need to implement this.

NPM contains a few modules, but which one to choose?

Please tell me your experiences with ACL (Node.js+Express+Mongoose). And If you know any tutorial it would be great :), but it's not so needed, what I exactly need to know what Node.js programmers are using for ACL.

Last possibility is write own acl-middleware, it could be interesting experience for me. I suppose :)

like image 714
otodockal Avatar asked Jan 09 '13 12:01

otodockal


People also ask

What is ACL in node JS?

Well, if you are looking for a flexible and elegant way to protect specific resources in your application, Node ACL (Access Control List for Node) is a module that can solve your problem, providing a smooth way to create roles and permissions, and assign those roles to specific users.

Is node JS popular 2020?

Node. js development has become very popular over the last four years and continues to stand the competition in 2022 making startups worldwide choose it over other available options. Being an experienced Node.


2 Answers

https://npmjs.org/package/acl

The most used ACL module. It has Express middleware for protect resources and mongo support too..

Update 9.2020:

  • the acl package has not been updated in 2 years
  • there is a fork with recent changes: https://github.com/flash-oss/node_acl
like image 145
the.ufon Avatar answered Sep 20 '22 15:09

the.ufon


acl package has not been updated for the last 2 years. I’m the author of CASL - isomorphic permission management for JavaScript - https://github.com/stalniy/casl

According to npm trends it’s the mostly used library nowadays - https://www.npmtrends.com/acl-vs-@casl/ability

By the way it makes an integration with MongoDB and mongoose really easy!

like image 24
Sergii Stotskyi Avatar answered Sep 19 '22 15:09

Sergii Stotskyi