{"answers":{"affected":"2 open source packages ship an affected version, including plone-restapi and plone.restapi.","exploited":"There is no known exploitation of GHSA-hc5c-r8m5-2gfh in the wild and no public exploit code.","fix":"Upgrade plone-restapi to 8.43.3 or later.","what":"GHSA-hc5c-r8m5-2gfh is a cross-site scripting vulnerability in plone-restapi, published on 21 Sep 2023. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for GHSA-hc5c-r8m5-2gfh and fix it if it is affected.\n\nWhat it is: GHSA-hc5c-r8m5-2gfh is a cross-site scripting vulnerability in plone-restapi, published on 21 Sep 2023. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of GHSA-hc5c-r8m5-2gfh in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- plone-restapi (PyPI): affected from 8.0.0; fixed in 8.43.3\n- plone.restapi (PyPI): affected from 8.0.0; fixed in 8.43.3\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-hc5c-r8m5-2gfh/ (Markdown: https://insights.sbomify.com/GHSA-hc5c-r8m5-2gfh/index.md)","id":"GHSA-hc5c-r8m5-2gfh","markdown":"https://insights.sbomify.com/GHSA-hc5c-r8m5-2gfh/index.md","name":"GHSA-hc5c-r8m5-2gfh","record":{"aliases":[],"analysis":{"component_type":"web_application","fix_type":"upgrade","impacts":["code_execution","account_takeover"],"network_reachable":"yes","non_default_config":false,"product_category":"Plone REST API","requires_auth":"low_privilege","summary":"An attacker can execute arbitrary scripts in victim browsers by uploading a malicious SVG as a user portrait, requiring the victim to view the profile.","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":"### Impact\nThere is a stored cross site scripting vulnerability for SVG images uploaded in user portraits.\n\nNote that a page that uses an image tag with an SVG image as source is never vulnerable, even when the SVG image contains malicious code. To exploit the vulnerability, an attacker would first need to upload an SVG image as user portrait, and then trick a user into following a link to this portrait.\n\n### Patches\nA patch will be released in `plone.restapi` 8.43.3. This version is good for Plone 6.0, and for Plone 5.2 on Python 3.\n\nIn `plone.restapi` 7 or earlier there was no `@portrait` endpoint yet, so there is nothing to fix in that version. It is still vulnerable to this attack, and needs a [fix in Zope 4](https://github.com/zopefoundation/Zope/security/advisories/GHSA-wm8q-9975-xh5v). These two vulnerabilities share the same CVE: CVE-2023-42458.\n\n### Workarounds\nYou could remove the portrait field from the member data schema, and possibly remove all portraits that are already in the database, but this seems a bit drastic.","ecosystems":["PyPI"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"plone.restapi vulnerable to Stored Cross Site Scripting with SVG image in user portrait","id":"GHSA-hc5c-r8m5-2gfh","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"PyPI","product":null,"products":[],"type":"xss","year":"2023"},"n_packages":2,"n_references":null,"packages":[{"ecosystem":"PyPI","fixed":["8.43.3"],"introduced":["8.0.0"],"last_affected":[],"package":"plone-restapi","purl":"pkg:pypi/plone-restapi","source":"GHSA-hc5c-r8m5-2gfh"},{"ecosystem":"PyPI","fixed":["8.43.3"],"introduced":["8.0.0"],"last_affected":[],"package":"plone.restapi","purl":null,"source":"GHSA-hc5c-r8m5-2gfh"}],"products":null,"published":"2023-09-21","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":"An attacker can execute arbitrary scripts in victim browsers by uploading a malicious SVG as a user portrait, requiring the victim to view the profile.","url":"https://insights.sbomify.com/GHSA-hc5c-r8m5-2gfh/"}