Skip to content

Commit

Permalink
[CVE-2018-8177] Edge - Speculative type confusion on PropertyString
Browse files Browse the repository at this point in the history
Re-order PropertyString poisoning code
  • Loading branch information
sethbrenith authored and MSLaguana committed May 8, 2018
1 parent 23848b1 commit eb4b00b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/Backend/Lower.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15260,13 +15260,14 @@ Lowerer::GenerateFastElemIStringIndexCommon(IR::Instr * instrInsert, bool isStor
IR::IndirOpnd::New(indexOpnd, 0, TyMachPtr, m_func),
LoadVTableValueOpnd(instrInsert, VTableValue::VtablePropertyString),
Js::OpCode::BrNeq_A, notPropStrLabel, instrInsert);
InsertBranch(Js::OpCode::Br, propStrLoadedLabel, instrInsert);

if (!isStore)
{
InsertObjectPoison(indexOpnd, branchInstr, instrInsert);
}

InsertBranch(Js::OpCode::Br, propStrLoadedLabel, instrInsert);

instrInsert->InsertBefore(notPropStrLabel);

branchInstr = InsertCompareBranch(
Expand Down

0 comments on commit eb4b00b

Please sign in to comment.