cve-2024-42108
Vulnerability from cvelistv5
Published
2024-07-30 07:46
Modified
2024-12-19 18:32
Severity ?
Summary
In the Linux kernel, the following vulnerability has been resolved: net: rswitch: Avoid use-after-free in rswitch_poll() The use-after-free is actually in rswitch_tx_free(), which is inlined in rswitch_poll(). Since `skb` and `gq->skbs[gq->dirty]` are in fact the same pointer, the skb is first freed using dev_kfree_skb_any(), then the value in skb->len is used to update the interface statistics. Let's move around the instructions to use skb->len before the skb is freed. This bug is trivial to reproduce using KFENCE. It will trigger a splat every few packets. A simple ARP request or ICMP echo request is enough.
Impacted products
Vendor Product Version
Linux Linux Version: 0aeec4bb6a9fc963932bf3c929bdf27d835d44e9
Version: 271e015b91535dd87fd0f5df0cc3b906c2eddef9
Version: 271e015b91535dd87fd0f5df0cc3b906c2eddef9
Create a notification for this product.
   Linux Linux Version: 6.8
Create a notification for this product.
Show details on NVD website


{
   containers: {
      adp: [
         {
            providerMetadata: {
               dateUpdated: "2024-08-02T04:54:32.138Z",
               orgId: "af854a3a-2127-422b-91ae-364da2661108",
               shortName: "CVE",
            },
            references: [
               {
                  tags: [
                     "x_transferred",
                  ],
                  url: "https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b",
               },
               {
                  tags: [
                     "x_transferred",
                  ],
                  url: "https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67",
               },
            ],
            title: "CVE Program Container",
         },
         {
            metrics: [
               {
                  other: {
                     content: {
                        id: "CVE-2024-42108",
                        options: [
                           {
                              Exploitation: "none",
                           },
                           {
                              Automatable: "no",
                           },
                           {
                              "Technical Impact": "partial",
                           },
                        ],
                        role: "CISA Coordinator",
                        timestamp: "2024-09-10T16:17:39.409257Z",
                        version: "2.0.3",
                     },
                     type: "ssvc",
                  },
               },
            ],
            providerMetadata: {
               dateUpdated: "2024-09-11T17:33:07.014Z",
               orgId: "134c704f-9b21-4f2e-91b3-4a467353bcc0",
               shortName: "CISA-ADP",
            },
            title: "CISA ADP Vulnrichment",
         },
      ],
      cna: {
         affected: [
            {
               defaultStatus: "unaffected",
               product: "Linux",
               programFiles: [
                  "drivers/net/ethernet/renesas/rswitch.c",
               ],
               repo: "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
               vendor: "Linux",
               versions: [
                  {
                     lessThan: "4a41bb9f2b402469d425a1c13359d3b3ea4e6403",
                     status: "affected",
                     version: "0aeec4bb6a9fc963932bf3c929bdf27d835d44e9",
                     versionType: "git",
                  },
                  {
                     lessThan: "92cbbe7759193e3418f38d0d73f8fe125312c58b",
                     status: "affected",
                     version: "271e015b91535dd87fd0f5df0cc3b906c2eddef9",
                     versionType: "git",
                  },
                  {
                     lessThan: "9a0c28efeec6383ef22e97437616b920e7320b67",
                     status: "affected",
                     version: "271e015b91535dd87fd0f5df0cc3b906c2eddef9",
                     versionType: "git",
                  },
               ],
            },
            {
               defaultStatus: "affected",
               product: "Linux",
               programFiles: [
                  "drivers/net/ethernet/renesas/rswitch.c",
               ],
               repo: "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
               vendor: "Linux",
               versions: [
                  {
                     status: "affected",
                     version: "6.8",
                  },
                  {
                     lessThan: "6.8",
                     status: "unaffected",
                     version: "0",
                     versionType: "semver",
                  },
                  {
                     lessThanOrEqual: "6.9.*",
                     status: "unaffected",
                     version: "6.9.9",
                     versionType: "semver",
                  },
                  {
                     lessThanOrEqual: "*",
                     status: "unaffected",
                     version: "6.10",
                     versionType: "original_commit_for_fix",
                  },
               ],
            },
         ],
         descriptions: [
            {
               lang: "en",
               value: "In the Linux kernel, the following vulnerability has been resolved:\n\nnet: rswitch: Avoid use-after-free in rswitch_poll()\n\nThe use-after-free is actually in rswitch_tx_free(), which is inlined in\nrswitch_poll(). Since `skb` and `gq->skbs[gq->dirty]` are in fact the\nsame pointer, the skb is first freed using dev_kfree_skb_any(), then the\nvalue in skb->len is used to update the interface statistics.\n\nLet's move around the instructions to use skb->len before the skb is\nfreed.\n\nThis bug is trivial to reproduce using KFENCE. It will trigger a splat\nevery few packets. A simple ARP request or ICMP echo request is enough.",
            },
         ],
         providerMetadata: {
            dateUpdated: "2024-12-19T18:32:36.917Z",
            orgId: "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            shortName: "Linux",
         },
         references: [
            {
               url: "https://git.kernel.org/stable/c/4a41bb9f2b402469d425a1c13359d3b3ea4e6403",
            },
            {
               url: "https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b",
            },
            {
               url: "https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67",
            },
         ],
         title: "net: rswitch: Avoid use-after-free in rswitch_poll()",
         x_generator: {
            engine: "bippy-5f407fcff5a0",
         },
      },
   },
   cveMetadata: {
      assignerOrgId: "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
      assignerShortName: "Linux",
      cveId: "CVE-2024-42108",
      datePublished: "2024-07-30T07:46:03.517Z",
      dateReserved: "2024-07-29T15:50:41.176Z",
      dateUpdated: "2024-12-19T18:32:36.917Z",
      state: "PUBLISHED",
   },
   dataType: "CVE_RECORD",
   dataVersion: "5.1",
   "vulnerability-lookup:meta": {
      nvd: "{\"cve\":{\"id\":\"CVE-2024-42108\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2024-07-30T08:15:03.333\",\"lastModified\":\"2024-12-19T19:15:07.023\",\"vulnStatus\":\"Modified\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nnet: rswitch: Avoid use-after-free in rswitch_poll()\\n\\nThe use-after-free is actually in rswitch_tx_free(), which is inlined in\\nrswitch_poll(). Since `skb` and `gq->skbs[gq->dirty]` are in fact the\\nsame pointer, the skb is first freed using dev_kfree_skb_any(), then the\\nvalue in skb->len is used to update the interface statistics.\\n\\nLet's move around the instructions to use skb->len before the skb is\\nfreed.\\n\\nThis bug is trivial to reproduce using KFENCE. It will trigger a splat\\nevery few packets. A simple ARP request or ICMP echo request is enough.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: net: rswitch: Evite el use after free en rswitch_poll() El use after free está en realidad en rswitch_tx_free(), que está incluido en rswitch_poll(). Dado que `skb` y `gq->skbs[gq->dirty]` son de hecho el mismo puntero, el skb primero se libera usando dev_kfree_skb_any(), luego el valor en skb->len se usa para actualizar las estadísticas de la interfaz. Avancemos por las instrucciones para usar skb->len antes de liberar el skb. Este error es trivial de reproducir usando KFENCE. Activará un sonido cada pocos paquetes. Una simple solicitud ARP o una solicitud de eco ICMP es suficiente.\"}],\"metrics\":{\"cvssMetricV31\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"cvssData\":{\"version\":\"3.1\",\"vectorString\":\"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H\",\"baseScore\":7.8,\"baseSeverity\":\"HIGH\",\"attackVector\":\"LOCAL\",\"attackComplexity\":\"LOW\",\"privilegesRequired\":\"LOW\",\"userInteraction\":\"NONE\",\"scope\":\"UNCHANGED\",\"confidentialityImpact\":\"HIGH\",\"integrityImpact\":\"HIGH\",\"availabilityImpact\":\"HIGH\"},\"exploitabilityScore\":1.8,\"impactScore\":5.9}]},\"weaknesses\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"description\":[{\"lang\":\"en\",\"value\":\"CWE-416\"}]}],\"configurations\":[{\"nodes\":[{\"operator\":\"OR\",\"negate\":false,\"cpeMatch\":[{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"6.8\",\"versionEndExcluding\":\"6.9.9\",\"matchCriteriaId\":\"5726EB4D-ED18-4DEC-B0C0-A525D33487E1\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/4a41bb9f2b402469d425a1c13359d3b3ea4e6403\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\",\"tags\":[\"Patch\"]}]}}",
      vulnrichment: {
         containers: "{\"adp\": [{\"title\": \"CVE Program Container\", \"references\": [{\"url\": \"https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67\", \"tags\": [\"x_transferred\"]}], \"providerMetadata\": {\"orgId\": \"af854a3a-2127-422b-91ae-364da2661108\", \"shortName\": \"CVE\", \"dateUpdated\": \"2024-08-02T04:54:32.138Z\"}}, {\"title\": \"CISA ADP Vulnrichment\", \"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2024-42108\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2024-09-10T16:17:39.409257Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2024-09-11T12:42:14.603Z\"}}], \"cna\": {\"title\": \"net: rswitch: Avoid use-after-free in rswitch_poll()\", \"affected\": [{\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"0aeec4bb6a9fc963932bf3c929bdf27d835d44e9\", \"lessThan\": \"4a41bb9f2b402469d425a1c13359d3b3ea4e6403\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"271e015b91535dd87fd0f5df0cc3b906c2eddef9\", \"lessThan\": \"92cbbe7759193e3418f38d0d73f8fe125312c58b\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"271e015b91535dd87fd0f5df0cc3b906c2eddef9\", \"lessThan\": \"9a0c28efeec6383ef22e97437616b920e7320b67\", \"versionType\": \"git\"}], \"programFiles\": [\"drivers/net/ethernet/renesas/rswitch.c\"], \"defaultStatus\": \"unaffected\"}, {\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"6.8\"}, {\"status\": \"unaffected\", \"version\": \"0\", \"lessThan\": \"6.8\", \"versionType\": \"semver\"}, {\"status\": \"unaffected\", \"version\": \"6.9.9\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.9.*\"}, {\"status\": \"unaffected\", \"version\": \"6.10\", \"versionType\": \"original_commit_for_fix\", \"lessThanOrEqual\": \"*\"}], \"programFiles\": [\"drivers/net/ethernet/renesas/rswitch.c\"], \"defaultStatus\": \"affected\"}], \"references\": [{\"url\": \"https://git.kernel.org/stable/c/4a41bb9f2b402469d425a1c13359d3b3ea4e6403\"}, {\"url\": \"https://git.kernel.org/stable/c/92cbbe7759193e3418f38d0d73f8fe125312c58b\"}, {\"url\": \"https://git.kernel.org/stable/c/9a0c28efeec6383ef22e97437616b920e7320b67\"}], \"x_generator\": {\"engine\": \"bippy-5f407fcff5a0\"}, \"descriptions\": [{\"lang\": \"en\", \"value\": \"In the Linux kernel, the following vulnerability has been resolved:\\n\\nnet: rswitch: Avoid use-after-free in rswitch_poll()\\n\\nThe use-after-free is actually in rswitch_tx_free(), which is inlined in\\nrswitch_poll(). Since `skb` and `gq->skbs[gq->dirty]` are in fact the\\nsame pointer, the skb is first freed using dev_kfree_skb_any(), then the\\nvalue in skb->len is used to update the interface statistics.\\n\\nLet's move around the instructions to use skb->len before the skb is\\nfreed.\\n\\nThis bug is trivial to reproduce using KFENCE. It will trigger a splat\\nevery few packets. A simple ARP request or ICMP echo request is enough.\"}], \"providerMetadata\": {\"orgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"shortName\": \"Linux\", \"dateUpdated\": \"2024-12-19T18:32:36.917Z\"}}}",
         cveMetadata: "{\"cveId\": \"CVE-2024-42108\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2024-12-19T18:32:36.917Z\", \"dateReserved\": \"2024-07-29T15:50:41.176Z\", \"assignerOrgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"datePublished\": \"2024-07-30T07:46:03.517Z\", \"assignerShortName\": \"Linux\"}",
         dataType: "CVE_RECORD",
         dataVersion: "5.1",
      },
   },
}


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.
  • 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.