cve-2024-27010
Vulnerability from cvelistv5
Published
2024-05-01 05:29
Modified
2024-08-02 00:21
Severity
Summary
net/sched: Fix mirred deadlock on device recursion
Impacted products
VendorProduct
LinuxLinux
LinuxLinux
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2024-27010",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-07-17T15:03:35.408191Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-07-17T15:03:46.655Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-02T00:21:05.885Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/e6b90468da4dae2281a6e381107f411efb48b0ef"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/0f022d32c3eca477fbf79a205243a6123ed0fe11"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "include/net/sch_generic.h",
            "net/core/dev.c",
            "net/sched/sch_generic.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "e6b90468da4d",
              "status": "affected",
              "version": "e578d9c02587",
              "versionType": "git"
            },
            {
              "lessThan": "0f022d32c3ec",
              "status": "affected",
              "version": "e578d9c02587",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "include/net/sch_generic.h",
            "net/core/dev.c",
            "net/sched/sch_generic.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "4.2"
            },
            {
              "lessThan": "4.2",
              "status": "unaffected",
              "version": "0",
              "versionType": "custom"
            },
            {
              "lessThanOrEqual": "6.8.*",
              "status": "unaffected",
              "version": "6.8.8",
              "versionType": "custom"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.9",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nnet/sched: Fix mirred deadlock on device recursion\n\nWhen the mirred action is used on a classful egress qdisc and a packet is\nmirrored or redirected to self we hit a qdisc lock deadlock.\nSee trace below.\n\n[..... other info removed for brevity....]\n[   82.890906]\n[   82.890906] ============================================\n[   82.890906] WARNING: possible recursive locking detected\n[   82.890906] 6.8.0-05205-g77fadd89fe2d-dirty #213 Tainted: G        W\n[   82.890906] --------------------------------------------\n[   82.890906] ping/418 is trying to acquire lock:\n[   82.890906] ffff888006994110 (\u0026sch-\u003eq.lock){+.-.}-{3:3}, at:\n__dev_queue_xmit+0x1778/0x3550\n[   82.890906]\n[   82.890906] but task is already holding lock:\n[   82.890906] ffff888006994110 (\u0026sch-\u003eq.lock){+.-.}-{3:3}, at:\n__dev_queue_xmit+0x1778/0x3550\n[   82.890906]\n[   82.890906] other info that might help us debug this:\n[   82.890906]  Possible unsafe locking scenario:\n[   82.890906]\n[   82.890906]        CPU0\n[   82.890906]        ----\n[   82.890906]   lock(\u0026sch-\u003eq.lock);\n[   82.890906]   lock(\u0026sch-\u003eq.lock);\n[   82.890906]\n[   82.890906]  *** DEADLOCK ***\n[   82.890906]\n[..... other info removed for brevity....]\n\nExample setup (eth0-\u003eeth0) to recreate\ntc qdisc add dev eth0 root handle 1: htb default 30\ntc filter add dev eth0 handle 1: protocol ip prio 2 matchall \\\n     action mirred egress redirect dev eth0\n\nAnother example(eth0-\u003eeth1-\u003eeth0) to recreate\ntc qdisc add dev eth0 root handle 1: htb default 30\ntc filter add dev eth0 handle 1: protocol ip prio 2 matchall \\\n     action mirred egress redirect dev eth1\n\ntc qdisc add dev eth1 root handle 1: htb default 30\ntc filter add dev eth1 handle 1: protocol ip prio 2 matchall \\\n     action mirred egress redirect dev eth0\n\nWe fix this by adding an owner field (CPU id) to struct Qdisc set after\nroot qdisc is entered. When the softirq enters it a second time, if the\nqdisc owner is the same CPU, the packet is dropped to break the loop."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2024-05-29T05:26:58.312Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/e6b90468da4dae2281a6e381107f411efb48b0ef"
        },
        {
          "url": "https://git.kernel.org/stable/c/0f022d32c3eca477fbf79a205243a6123ed0fe11"
        }
      ],
      "title": "net/sched: Fix mirred deadlock on device recursion",
      "x_generator": {
        "engine": "bippy-a5840b7849dd"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-27010",
    "datePublished": "2024-05-01T05:29:23.494Z",
    "dateReserved": "2024-02-19T14:20:24.208Z",
    "dateUpdated": "2024-08-02T00:21:05.885Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "meta": {
    "nvd": "{\"cve\":{\"id\":\"CVE-2024-27010\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2024-05-01T06:15:19.467\",\"lastModified\":\"2024-05-13T08:15:11.933\",\"vulnStatus\":\"Awaiting Analysis\",\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nnet/sched: Fix mirred deadlock on device recursion\\n\\nWhen the mirred action is used on a classful egress qdisc and a packet is\\nmirrored or redirected to self we hit a qdisc lock deadlock.\\nSee trace below.\\n\\n[..... other info removed for brevity....]\\n[   82.890906]\\n[   82.890906] ============================================\\n[   82.890906] WARNING: possible recursive locking detected\\n[   82.890906] 6.8.0-05205-g77fadd89fe2d-dirty #213 Tainted: G        W\\n[   82.890906] --------------------------------------------\\n[   82.890906] ping/418 is trying to acquire lock:\\n[   82.890906] ffff888006994110 (\u0026sch-\u003eq.lock){+.-.}-{3:3}, at:\\n__dev_queue_xmit+0x1778/0x3550\\n[   82.890906]\\n[   82.890906] but task is already holding lock:\\n[   82.890906] ffff888006994110 (\u0026sch-\u003eq.lock){+.-.}-{3:3}, at:\\n__dev_queue_xmit+0x1778/0x3550\\n[   82.890906]\\n[   82.890906] other info that might help us debug this:\\n[   82.890906]  Possible unsafe locking scenario:\\n[   82.890906]\\n[   82.890906]        CPU0\\n[   82.890906]        ----\\n[   82.890906]   lock(\u0026sch-\u003eq.lock);\\n[   82.890906]   lock(\u0026sch-\u003eq.lock);\\n[   82.890906]\\n[   82.890906]  *** DEADLOCK ***\\n[   82.890906]\\n[..... other info removed for brevity....]\\n\\nExample setup (eth0-\u003eeth0) to recreate\\ntc qdisc add dev eth0 root handle 1: htb default 30\\ntc filter add dev eth0 handle 1: protocol ip prio 2 matchall \\\\\\n     action mirred egress redirect dev eth0\\n\\nAnother example(eth0-\u003eeth1-\u003eeth0) to recreate\\ntc qdisc add dev eth0 root handle 1: htb default 30\\ntc filter add dev eth0 handle 1: protocol ip prio 2 matchall \\\\\\n     action mirred egress redirect dev eth1\\n\\ntc qdisc add dev eth1 root handle 1: htb default 30\\ntc filter add dev eth1 handle 1: protocol ip prio 2 matchall \\\\\\n     action mirred egress redirect dev eth0\\n\\nWe fix this by adding an owner field (CPU id) to struct Qdisc set after\\nroot qdisc is entered. When the softirq enters it a second time, if the\\nqdisc owner is the same CPU, the packet is dropped to break the loop.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se resolvi\u00f3 la siguiente vulnerabilidad: net/sched: corrige el punto muerto reflejado en la recursividad del dispositivo Cuando la acci\u00f3n reflejada se utiliza en una qdisc de salida con clase y un paquete se refleja o redirige a uno mismo, llegamos a un punto muerto de bloqueo de qdisc. Vea el rastro a continuaci\u00f3n. [..... otra informaci\u00f3n eliminada por brevedad....] [ 82.890906] [ 82.890906] ============================= ================ [82.890906] ADVERTENCIA: posible bloqueo recursivo detectado [82.890906] 6.8.0-05205-g77fadd89fe2d-dirty #213 Contaminado: GW [82.890906] ----- --------------------------------------- [ 82.890906] ping/418 est\u00e1 intentando adquirir el bloqueo : [ 82.890906] ffff888006994110 (\u0026amp;sch-\u0026gt;q.lock){+.-.}-{3:3}, en: __dev_queue_xmit+0x1778/0x3550 [ 82.890906] [ 82.890906] pero la tarea ya mantiene el bloqueo: [ 82.890906] 88006994110 (\u0026amp;sch-\u0026gt;q.lock){+.-.}-{3:3}, en: __dev_queue_xmit+0x1778/0x3550 [ 82.890906] [ 82.890906] otra informaci\u00f3n que podr\u00eda ayudarnos a depurar esto: [ 82.890906] Posible escenario de bloqueo inseguro : [ 82.890906] [ 82.890906] CPU0 [ 82.890906] ---- [ 82.890906] bloqueo(\u0026amp;sch-\u0026gt;q.lock); [ 82.890906] bloqueo(\u0026amp;sch-\u0026gt;q.lock); [ 82.890906] [ 82.890906] *** DEADLOCK *** [ 82.890906] [..... otra informaci\u00f3n eliminada por brevedad....] Ejemplo de configuraci\u00f3n (eth0-\u0026gt;eth0) para recrear tc qdisc agregar dev eth0 identificador ra\u00edz 1 : htb default 30 tc filter add dev eth0 handle 1: protocolo ip prio 2 matchall \\\\ action mirred egress redirigir dev eth0 Otro ejemplo (eth0-\u0026gt;eth1-\u0026gt;eth0) para recrear tc qdisc add dev eth0 root handle 1: htb default 30 tc filtro agregar dev eth0 identificador 1: protocolo ip prio 2 matchall \\\\ acci\u00f3n redirecci\u00f3n de salida reflejada dev eth1 tc qdisc agregar dev eth1 identificador ra\u00edz 1: htb predeterminado 30 tc filtro agregar dev eth1 identificador 1: protocolo ip prio 2 matchall \\\\ acci\u00f3n duplicada redirecci\u00f3n de salida dev eth0 Solucionamos esto agregando un campo de propietario (ID de CPU) a la estructura Qdisc establecida despu\u00e9s de ingresar la qdisc ra\u00edz. Cuando el softirq ingresa por segunda vez, si el propietario de la qdisc es la misma CPU, el paquete se descarta para romper el bucle.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/0f022d32c3eca477fbf79a205243a6123ed0fe11\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/e6b90468da4dae2281a6e381107f411efb48b0ef\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}"
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading...

Loading...