Krayin CRM — TinyMCE Upload Unrestricted File Upload to RCE (CVE-2026-38526)
by pawpic · 2026-07-05
- Severity
- Critical
- CVE
- CVE-2026-38526
- Category
- web
- Affected product
- Krayin CRM
- Affected versions
- <= 2.2.x
- Disclosed
- 2026-07-05
- Patch status
- unpatched
References
Archive entry
intelseclab/poc-archiveMetadata
| Field | Value |
|---|---|
| Date Added | 2026-07-05 |
| Last Updated | 2026-07 |
| Author / Researcher | pawpic |
| CVE / Advisory | CVE-2026-38526 |
| Category | web |
| Severity | Critical |
| CVSS Score | Not specified in source |
| Status | Weaponized |
| Tags | krayin-crm, laravel, unrestricted-file-upload, tinymce, rce, reverse-shell, authenticated |
| Related | N/A |
Affected Target
| Field | Value |
|---|---|
| Software / System | Krayin CRM |
| Versions Affected | <= 2.2.x |
| Language / Platform | Python (PoC) targeting PHP/Laravel web app |
| Authentication Required | Yes (valid login credentials) |
| Network Access Required | Yes |
Summary
Krayin CRM’s TinyMCE rich-text editor upload endpoint (/admin/tinymce/upload) fails to properly restrict uploaded file types, allowing an authenticated user to bypass the upload filter using a double-extension technique and upload a PHP webshell. Once uploaded, the attacker can access the file directly to execute arbitrary commands or spawn a reverse shell on the server. The included exploit fully automates Laravel login (with CSRF token handling), file upload, and shell interaction.
Vulnerability Details
Root Cause
The /admin/tinymce/upload endpoint does not adequately validate uploaded file extensions/content, permitting PHP files disguised via a double extension to be stored in a web-accessible location (CWE-434).
Attack Vector
- Authenticate to Krayin CRM with valid user credentials.
- Submit a crafted double-extension file (e.g.
shell.php.png) to the TinyMCE upload endpoint, bypassing extension filtering. - Request the uploaded file’s resulting URL to execute the embedded PHP payload.
- Use the resulting code execution to run commands or establish a reverse shell.
Impact
Full remote code execution on the Krayin CRM host as the web server user, enabling data theft, lateral movement, or persistent backdoor installation.
Environment / Lab Setup
Target: Krayin CRM <= 2.2.x (PHP/Laravel)
Attacker: python3, requests, beautifulsoup4, nc (for reverse shell listener)
Proof of Concept
PoC Script
See
exploit.pyin this folder.
| |
The script logs into Krayin CRM (handling Laravel CSRF tokens), uploads a PHP webshell via the vulnerable TinyMCE endpoint using a double-extension bypass, and either executes a single command (-c) or connects back a reverse shell to the attacker’s listener.
Detection & Indicators of Compromise
POST /admin/tinymce/upload HTTP/1.1
GET /storage/tinymce/<payload>.php.png HTTP/1.1
Signs of compromise:
- Uploaded files in the TinyMCE storage directory with double or suspicious extensions
- Outbound reverse-shell connections originating from the CRM host
Remediation
| Action | Detail |
|---|---|
| Primary fix | No vendor patch confirmed as of 2026-07-05 — monitor for advisory |
| Interim mitigation | Enforce strict single-extension/MIME-type allowlisting on the TinyMCE upload endpoint; store uploads outside the web root or disable PHP execution in the upload directory |
References
Notes
Mirrored from https://github.com/pawpic/CVE-2026-38526-POC on 2026-07-05.
| |