Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Clock-accurate timeout for Node.js and browser. Basically it is identical to setTimeout, but it triggers callback function precisely on the next second.
See an example here
Accuracy should be around 1–2ms.
npm install clocktick
Usage is similar to setTimeout, but without delay parameter:
var tick = require('clocktick')
tick(callback) // Ticks every second
You can use the delay parameter, but it is in seconds:
tick(callback, 2) // Ticks on 2nd second (00, 02, 04, 06, 08, 10,...)
You can also offset seconds:
tick(callback, 3) // Ticks on 3rd second (03, 06, 9, 12, 15, 18, ...)
tick(callback, 3, 1) // Ticks on 3rd+1 second (04, 07, 10, 13, 16, 19, ...)
tick(callback, 3, 2) // Ticks on 3rd+2 second (05, 08, 11, 14, 17, 20, ...)
You can repeat the tick by just calling it again:
tick(callback)
function callback () {
console.log('tick')
tick(callback)
}
You can cancel the tick by using clearTimeout:
var timeout = tick(callback)
clearTimeout(timeout)
Clone to desktop and then run following commands at clocktick folder:
npm install
npm test
npm install
npm run build
FAQs
Clock-accurate timeout for Node.js and browser
The npm package clocktick receives a total of 7 weekly downloads. As such, clocktick popularity was classified as not popular.
We found that clocktick 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.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.