{
  "schema_version": "1.6.1",
  "id": "RPI-CVE-2025-38180",
  "modified": "2026-10-09T11:39:44Z",
  "upstream": [
    "CVE-2025-38180"
  ],
  "published": "2025-07-04T13:42:19Z",
  "summary": "net: atm: fix /proc/net/atm/lec handling",
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\nnet: atm: fix /proc/net/atm/lec handling\n\n/proc/net/atm/lec must ensure safety against dev_lec[] changes.\n\nIt appears it had dev_put() calls without prior dev_hold(),\nleading to imbalance and UAF.",
  "severity": [
    {
      "type": "CVSS_V3",
      "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
    }
  ],
  "affected": [
    {
      "package": {
        "ecosystem": "Raspberry Pi OS:12",
        "name": "linux"
      },
      "versions": [
        "1:6.1.47-1+rpt4"
      ],
      "ecosystem_specific": {
        "binaries": [
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-2712",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v6",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v7",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v7l",
            "binary_version": "1:6.1.47-1+rpt4"
          },
          {
            "binary_name": "linux-image-6.1.0-rpi3-rpi-v8",
            "binary_version": "1:6.1.47-1+rpt4"
          }
        ]
      },
      "database_specific": {
        "per_version": {
          "1:6.1.47-1+rpt4": {
            "linux_commit": "655fc658a15ae7a6f37103754adb39ba52a9a14e",
            "upstream_version": "6.1.47",
            "assessment": "commit ancestry (strak rule)",
            "upstream_fixed": "6.1.142",
            "compiled_filter": false
          }
        }
      }
    }
  ],
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://www.cve.org/CVERecord?id=CVE-2025-38180"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/fcfccf56f4eba7d00aa2d33c7bb1b33083237742"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/f2d1443b18806640abdb530e88009af7be2588e7"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/ca3829c18c8d0ceb656605d3bff6bb3dfb078589"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/e612c4b014f5808fbc6beae21f5ccaca5e76a2f8"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/a5e3a144268899f1a8c445c8a3bfa15873ba85e8"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/5fe1b23a2f87f43aeeac51e08819cbc6fd808cbc"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/9b9aeb3ada44d8abea1e31e4446113f460848ae4"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/d03b79f459c7935cff830d98373474f440bd03ae"
    }
  ],
  "database_specific": {
    "source": "https://git.kernel.org/pub/scm/linux/security/vulns.git",
    "upstream_modified": "2026-08-05T12:19:11Z",
    "severity": {
      "source": "kernel CNA",
      "cvss_v3_score": 7.8,
      "cvss_v3_severity": "High",
      "scenario": "AV:L - The vulnerability is triggered by reading the local procfs file /proc/net/atm/lec; no network protocol data reaches the defective code. Exploitation requires a local account or any local code execution context on the host network namespace.\nAC:L - The unbalanced dev_put() fires deterministically on every read() of the file \u2014 no race must be won, and the attacker controls how many times to repeat it to drive the net_device refcount arbitrarily negative. The secondary dev_lec[] race is also attacker-paced via a tight read loop.\nPR:L - /proc/net/atm/lec is created with mode 0444, so any unprivileged local user can read it with no capability check on the path; the lec module itself is autoloadable by an unprivileged user via request_module(\"lec\") in do_vcc_ioctl() before any capable() test. CAP_NET_ADMIN is only needed to configure the LANE interface, which is a property of the target deployment rather than of the attacker.\nUI:N - The attacker triggers the defect entirely on their own by reading the procfs file; no victim action or cooperation of any kind is needed.\nS:U - The corrupted net_device object and the resulting memory corruption stay within the kernel's own security authority. No VM, IOMMU, or sandbox boundary is crossed.\nC:H - The refcount underflow lets a live net_device be freed while still referenced, and the missing lec_mutex allows the seq_show path to dereference a freed device; a UAF on a large kmalloc'd object gives the attacker control over the reclaimed contents and a kernel-memory read primitive.\nI:H - Premature free of an in-use net_device is a use-after-free on a structure dense with function pointers and list heads, sprayable for arbitrary write and control-flow hijack leading to privilege escalation.\nA:H - Driving the reference count below one reaches BUG_ON(netdev_refcnt_read(dev) != 1) in netdev_run_todo(), and use of the freed device oopses the kernel; either outcome is a full system crash reachable by an unprivileged loop."
    }
  }
}
