Skip to content

Commit

Permalink
Merge branch 'j433866-xss_fixes'
Browse files Browse the repository at this point in the history
  • Loading branch information
n1474335 committed Feb 8, 2019
2 parents d54d66c + 821bc94 commit 310ff30
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/core/operations/ToTable.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class ToTable extends Operation {
const [cellDelims, rowDelims, firstRowHeader, format] = args;

// Process the input into a nested array of elements.
const tableData = Utils.parseCSV(input, cellDelims.split(""), rowDelims.split(""));
const tableData = Utils.parseCSV(Utils.escapeHtml(input), cellDelims.split(""), rowDelims.split(""));

if (!tableData.length) return "";

Expand Down
2 changes: 1 addition & 1 deletion src/web/OutputWaiter.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ class OutputWaiter {
*/
showMagicButton(opSequence, result, recipeConfig) {
const magicButton = document.getElementById("magic");
magicButton.setAttribute("data-original-title", `<i>${opSequence}</i> will produce <span class="data-text">"${Utils.truncate(result, 30)}"</span>`);
magicButton.setAttribute("data-original-title", `<i>${opSequence}</i> will produce <span class="data-text">"${Utils.escapeHtml(Utils.truncate(result), 30)}"</span>`);
magicButton.setAttribute("data-recipe", JSON.stringify(recipeConfig), null, "");
magicButton.classList.remove("hidden");
}
Expand Down

0 comments on commit 310ff30

Please sign in to comment.