{"answers":{"affected":"3 open source packages ship an affected version, including xblock-drag-and-drop-v2. It affects 1 product.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-46147 exists.","fix":"Upgrade xblock-drag-and-drop-v2 to 3.0.0 or later.","what":"CVE-2022-46147 is a high-severity cross-site scripting vulnerability in openedx xblock-drag-and-drop-v2, published on 28 Nov 2022. An attacker needs administrator access to exploit it, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2022-46147 and fix it if it is affected.\n\nWhat it is: CVE-2022-46147 is a high-severity cross-site scripting vulnerability in openedx xblock-drag-and-drop-v2, published on 28 Nov 2022. An attacker needs administrator access to exploit it, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-46147 exists.\n\nAffected packages and fixed versions:\n- xblock-drag-and-drop-v2 (PyPI): affected all versions; fixed in 3.0.0\n- xblock-drag-and-drop-v2 (PyPI): affected all versions; fixed in 3.0.0\n- xblock-drag-and-drop-v2 (PyPI): affected all versions; fixed in 3.0.0\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2022-46147/ (Markdown: https://insights.sbomify.com/CVE-2022-46147/index.md)","id":"CVE-2022-46147","markdown":"https://insights.sbomify.com/CVE-2022-46147/index.md","name":"CVE-2022-46147","record":{"aliases":["GHSA-qv6c-367r-3w6q","PYSEC-2022-43175"],"analysis":{"component_type":"cms_plugin","fix_type":"upgrade","impacts":["code_execution","account_takeover"],"network_reachable":"yes","non_default_config":false,"product_category":"Open edX XBlock","requires_auth":"high_privilege","summary":"Attackers can inject malicious scripts into drag-and-drop XBlock fields, potentially compromising user sessions on Open edX platforms.","user_interaction":"required","vuln_class":"xss"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"xblock-drag-and-drop-v2","vendor":"openedx"}],"cvss":{"score":8.4,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"description":"Drag and Drop XBlock v2 implements a drag-and-drop style problem, where a learner has to drag items to zones on a target image. Versions prior to 3.0.0 are vulnerable to cross-site scripting in multiple XBlock Fields. Any platform that has deployed the XBlock may be impacted. Version 3.0.0 contains a patch for this issue. There are no known workarounds.","ecosystems":["PyPI"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"Drag and Drop XBlock v2 has XSS Issues in Xblock Input Fields","id":"CVE-2022-46147","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"PyPI","product":null,"products":[],"type":"xss","year":"2022"},"n_packages":3,"n_references":4,"next":{"headline":"Discourse allows self-XSS through malicious composer message","id":"CVE-2022-46148"},"packages":[{"ecosystem":"PyPI","fixed":["3.0.0"],"introduced":["0"],"last_affected":[],"package":"xblock-drag-and-drop-v2","purl":null,"source":"GHSA-qv6c-367r-3w6q"},{"ecosystem":"PyPI","fixed":["3.0.0"],"introduced":["0"],"last_affected":[],"package":"xblock-drag-and-drop-v2","purl":"pkg:pypi/xblock-drag-and-drop-v2","source":"GHSA-qv6c-367r-3w6q"},{"ecosystem":"PyPI","fixed":["3.0.0"],"introduced":["0"],"last_affected":[],"package":"xblock-drag-and-drop-v2","purl":"pkg:pypi/xblock-drag-and-drop-v2","source":"PYSEC-2022-43175"}],"prev":{"headline":"Prometheus Exporter Toolkit vulnerable to basic authentication bypass","id":"CVE-2022-46146"},"products":["xblock-drag-and-drop-v2"],"published":"2022-11-28","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CC BY 4.0","name":"PyPA Advisory Database","prefix":"PYSEC"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"total"},"state":"PUBLISHED","updated":"2025-04-22","vendors":["openedx"]},"summary":"Attackers can inject malicious scripts into drag-and-drop XBlock fields, potentially compromising user sessions on Open edX platforms.","url":"https://insights.sbomify.com/CVE-2022-46147/"}