
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 lightweight Promise based HTTP client, using Fetch API.
npm i --save fitch
** With ES2015 or TypeScript:**
import fitch from 'fitch'
CommonJS:
const fitch = require('fitch')
UMD:
<script src="node_modules/fitch/src/index.js"></script>
fitch.get(apiUrl)
.then(data => console.log(data))
fitch.get(apiUrl)
.then(data => console.log(data))
const req = {body: {name: 'Happy cat'}}
fitch.get(apiUrl, req)
.then(data => console.log(data))
const req = {body: {name: 'Happy cat'}}
fitch.get(apiUrl, req)
.then(data => console.log(data))
const req = {body: {name: 'Happy cat'}}
fitch.get(apiUrl, req)
.then(data => console.log(data))
fitch.get(apiUrl)
.then(data => console.log(data))
const config = {
cache = 'no-store',
headers = { 'Content-Type': 'application/json' },
mode = 'no-cors',
raw = true, // return the raw output of fetch()
params: { // transform to '?test1=test-1&test2=test-2'
test1: 'test-1',
test2: 'test-2',
},
}
fitch.get(apiUrl, config)
.then(data => console.log(data))
See more about fetch configuration at: Fetch API.
Note: This assumes that you’re using a transpiler like Babel.
Note: modern browsers such as Chrome, Firefox, and Microsoft Edge contain native implementations of window.fetch, so the polyfill doesn't have any affect on those browsers. See more at window.fetch polyfill.
First yout need to fork this repository. Then:
npm i # install local dependencies
npm start # run local server
npm run watch:test # watch files inside src/ and tests/
npm run examples # run examples
Note: Your code must be tested and pass in linter check.
You can verify your code with ESLint, using npm run lint
.
FAQs
A lightweight Promise based HTTP client, using Fetch API.
The npm package fitch receives a total of 4 weekly downloads. As such, fitch popularity was classified as not popular.
We found that fitch demonstrated a not healthy version release cadence and project activity because the last version was released 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.