GHSA-3W38-HV8F-F6M3
First-cycle coupons can be applied permanently to service renewals
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | GHSA-3W38-HV8F-F6M3 divulgada · CVSS 7.7 (GitHub) | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
An authenticated customer can exploit inconsistent coupon state handling during checkout to turn a first-billing-cycle discount into a permanent discount on all future service renewals.
`App\Livewire\Cart::checkout()` validates coupons using the server-side cart but determines the recurring service price using Livewire component state. When a coupon is applied through the `?coupon=` query parameter after the component has been initialized, these values can become inconsistent.
As a result, a first-cycle-only coupon can be stored as a permanent service discount. With a 100% coupon, the service is created with a recurring price of `0.00`, allowing it to renew indefinitely without generating further invoices.
Technical Details
`app/Livewire/Cart.php` validates the coupon using the authoritative cart record:
if ($cart->coupon && !ClassesCart::validateAndRefreshCoupon()) {
// ...
}However, the recurring service price is determined using `$this->coupon` instead:
if (is_object($this->coupon) && ($this->coupon->recurring === null || (int) $this->coupon->recurring == 1)) {
$price = $item->price->original_price;
} else {
$price = $item->price->price;
}The component's `$this->coupon` property is initialized during `mount()` and may become outdated when the cart is modified independently.
`app/Http/Middleware/CheckoutParameterMiddleware.php` allows coupons to be applied through the `?coupon=` query parameter:
private function handleCouponApplication(Request $request): void
{
if (!$request->has('coupon')) {
return;
}
try {
Cart::applyCoupon($request->input('coupon'));
} catch (DisplayException $e) {
return;
}
}Because this updates the cart without updating an already-mounted Livewire component, `$cart->coupon` can contain a valid coupon while `$this->coupon` remains `null`.
During checkout, the application consequently stores the discounted price in `services.price` instead of the original recurring price.
`app/Console/Commands/CronJob.php` uses `services.price` when generating renewal invoices, causing the discount to persist beyond its configured billing cycle.
For 100% discounts, the resulting price of `0.00` causes the renewal process to extend the service directly without creating an invoice.
Impact
An authenticated customer can convert a coupon intended for the first billing cycle into a permanent discount on all future renewals.
For example, a service normally costing $100 per month with a 50% first-cycle coupon can incorrectly renew at $50 indefinitely instead of returning to $100.
With a 100% first-cycle coupon, the recurring service price becomes $0, allowing the customer to receive ongoing service renewals without further payments or renewal invoices.
The vulnerability requires a valid first-cycle coupon and an authenticated customer account. No administrative privileges, modified Livewire payloads, or compromised payment gateways are required.
This can result in recurring revenue loss and may also occur unintentionally when customers apply promotional coupons in another browser tab before completing checkout.
Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
Packagistpaymenter/paymenter |
Sin parche | — | — | — |
Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/Paymenter/Paymenter/security/advisories/GHSA-3w38-hv8f-f6m3Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
