Skip to main content
No exploitation reportedFix available

CVE-2021-33913

No exploitation reported by the sources we read.

  • Published2022-01-19
  • Fixed in1.2.11
  • WeaknessCWE-787

Am I affected?

With a domain, we read the version its public headers and pages expose. A distribution build can carry the fix under an older number.

Description

libspf2 before 1.2.11 has a heap-based buffer overflow that might allow remote attackers to execute arbitrary code (via an unauthenticated e-mail message from anywhere on the Internet) with a crafted SPF DNS record, because of SPF_record_expand_data in spf_expand.c. The amount of overflowed data depends on the relationship between the length of an entire domain name and the length of its leftmost label. The vulnerable code may be part of the supply chain of a site's e-mail infrastructure (e.g., with additional configuration, Exim can use libspf2; the Postfix web site links to unofficial patches for use of libspf2 with Postfix; older versions of spfquery relied on libspf2) but most often is not.

Timeline

dates in UTC
  1. 2022-01-1918:15CVE publishedNVD
  2. 2026-11-1310:34EPSS crossed 10 %FIRST EPSS

Versions per branch

NVD
Libspf2 project libspf2
BranchAffectedFixed in
1.2< 1.2.111.2.11

as publishedRanges as NVD and OSV publish them; a distribution’s build can be fixed under an older number.

Distribution builds and vendor advisories

Packages from OSV.dev and products from the vendors' CSAF advisories.

version not verifiedVersions not verified: read as OSV.dev and the vendors publish them, not checked against each vendor's release list.

Packages

  • libspf2Ubuntu:Pro:18.04:LTSall versions · fixed in 1.2.10-7ubuntu0.18.04.1~esm1
  • libspf2Ubuntu:Pro:16.04:LTSall versions · fixed in 1.2.10-6ubuntu0.1~esm2
  • libspf2Ubuntu:Pro:16.04:LTSall versions · fixed in 1.2.10-6ubuntu0.1~esm1
  • libspf2Ubuntu:20.04:LTSall versions · fixed in 1.2.10-7+deb9u2build0.20.04.1
  • libspf2Debian:14all versions · fixed in 1.2.10-7.1
  • libspf2Debian:13all versions · fixed in 1.2.10-7.1
  • libspf2Debian:12all versions · fixed in 1.2.10-7.1
  • libspf2Debian:9all versions · fixed in 1.2.10-7+deb9u2

13 more package ranges on OSV.dev

Vendor advisories

  • CVE-2021-33913 Red Hat Product Security

    libspf2: heap-based buffer overflow in SPF_record_expand_data in spf_expand.c

Full record on NVD

Fix

  1. Update Libspf2 project libspf2 to 1.2.11

Detection

Nuclei template
none so far
ProjectDiscovery
Exploit-DB
no entry
Exploit-DB
Proof of concept
Metasploit modules
none listed
Metasploit Framework

Sources

Identifiers

Technical details

CVSS v3 vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Published
2022-01-19
Last modified
2026-06-17
NVD status
Modified
GitHub advisory
GHSA-7659-433m-4fhx

Frequently asked questions

What is CVE-2021-33913?

libspf2 before 1.2.11 has a heap-based buffer overflow that might allow remote attackers to execute arbitrary code (via an unauthenticated e-mail message from anywhere on the Internet) with a crafted SPF DNS record, because of SPF_record_expand_data in spf_expand.c. The amount of overflowed data depends on the relationship between the length of an entire domain name and the length of its leftmost label. The vulnerable code may be part of the supply chain of a site's e-mail infrastructure (e.g., with additional configuration, Exim can use libspf2; the Postfix web site links to unofficial patches for use of libspf2 with Postfix; older versions of spfquery relied on libspf2) but most often is not.

Is CVE-2021-33913 actively exploited?

Active exploitation of CVE-2021-33913 has not been confirmed. Its EPSS score was 10.3% on 2026-12-03, the estimated probability of exploitation in the next 30 days.

What is the CVSS score for CVE-2021-33913?

CVE-2021-33913 has a CVSS v3 base score of 9.8 (Critical severity), with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.

Running libspf2? Hear about its next vulnerability

Surveillance reads the versions in your stack — a domain, a lockfile or a list — checks each CVE against the ranges its sources publish, and alerts you when one you run is exploited or enters CISA KEV. A version it cannot read stays « version not verified ».

No credit card required · No monthly cap on website checks · 250 API requests/month

Sources for this record