CVE-2024-35827 (GCVE-0-2024-35827)

Vulnerability from cvelistv5 – Published: 2024-05-17 13:41 – Updated: 2025-05-04 09:06
VLAI?
Title
io_uring/net: fix overflow check in io_recvmsg_mshot_prep()
Summary
In the Linux kernel, the following vulnerability has been resolved: io_uring/net: fix overflow check in io_recvmsg_mshot_prep() The "controllen" variable is type size_t (unsigned long). Casting it to int could lead to an integer underflow. The check_add_overflow() function considers the type of the destination which is type int. If we add two positive values and the result cannot fit in an integer then that's counted as an overflow. However, if we cast "controllen" to an int and it turns negative, then negative values *can* fit into an int type so there is no overflow. Good: 100 + (unsigned long)-4 = 96 <-- overflow Bad: 100 + (int)-4 = 96 <-- no overflow I deleted the cast of the sizeof() as well. That's not a bug but the cast is unnecessary.
Severity ?
No CVSS data available.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 9b0fc3c054ff2eb13753104884f1045b5bb3a627 , < 868ec868616438df487b9e2baa5a99f8662cc47c (git)
Affected: 9b0fc3c054ff2eb13753104884f1045b5bb3a627 , < 59a534690ecc3af72c6ab121aeac1237a4adae66 (git)
Affected: 9b0fc3c054ff2eb13753104884f1045b5bb3a627 , < 0c8c74bb59e7d77554016efc34c2d10376985e5e (git)
Affected: 9b0fc3c054ff2eb13753104884f1045b5bb3a627 , < b6563ad0d599110bd5cf8f56c47d279c3ed796fe (git)
Affected: 9b0fc3c054ff2eb13753104884f1045b5bb3a627 , < 8ede3db5061bb1fe28e2c9683329aafa89d2b1b4 (git)
Create a notification for this product.
    Linux Linux Affected: 6.0
Unaffected: 0 , < 6.0 (semver)
Unaffected: 6.1.83 , ≤ 6.1.* (semver)
Unaffected: 6.6.23 , ≤ 6.6.* (semver)
Unaffected: 6.7.11 , ≤ 6.7.* (semver)
Unaffected: 6.8.2 , ≤ 6.8.* (semver)
Unaffected: 6.9 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2024-35827",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-05-17T15:12:59.146861Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-06-04T17:34:28.876Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-02T03:21:48.467Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/868ec868616438df487b9e2baa5a99f8662cc47c"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/59a534690ecc3af72c6ab121aeac1237a4adae66"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/0c8c74bb59e7d77554016efc34c2d10376985e5e"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/b6563ad0d599110bd5cf8f56c47d279c3ed796fe"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/8ede3db5061bb1fe28e2c9683329aafa89d2b1b4"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "io_uring/net.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "868ec868616438df487b9e2baa5a99f8662cc47c",
              "status": "affected",
              "version": "9b0fc3c054ff2eb13753104884f1045b5bb3a627",
              "versionType": "git"
            },
            {
              "lessThan": "59a534690ecc3af72c6ab121aeac1237a4adae66",
              "status": "affected",
              "version": "9b0fc3c054ff2eb13753104884f1045b5bb3a627",
              "versionType": "git"
            },
            {
              "lessThan": "0c8c74bb59e7d77554016efc34c2d10376985e5e",
              "status": "affected",
              "version": "9b0fc3c054ff2eb13753104884f1045b5bb3a627",
              "versionType": "git"
            },
            {
              "lessThan": "b6563ad0d599110bd5cf8f56c47d279c3ed796fe",
              "status": "affected",
              "version": "9b0fc3c054ff2eb13753104884f1045b5bb3a627",
              "versionType": "git"
            },
            {
              "lessThan": "8ede3db5061bb1fe28e2c9683329aafa89d2b1b4",
              "status": "affected",
              "version": "9b0fc3c054ff2eb13753104884f1045b5bb3a627",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "io_uring/net.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.0"
            },
            {
              "lessThan": "6.0",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.1.*",
              "status": "unaffected",
              "version": "6.1.83",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.23",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.7.*",
              "status": "unaffected",
              "version": "6.7.11",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.8.*",
              "status": "unaffected",
              "version": "6.8.2",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.9",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1.83",
                  "versionStartIncluding": "6.0",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.23",
                  "versionStartIncluding": "6.0",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.7.11",
                  "versionStartIncluding": "6.0",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.8.2",
                  "versionStartIncluding": "6.0",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.9",
                  "versionStartIncluding": "6.0",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nio_uring/net: fix overflow check in io_recvmsg_mshot_prep()\n\nThe \"controllen\" variable is type size_t (unsigned long).  Casting it\nto int could lead to an integer underflow.\n\nThe check_add_overflow() function considers the type of the destination\nwhich is type int.  If we add two positive values and the result cannot\nfit in an integer then that\u0027s counted as an overflow.\n\nHowever, if we cast \"controllen\" to an int and it turns negative, then\nnegative values *can* fit into an int type so there is no overflow.\n\nGood: 100 + (unsigned long)-4 = 96  \u003c-- overflow\n Bad: 100 + (int)-4 = 96 \u003c-- no overflow\n\nI deleted the cast of the sizeof() as well.  That\u0027s not a bug but the\ncast is unnecessary."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2025-05-04T09:06:16.892Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/868ec868616438df487b9e2baa5a99f8662cc47c"
        },
        {
          "url": "https://git.kernel.org/stable/c/59a534690ecc3af72c6ab121aeac1237a4adae66"
        },
        {
          "url": "https://git.kernel.org/stable/c/0c8c74bb59e7d77554016efc34c2d10376985e5e"
        },
        {
          "url": "https://git.kernel.org/stable/c/b6563ad0d599110bd5cf8f56c47d279c3ed796fe"
        },
        {
          "url": "https://git.kernel.org/stable/c/8ede3db5061bb1fe28e2c9683329aafa89d2b1b4"
        }
      ],
      "title": "io_uring/net: fix overflow check in io_recvmsg_mshot_prep()",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-35827",
    "datePublished": "2024-05-17T13:41:09.193Z",
    "dateReserved": "2024-05-17T12:19:12.347Z",
    "dateUpdated": "2025-05-04T09:06:16.892Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "vulnerability-lookup:meta": {
    "vulnrichment": {
      "containers": "{\"adp\": [{\"title\": \"CVE Program Container\", \"references\": [{\"url\": \"https://git.kernel.org/stable/c/868ec868616438df487b9e2baa5a99f8662cc47c\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/59a534690ecc3af72c6ab121aeac1237a4adae66\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/0c8c74bb59e7d77554016efc34c2d10376985e5e\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/b6563ad0d599110bd5cf8f56c47d279c3ed796fe\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/8ede3db5061bb1fe28e2c9683329aafa89d2b1b4\", \"tags\": [\"x_transferred\"]}], \"providerMetadata\": {\"orgId\": \"af854a3a-2127-422b-91ae-364da2661108\", \"shortName\": \"CVE\", \"dateUpdated\": \"2024-08-02T03:21:48.467Z\"}}, {\"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2024-35827\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2024-05-17T15:12:59.146861Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2024-05-23T19:01:24.547Z\"}, \"title\": \"CISA ADP Vulnrichment\"}], \"cna\": {\"title\": \"io_uring/net: fix overflow check in io_recvmsg_mshot_prep()\", \"affected\": [{\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"9b0fc3c054ff2eb13753104884f1045b5bb3a627\", \"lessThan\": \"868ec868616438df487b9e2baa5a99f8662cc47c\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"9b0fc3c054ff2eb13753104884f1045b5bb3a627\", \"lessThan\": \"59a534690ecc3af72c6ab121aeac1237a4adae66\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"9b0fc3c054ff2eb13753104884f1045b5bb3a627\", \"lessThan\": \"0c8c74bb59e7d77554016efc34c2d10376985e5e\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"9b0fc3c054ff2eb13753104884f1045b5bb3a627\", \"lessThan\": \"b6563ad0d599110bd5cf8f56c47d279c3ed796fe\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"9b0fc3c054ff2eb13753104884f1045b5bb3a627\", \"lessThan\": \"8ede3db5061bb1fe28e2c9683329aafa89d2b1b4\", \"versionType\": \"git\"}], \"programFiles\": [\"io_uring/net.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.0\"}, {\"status\": \"unaffected\", \"version\": \"0\", \"lessThan\": \"6.0\", \"versionType\": \"semver\"}, {\"status\": \"unaffected\", \"version\": \"6.1.83\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.1.*\"}, {\"status\": \"unaffected\", \"version\": \"6.6.23\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.6.*\"}, {\"status\": \"unaffected\", \"version\": \"6.7.11\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.7.*\"}, {\"status\": \"unaffected\", \"version\": \"6.8.2\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.8.*\"}, {\"status\": \"unaffected\", \"version\": \"6.9\", \"versionType\": \"original_commit_for_fix\", \"lessThanOrEqual\": \"*\"}], \"programFiles\": [\"io_uring/net.c\"], \"defaultStatus\": \"affected\"}], \"references\": [{\"url\": \"https://git.kernel.org/stable/c/868ec868616438df487b9e2baa5a99f8662cc47c\"}, {\"url\": \"https://git.kernel.org/stable/c/59a534690ecc3af72c6ab121aeac1237a4adae66\"}, {\"url\": \"https://git.kernel.org/stable/c/0c8c74bb59e7d77554016efc34c2d10376985e5e\"}, {\"url\": \"https://git.kernel.org/stable/c/b6563ad0d599110bd5cf8f56c47d279c3ed796fe\"}, {\"url\": \"https://git.kernel.org/stable/c/8ede3db5061bb1fe28e2c9683329aafa89d2b1b4\"}], \"x_generator\": {\"engine\": \"bippy-5f407fcff5a0\"}, \"descriptions\": [{\"lang\": \"en\", \"value\": \"In the Linux kernel, the following vulnerability has been resolved:\\n\\nio_uring/net: fix overflow check in io_recvmsg_mshot_prep()\\n\\nThe \\\"controllen\\\" variable is type size_t (unsigned long).  Casting it\\nto int could lead to an integer underflow.\\n\\nThe check_add_overflow() function considers the type of the destination\\nwhich is type int.  If we add two positive values and the result cannot\\nfit in an integer then that\u0027s counted as an overflow.\\n\\nHowever, if we cast \\\"controllen\\\" to an int and it turns negative, then\\nnegative values *can* fit into an int type so there is no overflow.\\n\\nGood: 100 + (unsigned long)-4 = 96  \u003c-- overflow\\n Bad: 100 + (int)-4 = 96 \u003c-- no overflow\\n\\nI deleted the cast of the sizeof() as well.  That\u0027s not a bug but the\\ncast is unnecessary.\"}], \"providerMetadata\": {\"orgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"shortName\": \"Linux\", \"dateUpdated\": \"2024-12-19T08:55:58.511Z\"}}}",
      "cveMetadata": "{\"cveId\": \"CVE-2024-35827\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2024-12-19T08:55:58.511Z\", \"dateReserved\": \"2024-05-17T12:19:12.347Z\", \"assignerOrgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"datePublished\": \"2024-05-17T13:41:09.193Z\", \"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 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…