Skip to content

Commit

Permalink
[CVE-2017-0010] asm.js return object with no properties should not va…
Browse files Browse the repository at this point in the history
…lidate
  • Loading branch information
MikeHolman committed Mar 16, 2017
1 parent 70e23dc commit f1a8c50
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/Runtime/Language/AsmJs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -965,6 +965,10 @@ namespace Js
}

ParseNode* objectElement = ParserWrapper::GetUnaryNode(objNode);
if (!objectElement)
{
return m.Fail(node, _u("Return object must not be empty"));
}
while( objectElement )
{
ParseNode* member = nullptr;
Expand Down

0 comments on commit f1a8c50

Please sign in to comment.