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.
forward-emitter
Advanced tools
Forward events from one Node EventEmitter to another.
npm install forward-emitter
var forward = require('forward-emitter');
// Basic forwarding
forward(src, dest);
// Forward only selected events
// In this example, only the 'connect' event is forwarded.
forward(src, dest, function (eventName) {
return eventName === 'connect';
});
// Forward all events except exclusions
var exclusions = ['connect', 'disconnect'];
forward(src, dest, function(eventName) {
return exclusions.indexOf(eventName) === -1;
});
forward-emitter
listens to the newListener
and removeListener
events, introduced in Node 0.8
and
Node 0.10
respectively. When a callback is bound to an event on the destination emitter, the listener
is forwarded to the source emitter.
For that reason, this module should not be used in Node < 0.10
if you plan to use removeListener
.
FAQs
Forward events from any Node EventEmitter to another EventEmitter.
We found that forward-emitter 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 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.