{"answers":{"affected":"2 open source packages ship an affected version, including hurl.","exploited":"There is no known exploitation of GHSA-v33j-v3x4-42qg in the wild and no public exploit code.","fix":"Upgrade hurl to 7.0.0 or later.","what":"GHSA-v33j-v3x4-42qg is a cross-site scripting vulnerability in hurl, published on 11 Jun 2025. 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 GHSA-v33j-v3x4-42qg and fix it if it is affected.\n\nWhat it is: GHSA-v33j-v3x4-42qg is a cross-site scripting vulnerability in hurl, published on 11 Jun 2025. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of GHSA-v33j-v3x4-42qg in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- hurl (crates.io): affected all versions; fixed in 7.0.0\n- hurl (crates.io): affected all versions; fixed in 7.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/GHSA-v33j-v3x4-42qg/ (Markdown: https://insights.sbomify.com/GHSA-v33j-v3x4-42qg/index.md)","id":"GHSA-v33j-v3x4-42qg","markdown":"https://insights.sbomify.com/GHSA-v33j-v3x4-42qg/index.md","name":"GHSA-v33j-v3x4-42qg","record":{"aliases":[],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"Hurl CLI tool","requires_auth":"none","summary":"Hurl CLI fails to escape regex literals in HTML exports, allowing attackers to inject malicious scripts that execute when the generated HTML is viewed.","user_interaction":"required","vuln_class":"xss"},"analysis_generated_by":"qwen3.8-flash-next","assigner":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"Given this Hurl file:\n\nregex.hurl:\n\n```\nGET https://foo.com\nHTTP 200\n[Asserts]\njsonpath \"$.body\" matches /\u003cimg src=\"\" onerror=\"alert('Hi!')\"\u003e/\n```\n\nWhen exported to HTML:\n\n```\n$ hurlfmt --out html regex.hurl\n\u003cpre\u003e\u003ccode class=\"language-hurl\"\u003e\u003cspan class=\"hurl-entry\"\u003e\u003cspan class=\"request\"\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"method\"\u003eGET\u003c/span\u003e \u003cspan class=\"url\"\u003ehttps://foo.com\u003c/span\u003e\u003c/span\u003e\n\u003c/span\u003e\u003cspan class=\"response\"\u003e\u003cspan class=\"line\"\u003e\u003cspan class=\"version\"\u003eHTTP\u003c/span\u003e \u003cspan class=\"number\"\u003e200\u003c/span\u003e\u003c/span\u003e\n\u003cspan class=\"line\"\u003e\u003cspan class=\"section-header\"\u003e[Asserts]\u003c/span\u003e\u003c/span\u003e\n\u003cspan class=\"line\"\u003e\u003cspan class=\"query-type\"\u003ejsonpath\u003c/span\u003e \u003cspan class=\"string\"\u003e\"$.body\"\u003c/span\u003e \u003cspan class=\"predicate-type\"\u003ematches\u003c/span\u003e \u003cspan class=\"regex\"\u003e/\u003cimg src=\"\" onerror=\"alert('Hi!')\"\u003e/\u003c/span\u003e\u003c/span\u003e\n\u003c/span\u003e\u003c/span\u003e\u003cspan class=\"line\"\u003e\u003c/span\u003e\n\u003c/code\u003e\u003c/pre\u003e\n```\n\nThe regex literal `/\u003cimg src=\"\" onerror=\"alert('Hi!')\"\u003e/` is not escaped:\n\n`\u003cspan class=\"regex\"\u003e/\u003cimg src=\"\" onerror=\"alert('Hi!')\"\u003e/\u003c/span\u003e\u003c/span\u003e`\n\nWhen opened in a browser, the code is run without user interaction:\n\n![regex](https://github.com/user-attachments/assets/9c20a2ff-900f-4420-b38b-1e7648749119)","ecosystems":["crates.io"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"Regex literal in Hurl files are not escaped when exported to HTML, allowing injections","id":"GHSA-v33j-v3x4-42qg","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"crates.io","product":null,"products":[],"type":"xss","year":"2025"},"n_packages":2,"n_references":null,"packages":[{"ecosystem":"crates.io","fixed":["7.0.0"],"introduced":["0"],"last_affected":[],"package":"hurl","purl":null,"source":"GHSA-v33j-v3x4-42qg"},{"ecosystem":"crates.io","fixed":["7.0.0"],"introduced":["0"],"last_affected":[],"package":"hurl","purl":"pkg:cargo/hurl","source":"GHSA-v33j-v3x4-42qg"}],"products":null,"published":"2025-06-11","related":[],"sources":[{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":null,"updated":null,"vendors":null},"summary":"Hurl CLI fails to escape regex literals in HTML exports, allowing attackers to inject malicious scripts that execute when the generated HTML is viewed.","url":"https://insights.sbomify.com/GHSA-v33j-v3x4-42qg/"}