CVE-2026-64458

Source
https://cve.org/CVERecord?id=CVE-2026-64458
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64458.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-64458
Downstream
Published
2026-07-25T08:51:26.072Z
Modified
2026-07-27T04:03:20.032052637Z
Summary
mm/damon/ops-common: handle extreme intervals in damon_hot_score()
Details

In the Linux kernel, the following vulnerability has been resolved:

mm/damon/ops-common: handle extreme intervals in damonhotscore()

Fix three issues in damonhotscore() that comes from wrong handling of extreme (zero or too high) monitoring intervals user setup.

When the user sets sampling interval zero, damonmaxnraccesses(), which is called from damonhot_score(), causes a divide-by-zero. Needless to say, it is a problem.

When the user sets the aggregation interval zero, the function returns zero. It is wrong, since the real maximum nracceses in the setup should be one. Worse yet, it can cause another divide-by-zero from its caller, damonhotscore(), since it uses damonmaxnraccesses() return value as a denominator.

When the user sets the aggregation interval very high, damonhotscore() could return a value out of [0, DAMOSMAXSCORE] range. Since the return value is used as an index to the regionsscorehistogram array, which is DAMOSMAXSCORE+1 size, it causes out of bounds array access.

The issues can be relatively easily reproduced like below. The sysfs write permission is required, though.

# ./damo start --damos_action lru_prio --damos_quota_space 100M \
        --damos_quota_interval 1s
# cd /sys/kernel/mm/damon/admin/kdamonds/0
# echo 0 > contexts/0/monitoring_attrs/intervals/sample_us
# echo 0 > contexts/0/monitoring_attrs/intervals/aggr_us
# echo commit > state
# dmesg
[...]
[  131.329762] Oops: divide error: 0000 [#1] SMP NOPTI
[...]
[  131.336089] RIP: 0010:damon_hot_score+0x27/0xd0
[...]

Fix the divide-by-zero intervals problems by explicitly handling the zero intervals in damonmaxnraccesses(). Fix the out-of-bound array access by applying [0, DAMOSMAXSCORE] bounds before returning from damonhot_score().

The issue was discovered [1] by Sashiko.

Database specific
{
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/64xxx/CVE-2026-64458.json",
    "cna_assigner": "Linux"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
198f0f4c58b9f481e4e51c8c70a6ab9852bbab7f
Fixed
58321b4e6e4f0f412069ab27ccdd56292757343a
Fixed
74fef68d521150281e36cdaa20e9e1ee3e3aa146
Fixed
ef2ae10a4582bc92b7e944181bbd2f87f3d30f3a
Fixed
9c8f31eaae6140ecadec0c07320498a944556de2
Fixed
76e415ea88d20f022ed5cfcf78c50e156a267e91
Fixed
35d4a3cf70a855b50e53189ac2f8463e20a02046

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64458.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
5.16.0
Fixed
6.1.178
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.6.145
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.12.96
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.18.39
Type
ECOSYSTEM
Events
Introduced
6.19.0
Fixed
7.1.4

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-64458.json"