Gathering detailed insights and metrics for casequelize
Gathering detailed insights and metrics for casequelize
Gathering detailed insights and metrics for casequelize
Gathering detailed insights and metrics for casequelize
npm install casequelize
Typescript
Module System
Node Version
NPM Version
TypeScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
Apache-2.0 License
21 Commits
1 Watchers
1 Branches
2 Contributors
Updated on May 15, 2025
Latest Version
1.1.0
Package Id
casequelize@1.1.0
Unpacked Size
25.72 kB
Size
7.88 kB
File Count
11
NPM Version
6.4.0
Node Version
8.9.4
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
Casbin Sequelize Adapter is the Sequelize adapter for Casbin. With this library, Casbin can load policy from Sequelize supported database or save policy to it.
Based on Officially Supported Databases, The current supported databases are:
You may find other 3rd-party supported DBs in Sequelize website or other places.
npm install casequelize
1const Adapter = require('casequelize'); 2const { Enforcer } = require('casbin'); 3 4module.exports = () => { 5 // Initialize a Sequelize adapter and use it in a Casbin enforcer: 6 // The adapter will use the MySQL database named "casbin". 7 // If it doesn't exist, the adapter will create it automatically. 8 9 const adapter = await Adapter.newAdapter('mysql://root:123456@localhost:3306/casbin', {}); // Your driver and data source. 10 const enforcer = await Enforcer.newEnforcer('examples/rbac_model.conf', adapter); 11 12 // Or you can use an existing DB "abc" like this: 13 // The adapter will use the table named "casbin_rule". 14 // If it doesn't exist, the adapter will create it automatically. 15 // adapter = sequelizeadapter.newAdapter("mysql", "mysql_username:mysql_password@tcp(127.0.0.1:3306)/abc", true) 16 17 // Load the policy from DB. 18 await enforcer.loadPolicy() 19 20 // Check the permission. 21 await enforcer.enforce('alice', 'data1', 'read') 22 23 // Modify the policy. 24 // e.addPolicy(...) 25 // e.removePolicy(...) 26 27 // Save the policy back to DB. 28 await enforcer.savePolicy() 29}
This project is under Apache 2.0 License. See the LICENSE file for the full license text.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 0/21 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
85 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More