CVE-2022-50240 (GCVE-0-2022-50240)

Vulnerability from cvelistv5 – Published: 2025-09-15 14:01 – Updated: 2025-10-10 15:53
VLAI?
Summary
In the Linux kernel, the following vulnerability has been resolved: android: binder: stop saving a pointer to the VMA Do not record a pointer to a VMA outside of the mmap_lock for later use. This is unsafe and there are a number of failure paths *after* the recorded VMA pointer may be freed during setup. There is no callback to the driver to clear the saved pointer from generic mm code. Furthermore, the VMA pointer may become stale if any number of VMA operations end up freeing the VMA so saving it was fragile to being with. Instead, change the binder_alloc struct to record the start address of the VMA and use vma_lookup() to get the vma when needed. Add lockdep mmap_lock checks on updates to the vma pointer to ensure the lock is held and depend on that lock for synchronization of readers and writers - which was already the case anyways, so the smp_wmb()/smp_rmb() was not necessary. [akpm@linux-foundation.org: fix drivers/android/binder_alloc_selftest.c]
Severity ?
No CVSS data available.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < 27a594bc7a7c8238d239e3cdbcf2edfa3bbe9a1b (git)
Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < 015ac18be7de25d17d6e5f1643cb3b60bfbe859e (git)
Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < 622ef885a89ad04cfb76ee478fb44f051125d1f1 (git)
Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < 925e6b6f82c9c80ab3c17acbde8d16f349da7d26 (git)
Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < 1ec3f76a436d750fd5023caec5da0494fc2870d2 (git)
Affected: dd2283f2605e3b3e9c61bcae844b34f2afa4813f , < a43cfc87caaf46710c8027a8c23b8a55f1078f19 (git)
Create a notification for this product.
    Linux Linux Affected: 4.20
Unaffected: 0 , < 4.20 (semver)
Unaffected: 5.4.224 , ≤ 5.4.* (semver)
Unaffected: 5.10.154 , ≤ 5.10.* (semver)
Unaffected: 5.15.61 , ≤ 5.15.* (semver)
Unaffected: 5.18.18 , ≤ 5.18.* (semver)
Unaffected: 5.19.2 , ≤ 5.19.* (semver)
Unaffected: 6.0 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/android/binder_alloc.c",
            "drivers/android/binder_alloc.h",
            "drivers/android/binder_alloc_selftest.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "27a594bc7a7c8238d239e3cdbcf2edfa3bbe9a1b",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            },
            {
              "lessThan": "015ac18be7de25d17d6e5f1643cb3b60bfbe859e",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            },
            {
              "lessThan": "622ef885a89ad04cfb76ee478fb44f051125d1f1",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            },
            {
              "lessThan": "925e6b6f82c9c80ab3c17acbde8d16f349da7d26",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            },
            {
              "lessThan": "1ec3f76a436d750fd5023caec5da0494fc2870d2",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            },
            {
              "lessThan": "a43cfc87caaf46710c8027a8c23b8a55f1078f19",
              "status": "affected",
              "version": "dd2283f2605e3b3e9c61bcae844b34f2afa4813f",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/android/binder_alloc.c",
            "drivers/android/binder_alloc.h",
            "drivers/android/binder_alloc_selftest.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "4.20"
            },
            {
              "lessThan": "4.20",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.4.*",
              "status": "unaffected",
              "version": "5.4.224",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.154",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.61",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.18.*",
              "status": "unaffected",
              "version": "5.18.18",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.19.*",
              "status": "unaffected",
              "version": "5.19.2",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.0",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.4.224",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.154",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.61",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.18.18",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.19.2",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.0",
                  "versionStartIncluding": "4.20",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nandroid: binder: stop saving a pointer to the VMA\n\nDo not record a pointer to a VMA outside of the mmap_lock for later use. \nThis is unsafe and there are a number of failure paths *after* the\nrecorded VMA pointer may be freed during setup.  There is no callback to\nthe driver to clear the saved pointer from generic mm code.  Furthermore,\nthe VMA pointer may become stale if any number of VMA operations end up\nfreeing the VMA so saving it was fragile to being with.\n\nInstead, change the binder_alloc struct to record the start address of the\nVMA and use vma_lookup() to get the vma when needed.  Add lockdep\nmmap_lock checks on updates to the vma pointer to ensure the lock is held\nand depend on that lock for synchronization of readers and writers - which\nwas already the case anyways, so the smp_wmb()/smp_rmb() was not\nnecessary.\n\n[akpm@linux-foundation.org: fix drivers/android/binder_alloc_selftest.c]"
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2025-10-10T15:53:38.644Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/27a594bc7a7c8238d239e3cdbcf2edfa3bbe9a1b"
        },
        {
          "url": "https://git.kernel.org/stable/c/015ac18be7de25d17d6e5f1643cb3b60bfbe859e"
        },
        {
          "url": "https://git.kernel.org/stable/c/622ef885a89ad04cfb76ee478fb44f051125d1f1"
        },
        {
          "url": "https://git.kernel.org/stable/c/925e6b6f82c9c80ab3c17acbde8d16f349da7d26"
        },
        {
          "url": "https://git.kernel.org/stable/c/1ec3f76a436d750fd5023caec5da0494fc2870d2"
        },
        {
          "url": "https://git.kernel.org/stable/c/a43cfc87caaf46710c8027a8c23b8a55f1078f19"
        }
      ],
      "title": "android: binder: stop saving a pointer to the VMA",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2022-50240",
    "datePublished": "2025-09-15T14:01:45.724Z",
    "dateReserved": "2025-09-15T13:58:00.971Z",
    "dateUpdated": "2025-10-10T15:53:38.644Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "vulnerability-lookup:meta": {
    "nvd": "{\"cve\":{\"id\":\"CVE-2022-50240\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-09-15T14:15:34.250\",\"lastModified\":\"2025-11-24T17:25:46.107\",\"vulnStatus\":\"Analyzed\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nandroid: binder: stop saving a pointer to the VMA\\n\\nDo not record a pointer to a VMA outside of the mmap_lock for later use. \\nThis is unsafe and there are a number of failure paths *after* the\\nrecorded VMA pointer may be freed during setup.  There is no callback to\\nthe driver to clear the saved pointer from generic mm code.  Furthermore,\\nthe VMA pointer may become stale if any number of VMA operations end up\\nfreeing the VMA so saving it was fragile to being with.\\n\\nInstead, change the binder_alloc struct to record the start address of the\\nVMA and use vma_lookup() to get the vma when needed.  Add lockdep\\nmmap_lock checks on updates to the vma pointer to ensure the lock is held\\nand depend on that lock for synchronization of readers and writers - which\\nwas already the case anyways, so the smp_wmb()/smp_rmb() was not\\nnecessary.\\n\\n[akpm@linux-foundation.org: fix drivers/android/binder_alloc_selftest.c]\"}],\"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\":\"4.20\",\"versionEndExcluding\":\"5.4.224\",\"matchCriteriaId\":\"1D67A077-EB45-4ADE-94CD-F9A76F6C319C\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.5\",\"versionEndExcluding\":\"5.10.154\",\"matchCriteriaId\":\"475D097C-AB5A-4CF5-899F-413077854ABD\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.11\",\"versionEndExcluding\":\"5.15.61\",\"matchCriteriaId\":\"51861563-7F40-460F-82CD-2D3FBDAD6618\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.16\",\"versionEndExcluding\":\"5.18.18\",\"matchCriteriaId\":\"5B42E453-8837-49D0-A5EF-03F818A6DC11\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.19\",\"versionEndExcluding\":\"5.19.2\",\"matchCriteriaId\":\"A1A2A5A5-4598-4D7E-BA07-4660398D6C8F\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/015ac18be7de25d17d6e5f1643cb3b60bfbe859e\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/1ec3f76a436d750fd5023caec5da0494fc2870d2\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/27a594bc7a7c8238d239e3cdbcf2edfa3bbe9a1b\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/622ef885a89ad04cfb76ee478fb44f051125d1f1\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/925e6b6f82c9c80ab3c17acbde8d16f349da7d26\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/a43cfc87caaf46710c8027a8c23b8a55f1078f19\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]}]}}"
  }
}


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…