CVE-2025-38162: netfilter: nft_set_pipapo: prevent overflow in lookup table allocation
In the Linux kernel, the following vulnerability has been resolved:
netfilter: nft_set_pipapo: prevent overflow in lookup table allocation
When calculating the lookup table size, ensure the following
multiplication does not overflow:
- desc->field_len[] maximum value is U8_MAX multiplied by
NFT_PIPAPO_GROUPS_PER_BYTE(f) that can be 2, worst case.
- NFT_PIPAPO_BUCKETS(f->bb) is 2^8, worst case.
- sizeof(unsigned long), from sizeof(*f->lt), lt in
struct nft_pipapo_field.
Then, use check_mul_overflow() to multiply by bucket size and then use
check_add_overflow() to the alignment for avx2 (if needed). Finally, add
lt_size_check_overflow() helper and use it to consolidate this.
While at it, replace leftover allocation using the GFP_KERNEL to
GFP_KERNEL_ACCOUNT for consistency, in pipapo_resize().
Security readout for executives and security teams
Plain-English summary
Linux nftables can miscalculate memory needed for a PIPAPO lookup table, potentially allocating too little memory. The supplied assessment rates the issue 7.8/high, with possible confidentiality, integrity, and availability impact. Exploitation requires local access and low privileges; no user interaction is required.
Executive priority
Treat this as a high-priority kernel update for affected systems, especially where untrusted or lower-privileged users have local access. It is less urgent than an unauthenticated remote flaw, but the stated potential impact spans data exposure, modification, and service disruption.
Technical view
CVE-2025-38162 is an integer-overflow flaw in nft_set_pipapo lookup-table sizing. Multiplication involving field length, grouping, bucket count, and element size can overflow before allocation; AVX2 alignment addition also requires checking. Stable fixes introduce multiplication and addition overflow checks through a consolidated helper.
Likely exposure
Exposure is limited to affected Linux kernels where the netfilter nftables PIPAPO allocation path is reachable. The supplied version data names releases from 5.6 through several later stable branches, but its formatting is insufficient for precise range determination. Confirm status through distribution or appliance-vendor advisories and backport records.
Exploitation context
The CVSS vector describes local, low-complexity exploitation requiring low privileges and no user interaction. CISA KEV status is false, and the supplied sources provide no evidence of active exploitation or a public exploit. Absence from KEV does not establish that exploitation is impossible.
Researcher notes
The record does not provide a CWE, demonstrated crash, exploit primitive, or confirmed attack activity. Its affected-version presentation includes repeated commit identifiers and ambiguous release entries, so version-only conclusions are unreliable. Validate fixes by vendor package provenance or applicable stable commit, not solely the displayed kernel version.
Mitigation direction
Apply a vendor-supported kernel update containing the applicable stable fix for CVE-2025-38162.
Check distribution and appliance-vendor advisories for branch-specific fixed packages and reboot requirements.
If updating is delayed, follow vendor-approved mitigations; none are specified in the supplied sources.
Validation and detection
Inventory running kernel versions across Linux hosts, appliances, virtual machines, and managed images.
Compare package changelogs or source provenance against the referenced stable fixes, accounting for vendor backports.
Confirm updated kernels are running after required reboots, rather than merely installed.
Determine whether affected systems use nftables PIPAPO sets to refine remediation priority.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2025-38162 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
8Source links
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.