# CVE-2024-31458: Cacti SQL Injection vulnerability in lib/html_form_templates.php by reading dirty data stored in database

- Severity: Medium 4.6 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:L/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 12.6%, higher than 96% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2024-05-13T15:07:08.051Z
- Modified: 2026-06-17T07:28:27.870Z
- Weaknesses: CWE-89
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact total
- Assigned by: GitHub_M

## Description

Cacti provides an operational monitoring and fault management framework. Prior to version 1.2.27, some of the data stored in `form_save()` function in `graph_template_inputs.php` is not thoroughly checked and is used to concatenate the SQL statement in `draw_nontemplated_fields_graph_item()` function from `lib/html_form_templates.php` , finally resulting in SQL injection. Version 1.2.27 contains a patch for the issue.

(As written by CVE List.)

## Affected

- Cacti cacti: < 1.2.27; from - before 1.2.27; before 1.2.27
- fedoraproject fedora: 39

## Every score

- GitHub_M: CVSS:3.1 4.6 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:N/I:L/A:L`
- NVD: CVSS:3.1 8.0 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H`

## References

- <https://github.com/Cacti/cacti/security/advisories/GHSA-jrxg-8wh8-943x> (exploit, vendor-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RBEOAFKRARQHTDIYSL723XAFJ2Q6624X/> (product)
- <https://lists.debian.org/debian-lts-announce/2024/09/msg00027.html>

## Sources

- CVE List: [CVE-2024-31458](https://www.cve.org/CVERecord?id=CVE-2024-31458), CVE Terms of Use, modified 2025-11-04
- NVD: [CVE-2024-31458](https://nvd.nist.gov/vuln/detail/CVE-2024-31458), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-31458 · Whole record: https://cve.day/CVE-2024-31458.json · Rebuilt by cve.day 2026-11-25T22:58:40.138Z
