CVE-2025-68167 (GCVE-0-2025-68167)

Vulnerability from cvelistv5 – Published: 2025-12-16 13:42 – Updated: 2026-08-05 12:09
VLAI
Title
gpiolib: fix invalid pointer access in debugfs
Summary
In the Linux kernel, the following vulnerability has been resolved: gpiolib: fix invalid pointer access in debugfs If the memory allocation in gpiolib_seq_start() fails, the s->private field remains uninitialized and is later dereferenced without checking in gpiolib_seq_stop(). Initialize s->private to NULL before calling kzalloc() and check it before dereferencing it.
Assigner
Linux CNA under the mitre root
CNA scorecard D 53/100 over 6794 records in the last 180 days details
Impacted products
Vendor Product Version CPE status
Linux Linux Affected: e348544f7994d252427ed3ae637c7081cbb90f66 , < 70180a6031056096c93ed2f47c41803268bdd91c (git)
Affected: e348544f7994d252427ed3ae637c7081cbb90f66 , < 3c91c8f424d3e44c8645ab765a38773e58afb07d (git)
Affected: e348544f7994d252427ed3ae637c7081cbb90f66 , < 2f6115ad8864cf3f48598f26c74c7c8e5c391919 (git)
guessed Create a notification for this product.
Linux Linux Affected: 6.9
Unaffected: 0 , < 6.9 (semver)
Unaffected: 6.12.58 , ≤ 6.12.* (semver)
Unaffected: 6.17.8 , ≤ 6.17.* (semver)
Unaffected: 6.18 , ≤ * (original_commit_for_fix)
guessed Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/gpio/gpiolib.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "70180a6031056096c93ed2f47c41803268bdd91c",
              "status": "affected",
              "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
              "versionType": "git"
            },
            {
              "lessThan": "3c91c8f424d3e44c8645ab765a38773e58afb07d",
              "status": "affected",
              "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
              "versionType": "git"
            },
            {
              "lessThan": "2f6115ad8864cf3f48598f26c74c7c8e5c391919",
              "status": "affected",
              "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/gpio/gpiolib.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.9"
            },
            {
              "lessThan": "6.9",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.58",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.17.*",
              "status": "unaffected",
              "version": "6.17.8",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.18",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.58",
                  "versionStartIncluding": "6.9",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.17.8",
                  "versionStartIncluding": "6.9",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.18",
                  "versionStartIncluding": "6.9",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\ngpiolib: fix invalid pointer access in debugfs\n\nIf the memory allocation in gpiolib_seq_start() fails, the s-\u003eprivate\nfield remains uninitialized and is later dereferenced without checking\nin gpiolib_seq_stop(). Initialize s-\u003eprivate to NULL before calling\nkzalloc() and check it before dereferencing it."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7.8,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:L - The vulnerability is reached only by reading the local debugfs file /sys/kernel/debug/gpio; there is no network or remote path into gpiolib\u0027s seq_file handlers.\nAC:L - The attacker fully controls both required conditions \u2014 memory pressure to make the small GFP_KERNEL kzalloc fail, and unbounded repetition of read()/lseek() on the file, each of which drives multiple start/stop cycles \u2014 so the failure can simply be retried until it lands.\nPR:L - The gpio debugfs file is explicitly created world-readable (mode 0444) and needs no capability, so any unprivileged local user reaches it on the many embedded, automotive, industrial and Android deployments that mount debugfs traversable (mode=755 or uid/gid options), which is common precisely because GPIO debugging is the reason debugfs is mounted there.\nUI:N - The attacker triggers the bug entirely through their own read() calls on the debugfs file; no action by any other user or victim process is needed.\nS:U - The corruption stays within the kernel\u0027s own security authority \u2014 freed slab memory and per-CPU SRCU counters \u2014 with no crossing of a VM, IOMMU or sandbox boundary.\nC:H - gpiolib_seq_stop() reads priv-\u003eidx out of an already-freed kmalloc-16 object, and the accompanying double free corrupts the slab freelist, enabling overlapping allocations that yield arbitrary kernel memory disclosure.\nI:H - The stale idx is fed unvalidated into __srcu_read_unlock(), producing this_cpu_inc() at an attacker-influenced out-of-bounds offset from the per-CPU srcu_data, and the subsequent kfree() of an object owned by another allocation is a classic double-free write primitive.\nA:H - On the first iteration s-\u003eprivate is NULL, so gpiolib_seq_stop() dereferences NULL and oopses; on later iterations the use-after-free, wild per-CPU increment and double free reliably panic the kernel."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T12:09:56.647Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/70180a6031056096c93ed2f47c41803268bdd91c"
        },
        {
          "url": "https://git.kernel.org/stable/c/3c91c8f424d3e44c8645ab765a38773e58afb07d"
        },
        {
          "url": "https://git.kernel.org/stable/c/2f6115ad8864cf3f48598f26c74c7c8e5c391919"
        }
      ],
      "title": "gpiolib: fix invalid pointer access in debugfs",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2025-68167",
    "datePublished": "2025-12-16T13:42:47.480Z",
    "dateReserved": "2025-12-16T13:41:40.250Z",
    "dateUpdated": "2026-08-05T12:09:56.647Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2025-68167",
      "date": "2026-11-02",
      "epss": "0.00152",
      "percentile": "0.04364"
    },
    "nvd": {
      "cve": {
        "affected": [
          {
            "affectedData": [
              {
                "defaultStatus": "unaffected",
                "product": "Linux",
                "programFiles": [
                  "drivers/gpio/gpiolib.c"
                ],
                "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                "vendor": "Linux",
                "versions": [
                  {
                    "lessThan": "70180a6031056096c93ed2f47c41803268bdd91c",
                    "status": "affected",
                    "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
                    "versionType": "git"
                  },
                  {
                    "lessThan": "3c91c8f424d3e44c8645ab765a38773e58afb07d",
                    "status": "affected",
                    "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
                    "versionType": "git"
                  },
                  {
                    "lessThan": "2f6115ad8864cf3f48598f26c74c7c8e5c391919",
                    "status": "affected",
                    "version": "e348544f7994d252427ed3ae637c7081cbb90f66",
                    "versionType": "git"
                  }
                ]
              },
              {
                "defaultStatus": "affected",
                "product": "Linux",
                "programFiles": [
                  "drivers/gpio/gpiolib.c"
                ],
                "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                "vendor": "Linux",
                "versions": [
                  {
                    "status": "affected",
                    "version": "6.9"
                  },
                  {
                    "lessThan": "6.9",
                    "status": "unaffected",
                    "version": "0",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "6.12.*",
                    "status": "unaffected",
                    "version": "6.12.58",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "6.17.*",
                    "status": "unaffected",
                    "version": "6.17.8",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "*",
                    "status": "unaffected",
                    "version": "6.18",
                    "versionType": "original_commit_for_fix"
                  }
                ]
              }
            ],
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
          }
        ],
        "cveTags": [],
        "descriptions": [
          {
            "lang": "en",
            "value": "In the Linux kernel, the following vulnerability has been resolved:\n\ngpiolib: fix invalid pointer access in debugfs\n\nIf the memory allocation in gpiolib_seq_start() fails, the s-\u003eprivate\nfield remains uninitialized and is later dereferenced without checking\nin gpiolib_seq_stop(). Initialize s-\u003eprivate to NULL before calling\nkzalloc() and check it before dereferencing it."
          },
          {
            "lang": "es",
            "value": "En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\ngpiolib: correcci\u00f3n de acceso a puntero no v\u00e1lido en debugfs\n\nSi la asignaci\u00f3n de memoria en gpiolib_seq_start() falla, el campo s -\u003e private permanece sin inicializar y es posteriormente desreferenciado sin verificar en gpiolib_seq_stop(). Inicialice s -\u003e private a NULL antes de llamar a kzalloc() y verif\u00edquelo antes de desreferenciarlo."
          }
        ],
        "id": "CVE-2025-68167",
        "lastModified": "2026-10-14T13:10:00.187",
        "metrics": {
          "cvssMetricV31": [
            {
              "cvssData": {
                "attackComplexity": "LOW",
                "attackVector": "LOCAL",
                "availabilityImpact": "HIGH",
                "baseScore": 7.8,
                "baseSeverity": "HIGH",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "LOW",
                "scope": "UNCHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
                "version": "3.1"
              },
              "exploitabilityScore": 1.8,
              "impactScore": 5.9,
              "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
              "type": "Secondary"
            }
          ]
        },
        "published": "2025-12-16T14:15:48.540",
        "references": [
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/2f6115ad8864cf3f48598f26c74c7c8e5c391919"
          },
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/3c91c8f424d3e44c8645ab765a38773e58afb07d"
          },
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/70180a6031056096c93ed2f47c41803268bdd91c"
          }
        ],
        "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "vulnStatus": "Deferred"
      }
    },
    "redhat_vex": {
      "aggregate_severity": "Moderate",
      "current_release_date": "2026-10-30T03:18:54+00:00",
      "cve": "CVE-2025-68167",
      "id": "CVE-2025-68167",
      "initial_release_date": "2025-12-16T00:00:00+00:00",
      "product_status:known_affected": "91",
      "product_status:known_not_affected": "185",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: gpiolib: fix invalid pointer access in debugfs",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2025/cve-2025-68167.json",
      "version": "3"
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.

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.
Vulnerability timeline

Sightings and recorded dates, grouped by day · UTC

JSON
Events included in the timeline

Loading timeline…


    Loading…

    Loading…

    Loading…

    Related by attack behaviour

    Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.