{"answers":{"affected":"2 open source packages ship an affected version, including simplesamlphp/simplesamlphp.","exploited":"There is no known exploitation of GHSA-vpr3-cw3h-prw8 in the wild and no public exploit code.","fix":"Upgrade simplesamlphp/simplesamlphp to 1.17.3 or later.","what":"GHSA-vpr3-cw3h-prw8 is a cross-site scripting vulnerability in simplesamlphp/simplesamlphp, published on 28 May 2024. 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-vpr3-cw3h-prw8 and fix it if it is affected.\n\nWhat it is: GHSA-vpr3-cw3h-prw8 is a cross-site scripting vulnerability in simplesamlphp/simplesamlphp, published on 28 May 2024. 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-vpr3-cw3h-prw8 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- simplesamlphp/simplesamlphp (Packagist): affected from 1.12.0; fixed in 1.17.3\n- simplesamlphp/simplesamlphp (Packagist): affected from 1.12.0; fixed in 1.17.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-vpr3-cw3h-prw8/ (Markdown: https://insights.sbomify.com/GHSA-vpr3-cw3h-prw8/index.md)","id":"GHSA-vpr3-cw3h-prw8","markdown":"https://insights.sbomify.com/GHSA-vpr3-cw3h-prw8/index.md","name":"GHSA-vpr3-cw3h-prw8","record":{"aliases":[],"analysis":{"component_type":"web_application","fix_type":"upgrade","impacts":["code_execution","account_takeover"],"network_reachable":"yes","non_default_config":false,"product_category":"SAML authentication library","requires_auth":"none","summary":"Attackers can execute arbitrary JavaScript in user browsers via malicious SAML metadata endpoints, potentially leading to session hijacking or account takeover.","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":"### Background\nSimpleSAMLphp uses metadata to determine how to interact with other SAML entities. This metadata includes what’s called endpoints, which are URLs belonging to that entity where SAML messages can be sent. These URLs are used directly by SimpleSAMLphp when a message is sent, either via an HTTP redirection or by automatically posting a form to them.\n\n### Description\nWhen sending a SAML message to another entity, SimpleSAMLphp will use the URL of the appropriate endpoint to redirect the user’s browser to it, or craft a form that will be automatically posted to it, depending on the SAML binding used. The URL that’s target of the message is fetched from the stored metadata for the given entity, and that metadata is trusted as correct.\n\nHowever, if that metadata has been altered by a malicious party (either an attacker or a rogue administrator) to substitute the URLs of the endpoints with javascript code, SimpleSAMLphp was blindly using them without any validation, trusting the contents of the metadata. This would lead to a reflected XSS where the javascript code is sent inline to the web browser, and if SimpleSAMLphp is not using a strict Content Security Policy to forbid inline javascript (which is the case of the default user interface), then the code will be executed in the end user’s browser.\n\n### Affected versions\nAll SimpleSAMLphp versions are affected, up to 1.17.2.\n\n### Impact\nIf metadata is consumed for a rogue entity that includes javascript code in the corresponding endpoints, this javascript code might be run by users trying to access this entity.\n\nEven though it’s unlikely that an administrator would add metadata for an entity that contains such endpoints inadvertently, if metadata is consumed automatically (e.g. using metarefresh) it would be easier to have an scenario like the one described here if a SAML entity is compromised and its metadata modified.\n\nThe severity is assessed as medium given the difficulty to exploit the issue.","ecosystems":["Packagist"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"SimpleSAMLphp Reflected Cross-site Scripting vulnerability","id":"GHSA-vpr3-cw3h-prw8","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"Packagist","product":null,"products":[],"type":"xss","year":"2024"},"n_packages":2,"n_references":null,"packages":[{"ecosystem":"Packagist","fixed":["1.17.3"],"introduced":["1.12.0"],"last_affected":[],"package":"simplesamlphp/simplesamlphp","purl":null,"source":"GHSA-vpr3-cw3h-prw8"},{"ecosystem":"Packagist","fixed":["1.17.3"],"introduced":["1.12.0"],"last_affected":[],"package":"simplesamlphp/simplesamlphp","purl":"pkg:composer/simplesamlphp/simplesamlphp","source":"GHSA-vpr3-cw3h-prw8"}],"products":null,"published":"2024-05-28","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":"Attackers can execute arbitrary JavaScript in user browsers via malicious SAML metadata endpoints, potentially leading to session hijacking or account takeover.","url":"https://insights.sbomify.com/GHSA-vpr3-cw3h-prw8/"}