{"id":"CVE-2025-71274","aliases":["CVE-2025-71274"],"related":[],"kind":"vulnerability","state":"published","title":"rpmsg: core: fix race in driver_override_show() and use core helper","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nrpmsg: core: fix race in driver_override_show() and use core helper\n\nThe driver_override_show function reads the driver_override string\nwithout holding the device_lock. However, the store function modifies\nand frees the string while holding the device_lock. This creates a race\ncondition where the string can be freed by the store function while\nbeing read by the show function, leading to a use-after-free.\n\nTo fix this, replace the rpmsg_string_attr macro with explicit show and\nstore functions. The new driver_override_store uses the standard\ndriver_set_override helper. Since the introduction of\ndriver_set_override, the comments in include/linux/rpmsg.h have stated\nthat this helper must be used to set or clear driver_override, but the\nimplementation was not updated until now.\n\nBecause driver_set_override modifies and frees the string while holding\nthe device_lock, the new driver_override_show now correctly holds the\ndevice_lock during the read operation to prevent the race.\n\nAdditionally, since rpmsg_string_attr has only ever been used for\ndriver_override, removing the macro simplifies the code.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nrpmsg: core: fix race in driver_override_show() and use core helper\n\nThe driver_override_show function reads the driver_override string\nwithout holding the device_lock. However, the store function modifies\nand frees the string while holding the device_lock. This creates a race\ncondition where the string can be freed by the store function while\nbeing read by the show function, leading to a use-after-free.\n\nTo fix this, replace the rpmsg_string_attr macro with explicit show and\nstore functions. The new driver_override_store uses the standard\ndriver_set_override helper. Since the introduction of\ndriver_set_override, the comments in include/linux/rpmsg.h have stated\nthat this helper must be used to set or clear driver_override, but the\nimplementation was not updated until now.\n\nBecause driver_set_override modifies and frees the string while holding\nthe device_lock, the new driver_override_show now correctly holds the\ndevice_lock during the read operation to prevent the race.\n\nAdditionally, since rpmsg_string_attr has only ever been used for\ndriver_override, removing the macro simplifies the code.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nrpmsg: core: corregir condición de carrera en driver_override_show() y usar la función auxiliar del core\n\nLa función driver_override_show lee la cadena driver_override sin mantener el device_lock. Sin embargo, la función store modifica y libera la cadena mientras mantiene el device_lock. Esto crea una condición de carrera donde la cadena puede ser liberada por la función store mientras es leída por la función show, lo que lleva a un uso después de liberación.\n\nPara solucionar esto, reemplace la macro rpmsg_string_attr con funciones show y store explícitas. La nueva driver_override_store utiliza la función auxiliar estándar driver_set_override. Desde la introducción de driver_set_override, los comentarios en include/linux/rpmsg.h han indicado que esta función auxiliar debe ser utilizada para establecer o borrar driver_override, pero la implementación no fue actualizada hasta ahora.\n\nDebido a que driver_set_override modifica y libera la cadena mientras mantiene el device_lock, la nueva driver_override_show ahora mantiene correctamente el device_lock durante la operación de lectura para prevenir la condición de carrera.\n\nAdemás, dado que rpmsg_string_attr solo ha sido utilizada para driver_override, eliminar la macro simplifica el código.","source":"nvd"}],"published":"2026-05-06T11:27:07.525Z","modified":"2026-10-19T19:17:18.423Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H","score":4.7,"rating":"MEDIUM"}],"cwes":["CWE-362"],"affected":[{"ranges":[{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"392c6b68334aa0e0ae9aba95c0a366bcb0d92f5d","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"d66b8074c555e8abb0ae19eea1c9f3635498bdde","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"47615557447185917afa432b7958f87583c417cb","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"90c8353f471821d7ccd4fe573a2402e056192494","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"7654e6e3cd6bdee9602f6063b3c670bd556d7e61","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"2e4a70f3c30910427e5ea848b799066d67b963d5","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"954557957177c3c13d7c655976665b1170da5e50","status":"affected"},{"type":"git","introduced":"39e47767ec9b22f844c2a07c9d329256960d4021","fixed":"42023d4b6d2661a40ee2dcf7e1a3528a35c638ca","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"4.18","status":"affected"},{"type":"semver","introduced":"0","fixed":"4.18","status":"unaffected"},{"type":"semver","introduced":"5.10.252","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.202","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.1.165","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.128","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.75","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.16","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"6.19.6","lastAffected":"6.19.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.0","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"4.18","fixed":"5.10.252"},{"status":"affected","introduced":"5.11","fixed":"5.15.202"},{"status":"affected","introduced":"5.16","fixed":"6.1.165"},{"status":"affected","introduced":"6.2","fixed":"6.6.128"},{"status":"affected","introduced":"6.7","fixed":"6.12.75"},{"status":"affected","introduced":"6.13","fixed":"6.18.16"},{"status":"affected","introduced":"6.19","fixed":"6.19.6"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/392c6b68334aa0e0ae9aba95c0a366bcb0d92f5d","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/d66b8074c555e8abb0ae19eea1c9f3635498bdde","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/47615557447185917afa432b7958f87583c417cb","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/90c8353f471821d7ccd4fe573a2402e056192494","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7654e6e3cd6bdee9602f6063b3c670bd556d7e61","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/2e4a70f3c30910427e5ea848b799066d67b963d5","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/954557957177c3c13d7c655976665b1170da5e50","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/42023d4b6d2661a40ee2dcf7e1a3528a35c638ca","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-10-16T15:06:16.861Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-71274","url":"https://www.cve.org/CVERecord?id=CVE-2025-71274","licence":"CVE Terms of Use","modified":"2026-10-19T18:25:25.313Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-71274","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71274","licence":"Public domain","modified":"2026-10-19T19:17:18.423Z"}],"updatedAt":"2026-11-25T22:59:12.137Z","epss":{"score":0.00126,"percentile":0.01096,"date":"2026-11-29T12:00:22.000Z"}}