From 820b81d25685f5d1d1810beb566740ed02fbdbb9 Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Fri, 10 Jul 2020 11:45:05 +0200 Subject: [PATCH] Fix security breach --- src/helpers/SurveyHelper.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/helpers/SurveyHelper.ts b/src/helpers/SurveyHelper.ts index 56f376f..f1ddfa3 100644 --- a/src/helpers/SurveyHelper.ts +++ b/src/helpers/SurveyHelper.ts @@ -3,6 +3,7 @@ import { DatabaseHelper, JoinType } from "./DatabaseHelper"; import { NewSurvey } from "../entities/NewSurvey"; import { mysql_date } from "../utils/DateUtils"; import { SurveyResponse } from "../entities/SurveyResponse"; +import { removeHTMLNodes } from "../utils/StringUtils"; /** * Survey helper @@ -67,7 +68,7 @@ export class SurveyHelper { await DatabaseHelper.InsertRow(SURVEY_CHOICES_TABLE, { ID_sondage: surveyID, date_creation: mysql_date(), - Choix: choice + Choix: removeHTMLNodes(choice) }); }