Search CVEs and advisories

Search CVEs and Linux security advisories by vendor, product, package, or severity, and see which vulnerabilities each advisory addresses.

CVE

CVE-2022-29221

published high CVSS 3.1 · 8.8

PHP Code Injection by malicious block or filename in Smarty

Published
24 May 2022, 00:00:00 UTC
Updated
23 Apr 2025, 18:22:54 UTC
Language
en

Package status and fixes

Distro / vendorReleasePackage / productPublisher statusFixed buildSource
smarty-php — smarty< 3.1.45 · >= 4.0.0, < 4.1.1 Affected Not stated GitHub_M
Debian bullseye smarty3 Advisory build 3.1.39-2+deb11u1 DSA-5151-1
Ubuntu bionic postfixadmin Advisory build 3.0.2-2ubuntu0.1~esm1 USN-6550-1
Debian buster smarty3 Advisory build 3.1.33+20180830.1.3a78a21f+selfpack1-1+deb10u1 DSA-5151-1
Debian stretch smarty3 Advisory build 3.1.31+20161214.1.c7d42e4+selfpack1-2+deb9u6 DLA-3033-1
Ubuntu focal postfixadmin Advisory build 3.2.1-3ubuntu0.1~esm1 USN-6550-1
Ubuntu jammy postfixadmin Advisory build 3.3.10-2ubuntu0.1~esm1 USN-6550-1
Ubuntu jammy smarty3 Advisory build 3.1.39-2ubuntu1.22.04.1 USN-6012-1

Description

Smarty is a template engine for PHP, facilitating the separation of presentation (HTML/CSS) from application logic. Prior to versions 3.1.45 and 4.1.1, template authors could inject php code by choosing a malicious {block} name or {include} file name. Sites that cannot fully trust template authors should upgrade to versions 3.1.45 or 4.1.1 to receive a patch for this issue. There are currently no known workarounds.

en · GitHub_M · cna

Vendor advisories explicitly linked to this CVE.

7

Assessment

CVSS risk assessment and additional context for this vulnerability.

CVSS version
3.1
Base score
8.8 / 10
Severity
high
Provider
GitHub_M · cna
Vector string
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Publisher product statements

Version ranges and default statuses as reported by each provider.

Affected vendor and product assertions
VendorProductVersion statusSource
smarty-php smarty < 3.1.45 (affected)>= 4.0.0, < 4.1.1 (affected) GitHub_M · cna

Weaknesses

1
  • CWE-94 CWE-94: Improper Control of Generation of Code ('Code Injection') (GitHub_M · cna)

References

9

Provider assertions

3

GitHub_M · cna

PHP Code Injection by malicious block or filename in Smarty

CISA-ADP · adp

CISA ADP Vulnrichment

CVE · adp

CVE Program Container

Provenance

Schema
5.1
Searchable
yes
Content hash
58e60f841a275d696a5a1125c3aea95d6546ab29b5dcef988361c3d7e8f9a474
Ingested
23 Sep 2026, 07:59:45 UTC
Source record
Official CVE record

Search filters

Match options apply to free text. CVE words match tokens; use contains:"…" for literal substrings.

Text

Words and phrases
buffer overflow "remote code execution"
Word prefix
auth*
Literal substring (title or description)
contains:"use-after-free"
Exclude a term or filter
-test -vendor:example

Affected product

Vendor
vendor:Example
Product
product:"Demo Widget"

Severity and score

Severity · none, low, medium, high, critical, unknown
severity:critical
CWE identifier
cwe:CWE-863
CVSS score (0–10)
cvss:>=7.0

Dates and status

Published date · comparisons, relative days
published:>=2026-01-01
Updated date · comparisons, relative days
updated:<30d
Status · published (default), rejected, unknown
status:rejected