# CVE-2023-28447: Cross site scripting vulnerability in Javascript escaping in smarty/smarty

- Severity: High 7.1 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/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): 1.02%, higher than 64% of CVEs (2026-12-02)
- Published: 2023-03-28T20:07:39.103Z
- Modified: 2026-06-17T05:47:45.520Z
- Also known as: GHSA-7j98-h7fp-4vwj
- Weaknesses: CWE-79
- Assigned by: GitHub_M

## Description

Smarty is a template engine for PHP. In affected versions smarty did not properly escape javascript code. An attacker could exploit this vulnerability to execute arbitrary JavaScript code in the context of the user's browser session. This may lead to unauthorized access to sensitive user data, manipulation of the web application's behavior, or unauthorized actions performed on behalf of the user. Users are advised to upgrade to either version 3.1.48 or to 4.3.1 to resolve this issue. There are no known workarounds for this vulnerability.

(As written by CVE List.)

## Affected

- smarty-php smarty: >= 4.0.0, < 4.3.1; < 3.1.48
- smarty/smarty (Packagist): from 4.0.0 before 4.3.1; before 3.1.48
- smarty smarty: before 3.1.48; from 4.0.0 before 4.3.1
- fedoraproject fedora: 36; 37; 38

## Every score

- GitHub_M: CVSS:3.1 7.1 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:L`
- GitHub: CVSS:3.1 7.1 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:L`
- NVD: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/smarty-php/smarty/security/advisories/GHSA-7j98-h7fp-4vwj> (third-party-advisory, web)
- <https://github.com/smarty-php/smarty/commit/685662466f653597428966d75a661073104d713d> (patch, web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/HSAUM3YHWHO4UCJXRGRLQGPJAO3MFOZZ/> (mailing-list, third-party-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/JBB35GLYTL6JL6EOM6BOZNYP47JKNNHT/> (mailing-list, third-party-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/P7O7SKTATM6GAP45S64QFXNLWIY5I7HP/> (mailing-list, third-party-advisory)
- <https://lists.debian.org/debian-lts-announce/2024/11/msg00013.html> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2023-28447> (advisory)
- <https://github.com/FriendsOfPHP/security-advisories/blob/master/smarty/smarty/CVE-2023-28447.yaml> (web)
- <https://github.com/smarty-php/smarty> (package)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/HSAUM3YHWHO4UCJXRGRLQGPJAO3MFOZZ> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/JBB35GLYTL6JL6EOM6BOZNYP47JKNNHT> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/P7O7SKTATM6GAP45S64QFXNLWIY5I7HP> (web)

## Sources

- CVE List: [CVE-2023-28447](https://www.cve.org/CVERecord?id=CVE-2023-28447), CVE Terms of Use, modified 2025-11-03
- GitHub Advisory Database: [GHSA-7j98-h7fp-4vwj](https://github.com/advisories/GHSA-7j98-h7fp-4vwj), CC-BY-4.0, modified 2025-11-04
- NVD: [CVE-2023-28447](https://nvd.nist.gov/vuln/detail/CVE-2023-28447), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2023-28447 · Whole record: https://cve.day/CVE-2023-28447.json · Rebuilt by cve.day 2026-11-25T22:58:22.759Z
