
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.
A JavaScript SDK to interact with the Crossbell. It works for both browser and Node.js.
npm install crossbell
Node.js >= 18.0.0 or Node.js >= 16.14.0 with fetch polyfill
import { createContract } from 'crossbell'
// Create a new contract instance with metamask provider
const provider = window.ethereum
const contract = new createContract(provider)
// Example API: Create a new character for an address
try {
const result = await contract.character.create({
owner: '0x1234567890123456789012345678901234567890',
handle: 'Jason',
metadataOrUri: 'ipfs://xxxx/metadata.json',
})
console.log(result.data) // '42' (characterId)
console.log(result.transactionHash) // '0xabcdef...'
} catch (e) {
console.error(e.message) // e.g. "execution reverted: Web3Entry: HandleExists"
}
You can also connect with a private key directly.
import { createContract } from 'crossbell'
const privateKey =
'0xabcdef0123456789012345678901234567890123456789012345678901234'
const contract = new createContract(provider)
You can also connect with a read-only provider. Note that in this case, you can't do write operations like createCharacter
.
import { createContract } from 'crossbell'
const contract = new createContract(provider) // just pass nothing to use a read-only provider
For more contract api, see docs.
You can fetch data from the crossbell indexer.
import { createIndexer } from 'crossbell'
const indexer = createIndexer()
// get a list of characters owned by a specific address
const res = await indexer.character.getMany(
'0x1234567890123456789012345678901234567890',
)
console.log(res.list)
For more indexer api, see docs.
FAQs
JavaScript SDK to interact with Crossbell
The npm package crossbell receives a total of 227 weekly downloads. As such, crossbell popularity was classified as not popular.
We found that crossbell 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.
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.