CVE-2022-49884 (GCVE-0-2022-49884)

Vulnerability from cvelistv5 – Published: 2025-05-01 14:10 – Updated: 2026-05-11 19:08
VLAI
Title
KVM: Initialize gfn_to_pfn_cache locks in dedicated helper
Summary
In the Linux kernel, the following vulnerability has been resolved: KVM: Initialize gfn_to_pfn_cache locks in dedicated helper Move the gfn_to_pfn_cache lock initialization to another helper and call the new helper during VM/vCPU creation. There are race conditions possible due to kvm_gfn_to_pfn_cache_init()'s ability to re-initialize the cache's locks. For example: a race between ioctl(KVM_XEN_HVM_EVTCHN_SEND) and kvm_gfn_to_pfn_cache_init() leads to a corrupted shinfo gpc lock. (thread 1) | (thread 2) | kvm_xen_set_evtchn_fast | read_lock_irqsave(&gpc->lock, ...) | | kvm_gfn_to_pfn_cache_init | rwlock_init(&gpc->lock) read_unlock_irqrestore(&gpc->lock, ...) | Rename "cache_init" and "cache_destroy" to activate+deactivate to avoid implying that the cache really is destroyed/freed. Note, there more races in the newly named kvm_gpc_activate() that will be addressed separately. [sean: call out that this is a bug fix]
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 982ed0de4753ed6e71dbd40f82a5a066baf133ed , < 61242001d6c9c253df7645dab090842d8da08764 (git)
Affected: 982ed0de4753ed6e71dbd40f82a5a066baf133ed , < 52491a38b2c2411f3f0229dc6ad610349c704a41 (git)
Create a notification for this product.
Linux Linux Affected: 5.17
Unaffected: 0 , < 5.17 (semver)
Unaffected: 6.0.8 , ≤ 6.0.* (semver)
Unaffected: 6.1 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "arch/x86/kvm/x86.c",
            "arch/x86/kvm/xen.c",
            "include/linux/kvm_host.h",
            "virt/kvm/pfncache.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "61242001d6c9c253df7645dab090842d8da08764",
              "status": "affected",
              "version": "982ed0de4753ed6e71dbd40f82a5a066baf133ed",
              "versionType": "git"
            },
            {
              "lessThan": "52491a38b2c2411f3f0229dc6ad610349c704a41",
              "status": "affected",
              "version": "982ed0de4753ed6e71dbd40f82a5a066baf133ed",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "arch/x86/kvm/x86.c",
            "arch/x86/kvm/xen.c",
            "include/linux/kvm_host.h",
            "virt/kvm/pfncache.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.17"
            },
            {
              "lessThan": "5.17",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.0.*",
              "status": "unaffected",
              "version": "6.0.8",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.1",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.0.8",
                  "versionStartIncluding": "5.17",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1",
                  "versionStartIncluding": "5.17",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: Initialize gfn_to_pfn_cache locks in dedicated helper\n\nMove the gfn_to_pfn_cache lock initialization to another helper and\ncall the new helper during VM/vCPU creation.  There are race\nconditions possible due to kvm_gfn_to_pfn_cache_init()\u0027s\nability to re-initialize the cache\u0027s locks.\n\nFor example: a race between ioctl(KVM_XEN_HVM_EVTCHN_SEND) and\nkvm_gfn_to_pfn_cache_init() leads to a corrupted shinfo gpc lock.\n\n                (thread 1)                |           (thread 2)\n                                          |\n kvm_xen_set_evtchn_fast                  |\n  read_lock_irqsave(\u0026gpc-\u003elock, ...)      |\n                                          | kvm_gfn_to_pfn_cache_init\n                                          |  rwlock_init(\u0026gpc-\u003elock)\n  read_unlock_irqrestore(\u0026gpc-\u003elock, ...) |\n\nRename \"cache_init\" and \"cache_destroy\" to activate+deactivate to\navoid implying that the cache really is destroyed/freed.\n\nNote, there more races in the newly named kvm_gpc_activate() that will\nbe addressed separately.\n\n[sean: call out that this is a bug fix]"
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-05-11T19:08:36.442Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/61242001d6c9c253df7645dab090842d8da08764"
        },
        {
          "url": "https://git.kernel.org/stable/c/52491a38b2c2411f3f0229dc6ad610349c704a41"
        }
      ],
      "title": "KVM: Initialize gfn_to_pfn_cache locks in dedicated helper",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2022-49884",
    "datePublished": "2025-05-01T14:10:30.589Z",
    "dateReserved": "2025-05-01T14:05:17.241Z",
    "dateUpdated": "2026-05-11T19:08:36.442Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2022-49884",
      "date": "2026-07-17",
      "epss": "0.00098",
      "percentile": "0.00958"
    },
    "nvd": "{\"cve\":{\"id\":\"CVE-2022-49884\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-05-01T15:16:13.387\",\"lastModified\":\"2026-06-17T05:19:25.040\",\"vulnStatus\":\"Analyzed\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nKVM: Initialize gfn_to_pfn_cache locks in dedicated helper\\n\\nMove the gfn_to_pfn_cache lock initialization to another helper and\\ncall the new helper during VM/vCPU creation.  There are race\\nconditions possible due to kvm_gfn_to_pfn_cache_init()\u0027s\\nability to re-initialize the cache\u0027s locks.\\n\\nFor example: a race between ioctl(KVM_XEN_HVM_EVTCHN_SEND) and\\nkvm_gfn_to_pfn_cache_init() leads to a corrupted shinfo gpc lock.\\n\\n                (thread 1)                |           (thread 2)\\n                                          |\\n kvm_xen_set_evtchn_fast                  |\\n  read_lock_irqsave(\u0026gpc-\u003elock, ...)      |\\n                                          | kvm_gfn_to_pfn_cache_init\\n                                          |  rwlock_init(\u0026gpc-\u003elock)\\n  read_unlock_irqrestore(\u0026gpc-\u003elock, ...) |\\n\\nRename \\\"cache_init\\\" and \\\"cache_destroy\\\" to activate+deactivate to\\navoid implying that the cache really is destroyed/freed.\\n\\nNote, there more races in the newly named kvm_gpc_activate() that will\\nbe addressed separately.\\n\\n[sean: call out that this is a bug fix]\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: KVM: Inicializar bloqueos de gfn_to_pfn_cache en un asistente dedicado. Trasladar la inicializaci\u00f3n del bloqueo de gfn_to_pfn_cache a otro asistente y llamar al nuevo asistente durante la creaci\u00f3n de la m\u00e1quina virtual o la vCPU. Es posible que se produzcan condiciones de competencia debido a la capacidad de kvm_gfn_to_pfn_cache_init() de reinicializar los bloqueos de la cach\u00e9. Por ejemplo: una competencia entre ioctl(KVM_XEN_HVM_EVTCHN_SEND) y kvm_gfn_to_pfn_cache_init() provoca un bloqueo de gpc de shinfo da\u00f1ado. (hilo 1) | (hilo 2) | kvm_xen_set_evtchn_fast | read_lock_irqsave(\u0026amp;gpc-\u0026gt;lock, ...) | | kvm_gfn_to_pfn_cache_init | rwlock_init(\u0026amp;gpc-\u0026gt;lock) read_unlock_irqrestore(\u0026amp;gpc-\u0026gt;lock, ...) | Renombra \\\"cache_init\\\" y \\\"cache_destroy\\\" como activate+deactivate para evitar que la cach\u00e9 se destruya o libere. Ten en cuenta que hay m\u00e1s ejecuciones en el nuevo nombre kvm_gpc_activate() que se abordar\u00e1n por separado. [sean: se indica que se trata de una correcci\u00f3n de error]\"}],\"affected\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"affectedData\":[{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"unaffected\",\"programFiles\":[\"arch/x86/kvm/x86.c\",\"arch/x86/kvm/xen.c\",\"include/linux/kvm_host.h\",\"virt/kvm/pfncache.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"982ed0de4753ed6e71dbd40f82a5a066baf133ed\",\"lessThan\":\"61242001d6c9c253df7645dab090842d8da08764\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"982ed0de4753ed6e71dbd40f82a5a066baf133ed\",\"lessThan\":\"52491a38b2c2411f3f0229dc6ad610349c704a41\",\"versionType\":\"git\",\"status\":\"affected\"}]},{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"affected\",\"programFiles\":[\"arch/x86/kvm/x86.c\",\"arch/x86/kvm/xen.c\",\"include/linux/kvm_host.h\",\"virt/kvm/pfncache.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"5.17\",\"status\":\"affected\"},{\"version\":\"0\",\"lessThan\":\"5.17\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.0.8\",\"lessThanOrEqual\":\"6.0.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.1\",\"lessThanOrEqual\":\"*\",\"versionType\":\"original_commit_for_fix\",\"status\":\"unaffected\"}]}]}],\"metrics\":{\"cvssMetricV31\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"cvssData\":{\"version\":\"3.1\",\"vectorString\":\"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H\",\"baseScore\":4.7,\"baseSeverity\":\"MEDIUM\",\"attackVector\":\"LOCAL\",\"attackComplexity\":\"HIGH\",\"privilegesRequired\":\"LOW\",\"userInteraction\":\"NONE\",\"scope\":\"UNCHANGED\",\"confidentialityImpact\":\"NONE\",\"integrityImpact\":\"NONE\",\"availabilityImpact\":\"HIGH\"},\"exploitabilityScore\":1.0,\"impactScore\":3.6}]},\"weaknesses\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"description\":[{\"lang\":\"en\",\"value\":\"CWE-362\"}]}],\"configurations\":[{\"nodes\":[{\"operator\":\"OR\",\"negate\":false,\"cpeMatch\":[{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.17\",\"versionEndExcluding\":\"6.0.8\",\"matchCriteriaId\":\"C7CE8283-1C20-4F40-8BE6-BCF33C4080B9\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.1:rc1:*:*:*:*:*:*\",\"matchCriteriaId\":\"E7E331DA-1FB0-4DEC-91AC-7DA69D461C11\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.1:rc2:*:*:*:*:*:*\",\"matchCriteriaId\":\"17F0B248-42CF-4AE6-A469-BB1BAE7F4705\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:6.1:rc3:*:*:*:*:*:*\",\"matchCriteriaId\":\"E2422816-0C14-4B5E-A1E6-A9D776E5C49B\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/52491a38b2c2411f3f0229dc6ad610349c704a41\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/61242001d6c9c253df7645dab090842d8da08764\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]}]}}",
    "redhat_vex": {
      "aggregate_severity": "Moderate",
      "current_release_date": "2026-06-29T21:29:31+00:00",
      "cve": "CVE-2022-49884",
      "id": "CVE-2022-49884",
      "initial_release_date": "2022-01-01T00:00:00+00:00",
      "product_status:known_affected": "90",
      "product_status:known_not_affected": "184",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: KVM: Initialize gfn_to_pfn_cache locks in dedicated helper",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2022/cve-2022-49884.json",
      "version": "3"
    }
  }
}



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…