The npm package mysql offers a JavaScript driver for connecting to MySQL databases, known for being lightweight and requiring no compilation. Comparing versions 2.5.4 and 2.5.3 reveals subtle but potentially important distinctions for developers. Both versions share the same core dependencies: bignumber.js for handling large numbers, readable-stream for efficient data streaming, and require-all for simplified module loading. Key differences lie within the development dependencies and release dates. Version 2.5.4 utilizes istanbul version 0.3.5 for code coverage, while version 2.5.3 relies on istanbul 0.3.2. This suggests potential improvements or bug fixes in the testing and code coverage aspects of the newer release. The release dates also highlight the difference, with version 2.5.4 being published on December 17, 2014 and version 2.5.3 on November 6, 2014, indicating a more recent set of updates and refinements in version 2.5.4. Developers should consider these finer points when choosing between the versions, particularly if testing or code coverage tools integration is critical to their workflow. Upgrading to 2.5.4 likely provides the benefit of the latest improvements in code coverage reporting thanks to the newer Istanbul version.
All the vulnerabilities related to the version 2.5.4 of the package
mysql Node.JS Module Vulnerable to Remote Memory Exposure
Versions of mysql
before 2.14.0 are vulnerable to remove memory exposure.
Affected versions of mysql
package allocate and send an uninitialized memory over the network when a number is provided as a password.
Only mysql
running on Node.js versions below 6.0.0 are affected due to a throw added in newer node.js versions.
Proof of Concept:
require('mysql').createConnection({
host: 'localhost',
user: 'user',
password : USERPROVIDEDINPUT, // number
database : 'my_db'
}).connect();
Update to version 2.14.0 or later.