CVE-2024-58240 (GCVE-0-2024-58240)

Vulnerability from cvelistv5 – Published: 2025-08-28 09:40 – Updated: 2026-08-05 11:47
VLAI
Title
tls: separate no-async decryption request handling from async
Summary
In the Linux kernel, the following vulnerability has been resolved: tls: separate no-async decryption request handling from async If we're not doing async, the handling is much simpler. There's no reference counting, we just need to wait for the completion to wake us up and return its result. We should preferably also use a separate crypto_wait. I'm not seeing a UAF as I did in the past, I think aec7961916f3 ("tls: fix race between async notify and socket close") took care of it. This will make the next fix easier.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 3c4d7559159bfe1e3b94df3a657b2cda3a34e218 , < 48905146d11dbf1ddbb2967319016a83976953f5 (git)
Affected: 3c4d7559159bfe1e3b94df3a657b2cda3a34e218 , < dec5b6e7b211e405d3bcb504562ab21aa7e5a64d (git)
Affected: 3c4d7559159bfe1e3b94df3a657b2cda3a34e218 , < 999115298017a675d8ddf61414fc7a85c89f1186 (git)
Affected: 3c4d7559159bfe1e3b94df3a657b2cda3a34e218 , < 41532b785e9d79636b3815a64ddf6a096647d011 (git)
Create a notification for this product.
Linux Linux Affected: 4.13
Unaffected: 0 , < 4.13 (semver)
Unaffected: 6.1.149 , ≤ 6.1.* (semver)
Unaffected: 6.6.21 , ≤ 6.6.* (semver)
Unaffected: 6.7.9 , ≤ 6.7.* (semver)
Unaffected: 6.8 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Siemens SIMATIC CN 4100 Affected: 0 , < V5.0 (custom)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "adp": [
      {
        "providerMetadata": {
          "dateUpdated": "2025-11-03T17:31:32.503Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "url": "https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html"
          }
        ],
        "title": "CVE Program Container"
      },
      {
        "affected": [
          {
            "defaultStatus": "unknown",
            "product": "SIMATIC CN 4100",
            "vendor": "Siemens",
            "versions": [
              {
                "lessThan": "V5.0",
                "status": "affected",
                "version": "0",
                "versionType": "custom"
              }
            ]
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2026-05-12T12:02:08.000Z",
          "orgId": "0b142b55-0307-4c5a-b3c9-f314f3fb7c5e",
          "shortName": "siemens-SADP"
        },
        "references": [
          {
            "url": "https://cert-portal.siemens.com/productcert/html/ssa-032379.html"
          }
        ],
        "x_adpType": "supplier"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "net/tls/tls_sw.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "48905146d11dbf1ddbb2967319016a83976953f5",
              "status": "affected",
              "version": "3c4d7559159bfe1e3b94df3a657b2cda3a34e218",
              "versionType": "git"
            },
            {
              "lessThan": "dec5b6e7b211e405d3bcb504562ab21aa7e5a64d",
              "status": "affected",
              "version": "3c4d7559159bfe1e3b94df3a657b2cda3a34e218",
              "versionType": "git"
            },
            {
              "lessThan": "999115298017a675d8ddf61414fc7a85c89f1186",
              "status": "affected",
              "version": "3c4d7559159bfe1e3b94df3a657b2cda3a34e218",
              "versionType": "git"
            },
            {
              "lessThan": "41532b785e9d79636b3815a64ddf6a096647d011",
              "status": "affected",
              "version": "3c4d7559159bfe1e3b94df3a657b2cda3a34e218",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "net/tls/tls_sw.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "4.13"
            },
            {
              "lessThan": "4.13",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.1.*",
              "status": "unaffected",
              "version": "6.1.149",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.21",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.7.*",
              "status": "unaffected",
              "version": "6.7.9",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.8",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1.149",
                  "versionStartIncluding": "4.13",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.21",
                  "versionStartIncluding": "4.13",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.7.9",
                  "versionStartIncluding": "4.13",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.8",
                  "versionStartIncluding": "4.13",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\ntls: separate no-async decryption request handling from async\n\nIf we\u0027re not doing async, the handling is much simpler. There\u0027s no\nreference counting, we just need to wait for the completion to wake us\nup and return its result.\n\nWe should preferably also use a separate crypto_wait. I\u0027m not seeing a\nUAF as I did in the past, I think aec7961916f3 (\"tls: fix race between\nasync notify and socket close\") took care of it.\n\nThis will make the next fix easier."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 9.8,
            "baseSeverity": "CRITICAL",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:N - The vulnerable code is kTLS record decryption (net/tls/tls_sw.c), driven entirely by TLS records arriving on a TCP socket from a remote peer or an on-path injector. Per kernel scoring guidance, kTLS bugs triggered by remote peer data are Network.\nAC:L - The remote peer controls every input to the race \u2014 record type (DATA\u2192async vs. alert/handshake\u2192sync), record rate (to fill the crypto backlog and force -EBUSY), and authentication failure (-EBADMSG) \u2014 so it creates both sides of the race and can retry indefinitely on a long-lived connection. Async AEAD (SIMD/cryptd AES-GCM, QAT, Chelsio) with TLS 1.2 is a normal kTLS deployment, not a rare config.\nPR:N - The attacker is the remote TLS peer of a kTLS socket (e.g. an anonymous client of an nginx/HAProxy/NVMe-TCP-TLS server) or an on-path attacker injecting records into an established connection, and holds no credentials or privileges on the target system. No authentication gate exists on the receive path.\nUI:N - Triggering requires only that the kTLS-enabled application perform its normal recvmsg() on the socket while the attacker sends crafted record sequences. No victim action beyond ordinary server operation is needed.\nS:U - The corruption is kernel heap and page memory within the same kernel security authority; there is no VM, IOMMU, or sandbox boundary crossed.\nC:H - The still-queued aead_request, its scatterlists and the output pages are freed and reallocated while the crypto engine continues to use them, giving an attacker who sprays the freed slab both a read primitive over reused kernel memory and plaintext written into unrelated allocations; additionally a lost -EBADMSG can leak a failed record\u0027s contents to userspace.\nI:H - The crypto driver writes decrypted output into kfree()\u0027d memory and put_page()\u0027d pages after they may be reallocated, an attacker-influenced out-of-bounds write usable for heap grooming and control-flow hijack; the clobbered ctx-\u003easync_wait.err can also suppress an authentication failure and admit forged record data.\nA:H - The use-after-free readily oopses or panics the kernel, and the mis-attributed completion leaves recvmsg() blocked forever in uninterruptible wait_for_completion() holding the socket lock, producing an unkillable D-state task and a permanently wedged socket."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T11:47:50.174Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/48905146d11dbf1ddbb2967319016a83976953f5"
        },
        {
          "url": "https://git.kernel.org/stable/c/dec5b6e7b211e405d3bcb504562ab21aa7e5a64d"
        },
        {
          "url": "https://git.kernel.org/stable/c/999115298017a675d8ddf61414fc7a85c89f1186"
        },
        {
          "url": "https://git.kernel.org/stable/c/41532b785e9d79636b3815a64ddf6a096647d011"
        }
      ],
      "title": "tls: separate no-async decryption request handling from async",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-58240",
    "datePublished": "2025-08-28T09:40:33.466Z",
    "dateReserved": "2025-04-16T07:19:43.804Z",
    "dateUpdated": "2026-08-05T11:47:50.174Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2024-58240",
      "date": "2026-08-06",
      "epss": "0.00313",
      "percentile": "0.23711"
    },
    "microsoft_vex": {
      "current_release_date": "2026-03-31T15:08:16.000Z",
      "cve": "CVE-2024-58240",
      "id": "msrc_CVE-2024-58240",
      "initial_release_date": "2025-08-02T00:00:00.000Z",
      "product_status:known_affected": "3",
      "source": "Microsoft CSAF VEX",
      "status": "final",
      "title": "tls: separate no-async decryption request handling from async",
      "url": "https://msrc.microsoft.com/csaf/vex/2025/msrc_cve-2024-58240.json",
      "version": "4"
    },
    "nvd": "{\"cve\":{\"id\":\"CVE-2024-58240\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-08-28T10:15:31.780\",\"lastModified\":\"2026-08-04T11:22:40.760\",\"vulnStatus\":\"Modified\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\ntls: separate no-async decryption request handling from async\\n\\nIf we\u0027re not doing async, the handling is much simpler. There\u0027s no\\nreference counting, we just need to wait for the completion to wake us\\nup and return its result.\\n\\nWe should preferably also use a separate crypto_wait. I\u0027m not seeing a\\nUAF as I did in the past, I think aec7961916f3 (\\\"tls: fix race between\\nasync notify and socket close\\\") took care of it.\\n\\nThis will make the next fix easier.\"}],\"affected\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"affectedData\":[{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"unaffected\",\"programFiles\":[\"net/tls/tls_sw.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"3c4d7559159bfe1e3b94df3a657b2cda3a34e218\",\"lessThan\":\"48905146d11dbf1ddbb2967319016a83976953f5\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"3c4d7559159bfe1e3b94df3a657b2cda3a34e218\",\"lessThan\":\"dec5b6e7b211e405d3bcb504562ab21aa7e5a64d\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"3c4d7559159bfe1e3b94df3a657b2cda3a34e218\",\"lessThan\":\"999115298017a675d8ddf61414fc7a85c89f1186\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"3c4d7559159bfe1e3b94df3a657b2cda3a34e218\",\"lessThan\":\"41532b785e9d79636b3815a64ddf6a096647d011\",\"versionType\":\"git\",\"status\":\"affected\"}]},{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"affected\",\"programFiles\":[\"net/tls/tls_sw.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"4.13\",\"status\":\"affected\"},{\"version\":\"0\",\"lessThan\":\"4.13\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.1.149\",\"lessThanOrEqual\":\"6.1.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.6.21\",\"lessThanOrEqual\":\"6.6.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.7.9\",\"lessThanOrEqual\":\"6.7.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.8\",\"lessThanOrEqual\":\"*\",\"versionType\":\"original_commit_for_fix\",\"status\":\"unaffected\"}]}]},{\"source\":\"0b142b55-0307-4c5a-b3c9-f314f3fb7c5e\",\"affectedData\":[{\"vendor\":\"Siemens\",\"product\":\"SIMATIC CN 4100\",\"defaultStatus\":\"unknown\",\"versions\":[{\"version\":\"0\",\"lessThan\":\"V5.0\",\"versionType\":\"custom\",\"status\":\"affected\"}]}]}],\"metrics\":{\"cvssMetricV31\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"type\":\"Secondary\",\"cvssData\":{\"version\":\"3.1\",\"vectorString\":\"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H\",\"baseScore\":9.8,\"baseSeverity\":\"CRITICAL\",\"attackVector\":\"NETWORK\",\"attackComplexity\":\"LOW\",\"privilegesRequired\":\"NONE\",\"userInteraction\":\"NONE\",\"scope\":\"UNCHANGED\",\"confidentialityImpact\":\"HIGH\",\"integrityImpact\":\"HIGH\",\"availabilityImpact\":\"HIGH\"},\"exploitabilityScore\":3.9,\"impactScore\":5.9},{\"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\":\"4.13\",\"versionEndExcluding\":\"6.1.149\",\"matchCriteriaId\":\"D8B7DA04-A2AD-4FA0-AEDC-03DD7814BE3A\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"6.2\",\"versionEndExcluding\":\"6.6.21\",\"matchCriteriaId\":\"B19074A2-9FE5-4E7D-9E2D-020F95013ADA\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"6.7\",\"versionEndExcluding\":\"6.7.9\",\"matchCriteriaId\":\"1C538467-EDA0-4A9A-82EB-2925DE9FF827\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc1:*:*:*:*:*:*\",\"matchCriteriaId\":\"B9F4EA73-0894-400F-A490-3A397AB7A517\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc2:*:*:*:*:*:*\",\"matchCriteriaId\":\"056BD938-0A27-4569-B391-30578B309EE3\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc3:*:*:*:*:*:*\",\"matchCriteriaId\":\"F02056A5-B362-4370-9FF8-6F0BD384D520\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc4:*:*:*:*:*:*\",\"matchCriteriaId\":\"62075ACE-B2A0-4B16-829D-B3DA5AE5CC41\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc5:*:*:*:*:*:*\",\"matchCriteriaId\":\"A780F817-2A77-4130-A9B7-5C25606314E3\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.8:rc6:*:*:*:*:*:*\",\"matchCriteriaId\":\"AEB9199B-AB8F-4877-8964-E2BA95B5F15C\"}]}]},{\"nodes\":[{\"operator\":\"OR\",\"negate\":false,\"cpeMatch\":[{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:*\",\"matchCriteriaId\":\"FA6FEEC2-9F11-4643-8827-749718254FED\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/41532b785e9d79636b3815a64ddf6a096647d011\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/48905146d11dbf1ddbb2967319016a83976953f5\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/999115298017a675d8ddf61414fc7a85c89f1186\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/dec5b6e7b211e405d3bcb504562ab21aa7e5a64d\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\",\"tags\":[\"Third Party Advisory\"]},{\"url\":\"https://cert-portal.siemens.com/productcert/html/ssa-032379.html\",\"source\":\"0b142b55-0307-4c5a-b3c9-f314f3fb7c5e\"}]}}",
    "redhat_vex": {
      "aggregate_severity": "Moderate",
      "current_release_date": "2026-08-05T03:46:26+00:00",
      "cve": "CVE-2024-58240",
      "id": "CVE-2024-58240",
      "initial_release_date": "2024-01-01T00:00:00+00:00",
      "product_status:fixed": "239",
      "product_status:known_affected": "156",
      "product_status:known_not_affected": "118",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: tls: separate no-async decryption request handling from async",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2024/cve-2024-58240.json",
      "version": "3"
    },
    "suse_vex": {
      "aggregate_severity": "low",
      "current_release_date": "2026-07-03T03:58:34Z",
      "cve": "CVE-2024-58240",
      "id": "CVE-2024-58240",
      "initial_release_date": "2025-08-28T23:31:14Z",
      "product_status:known_affected": "361",
      "product_status:known_not_affected": "79",
      "product_status:recommended": "654",
      "source": "SUSE CSAF VEX",
      "status": "interim",
      "title": "SUSE CVE CVE-2024-58240",
      "url": "https://ftp.suse.com/pub/projects/security/csaf-vex/cve-2024-58240.json",
      "version": "31"
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

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.

Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…

Loading…