{
  "schema_version": "1.6.1",
  "id": "RPI-CVE-2023-53495",
  "modified": "2026-10-09T11:39:44Z",
  "upstream": [
    "CVE-2023-53495"
  ],
  "published": "2025-10-01T11:50:00Z",
  "summary": "net: ethernet: mvpp2_main: fix possible OOB write in mvpp2_ethtool_get_rxnfc()",
  "details": "In the Linux kernel, the following vulnerability has been resolved:\n\nnet: ethernet: mvpp2_main: fix possible OOB write in mvpp2_ethtool_get_rxnfc()\n\nrules is allocated in ethtool_get_rxnfc and the size is determined by\nrule_cnt from user space. So rule_cnt needs to be check before using\nrules to avoid OOB writing or NULL pointer dereference.",
  "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.54",
            "compiled_filter": false
          }
        }
      }
    }
  ],
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://www.cve.org/CVERecord?id=CVE-2023-53495"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/ba6673824efa3dc198b04a54e69dce480066d7d9"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/61054a8ddb176b155a8f2bacdfefb3727187f5d9"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/5bb09dddc724c5f7c4dc6dd3bfebd685eecd93e8"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/349638f7e5d3c7d328565587bb7b0454bbee02e2"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/625b70d31dd4df4b96b3ddcbe251debb33bd67f5"
    },
    {
      "type": "FIX",
      "url": "https://git.kernel.org/stable/c/51fe0a470543f345e3c62b6798929de3ddcedc1d"
    }
  ],
  "database_specific": {
    "source": "https://git.kernel.org/pub/scm/linux/security/vulns.git",
    "upstream_modified": "2026-08-05T11:24:39Z",
    "severity": {
      "source": "kernel CNA",
      "cvss_v3_score": 7.8,
      "cvss_v3_severity": "High",
      "scenario": "AV:L - The vulnerability is reached through the `SIOCETHTOOL` ioctl on a local socket (`dev_ioctl` \u2192 `dev_ethtool` \u2192 `mvpp2_ethtool_get_rxnfc`), requiring a local process on the system. No remote or adjacent-network input reaches this code path.\nAC:L - The attacker fully controls `info.rule_cnt` and can deterministically choose the undersized (or NULL) buffer; there is no race, no secret to guess, and no memory-layout dependency, and `queue_mode` defaults to the multi-queue mode that enables the path. The only precondition is a persistent, standard ntuple flow-steering configuration, after which the attack succeeds 100% of the time and can be repeated at will.\nPR:L - `ETHTOOL_GRXCLSRLALL` is explicitly listed in `__dev_ethtool()`'s \"Allow some commands to be done by anyone\" whitelist, so it bypasses the `ns_capable(net->user_ns, CAP_NET_ADMIN)` check \u2014 any unprivileged local user, including one confined to a sandbox or container, can invoke it. Only a basic local account is needed, not root or CAP_NET_ADMIN.\nUI:N - The attacker performs the entire attack with a single ioctl from their own process; no victim action is required at attack time. The pre-existing ntuple rule configuration is ambient system state, not an interaction the attacker must induce.\nS:U - The out-of-bounds write corrupts kernel slab memory within the same kernel security authority, and the resulting RTNL deadlock/panic affects the same OS instance. No VM, IOMMU, or sandbox boundary is crossed.\nC:H - This is a heap out-of-bounds write into adjacent `kmalloc-8`/`kmalloc-16` objects reachable by any unprivileged user, and such slab corruption \u2014 including of SLUB freelist pointers and neighbouring length/index fields \u2014 can be groomed via userspace heap spraying into a kernel memory disclosure primitive. Per kernel scoring guidance, memory corruption leverageable for info disclosure is scored High.\nI:H - `rules[loc++] = i` writes up to 16 bytes into an attacker-sized 4/8/12-byte allocation, a genuine out-of-bounds slab write that lets the attacker overwrite fields of adjacent heap objects. Out-of-bounds writes are scored High as they are the classic basis for control-flow hijacking and privilege escalation.\nA:H - With `rule_cnt = 0` the driver writes through a NULL `rule_buf`, causing an immediate kernel oops, and the OOB variant corrupts slab freelists leading to later crashes. Because `dev_ethtool()` holds `rtnl_lock()` across the call, the oops leaves RTNL permanently held \u2014 wedging all networking configuration system-wide with unkillable D-state tasks, or panicking outright on the `panic_on_oops` appliance/embedded systems typical of mvpp2 hardware."
    }
  }
}
