Skip to content
Heist/ feed
Back to feed
HighFix available

PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy()

Type: advisorySources: OSV

In the Linux kernel, the following vulnerability has been resolved: PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy() pci_epc_destroy() invokes pci_bus_release_domain_nr() to release the PCI domain ID, but there are two issues: - 'epc->dev' is passed to pci_bus_release_domain_nr() which was already freed by device_unregister(), leading to a use-after-free issue. - Domain ID corresponds to the EPC device parent, so passing 'epc->dev' is also wrong. Fix these issues by passing 'epc->dev.parent' to pci_bus_release_domain_nr() and also do it before device_unregister(). [mani: reworded subject and description]

Products
Kernel
Affected versions
Not specified
Fixed versions
6.12.4
CVEs
CVE-2024-56561
Confirmed fixed CVEs
Not specified
Updated in this feed
6 Nov 2026, 17:56 UTC · Revision 1

Source evidence

PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy()

core-osv · Original source

Published 27 Dec 2024, 14:23 UTC

In the Linux kernel, the following vulnerability has been resolved: PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy() pci_epc_destroy() invokes pci_bus_release_domain_nr() to release the PCI domain ID, but there are two issues: - 'epc->dev' is passed to pci_bus_release_domain_nr() which was already freed by device_unregister(), leading to a use-after-free issue. - Domain ID corresponds to the EPC device parent, so passing 'epc->dev' is also wrong. Fix these issues by passing 'epc->dev.parent' to pci_bus_release_domain_nr() and also do it before device_unregister(). [mani: reworded subject and description]

osv:CVE-2024-56561

Kernel

Fixed versions: 6.12.4

Complete source record
{
  "id": "5dc972c5fa712bc0b1bb785401a6a2c80c4fb003b03189bb0a3ca35263c3283b",
  "url": "https://osv.dev/vulnerability/CVE-2024-56561",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy()",
    "summary": "In the Linux kernel, the following vulnerability has been resolved: PCI: endpoint: Fix PCI domain ID release in pci_epc_destroy() pci_epc_destroy() invokes pci_bus_release_domain_nr() to release the PCI domain ID, but there are two issues: - 'epc->dev' is passed to pci_bus_release_domain_nr() which was already freed by device_unregister(), leading to a use-after-free issue. - Domain ID corresponds to the EPC device parent, so passing 'epc->dev' is also wrong. Fix these issues by passing 'epc->dev.parent' to pci_bus_release_domain_nr() and also do it before device_unregister(). [mani: reworded subject and description]",
    "evidence": "osv:CVE-2024-56561",
    "products": [
      {
        "name": {
          "value": "Kernel",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "6.12.4",
            "evidence": "/affected/1/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "high",
    "structured": {
      "id": "CVE-2024-56561",
      "aliases": [
        "CVE-2024-56561"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0328947c50324cf4b2d8b181bf948edb8101f59f"
                },
                {
                  "fixed": "c74a1df6c2a2df7dd45c3fc1a5edc29a075dcf22"
                },
                {
                  "fixed": "4acc902ed3743edd4ac2d3846604a99d17104359"
                }
              ]
            },
            {
              "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
              "type": "GIT",
              "events": [
                {
                  "introduced": "6.11.4"
                },
                {
                  "fixed": "6.12"
                }
              ]
            },
            {
              "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
              "type": "GIT",
              "events": [
                {
                  "introduced": "a4934cd7a18d35fc57025f23773f6f19e2b2dbb1"
                }
              ]
            }
          ],
          "versions": [
            "v6.11.11",
            "v6.11.10",
            "v6.11.9",
            "v6.11.8",
            "v6.11.7",
            "v6.11.6",
            "v6.11.5",
            "v6.11.4"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-56561.json"
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "6.12.0"
                },
                {
                  "fixed": "6.12.4"
                }
              ]
            }
          ],
          "package": {
            "name": "Kernel",
            "ecosystem": "Linux"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-56561.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:47.836544870Z",
      "provider": "osv",
      "references": [
        "https://git.kernel.org/stable/c/4acc902ed3743edd4ac2d3846604a99d17104359",
        "https://git.kernel.org/stable/c/c74a1df6c2a2df7dd45c3fc1a5edc29a075dcf22",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/56xxx/CVE-2024-56561.json",
        "https://nvd.nist.gov/vuln/detail/CVE-2024-56561",
        "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
      ],
      "provider_metadata": {
        "cna_assigner": "Linux",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/56xxx/CVE-2024-56561.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2024-56561",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 515832,
  "published_at": "2024-12-27T14:23:06.288+00:00"
}