Research
Security News
Malicious PyPI Package ‘pycord-self’ Targets Discord Developers with Token Theft and Backdoor Exploit
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
express-brute-pg
Advanced tools
A PostgreSQL store for express-brute via node-postgres.
via npm:
$ npm install express-brute-pg
express-brute-pg expects a table named brute
(this may be overridden in the constructor) to exist in whatever database you're connecting to.
create table brute(id text primary key, count int, first_request timestamptz, last_request timestamptz, expires timestamptz);
var ExpressBrute = require('express-brute'),
PgStore = require('express-brute-pg');
var store = new PgStore({
host: '127.0.0.1',
database: 'sandbox',
username: 'appuser',
password: 'password'
});
var bruteforce = new ExpressBrute(store);
app.post('/auth',
bruteforce.prevent, // error 403 if we hit this route too often
function (req, res, next) {
res.send('Success!');
}
);
host
Postgres server host name or IP addressdatabase
Database name to connect tousername
Database usernamepassword
Corresponding passwordtableName
Include to use a storage table named something other than brute
schemaName
Include if your storage table is in a schema other than public
pg
You may pass in your application's pg
module to express-brute-pg
to share connection pools or use the native bindings; if not supplied, express-brute-pg
will spin up its own poolFAQs
A PostgreSQL store for express-brute
We found that express-brute-pg demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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 the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.
Security News
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.