ghsa-pfch-hqrr-v4q4
Vulnerability from github
Published
2025-11-12 12:30
Modified
2025-11-12 12:30
VLAI Severity ?
Details
In the Linux kernel, the following vulnerability has been resolved:
bpf: Reject negative offsets for ALU ops
When verifying BPF programs, the check_alu_op() function validates instructions with ALU operations. The 'offset' field in these instructions is a signed 16-bit integer.
The existing check 'insn->off > 1' was intended to ensure the offset is either 0, or 1 for BPF_MOD/BPF_DIV. However, because 'insn->off' is signed, this check incorrectly accepts all negative values (e.g., -1).
This commit tightens the validation by changing the condition to '(insn->off != 0 && insn->off != 1)'. This ensures that any value other than the explicitly permitted 0 and 1 is rejected, hardening the verifier against malformed BPF programs.
{
"affected": [],
"aliases": [
"CVE-2025-40169"
],
"database_specific": {
"cwe_ids": [],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-11-12T11:15:47Z",
"severity": null
},
"details": "In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Reject negative offsets for ALU ops\n\nWhen verifying BPF programs, the check_alu_op() function validates\ninstructions with ALU operations. The \u0027offset\u0027 field in these\ninstructions is a signed 16-bit integer.\n\nThe existing check \u0027insn-\u003eoff \u003e 1\u0027 was intended to ensure the offset is\neither 0, or 1 for BPF_MOD/BPF_DIV. However, because \u0027insn-\u003eoff\u0027 is\nsigned, this check incorrectly accepts all negative values (e.g., -1).\n\nThis commit tightens the validation by changing the condition to\n\u0027(insn-\u003eoff != 0 \u0026\u0026 insn-\u003eoff != 1)\u0027. This ensures that any value\nother than the explicitly permitted 0 and 1 is rejected, hardening the\nverifier against malformed BPF programs.",
"id": "GHSA-pfch-hqrr-v4q4",
"modified": "2025-11-12T12:30:28Z",
"published": "2025-11-12T12:30:28Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-40169"
},
{
"type": "WEB",
"url": "https://git.kernel.org/stable/c/21167bf70dbe400563e189ac632258d35eda38b5"
},
{
"type": "WEB",
"url": "https://git.kernel.org/stable/c/3bce44b344040e5eef3d64d38b157c15304c0aab"
},
{
"type": "WEB",
"url": "https://git.kernel.org/stable/c/5017c302ca4b2a45149ad64e058fa2d5623c068f"
},
{
"type": "WEB",
"url": "https://git.kernel.org/stable/c/55c0ced59fe17dee34e9dfd5f7be63cbab207758"
}
],
"schema_version": "1.4.0",
"severity": []
}
Loading…
Loading…
Sightings
| Author | Source | Type | Date |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
- Confirmed: The vulnerability is confirmed from an analyst perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
- Patched: This vulnerability was successfully patched by the user reporting the sighting.
- Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
- Not confirmed: The user expresses doubt about the veracity of the vulnerability.
- Not patched: This vulnerability was not successfully patched by the user reporting the sighting.
Loading…
Loading…