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.
Returns the next floating point number after any given number in the direction of some other floating point number. (Like the C standard library function).
var nextafter = require("nextafter")
var x = 0.1
console.log("The number", x, "is between", nextafter(x, -Infinity), "and", nextafter(x, Infinity))
Output:
The number 0.1 is between 0.09999999999999999 and 0.10000000000000002
npm install nextafter
require("nextafter")(from, to)
Returns the floating point number closest to from
in the direction on of to
from === to
, then returns from
from < to
, then returns next representable float after from
from > to
, then returns the floating point nubmer immediately before from
(c) 2014 Mikola Lysenko. MIT License
FAQs
Find the floating point number immediately after any given number
We found that nextafter 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.