CVE-2026-64120 (GCVE-0-2026-64120)
Vulnerability from cvelistv5
Published
2026-07-19 15:40
Modified
2026-07-19 15:40
Severity ?
Summary
In the Linux kernel, the following vulnerability has been resolved: net: ethtool: fix NULL pointer dereference in phy_reply_size In phy_prepare_data(), several strings such as 'name', 'drvname', 'upstream_sfp_name', and 'downstream_sfp_name' are allocated using kstrdup(). However, these allocations were not checked for failure. If kstrdup() fails for 'name', it returns NULL while the function continues. This leads to a kernel NULL pointer dereference and panic later in phy_reply_size() when it unconditionally calls strlen() on the NULL pointer. While other strings like 'upstream_sfp_name' might be checked before access in certain code paths, failing to handle these allocations consistently can lead to incomplete data reporting or hidden bugs. Fix this by adding proper NULL checks for all kstrdup() calls in phy_prepare_data() and implement a centralized error handling path using goto labels to ensure all previously allocated resources are freed on failure.
Impacted products
Vendor Product Version
Linux Linux Version: 9dd2ad5e92b962d1349a7541d167e8e214e49f95
Version: 9dd2ad5e92b962d1349a7541d167e8e214e49f95
Version: 9dd2ad5e92b962d1349a7541d167e8e214e49f95
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "net/ethtool/phy.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "61f53c1e58d68723bc1db10912a53f1991f08719",
              "status": "affected",
              "version": "9dd2ad5e92b962d1349a7541d167e8e214e49f95",
              "versionType": "git"
            },
            {
              "lessThan": "3dbe20a3809347bacda890822e7ca013bd85a18c",
              "status": "affected",
              "version": "9dd2ad5e92b962d1349a7541d167e8e214e49f95",
              "versionType": "git"
            },
            {
              "lessThan": "4908f1395fb1b832ceec11584af649874a2732ea",
              "status": "affected",
              "version": "9dd2ad5e92b962d1349a7541d167e8e214e49f95",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "net/ethtool/phy.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.16"
            },
            {
              "lessThan": "6.16",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.18.*",
              "status": "unaffected",
              "version": "6.18.34",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "7.0.*",
              "status": "unaffected",
              "version": "7.0.11",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "7.1",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.18.34",
                  "versionStartIncluding": "6.16",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.0.11",
                  "versionStartIncluding": "6.16",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.1",
                  "versionStartIncluding": "6.16",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nnet: ethtool: fix NULL pointer dereference in phy_reply_size\n\nIn phy_prepare_data(), several strings such as \u0027name\u0027, \u0027drvname\u0027,\n\u0027upstream_sfp_name\u0027, and \u0027downstream_sfp_name\u0027 are allocated using\nkstrdup(). However, these allocations were not checked  for failure.\n\nIf kstrdup() fails for \u0027name\u0027, it returns NULL while the function\ncontinues. This leads to a kernel NULL pointer dereference and panic\nlater in phy_reply_size() when it unconditionally calls strlen() on\nthe NULL pointer.\n\nWhile other strings like \u0027upstream_sfp_name\u0027 might be checked before\naccess in certain code paths, failing to handle these allocations\nconsistently can lead to incomplete data reporting or hidden bugs.\n\nFix this by adding proper NULL checks for all kstrdup() calls in\nphy_prepare_data() and implement a centralized error handling path\nusing goto labels to ensure all previously allocated resources are\nfreed on failure."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-07-19T15:40:19.044Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/61f53c1e58d68723bc1db10912a53f1991f08719"
        },
        {
          "url": "https://git.kernel.org/stable/c/3dbe20a3809347bacda890822e7ca013bd85a18c"
        },
        {
          "url": "https://git.kernel.org/stable/c/4908f1395fb1b832ceec11584af649874a2732ea"
        }
      ],
      "title": "net: ethtool: fix NULL pointer dereference in phy_reply_size",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2026-64120",
    "datePublished": "2026-07-19T15:40:19.044Z",
    "dateReserved": "2026-07-19T07:54:57.036Z",
    "dateUpdated": "2026-07-19T15:40:19.044Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2"
}


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.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • 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.


Loading…

Loading…