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.
Queue javascript objects dynamically then process the queue according to the appender. All appenders are handled synchronously.
Included tag appenders:
* files - See if inputed files exists.
* all - process all added objects.
* top_one - process only the object in the 0(zero) position of the process array.
* bottom_one - process only the object in the last position of the process array.
* func_all - process custom function names in created objects. Custom processing names can be used in any appender, this is just one example.
* status - queue and process all objects by status.
* name - queue and process all objects by name.
* version - queue and process all objects by version.
* json_all - process a class object per json input array variables.
* json_top_one - process a class object per the first json input array variable.
* json_bottom_one - process a class object per the last json input array variable.
* json_func_all - process custom function names in created objects. Custom processing names can be used in any json appender, this is just one example.
* json_status - queue and process all objects by status.
* json_name - queue and process all objects by name.
* json_version - queue and process all objects by version.
npm test
npm run test_files
npm run test_all
npm run test_top_one
npm run test_bottom_one
npm run test_func_all
npm run test_status_matching
npm run test_status_non_matching
npm run test_name_matching
npm run test_name_non_matching
npm run test_version_matching
npm run test_version_non_matching
npm run test_http_all
npm run test_json_http_all
npm run test_json_all
npm run test_json_top_one
npm run test_json_bottom_one
npm run test_json_func_all
npm run test_json_status_matching
npm run test_json_status_non_matching
npm run test_json_version_matching
npm run test_json_version_non_matching
npm run test_json_name_matching
npm run test_json_name_non_matching
var queue = require("queueobj");
var tst1 = class test1 {
constructor(props) {
let t = this, fname = "test_all.test1.constructor"
t.log = props.log
t.id = props.id
}
process(callback) {
let t = this, fname = "test_all.test1.process"
t.log({ msg: `This object (${fname}) is id (${t.id}). Do stuff here`.bgBrightGreen, type: "info" })
callback({ success: { msg: `processing all test1` } })
}
}
var tst2 = class test2 {
constructor(props) {
let t = this, fname = "test_all.test2.constructor"
t.log = props.log
t.id = props.id
}
process(callback) {
let t = this, fname = "test_all.test2.process"
t.log({ msg: `This object (${fname}) is id (${t.id}). Do stuff here`.bgBrightGreen, type: "info" })
setTimeout(() => {
callback({ success: { msg: `processing all test2` } })
}, 4000)
}
}
var tst3 = class test3 {
constructor(props) {
let t = this, fname = "test_all.test3.constructor"
t.log = props.log
t.id = props.id
}
process(callback) {
let t = this, fname = "test_all.test3.process"
t.log({ msg: `This object (${fname}) is id (${t.id}). Do stuff here`.bgBrightGreen, type: "info" })
// callback({success: { msg: `processing all test3` }})
callback({ error: { msg: `there is some problem thrown here on test3` } })
}
}
var tst4 = class test4 {
constructor(props) {
let t = this, fname = "test_all.test4.constructor"
t.log = props.log
t.id = props.id
}
process(callback) {
let t = this, fname = "test_all.test4.process"
t.log({ msg: `This object (${fname}) is id (${t.id}). Do stuff here`.bgBrightGreen, type: "info" })
callback({ success: { msg: `processing all test4` } })
}
}
var qObj = new queue()
qObj.init().process({
appender: "all",
exclude_logMsg: ["debug"], /* example ["debug", "info"] */
process_objects: [tst1, tst2, tst3, tst4]
}).then((success) => {
qObj.logMsg({ msg: `test success: {msg: "all objects processed with no errors"}`.success.italic.bold, type: "success" })
}, (error) => {
if (typeof error == "string") {
qObj.logMsg({ msg: `error: ${error}`.error.italic.bold, type: "error" })
} else {
let add_s = (error.error_count > 1) ? 's' : ''
qObj.logMsg({ msg: `${error.error_count} error${add_s} detected`.error.italic.bold, type: "error" })
}
})
FAQs
Queue File Objects
The npm package queueobj receives a total of 8 weekly downloads. As such, queueobj popularity was classified as not popular.
We found that queueobj demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
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.