CVE-2022-50158 (GCVE-0-2022-50158)

Vulnerability from cvelistv5 – Published: 2025-06-18 11:03 – Updated: 2026-05-23 15:23
VLAI
Title
mtd: partitions: Fix refcount leak in parse_redboot_of
Summary
In the Linux kernel, the following vulnerability has been resolved: mtd: partitions: Fix refcount leak in parse_redboot_of of_get_child_by_name() returns a node pointer with refcount incremented, we should use of_node_put() on it when not need anymore. Add missing of_node_put() to avoid refcount leak.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 6490ed7c4684caf9851a0b98e0ab17a8d693dada , < f3cc27198c5d78cdda60a55ae749f815cd1fe5eb (git)
Affected: 2f8824f556a3ebea9840c53326e55cc183316611 , < 55d0f7da66dec93c4d53d0886a1555618079a900 (git)
Affected: 237960880960863fb41888763d635b384cffb104 , < 8ea607579d300b2f7fc997f3dd20949114565fcd (git)
Affected: 237960880960863fb41888763d635b384cffb104 , < 7ec48ac18d8f9e002ce9bfbad32741086739e499 (git)
Affected: 237960880960863fb41888763d635b384cffb104 , < e24af43d0cbe9f6aaa413c15ccce50bbbfd61e0e (git)
Affected: 237960880960863fb41888763d635b384cffb104 , < 9f7e62815cf3cbbcb1b8cb21649fb4dfdb3aa016 (git)
Affected: fa132c7ea108eacc67357ffe3172d3e68fcd71a2 (git)
Affected: d5023eb76f0dc651558b0c7ba04565891ff18435 (git)
Affected: 5.4.132 , < 5.4.211 (semver)
Affected: 5.10.50 , < 5.10.137 (semver)
Affected: 5.12.17 , < 5.13 (semver)
Affected: 5.13.2 , < 5.14 (semver)
Create a notification for this product.
Linux Linux Affected: 5.14
Unaffected: 0 , < 5.14 (semver)
Unaffected: 5.4.211 , ≤ 5.4.* (semver)
Unaffected: 5.10.137 , ≤ 5.10.* (semver)
Unaffected: 5.15.61 , ≤ 5.15.* (semver)
Unaffected: 5.18.18 , ≤ 5.18.* (semver)
Unaffected: 5.19.2 , ≤ 5.19.* (semver)
Unaffected: 6.0 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/mtd/parsers/redboot.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "f3cc27198c5d78cdda60a55ae749f815cd1fe5eb",
              "status": "affected",
              "version": "6490ed7c4684caf9851a0b98e0ab17a8d693dada",
              "versionType": "git"
            },
            {
              "lessThan": "55d0f7da66dec93c4d53d0886a1555618079a900",
              "status": "affected",
              "version": "2f8824f556a3ebea9840c53326e55cc183316611",
              "versionType": "git"
            },
            {
              "lessThan": "8ea607579d300b2f7fc997f3dd20949114565fcd",
              "status": "affected",
              "version": "237960880960863fb41888763d635b384cffb104",
              "versionType": "git"
            },
            {
              "lessThan": "7ec48ac18d8f9e002ce9bfbad32741086739e499",
              "status": "affected",
              "version": "237960880960863fb41888763d635b384cffb104",
              "versionType": "git"
            },
            {
              "lessThan": "e24af43d0cbe9f6aaa413c15ccce50bbbfd61e0e",
              "status": "affected",
              "version": "237960880960863fb41888763d635b384cffb104",
              "versionType": "git"
            },
            {
              "lessThan": "9f7e62815cf3cbbcb1b8cb21649fb4dfdb3aa016",
              "status": "affected",
              "version": "237960880960863fb41888763d635b384cffb104",
              "versionType": "git"
            },
            {
              "status": "affected",
              "version": "fa132c7ea108eacc67357ffe3172d3e68fcd71a2",
              "versionType": "git"
            },
            {
              "status": "affected",
              "version": "d5023eb76f0dc651558b0c7ba04565891ff18435",
              "versionType": "git"
            },
            {
              "lessThan": "5.4.211",
              "status": "affected",
              "version": "5.4.132",
              "versionType": "semver"
            },
            {
              "lessThan": "5.10.137",
              "status": "affected",
              "version": "5.10.50",
              "versionType": "semver"
            },
            {
              "lessThan": "5.13",
              "status": "affected",
              "version": "5.12.17",
              "versionType": "semver"
            },
            {
              "lessThan": "5.14",
              "status": "affected",
              "version": "5.13.2",
              "versionType": "semver"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/mtd/parsers/redboot.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.14"
            },
            {
              "lessThan": "5.14",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.4.*",
              "status": "unaffected",
              "version": "5.4.211",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.137",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.61",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.18.*",
              "status": "unaffected",
              "version": "5.18.18",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.19.*",
              "status": "unaffected",
              "version": "5.19.2",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.0",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.4.211",
                  "versionStartIncluding": "5.4.132",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.137",
                  "versionStartIncluding": "5.10.50",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.61",
                  "versionStartIncluding": "5.14",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.18.18",
                  "versionStartIncluding": "5.14",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.19.2",
                  "versionStartIncluding": "5.14",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.0",
                  "versionStartIncluding": "5.14",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionStartIncluding": "5.12.17",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionStartIncluding": "5.13.2",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nmtd: partitions: Fix refcount leak in parse_redboot_of\n\nof_get_child_by_name() returns a node pointer with refcount\nincremented, we should use of_node_put() on it when not need anymore.\nAdd missing of_node_put() to avoid refcount leak."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-05-23T15:23:44.887Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/f3cc27198c5d78cdda60a55ae749f815cd1fe5eb"
        },
        {
          "url": "https://git.kernel.org/stable/c/55d0f7da66dec93c4d53d0886a1555618079a900"
        },
        {
          "url": "https://git.kernel.org/stable/c/8ea607579d300b2f7fc997f3dd20949114565fcd"
        },
        {
          "url": "https://git.kernel.org/stable/c/7ec48ac18d8f9e002ce9bfbad32741086739e499"
        },
        {
          "url": "https://git.kernel.org/stable/c/e24af43d0cbe9f6aaa413c15ccce50bbbfd61e0e"
        },
        {
          "url": "https://git.kernel.org/stable/c/9f7e62815cf3cbbcb1b8cb21649fb4dfdb3aa016"
        }
      ],
      "title": "mtd: partitions: Fix refcount leak in parse_redboot_of",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2022-50158",
    "datePublished": "2025-06-18T11:03:15.177Z",
    "dateReserved": "2025-06-18T10:57:27.425Z",
    "dateUpdated": "2026-05-23T15:23:44.887Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2022-50158",
      "date": "2026-07-06",
      "epss": "0.00156",
      "percentile": "0.05169"
    },
    "nvd": "{\"cve\":{\"id\":\"CVE-2022-50158\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-06-18T11:15:45.977\",\"lastModified\":\"2026-06-17T05:22:52.633\",\"vulnStatus\":\"Analyzed\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nmtd: partitions: Fix refcount leak in parse_redboot_of\\n\\nof_get_child_by_name() returns a node pointer with refcount\\nincremented, we should use of_node_put() on it when not need anymore.\\nAdd missing of_node_put() to avoid refcount leak.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: mtd: particiones: Se corrige la fuga de recuento de referencias en parse_redboot_of. of_get_child_by_name() devuelve un puntero de nodo con el recuento de referencias incrementado. Debemos usar of_node_put() cuando ya no sea necesario. Se ha a\u00f1adido la funci\u00f3n of_node_put() que falta para evitar la fuga de recuento de referencias.\"}],\"affected\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"affectedData\":[{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"unaffected\",\"programFiles\":[\"drivers/mtd/parsers/redboot.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"6490ed7c4684caf9851a0b98e0ab17a8d693dada\",\"lessThan\":\"f3cc27198c5d78cdda60a55ae749f815cd1fe5eb\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"2f8824f556a3ebea9840c53326e55cc183316611\",\"lessThan\":\"55d0f7da66dec93c4d53d0886a1555618079a900\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"237960880960863fb41888763d635b384cffb104\",\"lessThan\":\"8ea607579d300b2f7fc997f3dd20949114565fcd\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"237960880960863fb41888763d635b384cffb104\",\"lessThan\":\"7ec48ac18d8f9e002ce9bfbad32741086739e499\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"237960880960863fb41888763d635b384cffb104\",\"lessThan\":\"e24af43d0cbe9f6aaa413c15ccce50bbbfd61e0e\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"237960880960863fb41888763d635b384cffb104\",\"lessThan\":\"9f7e62815cf3cbbcb1b8cb21649fb4dfdb3aa016\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"fa132c7ea108eacc67357ffe3172d3e68fcd71a2\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"d5023eb76f0dc651558b0c7ba04565891ff18435\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"5.4.132\",\"lessThan\":\"5.4.211\",\"versionType\":\"semver\",\"status\":\"affected\"},{\"version\":\"5.10.50\",\"lessThan\":\"5.10.137\",\"versionType\":\"semver\",\"status\":\"affected\"},{\"version\":\"5.12.17\",\"lessThan\":\"5.13\",\"versionType\":\"semver\",\"status\":\"affected\"},{\"version\":\"5.13.2\",\"lessThan\":\"5.14\",\"versionType\":\"semver\",\"status\":\"affected\"}]},{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"affected\",\"programFiles\":[\"drivers/mtd/parsers/redboot.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"5.14\",\"status\":\"affected\"},{\"version\":\"0\",\"lessThan\":\"5.14\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.4.211\",\"lessThanOrEqual\":\"5.4.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.10.137\",\"lessThanOrEqual\":\"5.10.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.15.61\",\"lessThanOrEqual\":\"5.15.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.18.18\",\"lessThanOrEqual\":\"5.18.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.19.2\",\"lessThanOrEqual\":\"5.19.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.0\",\"lessThanOrEqual\":\"*\",\"versionType\":\"original_commit_for_fix\",\"status\":\"unaffected\"}]}]}],\"metrics\":{\"cvssMetricV31\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"cvssData\":{\"version\":\"3.1\",\"vectorString\":\"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H\",\"baseScore\":5.5,\"baseSeverity\":\"MEDIUM\",\"attackVector\":\"LOCAL\",\"attackComplexity\":\"LOW\",\"privilegesRequired\":\"LOW\",\"userInteraction\":\"NONE\",\"scope\":\"UNCHANGED\",\"confidentialityImpact\":\"NONE\",\"integrityImpact\":\"NONE\",\"availabilityImpact\":\"HIGH\"},\"exploitabilityScore\":1.8,\"impactScore\":3.6}]},\"weaknesses\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"description\":[{\"lang\":\"en\",\"value\":\"NVD-CWE-Other\"}]}],\"configurations\":[{\"nodes\":[{\"operator\":\"OR\",\"negate\":false,\"cpeMatch\":[{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.4.132\",\"versionEndExcluding\":\"5.4.211\",\"matchCriteriaId\":\"6A8F272D-26DC-40F8-B558-45A8EA5AB5BA\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.10.50\",\"versionEndExcluding\":\"5.10.137\",\"matchCriteriaId\":\"CFB85EBC-F3AF-425F-8D42-981B2F776CD5\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.12.17\",\"versionEndExcluding\":\"5.13\",\"matchCriteriaId\":\"CDB1D52E-21AB-4ECE-9119-6594F8FF3B3A\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.13.2\",\"versionEndExcluding\":\"5.15.61\",\"matchCriteriaId\":\"C6935A66-8326-4D16-8E57-0D3E9F8908DD\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.16\",\"versionEndExcluding\":\"5.18.18\",\"matchCriteriaId\":\"5B42E453-8837-49D0-A5EF-03F818A6DC11\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.19\",\"versionEndExcluding\":\"5.19.2\",\"matchCriteriaId\":\"A1A2A5A5-4598-4D7E-BA07-4660398D6C8F\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/55d0f7da66dec93c4d53d0886a1555618079a900\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/7ec48ac18d8f9e002ce9bfbad32741086739e499\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/8ea607579d300b2f7fc997f3dd20949114565fcd\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/9f7e62815cf3cbbcb1b8cb21649fb4dfdb3aa016\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/e24af43d0cbe9f6aaa413c15ccce50bbbfd61e0e\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/f3cc27198c5d78cdda60a55ae749f815cd1fe5eb\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]}]}}"
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…