Node-fetch is a lightweight module that empowers Node.js developers with the Fetch API and version 3.2.7 represents a minor update over the previous stable version, 3.2.6. Both versions share the same core dependencies, including "data-uri-to-buffer," "fetch-blob," and "formdata-polyfill," ensuring consistent handling of data URIs, Blob objects, and FormData respectively. Similarly, the development dependencies remain unchanged, encompassing tools for testing (like "chai," "mocha"), code coverage ("c8," "coveralls"), and linting ("xo"). This indicates that the development workflow and quality assurance processes are consistent across both versions.
The core functionalities and intended use of the library are stable. The module excels at fetching resources over the network, effectively mirroring the browser-based Fetch API in a Node.js environment. This makes it ideal for tasks like consuming REST APIs, scraping web content, or interacting with other network services directly from a Node.js application.
The noteworthy changes between 3.2.6 and 3.2.7 come down to internal modifications as reflected in the "dist" object: "unpackedSize" increased slightly from 105987 to 106007. This might reflect very minor code updates, documentation tweaks, or build process adaptations but signifies that the update is minimal. The release date also gives information about the versions lifecycles: version 3.2.7 was released on July 11, 2022 while 3.2.6 was released on June 9, 2022. For developers relying on node-fetch, upgrading from 3.2.6 to 3.2.7 should be a seamless experience, carrying minimal risks and offering the benefit of potential bug fixes or performance improvements, however incremental that last might be.
All the vulnerabilities related to the version 3.2.7 of the package
node-fetch Inefficient Regular Expression Complexity
node-fetch is a light-weight module that brings window.fetch to node.js.
Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) in the isOriginPotentiallyTrustworthy()
function in referrer.js
, when processing a URL string with alternating letters and periods, such as 'http://' + 'a.a.'.repeat(i) + 'a'
.