Skip to content

Commit

Permalink
Fixed issue #07085: Cross Site Scripting (XSS) in printing page
Browse files Browse the repository at this point in the history
Dev: just htmlentities
  • Loading branch information
Shnoulle committed Dec 14, 2012
1 parent 1ddb416 commit df6e77c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions application/controllers/PrintanswersController.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ function actionView($surveyid,$printableexport=FALSE)
}
else
{
$printoutput .= "\t<tr class='printanswersquestionhead'><td colspan='2'>{$fname[0]}</td></tr>\n";
$printoutput .= "\t<tr class='printanswersquestionhead'><td colspan='2'>{$fname[0]}</td></tr>\n";
}
}
elseif ($sFieldname=='submitdate')
Expand All @@ -199,7 +199,7 @@ function actionView($surveyid,$printableexport=FALSE)
}
else
{
$printoutput .= "\t<tr class='printanswersquestion'><td>{$fname[0]} {$fname[1]}</td><td class='printanswersanswertext'>{$fname[2]}</td></tr>";
$printoutput .= "\t<tr class='printanswersquestion'><td>{$fname[0]} {$fname[1]}</td><td class='printanswersanswertext'>".htmlspecialchars($fname[2])."</td></tr>";
}
}
}
Expand Down

0 comments on commit df6e77c

Please sign in to comment.