{"answers":{"affected":"2 open source packages ship an affected version, including @orpc/openapi. It affects 1 product.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-33331 exists.","fix":"Upgrade @orpc/openapi to 1.13.9 or later.","what":"CVE-2026-33331 is a high-severity cross-site scripting vulnerability in middleapi orpc, published on 24 Mar 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2026-33331 and fix it if it is affected.\n\nWhat it is: CVE-2026-33331 is a high-severity cross-site scripting vulnerability in middleapi orpc, published on 24 Mar 2026. An attacker can exploit it over the internet without logging in, 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-2026-33331 exists.\n\nAffected packages and fixed versions:\n- @orpc/openapi (npm): affected all versions; fixed in 1.13.9\n- @orpc/openapi (npm): affected all versions; fixed in 1.13.9\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-2026-33331/ (Markdown: https://insights.sbomify.com/CVE-2026-33331/index.md)","id":"CVE-2026-33331","markdown":"https://insights.sbomify.com/CVE-2026-33331/index.md","name":"CVE-2026-33331","record":{"aliases":["GHSA-7f6v-3gx7-27q8"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"oRPC API library","requires_auth":"none","summary":"Attackers can execute arbitrary JavaScript in users' browsers by injecting malicious code into OpenAPI specification fields viewed in the documentation.","user_interaction":"required","vuln_class":"xss"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"orpc","vendor":"orpc"}],"cvss":{"score":8.2,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:L/A:N","version":"3.1"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"description":"oRPC is an tool that helps build APIs that are end-to-end type-safe and adhere to OpenAPI standards. Prior to version 1.13.9, a stored cross-site scripting (XSS) vulnerability exists in the OpenAPI documentation generation of orpc. If an attacker can control any field within the OpenAPI specification (such as info.description), they can break out of the JSON context and execute arbitrary JavaScript when a user views the generated API documentation. This issue has been patched in version 1.13.9.","ecosystems":["npm"],"exploits":{"exploitdb":0,"first_seen":"2026-04-04","github_poc":1,"max_poc_stars":0,"metasploit":0,"nuclei":0,"refs":[{"date":"2026-04-04T17:03:14Z","kind":"github_poc","ref":"https://github.com/abhayclasher/CVE-2026-33331","stars":0,"title":"Proof-of-concept lab for stored XSS in orpc (CVE-2026-33331)"}],"tier":"weaponised"},"has_fix":true,"headline":"oRPC: Stored XSS in OpenAPI Reference Plugin via unescaped JSON.stringify","id":"CVE-2026-33331","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"npm","product":null,"products":[],"type":"xss","year":"2026"},"n_packages":2,"n_references":3,"next":{"headline":"NiceGUI's unvalidated chunk size parameter in media routes can cause memory exhaustion","id":"CVE-2026-33332"},"packages":[{"ecosystem":"npm","fixed":["1.13.9"],"introduced":["0"],"last_affected":[],"package":"@orpc/openapi","purl":null,"source":"GHSA-7f6v-3gx7-27q8"},{"ecosystem":"npm","fixed":["1.13.9"],"introduced":["0"],"last_affected":[],"package":"@orpc/openapi","purl":"pkg:npm/%40orpc/openapi","source":"GHSA-7f6v-3gx7-27q8"}],"prev":{"headline":"FileRise ONLYOFFICE integration allows read-only users to overwrite files via forged save callback","id":"CVE-2026-33330"},"products":["orpc"],"published":"2026-03-24","related":[{"cvss_score":9.3,"headline":"oRPC: Prototype Pollution in `@orpc/client` via `StandardRPCJsonSerializer` Deserialization","id":"CVE-2026-28794","kev_date_added":null,"published":"2026-03-06"}],"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":"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)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"partial"},"state":"PUBLISHED","updated":"2026-03-25","vendors":["middleapi"]},"summary":"Attackers can execute arbitrary JavaScript in users' browsers by injecting malicious code into OpenAPI specification fields viewed in the documentation.","url":"https://insights.sbomify.com/CVE-2026-33331/"}