MDL-41820 XSS in the quiz responses report.

Thanks to Michael Hess for finding this bug and reporting it to us.
This commit is contained in:
Tim Hunt 2013-09-17 18:26:53 +01:00 committed by Dan Poltawski
parent f859f6b4e6
commit 78a492330d

View File

@ -97,6 +97,11 @@ class quiz_responses_table extends quiz_attempts_report_table {
$summary = trim($stepdata->$field);
}
if ($this->is_downloading() && $this->is_downloading() != 'xhtml') {
return $summary;
}
$summary = s($summary);
if ($this->is_downloading() || $field != 'responsesummary') {
return $summary;
}