bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer
In the Linux kernel, the following vulnerability has been resolved: bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer In check_alu_op(), the verifier currently calls check_reg_arg() and adjust_scalar_min_max_vals() unconditionally for BPF_NEG operations. However, if the destination register holds a pointer, these scalar adjustments are unnecessary and potentially incorrect. This patch adds a check to skip the adjustment logic when the destination register contains a pointer.
- Products
- Kernel
- Affected versions
- Not specified
- Fixed versions
- 6.17.3
- CVEs
- CVE-2025-40050
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 4 Nov 2026, 11:34 UTC · Revision 1
Source evidence
bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer
core-osv · Original sourcePublished 28 Oct 2025, 11:48 UTC
In the Linux kernel, the following vulnerability has been resolved: bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer In check_alu_op(), the verifier currently calls check_reg_arg() and adjust_scalar_min_max_vals() unconditionally for BPF_NEG operations. However, if the destination register holds a pointer, these scalar adjustments are unnecessary and potentially incorrect. This patch adds a check to skip the adjustment logic when the destination register contains a pointer.
osv:CVE-2025-40050
Kernel
Fixed versions: 6.17.3
Complete source record
{
"id": "c91a4cfda721e375c4fe911b0416db0c1be3ac6e91a9b115740828b81349437f",
"url": "https://osv.dev/vulnerability/CVE-2025-40050",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer",
"summary": "In the Linux kernel, the following vulnerability has been resolved: bpf: Skip scalar adjustment for BPF_NEG if dst is a pointer In check_alu_op(), the verifier currently calls check_reg_arg() and adjust_scalar_min_max_vals() unconditionally for BPF_NEG operations. However, if the destination register holds a pointer, these scalar adjustments are unnecessary and potentially incorrect. This patch adds a check to skip the adjustment logic when the destination register contains a pointer.",
"evidence": "osv:CVE-2025-40050",
"products": [
{
"name": {
"value": "Kernel",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "6.17.3",
"evidence": "/affected/1/ranges"
}
],
"affected_versions": []
}
],
"severity": "unknown",
"structured": {
"id": "CVE-2025-40050",
"aliases": [
"CVE-2025-40050"
],
"affected": [
{
"ranges": [
{
"repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
"type": "GIT",
"events": [
{
"introduced": "aced132599b3c8884c050218d4c48eef203678f6"
},
{
"fixed": "b9ef4963227246b9222e1559ddeec8e7af63e6c6"
},
{
"fixed": "34904582b502a86fdb4d7984b12cacd2faabbe0d"
}
]
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-40050.json"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "6.17.0"
},
{
"fixed": "6.17.3"
}
]
}
],
"package": {
"name": "Kernel",
"ecosystem": "Linux"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-40050.json"
}
}
],
"modified": "2026-10-28T02:30:34.663463028Z",
"provider": "osv",
"references": [
"https://git.kernel.org/stable/c/34904582b502a86fdb4d7984b12cacd2faabbe0d",
"https://git.kernel.org/stable/c/b9ef4963227246b9222e1559ddeec8e7af63e6c6",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/40xxx/CVE-2025-40050.json",
"https://nvd.nist.gov/vuln/detail/CVE-2025-40050",
"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
],
"provider_metadata": {
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/40xxx/CVE-2025-40050.json"
}
},
"related_cves": [
{
"value": "CVE-2025-40050",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": null
},
"source_id": "core-osv",
"document_id": 502065,
"published_at": "2025-10-28T11:48:26.654+00:00"
}