{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2025-71111","id":"CVE-2025-71111","title":"hwmon: (w83791d) Convert macros to functions to avoid TOCTOU","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nhwmon: (w83791d) Convert macros to functions to avoid TOCTOU\n\nThe macro FAN_FROM_REG evaluates its arguments multiple times. When used\nin lockless contexts involving shared driver data, this leads to\nTime-of-Check to Time-of-Use (TOCTOU) race conditions, potentially\ncausing divide-by-zero errors.\n\nConvert the macro to a static fu","descriptionLong":"In the Linux kernel, the following vulnerability has been resolved:\n\nhwmon: (w83791d) Convert macros to functions to avoid TOCTOU\n\nThe macro FAN_FROM_REG evaluates its arguments multiple times. When used\nin lockless contexts involving shared driver data, this leads to\nTime-of-Check to Time-of-Use (TOCTOU) race conditions, potentially\ncausing divide-by-zero errors.\n\nConvert the macro to a static function. This guarantees that arguments\nare evaluated only once (pass-by-value), preventing the race\nconditions.\n\nAdditionally, in store_fan_div, move the calculation of the minimum\nlimit inside the update lock. This ensures that the read-modify-write\nsequence operates on consistent data.\n\nAdhere to the principle of minimal changes by only converting macros\nthat evaluate arguments multiple times and are used in lockless\ncontexts.","published":"2026-01-14T15:05:58.649Z","updated":"2026-10-28T02:30:43.392137131Z","reserved":"2026-01-13T15:30:19.653Z","status":"Modified","rejected":false,"assigner":"Linux","metric":{"version":"3.1","score":4.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"},"metrics":[{"version":"3.1","score":4.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"}],"rating":"medium","products":["Linux"],"affectedProducts":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"3dceb68f6ad33156032ef4da21a93d84059cca6d","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"bf5b03227f2e6d4360004886d268f9df8993ef8f","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"f2b579a0c37c0df19603d719894a942a295f634a","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"f94800fbc26ccf7c81eb791707b038a57aa39a18","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"a9fb6e8835a22f5796c1182ed612daed3fd273af","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"c8cf0c2bdcccc6634b6915ff793b844e12436680","status":"affected","versionType":"git"},{"version":"9873964d6eb24bd0205394f9b791de9eddbcb855","lessThan":"670d7ef945d3a84683594429aea6ab2cdfa5ceb4","status":"affected","versionType":"git"}],"platforms":[]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"2.6.18","status":"affected"},{"version":"0","lessThan":"2.6.18","status":"unaffected","versionType":"semver"},{"version":"5.10.248","lessThanOrEqual":"5.10.*","status":"unaffected","versionType":"semver"},{"version":"5.15.198","lessThanOrEqual":"5.15.*","status":"unaffected","versionType":"semver"},{"version":"6.1.160","lessThanOrEqual":"6.1.*","status":"unaffected","versionType":"semver"},{"version":"6.6.120","lessThanOrEqual":"6.6.*","status":"unaffected","versionType":"semver"},{"version":"6.12.64","lessThanOrEqual":"6.12.*","status":"unaffected","versionType":"semver"},{"version":"6.18.3","lessThanOrEqual":"6.18.*","status":"unaffected","versionType":"semver"},{"version":"6.19","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}],"platforms":[]}],"packages":[],"cwes":["CWE-362","CWE-367"],"aliases":[],"references":[{"url":"https://git.kernel.org/stable/c/3dceb68f6ad33156032ef4da21a93d84059cca6d","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/bf5b03227f2e6d4360004886d268f9df8993ef8f","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/f2b579a0c37c0df19603d719894a942a295f634a","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/f94800fbc26ccf7c81eb791707b038a57aa39a18","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/a9fb6e8835a22f5796c1182ed612daed3fd273af","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/c8cf0c2bdcccc6634b6915ff793b844e12436680","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/670d7ef945d3a84683594429aea6ab2cdfa5ceb4","tags":["Patch","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/71xxx/CVE-2025-71111.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71111","tags":["advisory"]},{"url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","tags":["package"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial"},"epss":0.00104,"epssPercentile":0.01063,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2025-71111","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71111","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2025-71111","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2025-71111","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}