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/chewxy/vecf32
Package vecf32 provides common functions and methods for slices of float32
go get -u gorgonia.org/vecf32
This package math32. For testing this package uses testify/assert, which is licenced with a MIT/BSD-like licence
The point of this package is to provide operations that are accelerated by SIMD. However, this pakcage by default does not use SIMD. To use SIMD, build tags must be used. The supported build tags are sse
and avx
. Here's an example on how to use them:
b = b[:len(a)]
lines?This is mainly done to eliminate bounds checking in a loop. The idea is the bounds of the slice is checked early on, and if need be, panics early. Then if everything is normal, there won't be bounds checking while in the loop. This also means that b
must be at least len(a)
, otherwise a panic will occur.
To check for boundschecking and bounds check elimination (an amazing feature that landed in Go 1.7), compile your programs with -gcflags='-d=ssa/check_bce/debug=1'
.
Contributions are welcome. The typical process works like this:
This package is very well tested. Please ensure tests are written if any new features are added. If bugs are fixed, please add the bugs to the tests as well.
Package vecf32 is licenced under the MIT licence.
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.