Entreprise d'experts en Sécurité Informatique : Audits et conseils en cybersécurité
Entreprise française de cybersécurité depuis 2004
☎ 03 60 47 09 81 - info@securiteinfo.com


CVE-2025-38027

Description

In the Linux kernel, the following vulnerability has been resolved:regulator: max20086: fix invalid memory accessmax20086_parse_regulators_dt() calls of_regulator_match() using anarray of struct of_regulator_match allocated on the stack for thematches argument.of_regulator_match() calls devm_of_regulator_put_matches(), which callsdevres_alloc() to allocate a struct devm_of_regulator_matches which willbe de-allocated using devm_of_regulator_put_matches().struct devm_of_regulator_matches is populated with the stack allocatedmatches array.If the device fails to probe, devm_of_regulator_put_matches() will becalled and will try to call of_node_put() on that stack pointer,generating the following dmesg entries:max20086 6-0028: Failed to read DEVICE_ID reg: -121kobject: '\xc0$\xa5\x03' (000000002cebcb7a): is not initialized, yetkobject_put() is being called.Followed by a stack trace matching the call flow described above.Switch to allocating the matches array using devm_kcalloc() toavoid accessing the stack pointer long after it's out of scope.This also has the advantage of allowing multiple max20086 to probewithout overriding the data stored inside the global of_regulator_match.

POC

Reference

No PoCs from references.

Github

- https://github.com/w4zu/Debian_security