{"id":"CVE-2022-50474","aliases":["CVE-2022-50474"],"related":[],"kind":"vulnerability","state":"published","title":"macintosh: fix possible memory leak in macio_add_one_device()","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nmacintosh: fix possible memory leak in macio_add_one_device()\n\nAfer commit 1fa5ae857bb1 (\"driver core: get rid of struct device's\nbus_id string array\"), the name of device is allocated dynamically. It\nneeds to be freed when of_device_register() fails. Call put_device() to\ngive up the reference that's taken in device_initialize(), so that it\ncan be freed in kobject_cleanup() when the refcount hits 0.\n\nmacio device is freed in macio_release_dev(), so the kfree() can be\nremoved.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nmacintosh: fix possible memory leak in macio_add_one_device()\n\nAfer commit 1fa5ae857bb1 (\"driver core: get rid of struct device's\nbus_id string array\"), the name of device is allocated dynamically. It\nneeds to be freed when of_device_register() fails. Call put_device() to\ngive up the reference that's taken in device_initialize(), so that it\ncan be freed in kobject_cleanup() when the refcount hits 0.\n\nmacio device is freed in macio_release_dev(), so the kfree() can be\nremoved.","source":"cvelist"}],"published":"2025-10-04T15:16:35.537Z","modified":"2026-06-17T05:23:37.590Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":["CWE-401"],"affected":[{"ranges":[{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"3a866ff6fc2232c8e393cdb55ffb8ce947349e03","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"aa9054267366ff0a382d403d17728e21951ddbb9","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"35858b87a943917fa30172aa4bf01ce7adbcb42c","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"b29a2f1dd33ae9b94821ab2f4d398b9081786748","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"2ac0a7059b7bcbed35bfffa34a82c9a9e99638ef","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"19ded60b40e86b0903c8d5bd0161437ed5107a8b","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"ca765257feb89dacf604ced9cd233db5f865dee0","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"76837e7f6b30da72ad59f56291e22804a219e015","status":"affected"},{"type":"git","introduced":"1fa5ae857bb14f6046205171d98506d8112dd74e","fixed":"5ca86eae55a2f006e6c1edd2029b2cacb6979515","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"2.6.30","status":"affected"},{"type":"semver","introduced":"0","fixed":"2.6.30","status":"unaffected"},{"type":"semver","introduced":"4.9.337","lastAffected":"4.9.*","status":"unaffected"},{"type":"semver","introduced":"4.14.303","lastAffected":"4.14.*","status":"unaffected"},{"type":"semver","introduced":"4.19.270","lastAffected":"4.19.*","status":"unaffected"},{"type":"semver","introduced":"5.4.229","lastAffected":"5.4.*","status":"unaffected"},{"type":"semver","introduced":"5.10.163","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.86","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.0.16","lastAffected":"6.0.*","status":"unaffected"},{"type":"semver","introduced":"6.1.2","lastAffected":"6.1.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.2","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":"2.6.30","fixed":"4.9.337"},{"status":"affected","introduced":"4.10","fixed":"4.14.303"},{"status":"affected","introduced":"4.15","fixed":"4.19.270"},{"status":"affected","introduced":"4.20","fixed":"5.4.229"},{"status":"affected","introduced":"5.5","fixed":"5.10.163"},{"status":"affected","introduced":"5.11","fixed":"5.15.86"},{"status":"affected","introduced":"5.16","fixed":"6.0.16"},{"status":"affected","introduced":"6.1","fixed":"6.1.2"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/3a866ff6fc2232c8e393cdb55ffb8ce947349e03","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/aa9054267366ff0a382d403d17728e21951ddbb9","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/35858b87a943917fa30172aa4bf01ce7adbcb42c","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/b29a2f1dd33ae9b94821ab2f4d398b9081786748","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/2ac0a7059b7bcbed35bfffa34a82c9a9e99638ef","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/19ded60b40e86b0903c8d5bd0161437ed5107a8b","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ca765257feb89dacf604ced9cd233db5f865dee0","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/76837e7f6b30da72ad59f56291e22804a219e015","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/5ca86eae55a2f006e6c1edd2029b2cacb6979515","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-50474","url":"https://www.cve.org/CVERecord?id=CVE-2022-50474","licence":"CVE Terms of Use","modified":"2026-05-11T19:20:11.509Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-50474","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-50474","licence":"Public domain","modified":"2026-06-17T05:23:37.590Z"}],"updatedAt":"2026-11-25T22:58:21.233Z","epss":{"score":0.00167,"percentile":0.06217,"date":"2026-12-02T12:00:21.000Z"}}