WordPress Core < 5.8.3 - SQL Injection via WP_Query

8.0
Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')
CVE CVE-2022-21661
CVSS 8.0 (High)
Publicly Published January 6, 2021
Last Updated July 8, 2022
Researchers ngocnb from GiaoHangTietKiem JSC
khuyenn from GiaoHangTietKiem JSC

Description

WordPress is a free and open-source content management system written in PHP and paired with a MariaDB database. Due to improper sanitization in WP_Query, there can be cases where SQL injection is possible through plugins or themes that use it in a certain way. This has been patched in WordPress version 5.8.3. Older affected versions are also fixed via security release, that go back till 3.7.37. We strongly recommend that you keep auto-updates enabled. There are no known workarounds for this vulnerability.

References

Share

1 affected software package

Software Type Core
Patched? Yes
Remediation Update to one of the following versions, or a newer patched version: 3.7.37, 3.8.37, 3.9.35, 4.0.34, 4.1.34, 4.2.31, 4.3.27, 4.4.26, 4.5.25, 4.6.22, 4.7.22, 4.8.18, 4.9.19, 5.0.15, 5.1.12, 5.2.14, 5.3.11, 5.4.9, 5.5.8, 5.6.7, 5.7.5, 5.8.3
Affected Versions
  • 5.4 - 5.4.9 (exclusive)
  • 5.5 - 5.5.8 (exclusive)
  • 5.6 - 5.6.7 (exclusive)
  • 5.7 - 5.7.5 (exclusive)
Expand to see 18 more affected version ranges.
  • 5.8 - 5.8.3 (exclusive)
  • 3.7 - 3.7.37 (exclusive)
  • 3.8 - 3.8.37 (exclusive)
  • 3.9 - 3.9.35 (exclusive)
  • 4.0 - 4.0.34 (exclusive)
  • 4.1 - 4.1.34 (exclusive)
  • 4.2 - 4.2.31 (exclusive)
  • 4.3 - 4.3.27 (exclusive)
  • 4.4 - 4.4.26 (exclusive)
  • 4.5 - 4.5.25 (exclusive)
  • 4.6 - 4.6.22 (exclusive)
  • 4.7 - 4.7.22 (exclusive)
  • 4.8 - 4.8.18 (exclusive)
  • 4.9 - 4.9.19 (exclusive)
  • 5.0 - 5.0.15 (exclusive)
  • 5.1 - 5.1.12 (exclusive)
  • 5.2 - 5.2.14 (exclusive)
  • 5.3 - 5.3.11 (exclusive)
Patched Versions
  • 3.7.37
  • 3.8.37
  • 3.9.35
  • 4.0.34
Expand to see 18 more patched versions.
  • 4.1.34
  • 4.2.31
  • 4.3.27
  • 4.4.26
  • 4.5.25
  • 4.6.22
  • 4.7.22
  • 4.8.18
  • 4.9.19
  • 5.0.15
  • 5.1.12
  • 5.2.14
  • 5.3.11
  • 5.4.9
  • 5.5.8
  • 5.6.7
  • 5.7.5
  • 5.8.3

Did you know Wordfence Intelligence provides free personal and commercial API access to our comprehensive WordPress vulnerability database, along with a free webhook integration to stay on top of the latest vulnerabilities added and updated in the database? Get started today!

Learn more

Want to get notified of the latest vulnerabilities that may affect your WordPress site?
Install Wordfence on your site today to get notified immediately if your site is affected by a vulnerability that has been added to our database.

Get Wordfence

The Wordfence Intelligence WordPress vulnerability database is completely free to access and query via API. Please review the documentation on how to access and consume the vulnerability data via API.

Documentation