
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
@bookmate/with-express-graceful-shutdown
Advanced tools
Decorator for Express apps to enable graceful shutdown
This is a decorator for an Express http server enabling its graceful shutdown.
Based on ideas from:
express-graceful-shutdown middleware, which in turn used this blog post for inspiration;
npm install @bookmate/with-express-graceful-shutdown --save
const withGracefulShutdown = require('@bookmate/with-express-graceful-shutdown');
const app = require('./app'); // a regular Express app
const logger = require('./logger') // a custom logger
const expressPort = 3000;
const forceTimout = 30 * 1000; // timeout after which the app should be shut down forcefully
const options = {
logger,
forceTimout
}
const server = app.listen(expressPort, () => {
// your server is running
});
withGracefulShutdown(server, options);
logger
: a logger that provides info
, warn
, and error
functions for recording graceful shutdown. Default: console
.
forceTimeout
: number of milliseconds to wait for server.close() to complete before calling process.exit(1). Default: 60000.
FAQs
Decorator for Express apps to enable graceful shutdown
The npm package @bookmate/with-express-graceful-shutdown receives a total of 1 weekly downloads. As such, @bookmate/with-express-graceful-shutdown popularity was classified as not popular.
We found that @bookmate/with-express-graceful-shutdown demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.