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/jeamon/gorqs
gorqs
means Go Runnable Queue Service. This is a multi-features go-based concurrent-safe library to queue & execute jobs and records their execution result. You can start the Queue service into synchronous or asynchronous mode.
The mode defines wether each added job should be processed synchronously or asynchronously. Be aware that adding a job to the Queue system is always a non-blocking operation and returns the job id on success. Fetching a given job execution result removes that entry from local records cache.
gorqs.New(gorqs.SyncMode | gorqs.TrackJobs)
or gorqs.New(gorqs.AsyncMode | gorqs.TrackJobs)
method provides a Queue object which implements the Queuer
interface with below actions.
Action | Description |
---|---|
Start(context.Context) error | starts the jobs queue |
Stop(context.Context) error | stops the jobs queue |
Push(context.Context, Runner) (int64, error) | adds a job to the queue asynchronously |
Fetch(context.Context, int64) error | gets result execution of given job |
IsRunning() bool | provides queue service status |
Clear() | delete all jobs results records |
An acceptable runnable job should implement the Runner
interface defined as below :
type Runner interface {
Run() error
}
Just import the gorqs
library as external package to start using it into your project. There are some examples into the examples folder.
[Step 1] - Download the package
$ go get github.com/jeamon/gorqs
[Step 2] - Import the package into your project
$ import "github.com/jeamon/gorqs"
[Step 3] - Optional: Clone the library to run some examples
$ git clone https://github.com/jeamon/gorqs.git
$ cd gorqs
$ go run examples/sync-mode/example.go
$ go run examples/async-mode/example.go
Feel free to reach out to me before any action. Feel free to connect on Twitter or linkedin
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.