Skip to content

Commit

Permalink
v2.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
dead-claudia committed Jul 28, 2019
1 parent e58e918 commit 0d10dc2
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -18,7 +18,7 @@ mithril.js [![npm Version](https://img.shields.io/npm/v/mithril.svg)](https://ww

## What is Mithril?

A modern client-side Javascript framework for building Single Page Applications. It's small (<!-- size -->9.77 KB<!-- /size --> gzipped), fast and provides routing and XHR utilities out of the box.
A modern client-side Javascript framework for building Single Page Applications. It's small (<!-- size -->9.78 KB<!-- /size --> gzipped), fast and provides routing and XHR utilities out of the box.

Mithril is used by companies like Vimeo and Nike, and open source platforms like Lichess 👍.

Expand Down
5 changes: 4 additions & 1 deletion docs/change-log.md
@@ -1,5 +1,6 @@
# Change log

- [v2.0.3](#v203)
- [v2.0.1](#v201)
- [v2.0.0](#v200)
- [Migrating from v1.x](migration-v1x.md)
Expand All @@ -18,11 +19,13 @@
-->

### v2.0.2
### v2.0.3

- Ensure vnodes are removed correctly in the face of `onbeforeremove` resolving after new nodes are added ([#2492](https://github.com/MithrilJS/mithril.js/pull/2492) [@isiahmeadows](https://github.com/isiahmeadows))
- Fix prototype pollution vulnerability in `m.parseQueryString` ([#2494](https://github.com/MithrilJS/mithril.js/pull/2494) [@isiahmeadows](https://github.com/isiahmeadows))

*v2.0.2 was skipped as it had a critical flaw and was immediately unpublished.*

### v2.0.1

Same as v2.0.0, but with a publish that didn't have a botched upload.
Expand Down
11 changes: 5 additions & 6 deletions mithril.js
Expand Up @@ -1510,7 +1510,6 @@ var parseQueryString = function(string) {
for (var j0 = 0; j0 < levels.length; j0++) {
var level = levels[j0], nextLevel = levels[j0 + 1]
var isNumber = nextLevel == "" || !isNaN(parseInt(nextLevel, 10))
var isValue = j0 === levels.length - 1
if (level === "") {
var key5 = levels.slice(0, j0).join()
if (counters[key5] == null) {
Expand All @@ -1520,15 +1519,15 @@ var parseQueryString = function(string) {
}
// Disallow direct prototype pollution
else if (level === "__proto__") break
if (isValue) cursor[level] = value2
if (j0 === levels.length - 1) cursor[level] = value2
else {
// Read own properties exclusively to disallow indirect
// prototype pollution
value2 = Object.getOwnPropertyDescriptor(cursor, level)
if (value2 != null) value2 = value2.value
if (value2 == null) value2 = cursor[level] = isNumber ? [] : {}
var desc = Object.getOwnPropertyDescriptor(cursor, level)
if (desc != null) desc = desc.value
if (desc == null) cursor[level] = desc = isNumber ? [] : {}
cursor = desc
}
cursor = value2
}
}
return data0
Expand Down
2 changes: 1 addition & 1 deletion mithril.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "mithril",
"version": "2.0.2",
"version": "2.0.3",
"description": "A framework for building brilliant applications",
"author": "Leo Horie",
"license": "MIT",
Expand Down

0 comments on commit 0d10dc2

Please sign in to comment.