{"id":"CVE-2021-21313","aliases":["CVE-2021-21313"],"related":[],"kind":"vulnerability","state":"published","title":"XSS on tabs","summary":"GLPI is open source software which stands for Gestionnaire Libre de Parc Informatique and it is a Free Asset and IT Management Software package. In GLPI before verison 9.5.4, there is a vulnerability in the /ajax/common.tabs.php endpoint, indeed, at least two parameters _target and id are not properly sanitized. Here are two payloads (due to two different exploitations depending on which parameter you act) to exploit the vulnerability:/ajax/common.tabs.php?_target=javascript:alert(document.cookie)&_itemtype=DisplayPreference&_glpi_tab=DisplayPreference$2&id=258&displaytype=Ticket (Payload triggered if you click on the button). /ajax/common.tabs.php?_target=/front/ticket.form.php&_itemtype=Ticket&_glpi_tab=Ticket$1&id=(){};(function%20(){alert(document.cookie);})();function%20a&#.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"GLPI is open source software which stands for Gestionnaire Libre de Parc Informatique and it is a Free Asset and IT Management Software package. In GLPI before verison 9.5.4, there is a vulnerability in the /ajax/common.tabs.php endpoint, indeed, at least two parameters _target and id are not properly sanitized. Here are two payloads (due to two different exploitations depending on which parameter you act) to exploit the vulnerability:/ajax/common.tabs.php?_target=javascript:alert(document.cookie)&_itemtype=DisplayPreference&_glpi_tab=DisplayPreference$2&id=258&displaytype=Ticket (Payload triggered if you click on the button). /ajax/common.tabs.php?_target=/front/ticket.form.php&_itemtype=Ticket&_glpi_tab=Ticket$1&id=(){};(function%20(){alert(document.cookie);})();function%20a&#.","source":"cvelist"},{"lang":"es","text":"GLPI es un software de código abierto que significa Gestionnaire Libre de Parc Informatique y es un paquete gratuito de Software de Gestión de Activos y TI.&#xa0;En GLPI anterior a la versión 9.5.4, existe una vulnerabilidad en el endpoint /ajax/common.tabs.php, de hecho, al menos dos parámetros _target e id no están correctamente saneados.&#xa0;Aquí existen dos cargas útiles (debido a dos explotaciones diferentes según el parámetro que actúe) para explotar la vulnerabilidad: /ajax/common.tabs.php?_target=javascript:alert(document.cookie)&amp; _itemtype=DisplayPreference&amp;_glpi_tab=DisplayPreference$2&amp;id=258&amp;displaytype=Ticket (Carga útil que se activa si hace clic en el botón).&#xa0;/ajax/common.tabs.php?_target=/front/ticket.form.php&amp;_itemtype=Ticket&amp;_glpi_tab=Ticket$1&amp;id=(){}; (function%20(){alert(document.cookie);})(); function%20a&amp;#","source":"nvd"}],"published":"2021-03-03T19:25:13.000Z","modified":"2026-06-17T03:35:16.477Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","score":6.1,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:N/I:P/A:N","score":4.3,"rating":"MEDIUM"}],"cwes":["CWE-74","CWE-79"],"affected":[{"ranges":[{"version":"< 9.5.4","status":"affected"}],"vendor":"glpi-project","product":"glpi","source":"cvelist"},{"ranges":[{"status":"affected","fixed":"9.5.4"}],"vendor":"glpi-project","product":"glpi","cpe":"cpe:2.3:a:glpi-project:glpi:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/glpi-project/glpi/security/advisories/GHSA-h4hj-mrpg-xfgx","tags":["third-party-advisory","x-refsource-confirm","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://github.com/glpi-project/glpi/releases/tag/9.5.4","tags":["release-notes","third-party-advisory","x-refsource-misc","x-transferred"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"GitHub_M","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2021-21313","url":"https://www.cve.org/CVERecord?id=CVE-2021-21313","licence":"CVE Terms of Use","modified":"2024-08-03T18:09:15.301Z"},{"source":"nvd","name":"NVD","id":"CVE-2021-21313","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-21313","licence":"Public domain","modified":"2026-06-17T03:35:16.477Z"}],"updatedAt":"2026-11-25T22:58:00.134Z","epss":{"score":0.0093,"percentile":0.61631,"date":"2026-12-01T12:00:22.000Z"}}