Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
github.com/axllent/semver
This semver package provides the ability to sort & compare Semantic Versions in Go.
This package follows Semantic Versioning 2.0.0 with one exception: It recognizes MAJOR and MAJOR.MINOR (with no prereleases or build suffixes) as shorthands for MAJOR.0.0 and MAJOR.MINOR.0.
It is based on Golang's internal semver functionality, and has the following features:
v
prefixIf you require a full-blown solution then try masterminds/semver.
if semver.Compare("1.0.1", "1.0.0") == 1 { // higher
//...
}
if semver.Compare("1.0.1", "1.0.1-beta") == 1 { // higher
//...
}
fmt.Println(semver.Max("v1.0.1", "v1.0.1-beta"))
// v1.0.1
versions := []string{"5.0.0", "v5.1.0", "5.1.0-beta", "1.2.3"}
fmt.Prinlnln(semver.SortMax(versions))
// [v5.1.0 5.1.0-beta 5.0.0 1.2.3]
FAQs
Unknown package
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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.