# CVE-2025-1040: Server-Side Template Injection (SSTI) in significant-gravitas/autogpt

- Severity: High 8.8 (CVSS:3.0, scored by @huntr_ai) `CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- 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): 1.75%, higher than 78% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2025-03-20T10:11:05.749Z
- Modified: 2026-06-17T08:38:16.633Z
- Weaknesses: CWE-1336
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: @huntr_ai

## Description

AutoGPT versions 0.3.4 and earlier are vulnerable to a Server-Side Template Injection (SSTI) that could lead to Remote Code Execution (RCE). The vulnerability arises from the improper handling of user-supplied format strings in the `AgentOutputBlock` implementation, where malicious input is passed to the Jinja2 templating engine without adequate security measures. Attackers can exploit this flaw to execute arbitrary commands on the host system. The issue is fixed in version 0.4.0.

(As written by CVE List.)

## Affected

- significant-gravitas significant-gravitas/autogpt: from unspecified before v0.4.0
- agpt autogpt_platform: before 0.4.0

## Every score

- @huntr_ai: CVSS:3.0 8.8 High `CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://huntr.com/bounties/b74ef75f-61d5-4422-ab15-9550c8b4f185> (exploit)
- <https://github.com/significant-gravitas/autogpt/commit/6dba31e0215549604bdcc1aed24e3a1714e75ee2> (patch)

## Sources

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

---

Page: https://cve.day/CVE-2025-1040 · Whole record: https://cve.day/CVE-2025-1040.json · Rebuilt by cve.day 2026-11-25T22:58:55.381Z
