GHSA-H4X8-V7VH-37H6
Improper ownership checks allow unauthorized admin modifications to services and invoices
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | GHSA-H4X8-V7VH-37H6 divulgada · CVSS 8.1 (GitHub) | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
An authenticated staff user with only `admin.services.viewAny` or `admin.invoices.viewAny` permission can modify their own services and invoices through the admin panel without the corresponding update permissions.
Both `ServicePolicy::update()` and `InvoicePolicy::update()` allow modifications whenever the authenticated user owns the resource, regardless of whether the request originates from the admin panel. This bypasses the intended administrative permission restrictions.
As a result, a low-privileged staff user can modify service pricing, expiration dates, and resource allocations, or mark invoices as paid to activate services and generate account credit without payment.
Technical Details
`app/Policies/ServicePolicy.php` authorizes service updates using:
public function update(User $user, Service $service): bool
{
return $this->adminPermission($user, 'admin.services.update')
|| $service->user_id === $user->id;
}Similarly, `app/Policies/InvoicePolicy.php` authorizes invoice updates using:
public function update(User $user, Invoice $invoice): bool
{
return $this->adminPermission($user, 'admin.invoices.update')
|| $invoice->user_id === $user->id;
}Although `adminPermission()` checks the appropriate administrative permissions, the ownership condition is evaluated independently and is not restricted to client-facing routes.
Consequently, staff users can access the Filament edit pages for resources they own without holding the corresponding update permissions.
The service editor exposes fields such as `status`, `expires_at`, `price`, `product_id`, and `plan_id`, alongside configuration options and server extension actions for provisioning, upgrading, and unsuspending servers.
The invoice editor allows modifying invoice line items and payment status. When an invoice is marked as paid, `app/Observers/InvoiceObserver.php` triggers:
if ($invoice->isDirty('status') && $invoice->status == 'paid') {
DB::afterCommit(
fn () => app(ProcessPaidInvoiceService::class)->handle($invoice)
);
}This processes the invoice as legitimately paid, potentially activating services, extending subscriptions, or adding credit to the customer's balance without receiving payment.
The same unrestricted ownership fallback is also present in `TicketPolicy::view()` and `TicketPolicy::update()`, allowing similar unauthorized administrative access to tickets owned by the staff user.
Impact
A low-privileged staff user can bypass administrative update permissions for services and invoices they own.
This allows attackers to modify service prices, extend expiration dates, increase hosting resource allocations, and trigger server provisioning or upgrade operations without payment.
Additionally, attackers can mark their own invoices as paid, resulting in unauthorized service activation, renewals, or account credit creation.
The vulnerability compromises billing integrity and can result in direct financial losses and unauthorized consumption of hosting resources.
Exploitation requires an authenticated staff account with the relevant resource-viewing permission and ownership of the affected service or invoice. It does not allow direct modification of resources owned by other customers.
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-h4x8-v7vh-37h6Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
