# Razorpay for WooCommerce <= 4.8.9 - Unauthenticated Gift Card Double Spend via Magic Checkout

- **ID:** WPSEC-2026-4013
- **Plugin:** Razorpay for WooCommerce (`woo-razorpay`), https://wordpress.org/plugins/woo-razorpay/
- **Affected versions:** from 4.4.0 before 4.8.10
- **Fixed in:** 4.8.10 (Update to 4.8.10 or later.)
- **Severity:** Medium 5.3 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N)
- **Weakness:** CWE-367
- **Usage among sites WPSec scans:** plugin Low, affected versions Low (as of 2026-11-26)
- **Attack surface analysis:** https://attacksurface.wpsec.com/plugin/woo-razorpay
- **Fix released:** 2026-11-25
- **Published:** 2026-11-26
- **URL:** https://wpsec.com/vuln/WPSEC-2026-4013/

## Description

The Razorpay for WooCommerce plugin for WordPress is vulnerable to a gift card double spend in Magic Checkout (1cc) orders in all versions up to, and including, 4.8.9. The cause is that a gift card's balance is checked only when the card is applied, and is not checked again after payment. The post-payment check in handlePromotions() is written so that it practically never fails, so the card is debited, even below zero, and the order is completed. In addition, an exception during the order update before promotions are handled still leads to the order being completed with no gift card debit. This makes it possible for unauthenticated attackers, such as guest shoppers holding a gift card, to apply the same balance to several Magic Checkout orders and have all of them completed, getting goods worth more than the card's value. Exploitation requires Magic Checkout with a supported gift card plugin (YITH WooCommerce Gift Cards or PW WooCommerce Gift Cards).

## References

- https://wpsec.com/vuln/WPSEC-2026-4013/
- https://plugins.svn.wordpress.org/woo-razorpay/tags/4.8.10/
- https://wordpress.org/plugins/woo-razorpay/

Source: WPSec, https://wpsec.com/vuln/WPSEC-2026-4013/

License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Free to use, share and adapt, also commercially, if you credit WPSec and link to this advisory.
