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.
"top" command for Node apps
The idea is to be able to quickly see the heaviest currently running Node functions using a single command in the terminal just like with "top" for regular processes. Another major point is only attaching the inspector for the time of the profiling so the tool can be always available in a production server without causing any overhead.
Once this is enabled there's no need to restart the app with "--profile" flag so any unexpected high CPU usage can be debugged more easily.
Usage
npm i ntop
Add to the script to enable communication with CLI tool
const ntop = require('ntop') ntop()
Then run the CLI. It will find all processes enabled for ntop communication
npx ntop
You'll see a list of ntop-enabled Node processes and their corresponding PIDs for convenience. Now you can see the list of functions for any process with
npx ntop 12345
Custom sampling time 5s
npx ntop 12345 5000
Verbose output showing breadcrumbs i.e. to see what called (anonymous)
npx ntop 12345 5000 -v
Experimental flame chart
npx ntop 12345 5000 -f
FAQs
Node CLI runtime profiler - easily debug unexpected high CPU usage
The npm package ntop receives a total of 4 weekly downloads. As such, ntop popularity was classified as not popular.
We found that ntop 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.