Headline
CVE-2022-35945: Escape GLPI-Network registration information · glpi-project/glpi@2b8f9aa
GLPI stands for Gestionnaire Libre de Parc Informatique and is a Free Asset and IT Management Software package, that provides ITIL Service Desk features, licenses tracking and software auditing. Information associated to registration key are not properly escaped in registration key configuration page. They can be used to steal a GLPI administrator cookie. Users are advised to upgrade to 10.0.3. There are no known workarounds for this issue. ### Workarounds Do not use a registration key created by an untrusted person.
@@ -33,6 +33,7 @@
* ---------------------------------------------------------------------
*/
use Glpi\Toolbox\Sanitizer;
use Glpi\Toolbox\VersionParser;
class GLPINetwork extends CommonGLPI
@@ -105,20 +106,20 @@ public static function showForConfig()
echo "<td>";
echo "<div class=’ " . (($informations[‘is_valid’] && $informations[‘subscription’][‘is_running’] ?? false) ? ‘ok’ : ‘red’) . "’> ";
echo "<i class=’fa fa-info-circle’></i>";
echo $informations[‘validation_message’];
echo Sanitizer::encodeHtmlSpecialChars($informations[‘validation_message’]);
echo "</div>";
echo "</td>";
echo "</tr>";
}
echo "<tr class=’tab_bg_2’>";
echo “<td>” . __(‘Subscription’) . "</td>";
echo “<td>” . ($informations[‘subscription’] !== null ? $informations[‘subscription’][‘title’] : __(‘Unknown’)) . "</td>";
echo “<td>” . ($informations[‘subscription’] !== null ? Sanitizer::encodeHtmlSpecialChars($informations[‘subscription’][‘title’]) : __(‘Unknown’)) . "</td>";
echo "</tr>";
echo "<tr class=’tab_bg_2’>";
echo “<td>” . __(‘Registered by’) . "</td>";
echo “<td>” . ($informations[‘owner’] !== null ? $informations[‘owner’][‘name’] : __(‘Unknown’)) . "</td>";
echo “<td>” . ($informations[‘owner’] !== null ? Sanitizer::encodeHtmlSpecialChars($informations[‘owner’][‘name’]) : __(‘Unknown’)) . "</td>";
echo "</tr>";
}