Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
chpr-blocked
Advanced tools
chpr-blocked is a tiny utility to monitor event loop blocking, inspired from tj/blocked, but configurable with environment variables.
When the event loop is blocked for more than a set threshold (defaults to 100ms), a log is emitted (using the specified level) using chpr-logger, and metrics are sent (increment + timing).
There is a "warmup delay" (defaults to 2000ms), because it's ok to use a lot of CPU in at the statup of the node app (e.g. to require most of the app code).
Install the package.
npm i chpr-blocked --save
Then require the module in the entry point in your code (e.g. server.js, worker.js, etc...).
require('chpr-blocked').start();
The configuration is done with environment variables.
Name | Description | Default |
---|---|---|
BLOCKED_DELAY | The tolerated warmup time after requiring chpr-blocked, milliseconds | 2000 |
BLOCKED_THRESHOLD | The threshold above which a log/metric is emitted, once the warmup delay is over | 100 |
BLOCKED_LOGGER_LEVEL | The logger level to apply on a blocked process | 'info' |
FAQs
Inspired from tj/blocked, but configurable with environment variables
The npm package chpr-blocked receives a total of 1 weekly downloads. As such, chpr-blocked popularity was classified as not popular.
We found that chpr-blocked 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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.