{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2022-50227",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2025-06-18T10:57:27.432Z",
        "datePublished": "2025-06-18T11:03:59.885Z",
        "dateUpdated": "2026-08-05T08:57:47.222Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-08-05T08:57:47.222Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: x86/xen: Initialize Xen timer only once\n\nAdd a check for existing xen timers before initializing a new one.\n\nCurrently kvm_xen_init_timer() is called on every\nKVM_XEN_VCPU_ATTR_TYPE_TIMER, which is causing the following ODEBUG\ncrash when vcpu->arch.xen.timer is already set.\n\nODEBUG: init active (active state 0)\nobject type: hrtimer hint: xen_timer_callbac0\nRIP: 0010:debug_print_object+0x16e/0x250 lib/debugobjects.c:502\nCall Trace:\n__debug_object_init\ndebug_hrtimer_init\ndebug_init\nhrtimer_init\nkvm_xen_init_timer\nkvm_xen_vcpu_set_attr\nkvm_arch_vcpu_ioctl\nkvm_vcpu_ioctl\nvfs_ioctl"
                }
            ],
            "metrics": [
                {
                    "cvssV3_1": {
                        "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"
                    },
                    "scenarios": [
                        {
                            "lang": "en",
                            "value": "AV:L - Triggered only via the host KVM_XEN_VCPU_SET_ATTR vCPU ioctl on /dev/kvm; guest Xen timer hypercalls call kvm_xen_start_timer but never kvm_xen_init_timer, so this is not remotely reachable.\nAC:L - An attacker with a vCPU fd can reliably reproduce by issuing KVM_XEN_VCPU_ATTR_TYPE_TIMER twice with a non-zero port and expires_ns, fully controlling both the initial arming and the re-init; no race or external condition is required.\nPR:L - Reachable by any unprivileged local user who can open /dev/kvm (typically kvm-group membership), create a VM/vCPU, and issue the ioctl; no CAP_SYS_ADMIN or init-namespace root is required.\nUI:N - Exploitation is entirely attacker-driven through ioctl calls; no victim action is needed.\nS:U - This is host userspace (VMM) corrupting the host kernel timer subsystem, not a guest-to-host escape; impact stays within the host kernel authority.\nC:H - Without DEBUG_OBJECTS, hrtimer_init memset()s an still-enqueued hrtimer, corrupting the timerqueue rbtree and enabling use-after-free primitives that can yield arbitrary kernel reads.\nI:H - The same timer-queue corruption provides a write/UAF primitive against kernel timer structures, which can be leveraged for control-flow hijacking or arbitrary writes.\nA:H - Re-init of an active hrtimer causes kernel WARN/oops under debugobjects and timer-subsystem crashes or hangs on production kernels when the corrupted rbtree is walked."
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "arch/x86/kvm/xen.c"
                    ],
                    "versions": [
                        {
                            "version": "536395260582be7443b0b35b0bbb89ffe3947f62",
                            "lessThan": "9a9b5771e930f408c3419799000f76a9abaf2278",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "536395260582be7443b0b35b0bbb89ffe3947f62",
                            "lessThan": "af735db31285fa699384c649be72a9f32ecbb665",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "arch/x86/kvm/xen.c"
                    ],
                    "versions": [
                        {
                            "version": "5.19",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "5.19",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.19.2",
                            "lessThanOrEqual": "5.19.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.0",
                            "lessThanOrEqual": "*",
                            "status": "unaffected",
                            "versionType": "original_commit_for_fix"
                        }
                    ]
                }
            ],
            "cpeApplicability": [
                {
                    "nodes": [
                        {
                            "operator": "OR",
                            "negate": false,
                            "cpeMatch": [
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.19",
                                    "versionEndExcluding": "5.19.2"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.19",
                                    "versionEndExcluding": "6.0"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/9a9b5771e930f408c3419799000f76a9abaf2278"
                },
                {
                    "url": "https://git.kernel.org/stable/c/af735db31285fa699384c649be72a9f32ecbb665"
                }
            ],
            "title": "KVM: x86/xen: Initialize Xen timer only once",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        }
    }
}