Headline
CVE-2023-32066: Addressed stored XSS vulnerability in week.php by escaping cell title. · anuko/timetracker@093cfe1
Time Tracker is an open source time tracking system. The week view plugin in Time Tracker versions 1.22.11.5782 and prior was not escaping titles for notes in week view table. Because of that, it was possible for a logged in user to enter notes with elements of JavaScript. Such script could then be executed in user browser on subsequent requests to week view. This issue is fixed in version 1.22.12.5783. As a workaround, use htmlspecialchars
when calling $field->setTitle
on line #245 in the week.php
file, as happens in version 1.22.12.5783.
Expand Up @@ -242,7 +242,7 @@ function render(&$table, $value, $row, $column, $selected = false) { $field->setValue($table->getValueAt($row,$column)[‘duration’]); // Duration for even rows. } else { $field->setValue($table->getValueAt($row,$column)[‘note’]); // Comment for odd rows. $field->setTitle($table->getValueAt($row,$column)[‘note’]); // Tooltip to help view the entire comment. $field->setTitle(htmlspecialchars($table->getValueAt($row,$column)[‘note’])); // Tooltip to help view the entire comment. } } else { $field->setValue($table->getValueAt($row,$column)[‘duration’]); Expand Down