
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
scrpr is a lightweight scraper multitool. it can fetch data via https, detect changes and parse the most common formats.
const scrpr = require("scrpr");
const scraper = scrpr({
concurrency: 5,
cachedir: '/tmp/scraper-cache',
});
scraper("https://example.org/data.csv", {
parse: "csv",
}, function(err, change, data){
if (err) console.error(err);
if (change) console.log(data);
});
scrpr(opts) → function scraperConstructor, returns scraper function
Opts:
concurrency — number of parallel requests; default: 1cachedir — directory to save cache data in; default: <root module>/.scrpr-cachescraper([url], [opts], [callback(err, change, data)])Scraper, delivers data
Opts:
method — http method; default: geturl — URL, alternative to url parameterheaders — additional http request headers, default: {}data — http data to be sent, default: nullcache — use cache, default: truecacheid — override cache id, default: hash(url, opts)parse — format to parse, default: null (raw data)successCodes — array of http status codes considered successful, default: [ 200 ]needle — options passed on to needle, default {}xlsx — options passed on to xlsx, default {}xsv — options passed on to xsv, default {}pdf — options passed on to pdf.js-extract, default {}preprocess(data, callback(err, data)) — modify data before parsingpostprocess(data, callback(err, data)) — modify data after parsingstream — deliver data as ReadableStream — no parsing or processing, default: falsemetaredirects — follow <meta http-equiv="refresh"> style redirects, default: falseiconv — decode stream or data as this charset with iconv-lite before parsing, default: falsecooldown — microseconds since last fetch before a resource is fetched again, default: falsesizechange — treat unchanged content-length as same file, default: falseCallback:
err — contains Error or nullchange — true if data changeddata — raw or parsed data when changed, otherwise status stringcsv — Comma Seperated Values; data is an Object, parsed with xsvtsv — Tab Separated Values; data is an Object, parsed with xsvssv — Semicolon Separated Values (data has been exported "as csv" with some localizations of Microsoft Excel): data is an Object, parsed with xsvxml — eXtensible Markup Language; data is an Object, parsed with xml2jsjson — JavaScript object Notation; data is an Object, parsed nativelyhtml — HyperText Markup Language; data is an instance of cheerioyaml — YAML Ain't Markup Language; data is an Object, parsed with yamlxlsx — Office Open XML Workbook; data is an Object, parsed with xlsx; { "<sheetname>": [ [ cell, cell, cell, ... ], ... ] }pdf — Portable Document Format; data is an Object, parsed with pdf.js-extract;kdl — KDL Document Language; data is an Object, parsed with kdljs;dw — Datawrapper Visualisation; data is an Object, extracted with dataunwrapper;Rudimentary handling for ftp URLs is available if the optional get-uri dependency is installed.
Rudimentary handling for local files is available with the file:/ pseude-protocol.
xsv, xlsx, xml2js, yaml, cheerio, dataunwrapper, iconv-lite, kdljs, pdf.js-extract and get-uri are optional dependencies. They should only be installed if their use is required.
FAQs
a scraper multitool
We found that scrpr 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.