{"answers":{"affected":"12 open source packages ship an affected version, including api-platform/core and api-platform/graphql.","exploited":"There is no known exploitation of CVE-2025-31485 in the wild and no public exploit code.","fix":"Upgrade api-platform/core to a fixed version for your release line: 3.4.17, 4.0.22 or 4.1.5.","what":"CVE-2025-31485 is a high-severity missing authorization vulnerability in api-platform core, published on 3 Apr 2025. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2025-31485 and fix it if it is affected.\n\nWhat it is: CVE-2025-31485 is a high-severity missing authorization vulnerability in api-platform core, published on 3 Apr 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2025-31485 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- api-platform/core (Packagist): affected all versions; fixed in 3.4.17\n- api-platform/core (Packagist): affected all versions; fixed in 3.4.17\n- api-platform/core (Packagist): affected from 4.0.0-alpha.1; fixed in 4.0.22\n- api-platform/core (Packagist): affected from 4.0.0-alpha.1; fixed in 4.0.22\n- api-platform/core (Packagist): affected from 4.1.0-alpha.1; fixed in 4.1.5\n- api-platform/core (Packagist): affected from 4.1.0-alpha.1; fixed in 4.1.5\n- api-platform/graphql (Packagist): affected all versions; fixed in 3.4.17\n- api-platform/graphql (Packagist): affected all versions; fixed in 3.4.17\n- api-platform/graphql (Packagist): affected from 4.0.0-alpha.1; fixed in 4.0.22\n- api-platform/graphql (Packagist): affected from 4.0.0-alpha.1; fixed in 4.0.22\n- api-platform/graphql (Packagist): affected from 4.1.0-alpha.1; fixed in 4.1.5\n- api-platform/graphql (Packagist): affected from 4.1.0-alpha.1; fixed in 4.1.5\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-2025-31485/ (Markdown: https://insights.sbomify.com/CVE-2025-31485/index.md)","id":"CVE-2025-31485","markdown":"https://insights.sbomify.com/CVE-2025-31485/index.md","name":"CVE-2025-31485","record":{"aliases":["GHSA-428q-q3vv-3fq3"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["data_read","security_bypass"],"network_reachable":"yes","non_default_config":false,"product_category":"API Platform Core","requires_auth":"none","summary":"Attackers can bypass GraphQL property access controls due to incorrect cache key generation, potentially reading unauthorized data.","user_interaction":"not_required","vuln_class":"missing_authorization"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[],"cvss":{"score":7.5,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","version":"3.1"},"cwes":[{"id":"CWE-696","name":"Incorrect Behavior Order"}],"description":"API Platform Core is a system to create hypermedia-driven REST and GraphQL APIs. Prior to 4.0.22 and 3.4.17, a GraphQL grant on a property might be cached with different objects. The ApiPlatform\\GraphQl\\Serializer\\ItemNormalizer::isCacheKeySafe() method is meant to prevent the caching but the parent::normalize method that is called afterwards still creates the cache key and causes the issue. This vulnerability is fixed in 4.0.22 and 3.4.17.","ecosystems":["Packagist"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"GraphQL grant on a property might be cached with different objects","id":"CVE-2025-31485","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Packagist","product":null,"products":[],"type":"missing_authorization","year":"2025"},"n_packages":12,"n_references":4,"next":{"headline":"Vite allows server.fs.deny to be bypassed with .svg or relative paths","id":"CVE-2025-31486"},"packages":[{"ecosystem":"Packagist","fixed":["3.4.17"],"introduced":["0"],"last_affected":[],"package":"api-platform/core","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["3.4.17"],"introduced":["0"],"last_affected":[],"package":"api-platform/core","purl":"pkg:composer/api-platform/core","source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.0.22"],"introduced":["4.0.0-alpha.1"],"last_affected":[],"package":"api-platform/core","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.0.22"],"introduced":["4.0.0-alpha.1"],"last_affected":[],"package":"api-platform/core","purl":"pkg:composer/api-platform/core","source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.1.5"],"introduced":["4.1.0-alpha.1"],"last_affected":[],"package":"api-platform/core","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.1.5"],"introduced":["4.1.0-alpha.1"],"last_affected":[],"package":"api-platform/core","purl":"pkg:composer/api-platform/core","source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["3.4.17"],"introduced":["0"],"last_affected":[],"package":"api-platform/graphql","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["3.4.17"],"introduced":["0"],"last_affected":[],"package":"api-platform/graphql","purl":"pkg:composer/api-platform/graphql","source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.0.22"],"introduced":["4.0.0-alpha.1"],"last_affected":[],"package":"api-platform/graphql","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.0.22"],"introduced":["4.0.0-alpha.1"],"last_affected":[],"package":"api-platform/graphql","purl":"pkg:composer/api-platform/graphql","source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.1.5"],"introduced":["4.1.0-alpha.1"],"last_affected":[],"package":"api-platform/graphql","purl":null,"source":"GHSA-428q-q3vv-3fq3"},{"ecosystem":"Packagist","fixed":["4.1.5"],"introduced":["4.1.0-alpha.1"],"last_affected":[],"package":"api-platform/graphql","purl":"pkg:composer/api-platform/graphql","source":"GHSA-428q-q3vv-3fq3"}],"prev":{"headline":"conda-forge infrastructure uses a bad token for Azure's cf-staging access","id":"CVE-2025-31484"},"products":["core"],"published":"2025-04-03","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":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"yes","exploitation":"none","technical_impact":"partial"},"state":"PUBLISHED","updated":"2025-04-08","vendors":["api-platform"]},"summary":"Attackers can bypass GraphQL property access controls due to incorrect cache key generation, potentially reading unauthorized data.","url":"https://insights.sbomify.com/CVE-2025-31485/"}