Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
casbin-redis-adapter
Advanced tools
[![NPM version][npm-image]][npm-url] [![NPM download][download-image]][download-url] [![CI](https://github.com/node-casbin/redis-adapter/actions/workflows/ci.yml/badge.svg)](https://github.com/node-casbin/redis-adapter/actions/workflows/ci.yml) [![Coverag
Redis policy storage, implemented as an adapter for node-casbin.
npm install --save casbin-redis-adapter
// or
yarn add casbin-redis-adapter
Require it in a place, where you are instantiating an enforcer (read more about enforcer here):
import {newEnforcer} from 'casbin';
import {NodeRedisAdapter} from './adapter' ;
import {join} from 'path';
const model = join(__dirname, 'casbin_conf/model.conf');
const adapter = await NodeRedisAdapter.newAdapter({host: "127.0.0.1", port: 6379});
const enforcer = await newEnforcer(model, adapter);
That is all what required for integrating the adapter into casbin.
NodeRedisAdapter.newAdapter()
takes the following parameters as an object to establish the connection with
redis-server
options: interface IConnectionOptions {
host: string // IP address of the Redis server
port: number // Port of the Redis server
}
redisOpts ? : redis.ClientOpts //https://github.com/NodeRedis/node-redis#options-object-properties
FAQs
[![NPM version][npm-image]][npm-url] [![NPM download][download-image]][download-url] [![CI](https://github.com/node-casbin/redis-adapter/actions/workflows/ci.yml/badge.svg)](https://github.com/node-casbin/redis-adapter/actions/workflows/ci.yml) [![Coverag
The npm package casbin-redis-adapter receives a total of 16 weekly downloads. As such, casbin-redis-adapter popularity was classified as not popular.
We found that casbin-redis-adapter demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.