{"answers":{"affected":"2 open source packages ship an affected version, including @vendure/core.","exploited":"There is no known exploitation of GHSA-wm63-7627-ch33 in the wild and no public exploit code.","fix":"Upgrade @vendure/core to 2.1.3 or later.","what":"GHSA-wm63-7627-ch33 is a vulnerability in @vendure/core, published on 17 Nov 2023. Any signed-in user can exploit it over the network, with no action from the victim."},"fix_prompt":"Check this codebase for GHSA-wm63-7627-ch33 and fix it if it is affected.\n\nWhat it is: GHSA-wm63-7627-ch33 is a vulnerability in @vendure/core, published on 17 Nov 2023. Any signed-in user can exploit it over the network, with no action from the victim.\nExploitation: There is no known exploitation of GHSA-wm63-7627-ch33 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- @vendure/core (npm): affected all versions; fixed in 2.1.3\n- @vendure/core (npm): affected all versions; fixed in 2.1.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-wm63-7627-ch33/ (Markdown: https://insights.sbomify.com/GHSA-wm63-7627-ch33/index.md)","id":"GHSA-wm63-7627-ch33","markdown":"https://insights.sbomify.com/GHSA-wm63-7627-ch33/index.md","name":"GHSA-wm63-7627-ch33","record":{"aliases":[],"analysis":{"component_type":"web_application","fix_type":"upgrade","impacts":["data_modify","security_bypass"],"network_reachable":"yes","non_default_config":false,"product_category":"E-commerce platform","requires_auth":"low_privilege","summary":"Attackers can manipulate currency codes to pay incorrect amounts, bypassing price validation in Vendure e-commerce deployments.","user_interaction":"not_required","vuln_class":"business_logic"},"analysis_generated_by":"qwen3.8-flash-next","assigner":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"### Impact\n\nCurrently, in many Vendure deployments it's possible to select any currencyCode (really any, doesn't need to be assigned to the channel) and pay through Mollie and Stripe in that particular currencyCode.\nThe prices are not transformed. The result is the Order is in Payment Settled in the foreign currency.\nSee SS, CZK is not in the channel.\nI've tested with Mollie and Stripe it both works.\n\n**Further notes**\n\nAfter looking into this further and with help from the comments below, the root cause of this vulnerability is the ability to specify an arbitrary `currencyCode` as a query parameter to an API call, and then Vendure will use this and pass it to the rest of the system as `RequestContext.currencyCode`.\n\nThe solution is to add validation to the passed `currencyCode` to ensure that it matches one of the available `availableCurrencyCodes` of the active Channel.\n\nFurthermore, an additional check has been added for when the currencyCode changes during the AddingItems stage - in this case we need to re-calculate the prices in the new currency.\n\n### Patches\nv2.1.3\n\n### Workarounds\nYou can define a custom OrderProcess [onTransitionStart function](https://docs.vendure.io/guides/core-concepts/orders/#intercepting-a-state-transition) which can verify the order's `currencyCode` is as expected before allowing the transition to the `ArrangingPayment` state.","ecosystems":["npm"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"@vendure/core's insecure currencyCode handling allows wrong payment amounts","id":"GHSA-wm63-7627-ch33","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"npm","product":null,"products":[],"type":"business_logic","year":"2023"},"n_packages":2,"n_references":null,"packages":[{"ecosystem":"npm","fixed":["2.1.3"],"introduced":["0"],"last_affected":[],"package":"@vendure/core","purl":null,"source":"GHSA-wm63-7627-ch33"},{"ecosystem":"npm","fixed":["2.1.3"],"introduced":["0"],"last_affected":[],"package":"@vendure/core","purl":"pkg:npm/%40vendure/core","source":"GHSA-wm63-7627-ch33"}],"products":null,"published":"2023-11-17","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 manipulate currency codes to pay incorrect amounts, bypassing price validation in Vendure e-commerce deployments.","url":"https://insights.sbomify.com/GHSA-wm63-7627-ch33/"}