# CVE-2026-31018: Dolibarr ERP & CRM PHP code injection in Website module

Source: https://junglewise.ai/threats/cve-2026-31018-dolibarr-erp-crm-php-code-injection-in-website-module  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-04-21. Updated: 2026-07-05  
License: CC BY 4.0 with a link back

CVE-2026-31018 · Severity: high · CVSS 8.8 · Published 2026-04-21

Dolibarr ERP & CRM is a suite of business management software used for managing customers, inventory, and websites. A security flaw in its website builder module allows users who should only be able to edit basic text and layout to instead run malicious code on the server. This could lead to a complete takeover of the system, theft of sensitive business data, or disruption of operations.

Technologies: [Dolibarr Crm](https://junglewise.ai/threats/technologies/crm), [Dolibarr ERP/CRM](https://junglewise.ai/threats/technologies/erp-crm), [Dolibarr Erp\](https://junglewise.ai/threats/technologies/dolibarr-erp), [dolibarr/dolibarr (Packagist)](https://junglewise.ai/threats/technologies/dolibarr-dolibarr). Vendors: [Dolibarr](https://junglewise.ai/threats/vendors/dolibarr), [Packagist](https://junglewise.ai/threats/vendors/packagist).

## Quick answers

**Is CVE-2026-31018 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-31018 being exploited in the wild.

**How severe is CVE-2026-31018?** High severity, with a CVSS score of 8.8, published 21 April 2026.

**Which products and versions are affected?** Dolibarr ERP/CRM <= 22.0.4; dolibarr/dolibarr (Packagist) <= 15.0.3, ECOSYSTEM:introduced=0,last_affected=15.0.3.

**Is there a fix for CVE-2026-31018?** No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.

**How is CVE-2026-31018 attacked?** It is attacked over the network, in a network appliance.

**Am I affected by CVE-2026-31018?** Check whether you run Dolibarr Crm, Dolibarr ERP/CRM, Dolibarr Erp\ or one of the others listed at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

A Remote Code Execution (RCE) vulnerability exists in the Website module of Dolibarr ERP/CRM due to improper access control and code injection (CWE-94, CWE-284). While the application defines distinct permission levels for static (HTML/JS) versus dynamic (PHP) content editing, the validation logic is inconsistently applied during the 'Create page from scratch or from a page template' workflow. An authenticated attacker with low-level permissions (restricted to HTML/JS) can bypass these restrictions by injecting PHP code into unprotected input parameters during page creation. This allows for arbitrary code execution on the underlying server. The vulnerability affects versions up to and including 22.0.4.

## Affected products

- Dolibarr Dolibarr ERP & CRM <= 22.0.4

## Identifiers

- CVE-2026-31018
- GHSA-676v-wh57-p375

## Timeline

- 2026-02-06: disclosed: Reported to vendor and MITRE
- 2026-02-12: other: Vendor acknowledged the issue
- 2026-04-21: advisory: NVD publication date

## References

- [https://github.com/PhDg1410/CVE/blob/main/CVE-2026-31018/README.md](https://github.com/PhDg1410/CVE/blob/main/CVE-2026-31018/README.md)

## Related threats

- [Dolibarr SQL injection in localtax parameters](https://junglewise.ai/threats/cve-2026-33944-dolibarr-has-sql-injection-in-societe-class-societe-class-php-via)
- [Dolibarr path traversal in email attachment handling](https://junglewise.ai/threats/cve-2026-81730-dolibarr-path-traversal-in-email-attachment-handling)
- [Dolibarr REST API authorization bypass in document deletion](https://junglewise.ai/threats/cve-2026-81729-dolibarr-rest-api-authorization-bypass-in-document-deletion)
- [Dolibarr SQL injection in CSV/XLSX import wizard](https://junglewise.ai/threats/cve-2026-81728-dolibarr-sql-injection-in-csv-xlsx-import-wizard)
- [Dolibarr authorization bypass in clonetasks private project check](https://junglewise.ai/threats/cve-2026-77923-dolibarr-authorization-bypass-in-clonetasks-private-project-check)
