Description
InvoiceNinja v5-stable renders an invoice or quote's "terms" field in the client portal using Laravel Blade's raw output directive {!! $entity->terms !!} (resources/views/portal/ninja2020/invoices/includes/terms.blade.php) with no HTML sanitization. StoreInvoiceRequest.php only strips newlines from the field and does not purify HTML. An authenticated user with invoice creation access can set the terms field via the REST API (PUT /api/v1/invoices/{id}) to an HTML/JavaScript payload that executes in the client's browser when they view the invoice, enabling session cookie theft and client account takeover. This is a distinct code path from the previously published invoice line-item description field XSS (GHSA-98wm-cxpw-847p / CVE-2026-33628).
Published: 2026-08-05
Score: 8.7 High
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

InvoiceNinja v5‑stable stores the invoice or quote "terms" field without sanitization, rendering raw HTML or JavaScript using Blade’s raw output directive. An authenticated user who can create or modify invoices can inject a script through the REST API endpoint /api/v1/invoices/{id}. When a client opens the invoice, the malicious script runs in the client’s browser, enabling theft of session cookies and the possibility of taking over the client account. This stored cross‑site scripting flaw compromises both the confidentiality of client credentials and the integrity of their account permissions, and can be leveraged to execute arbitrary actions within the portal.

Affected Systems

The affected product is InvoiceNinja, specifically the v5‑stable release that contains the unfiltered terms rendering logic. Any installation deployed via the standard web interface that allows users to create or modify invoices through the public REST API is susceptible. The flaw is independent of enablement of the previously disclosed invoice line‑item description XSS.

Risk and Exploitability

The CVSS score of 8.7 indicates a high‑severity vulnerability with wide impact. The EPSS score is not available, but the lack of a KEV listing means no confirmed exploit has been documented publicly yet. However, the attack path only requires an authenticated user with invoice‑creation permissions, so insider or compromised accounts can trivially exploit it. The script executes in the victim’s browser when the invoice is viewed, making it a straightforward client‑side attack that requires no additional network connectivity once the malicious payload is stored.

Generated by OpenCVE AI on August 5, 2026 at 12:28 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to the latest InvoiceNinja release that includes the fix for unsanitized invoice terms rendering.
  • If an immediate upgrade is not possible, block or restrict write access to the /api/v1/invoices/{id} endpoint for non‑trusted users and enforce server‑side sanitization of the terms field to strip all HTML and JavaScript.
  • In the interim, force all affected clients to log out and re‑authenticate, rotate session cookies, and monitor the portal for anomalous activity indicative of cookie theft or unauthorized actions.

Generated by OpenCVE AI on August 5, 2026 at 12:28 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Wed, 05 Aug 2026 11:15:00 +0000

Type Values Removed Values Added
Description InvoiceNinja v5-stable renders an invoice or quote's "terms" field in the client portal using Laravel Blade's raw output directive {!! $entity->terms !!} (resources/views/portal/ninja2020/invoices/includes/terms.blade.php) with no HTML sanitization. StoreInvoiceRequest.php only strips newlines from the field and does not purify HTML. An authenticated user with invoice creation access can set the terms field via the REST API (PUT /api/v1/invoices/{id}) to an HTML/JavaScript payload that executes in the client's browser when they view the invoice, enabling session cookie theft and client account takeover. This is a distinct code path from the previously published invoice line-item description field XSS (GHSA-98wm-cxpw-847p / CVE-2026-33628).
Title InvoiceNinja: Stored XSS via Invoice/Quote Terms Field
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 8.7, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N'}


Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: TuranSec

Published:

Updated: 2026-08-05T10:56:18.781Z

Reserved: 2026-08-05T10:53:53.175Z

Link: CVE-2026-71233

cve-icon Vulnrichment

No data.

cve-icon NVD

No data.

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-05T12:30:12Z

Weaknesses
  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')