已合并
remote: Fix integer overflow in RPC handler for virNodeGetFreePages (CVE-2026-18917) #445
remote: Fix integer overflow in RPC handler for virNodeGetFreePages (CVE-2026-18917) #445
已合并
hanzhibian创建于 27 天前
hanzhibian
27 天前

一、漏洞信息
漏洞编号:CVE-2026-18917
漏洞归属组件:libvirt
漏洞归属的版本:6.2.0,9.10.0
CVSS评分:
BaseScore:7.8 High
Vector:CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
漏洞简述:
A flaw was found in libvirt. An unprivileged local user could exploit an integer overflow vulnerability in the NodeGetFreePages RPC handler. This flaw allows crafted values to bypass a size check, leading to an undersized memory buffer. Subsequently, real NUMA node data can overwrite this buffer. This heap buffer overflow can corrupt the root libvirt daemon s memory, potentially leading to a denial of service or local privilege escalation.
漏洞公开时间:2026-08-20 18:16:40
漏洞创建时间:2026-08-20 20:07:14
漏洞详情参考链接:
https://nvd.nist.gov/vuln/detail/CVE-2026-18917

更多参考(点击展开)
漏洞分析指导链接:
https://atomgit.com/openeuler/cve-manager/blob/master/cve-vulner-manager/doc/md/manual.md
漏洞数据来源:
七彩瞬析开源风险感知平台
漏洞补丁信息:

详情(点击展开)
二、漏洞分析结构反馈
影响性分析说明:
A flaw was found in libvirt. An unprivileged local user could exploit an integer overflow vulnerability in the NodeGetFreePages RPC handler. This flaw allows crafted values to bypass a size check, leading to an undersized memory buffer. Subsequently, real NUMA node data can overwrite this buffer. This heap buffer overflow can corrupt the root libvirt daemon s memory, potentially leading to a denial of service or local privilege escalation.
openEuler评分:
7.8
Vector:CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
受影响版本排查(受影响/不受影响):
1.master(9.10.0):受影响
2.openEuler-20.03-LTS-SP4(6.2.0):受影响
3.openEuler-22.03-LTS-SP4(6.2.0):受影响
4.openEuler-24.03-LTS-Next(9.10.0):受影响
5.openEuler-24.03-LTS-SP1(9.10.0):受影响
6.openEuler-24.03-LTS-SP3(9.10.0):受影响
7.openEuler-24.03-LTS-SP4(9.10.0):受影响

修复是否涉及abi变化(是/否):
1.master(9.10.0):否
2.openEuler-20.03-LTS-SP4(6.2.0):否
3.openEuler-22.03-LTS-SP4(6.2.0):否
4.openEuler-24.03-LTS-Next(9.10.0):否
5.openEuler-24.03-LTS-SP1(9.10.0):否
6.openEuler-24.03-LTS-SP3(9.10.0):否
7.openEuler-24.03-LTS-SP4(9.10.0):否

原因说明:
1.master(9.10.0):正常修复
2.openEuler-20.03-LTS-SP4(6.2.0):正常修复
3.openEuler-22.03-LTS-SP4(6.2.0):正常修复
4.openEuler-24.03-LTS-Next(9.10.0):正常修复
5.openEuler-24.03-LTS-SP1(9.10.0):正常修复
6.openEuler-24.03-LTS-SP3(9.10.0):正常修复
7.openEuler-24.03-LTS-SP4(9.10.0):正常修复

likedislike
Pull Request已成功合入, 合并人@openeuler-ci-bot
(感谢 hanzhibian 的贡献)
Hhanzhibian
27 天前 创建了 pull request,commit 0aa81a2e
atomgit-bot
atomgit-bot
27 天前 评论:

变更摘要

本 PR 修复 libvirt 中 virNodeGetFreePages 的 RPC 处理器 remoteDispatchNodeGetFreePagessrc/remote/remote_daemon_dispatch.c)存在的整数溢出漏洞(CVE-2026-18917)。原实现对 args->pages.pages_lenargs->cellCount 相乘后再与 REMOTE_NODE_MAX_CELLS 比较,攻击者可构造极值使乘法结果溢出从而绕过大小检查,导致分配过小的缓冲区并触发堆溢出。本改动在乘法前使用 VIR_INT_MULTIPLY_OVERFLOW 检测溢出,并在溢出或结果超限时直接报错返回,同时优化了错误提示信息。

主要改动

  • 新增整数溢出检测:将原先仅判断乘积是否大于 REMOTE_NODE_MAX_CELLS 的条件,改为先通过 VIR_INT_MULTIPLY_OVERFLOW(args->pages.pages_len, args->cellCount) 检测乘法溢出,杜绝利用溢出绕过大小校验的可能。
  • 保留结果上限校验:在溢出检测通过后,仍校验 args->pages.pages_len * args->cellCount > REMOTE_NODE_MAX_CELLS,确保分配缓冲区的大小不超过上限。
  • 完善错误信息:更新报错文案为 "npages * cellcount > REMOTE_NODE_MAX_CELLS (%1$u)",通过 %1$u 输出 REMOTE_NODE_MAX_CELLS 的实际数值,便于定位问题,同时移除原 /* Allocate return buffer. */ 注释。
likedislike
不准确?
atomgit-bot
atomgit-bot
27 天前 评论:

代码审查

✅ 未发现问题

likedislike
不准确?
openeuler-ci-botopeneuler-ci-bot成员
27 天前 将Chuan-Zheng,kevinzhu1,imxcc,cellfaint,flyking001,RootWB设为审查人
openeuler-ci-botopeneuler-ci-bot成员
27 天前 添加了label:sig/Virt
openeuler-ci-bot
openeuler-ci-bot成员
27 天前 评论:

Welcome To openEuler Community

Hey @hanzhibian , thanks for your contribution to the community.

Bot Usage Manual

I'm the Bot here serving you. You can find the instructions on how to interact with me at Here . That means you can comment below every pull request or issue to trigger Bot Commands. You can self-configure the PR merge rules for this repository. For more details, please refer to Here.

Contact Guide

If you have any questions, please contact the SIG: Virt ,
and any of the maintainers: @Chuan-Zheng, @RootWB, @cellfaint, @flyking001, @imxcc, @kevinzhu1 ,
and any of the committers: @eillon, @huang987246510, @mdsc, @yebiaoxiang, @zhangliang5 .

likedislike
openeuler-ci-botopeneuler-ci-bot成员
27 天前 添加了label:openeuler-cla/no
openeuler-ci-botopeneuler-ci-bot成员
27 天前 添加了label:ci_processing
openeuler-ci-bot
openeuler-ci-bot成员
27 天前 评论:

门禁正在运行, 您可以通过以下链接查看实时门禁检查结果.
若您对门禁结果含义不清晰或者遇到问题不知如何解决,可参考门禁指导手册
门禁入口及编码规范检查: multiarch/openeuler/trigger/libvirt/113/console

likedislike
openeuler-ci-botopeneuler-ci-bot成员
27 天前 删除了label:ci_processing
openeuler-ci-bot
openeuler-ci-bot成员
27 天前 评论:
Check Name Build Result 详情 Build Details
check_sca WARNING • SCA检查发现未确认的开源组件问题,请查看报告: https://www.openlibing.com/apps/personalScandTaskInfor/person/37388b5c-d28c-4526-a93d-f4c69e132f30?projectId=300024&codeHostingPlatformFlag=gitcode #113
check_code SUCCESS
check_package_license SUCCESS
x86_64 check_build SUCCESS #104
aarch64 check_build SUCCESS #113
likedislike
openeuler-ci-botopeneuler-ci-bot成员
27 天前 添加了label:ci_successful
openeuler-ci-bot
openeuler-ci-bot成员
27 天前 评论:
likedislike
Hhanzhibian
27 天前 关闭了 pull request
Hhanzhibian
27 天前 重新打开了 pull request
Hhanzhibian
27 天前 update merge request[project id:7678739, iid:445, commit_id:4b2ba68ba4c430ca262677e0891c2f3d4ea04f82], virtual merging success
hanzhibian
26 天前 评论:

/check-cla

likedislike
Hhanzhibian
26 天前 关闭了 pull request
Hhanzhibian
26 天前 重新打开了 pull request
Hhanzhibian
26 天前 update merge request[project id:7678739, iid:445, commit_id:a9b2ecd8cf75443e68f1b4616ddcf83d94c230a4], virtual merging success
Hhanzhibian
26 天前 预合并成功(commit_id: 5eeb9eef3effb0c52b81cba4e55223ff3ad6f265)
Hhanzhibian
26 天前 强制推送  1 个提交:816fc2ea-remote: Fix integer overflow in RPC handler for virNodeGetFreePages (CVE-2026-18917)
Hhanzhibian
26 天前 预合并成功(commit_id: df41d57023dac148fcdee7f1577943f2cc7f49f6)
hanzhibian
26 天前 评论:

/check-cla

likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 删除了label:openeuler-cla/no
openeuler-ci-botopeneuler-ci-bot成员
26 天前 删除了label:ci_successful
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:

Notification

This pull request has been changed(code update) or closed, so removes the following label(s): ci_successful.

likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 添加了label:openeuler-cla/yes
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:

CLA Signature Pass

hanzhibian, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 添加了label:ci_processing
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:

门禁正在运行, 您可以通过以下链接查看实时门禁检查结果.
若您对门禁结果含义不清晰或者遇到问题不知如何解决,可参考门禁指导手册
门禁入口及编码规范检查: multiarch/openeuler/trigger/libvirt/128/console

likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 删除了label:ci_processing
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:
Check Name Build Result 详情 Build Details
check_sca WARNING • SCA检查发现未确认的开源组件问题,请查看报告: https://www.openlibing.com/apps/personalScandTaskInfor/person/5c603e3d-8de4-4095-940b-a7316582da39?projectId=300024&codeHostingPlatformFlag=gitcode #128
check_code SUCCESS
check_package_license SUCCESS
x86_64 check_build SUCCESS #119
aarch64 check_build SUCCESS #128
likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 添加了label:ci_successful
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:
likedislike
fd24677成员
26 天前 评论:

/lgtm

likedislike
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:

Label Command Feedback

  • Thanks for your review, your opinion is very important to us. The maintainers will consider your advice carefully.
  • The label(s) lgtm permission is outside.
likedislike
mdsc成员
26 天前 评论:

/lgtm
/approve

likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 添加了label:approvedlgtm
openeuler-ci-bot
openeuler-ci-bot成员
26 天前 评论:

Review Code Feedback

  • The label lgtm, approved was added to this pull request. It means that mdsc reviewed the code changes. 👋
Tips
  • If this pull request is not merged while all conditions are met, comment /check-pr to try again. 😄
likedislike
openeuler-ci-botopeneuler-ci-bot成员
26 天前 合入了pull request,合并节点 SHA:74496201e67059ea41cabf4e823f1c47cf7d907e