Lucene search

K
cvelistLinuxCVELIST:CVE-2024-35847
HistoryMay 17, 2024 - 2:47 p.m.

CVE-2024-35847 irqchip/gic-v3-its: Prevent double free on error

2024-05-1714:47:26
Linux
www.cve.org
1
linux kernel
cve-2024-35847
vulnerability resolution
irqchip/gic-v3-its
double free
error handling

6.5 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

13.0%

In the Linux kernel, the following vulnerability has been resolved:

irqchip/gic-v3-its: Prevent double free on error

The error handling path in its_vpe_irq_domain_alloc() causes a double free
when its_vpe_init() fails after successfully allocating at least one
interrupt. This happens because its_vpe_irq_domain_free() frees the
interrupts along with the area bitmap and the vprop_page and
its_vpe_irq_domain_alloc() subsequently frees the area bitmap and the
vprop_page again.

Fix this by unconditionally invoking its_vpe_irq_domain_free() which
handles all cases correctly and by removing the bitmap/vprop_page freeing
from its_vpe_irq_domain_alloc().

[ tglx: Massaged change log ]

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/irqchip/irq-gic-v3-its.c"
    ],
    "versions": [
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "f5417ff561b8",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "b72d2b1448b6",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "aa44d2157475",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "5dbdbe113391",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "dd681710ab77",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "03170e657f62",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "5b012f77abde",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "7d75bbb4bc1a",
        "lessThan": "c26591afd33a",
        "status": "affected",
        "versionType": "git"
      }
    ]
  },
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "affected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/irqchip/irq-gic-v3-its.c"
    ],
    "versions": [
      {
        "version": "4.14",
        "status": "affected"
      },
      {
        "version": "0",
        "lessThan": "4.14",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "4.19.313",
        "lessThanOrEqual": "4.19.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.4.275",
        "lessThanOrEqual": "5.4.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.10.216",
        "lessThanOrEqual": "5.10.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.15.158",
        "lessThanOrEqual": "5.15.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.1.90",
        "lessThanOrEqual": "6.1.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.6.30",
        "lessThanOrEqual": "6.6.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.8.9",
        "lessThanOrEqual": "6.8.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.9",
        "lessThanOrEqual": "*",
        "status": "unaffected",
        "versionType": "original_commit_for_fix"
      }
    ]
  }
]

6.5 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

13.0%