
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
@hexly/dbo
Advanced tools
Easiest usage is to isolate all instances to a single DBO in dbo.js
or something:
const path = require('path')
const { Pool } = require('pg')
const { DboFactory, Configurer } = require('@hexly/dbo')
let dbo
const initDbo = async () => {
if (dbo) {
return dbo
}
const pool = new Pool({
connectionString: 'postgres://postgres@localhost:5432/postgres'
})
new Configurer().configure()
const root = path.resolve(__dirname, './src')
const factory = new DboFactory().scan(root)
dbo = factory.build(pool.connect.bind(pool))
return dbo
}
module.exports = {
initDbo
}
And then have your middleware/etc wire it up:
var express = require('express')
const { initDbo } = require('./dbo')
var app = express()
app.use( async(req, res, next) => {
const dbo = await initDbo()
req.dbo = dbo
next()
})
app.get('/', async (req, res) => {
const person = await req.dbo.getPeople.one({ids: [1]})
const people = await req.dbo.getPeople.many({})
res.send({ person, people })
})
const port = process.env.PORT || 3000
app.listen(port, (a, b, c) => {
console.log('listening on', port)
})
FAQs
Unknown package
We found that @hexly/dbo demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers 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
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.