{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2022-49549","id":"CVE-2022-49549","title":"x86/MCE/AMD: Fix memory leak when threshold_create_bank() fails","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nx86/MCE/AMD: Fix memory leak when threshold_create_bank() fails\n\nIn mce_threshold_create_device(), if threshold_create_bank() fails, the\npreviously allocated threshold banks array @bp will be leaked because\nthe call to mce_threshold_remove_device() will not free it.\n\nThis happens because mce_threshold_remove_device() fetches the ","descriptionLong":"In the Linux kernel, the following vulnerability has been resolved:\n\nx86/MCE/AMD: Fix memory leak when threshold_create_bank() fails\n\nIn mce_threshold_create_device(), if threshold_create_bank() fails, the\npreviously allocated threshold banks array @bp will be leaked because\nthe call to mce_threshold_remove_device() will not free it.\n\nThis happens because mce_threshold_remove_device() fetches the pointer\nthrough the threshold_banks per-CPU variable but bp is written there\nonly after the bank creation is successful, and not before, when\nthreshold_create_bank() fails.\n\nAdd a helper which unwinds all the bank creation work previously done\nand pass into it the previously allocated threshold banks array for\nfreeing.\n\n  [ bp: Massage. ]","published":"2025-02-26T02:14:00.256Z","updated":"2026-10-28T02:30:54.044698779Z","reserved":"2025-02-26T02:08:31.590Z","status":"Modified","rejected":false,"assigner":"Linux","metric":{"version":"3.1","score":5.5,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"},"metrics":[{"version":"3.1","score":5.5,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"},{"version":"3.1","score":5.5,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"CISA-ADP"},{"version":"3.1","score":5.5,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"OSV"}],"rating":"medium","products":["Linux"],"affectedProducts":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"6458de97fc15530b54477c4e2b70af653e8ac3d9","lessThan":"b4acb8e7f1594607bc9017ef0aacb40b24a003d6","status":"affected","versionType":"git"},{"version":"6458de97fc15530b54477c4e2b70af653e8ac3d9","lessThan":"cc0dd4456f9573bf8af9b4d8754433918e809e1e","status":"affected","versionType":"git"},{"version":"6458de97fc15530b54477c4e2b70af653e8ac3d9","lessThan":"9708f1956eeb70c86943e0bc62fa3b0101b59616","status":"affected","versionType":"git"},{"version":"6458de97fc15530b54477c4e2b70af653e8ac3d9","lessThan":"396b8e7ab2a99ddac57d3522b3da5e58cb608d37","status":"affected","versionType":"git"},{"version":"6458de97fc15530b54477c4e2b70af653e8ac3d9","lessThan":"e5f28623ceb103e13fc3d7bd45edf9818b227fd0","status":"affected","versionType":"git"}],"platforms":[]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.8","status":"affected"},{"version":"0","lessThan":"5.8","status":"unaffected","versionType":"semver"},{"version":"5.10.121","lessThanOrEqual":"5.10.*","status":"unaffected","versionType":"semver"},{"version":"5.15.46","lessThanOrEqual":"5.15.*","status":"unaffected","versionType":"semver"},{"version":"5.17.14","lessThanOrEqual":"5.17.*","status":"unaffected","versionType":"semver"},{"version":"5.18.3","lessThanOrEqual":"5.18.*","status":"unaffected","versionType":"semver"},{"version":"5.19","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}],"platforms":[]}],"packages":[],"cwes":["CWE-401"],"aliases":[],"references":[{"url":"https://git.kernel.org/stable/c/b4acb8e7f1594607bc9017ef0aacb40b24a003d6","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/cc0dd4456f9573bf8af9b4d8754433918e809e1e","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/9708f1956eeb70c86943e0bc62fa3b0101b59616","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/396b8e7ab2a99ddac57d3522b3da5e58cb608d37","tags":["Patch","web"]},{"url":"https://git.kernel.org/stable/c/e5f28623ceb103e13fc3d7bd45edf9818b227fd0","tags":["Patch","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/49xxx/CVE-2022-49549.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49549","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.00268,"epssPercentile":0.19267,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2022-49549","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49549","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2022-49549","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-2022-49549","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}