cve-2024-26623
Vulnerability from cvelistv5
Published
2024-03-06 06:45
Modified
2024-11-05 09:12
Severity ?
Summary
pds_core: Prevent race issues involving the adminq
Impacted products
LinuxLinux
LinuxLinux
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2024-26623",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-03-06T14:15:26.675181Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-06-04T17:48:43.755Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-02T00:07:19.860Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/22cd6046eb2148b18990257505834dd45c672a1b"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/5939feb63ea1f011027576c64b68b681cbad31ca"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/7e82a8745b951b1e794cc780d46f3fbee5e93447"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/net/ethernet/amd/pds_core/adminq.c",
            "drivers/net/ethernet/amd/pds_core/core.c",
            "drivers/net/ethernet/amd/pds_core/core.h"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "22cd6046eb21",
              "status": "affected",
              "version": "01ba61b55b20",
              "versionType": "git"
            },
            {
              "lessThan": "5939feb63ea1",
              "status": "affected",
              "version": "01ba61b55b20",
              "versionType": "git"
            },
            {
              "lessThan": "7e82a8745b95",
              "status": "affected",
              "version": "01ba61b55b20",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/net/ethernet/amd/pds_core/adminq.c",
            "drivers/net/ethernet/amd/pds_core/core.c",
            "drivers/net/ethernet/amd/pds_core/core.h"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.4"
            },
            {
              "lessThan": "6.4",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.16",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.7.*",
              "status": "unaffected",
              "version": "6.7.4",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.8",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\npds_core: Prevent race issues involving the adminq\n\nThere are multiple paths that can result in using the pdsc\u0027s\nadminq.\n\n[1] pdsc_adminq_isr and the resulting work from queue_work(),\n    i.e. pdsc_work_thread()-\u003epdsc_process_adminq()\n\n[2] pdsc_adminq_post()\n\nWhen the device goes through reset via PCIe reset and/or\na fw_down/fw_up cycle due to bad PCIe state or bad device\nstate the adminq is destroyed and recreated.\n\nA NULL pointer dereference can happen if [1] or [2] happens\nafter the adminq is already destroyed.\n\nIn order to fix this, add some further state checks and\nimplement reference counting for adminq uses. Reference\ncounting was used because multiple threads can attempt to\naccess the adminq at the same time via [1] or [2]. Additionally,\nmultiple clients (i.e. pds-vfio-pci) can be using [2]\nat the same time.\n\nThe adminq_refcnt is initialized to 1 when the adminq has been\nallocated and is ready to use. Users/clients of the adminq\n(i.e. [1] and [2]) will increment the refcnt when they are using\nthe adminq. When the driver goes into a fw_down cycle it will\nset the PDSC_S_FW_DEAD bit and then wait for the adminq_refcnt\nto hit 1. Setting the PDSC_S_FW_DEAD before waiting will prevent\nany further adminq_refcnt increments. Waiting for the\nadminq_refcnt to hit 1 allows for any current users of the adminq\nto finish before the driver frees the adminq. Once the\nadminq_refcnt hits 1 the driver clears the refcnt to signify that\nthe adminq is deleted and cannot be used. On the fw_up cycle the\ndriver will once again initialize the adminq_refcnt to 1 allowing\nthe adminq to be used again."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2024-11-05T09:12:46.739Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/22cd6046eb2148b18990257505834dd45c672a1b"
        },
        {
          "url": "https://git.kernel.org/stable/c/5939feb63ea1f011027576c64b68b681cbad31ca"
        },
        {
          "url": "https://git.kernel.org/stable/c/7e82a8745b951b1e794cc780d46f3fbee5e93447"
        }
      ],
      "title": "pds_core: Prevent race issues involving the adminq",
      "x_generator": {
        "engine": "bippy-9e1c9544281a"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-26623",
    "datePublished": "2024-03-06T06:45:32.278Z",
    "dateReserved": "2024-02-19T14:20:24.134Z",
    "dateUpdated": "2024-11-05T09:12:46.739Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "meta": {
    "nvd": "{\"cve\":{\"id\":\"CVE-2024-26623\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2024-03-06T07:15:12.173\",\"lastModified\":\"2024-03-06T15:18:08.093\",\"vulnStatus\":\"Awaiting Analysis\",\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\npds_core: Prevent race issues involving the adminq\\n\\nThere are multiple paths that can result in using the pdsc\u0027s\\nadminq.\\n\\n[1] pdsc_adminq_isr and the resulting work from queue_work(),\\n    i.e. pdsc_work_thread()-\u003epdsc_process_adminq()\\n\\n[2] pdsc_adminq_post()\\n\\nWhen the device goes through reset via PCIe reset and/or\\na fw_down/fw_up cycle due to bad PCIe state or bad device\\nstate the adminq is destroyed and recreated.\\n\\nA NULL pointer dereference can happen if [1] or [2] happens\\nafter the adminq is already destroyed.\\n\\nIn order to fix this, add some further state checks and\\nimplement reference counting for adminq uses. Reference\\ncounting was used because multiple threads can attempt to\\naccess the adminq at the same time via [1] or [2]. Additionally,\\nmultiple clients (i.e. pds-vfio-pci) can be using [2]\\nat the same time.\\n\\nThe adminq_refcnt is initialized to 1 when the adminq has been\\nallocated and is ready to use. Users/clients of the adminq\\n(i.e. [1] and [2]) will increment the refcnt when they are using\\nthe adminq. When the driver goes into a fw_down cycle it will\\nset the PDSC_S_FW_DEAD bit and then wait for the adminq_refcnt\\nto hit 1. Setting the PDSC_S_FW_DEAD before waiting will prevent\\nany further adminq_refcnt increments. Waiting for the\\nadminq_refcnt to hit 1 allows for any current users of the adminq\\nto finish before the driver frees the adminq. Once the\\nadminq_refcnt hits 1 the driver clears the refcnt to signify that\\nthe adminq is deleted and cannot be used. On the fw_up cycle the\\ndriver will once again initialize the adminq_refcnt to 1 allowing\\nthe adminq to be used again.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: pds_core: evita problemas de ejecuci\u00f3n relacionados con adminq. Hay varias rutas que pueden resultar en el uso de adminq de pdsc. [1] pdsc_adminq_isr y el trabajo resultante de queue_work(), es decir, pdsc_work_thread()-\u0026gt;pdsc_process_adminq() [2] pdsc_adminq_post() Cuando el dispositivo se reinicia mediante reinicio de PCIe y/o un ciclo fw_down/fw_up debido a un estado incorrecto de PCIe o mal estado del dispositivo, adminq se destruye y se vuelve a crear. Puede ocurrir una desreferencia de puntero NULL si [1] o [2] ocurre despu\u00e9s de que adminq ya est\u00e9 destruido. Para solucionar este problema, agregue algunas comprobaciones de estado adicionales e implemente el recuento de referencias para usos de adminq. Se utiliz\u00f3 el recuento de referencias porque varios subprocesos pueden intentar acceder a adminq al mismo tiempo a trav\u00e9s de [1] o [2]. Adem\u00e1s, varios clientes (es decir, pds-vfio-pci) pueden utilizar [2] al mismo tiempo. adminq_refcnt se inicializa en 1 cuando adminq se ha asignado y est\u00e1 listo para usar. Los usuarios/clientes de adminq (es decir, [1] y [2]) incrementar\u00e1n el refcnt cuando utilicen adminq. Cuando el controlador entra en un ciclo fw_down, establecer\u00e1 el bit PDSC_S_FW_DEAD y luego esperar\u00e1 a que adminq_refcnt llegue a 1. Configurar PDSC_S_FW_DEAD antes de esperar evitar\u00e1 m\u00e1s incrementos de adminq_refcnt. Esperar a que adminq_refcnt llegue a 1 permite que cualquier usuario actual de adminq finalice antes de que el controlador libere adminq. Una vez que adminq_refcnt llega a 1, el controlador borra el refcnt para indicar que adminq se elimina y no se puede utilizar. En el ciclo fw_up, el controlador inicializar\u00e1 una vez m\u00e1s adminq_refcnt en 1, lo que permitir\u00e1 utilizar adminq nuevamente.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/22cd6046eb2148b18990257505834dd45c672a1b\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/5939feb63ea1f011027576c64b68b681cbad31ca\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/7e82a8745b951b1e794cc780d46f3fbee5e93447\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}"
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading...

Loading...

Loading...

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.