BoidCMS
BoidCMS: Local File Inclusion (LFI) leads to Remote Code Execution (RCE) via tpl parameter
BoidCMS is an open-source, PHP-based flat-file CMS for building simple websites and blogs, using JSON as its database. Versions prior to 2.1.3 are vulnerable to a critical Local File Inclusion (LFI) attack via the tpl parameter, which can lead to Remote Code Execution (RCE).The application fails to sanitize the tpl (template) parameter during page creation and updates. This parameter is passed directly to a require_once() statement without path validation. An authenticated administrator can exploit this by injecting path traversal sequences (../) into the tpl value to escape the intended theme directory and include arbitrary files — specifically, files from the server's media/ directory. When combined with the file upload functionality, this becomes a full RCE chain: an attacker can first upload a file with embedded PHP code (e.g., disguised as image data), then use the path traversal vulnerability to include that file via require_once(), executing the embedded code with web server privileges. This issue has been fixed in version 2.1.3.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 2.1.3
Fixed in 2.1.3
Mitigation
Upgrade BoidCMS to 2.1.3 or later.
References
- Vendor advisory github.com/BoidCMS/BoidCMS/security/advisories…
- Release notes github.com/BoidCMS/BoidCMS/releases/tag/v2.1.3
Timeline
Days relative to CVE publicationFirst public PoC 17 days after publication; not in CISA KEV. First PoC: xp1tr/CVE-2026-39387 (created 2 May 2026, found by us: backfilled).
PoC repositories
Found on GitHub.1 PoCs
PoCs 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| xp1tr/CVE-2026-39387 | 2 May 2026 +17 d | 0 | PoC
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
PoC characteristics
What to hunt for in your logs · from 1 PoC repoGET /{var}
- Query
cmd=- Seen in
- 1 repo: xp1tr/CVE-2026-39387
- Evidence
- xp1tr/CVE-2026-39387/CVE-2026-39387.py:97
POST /admin
- Query
page=mediapage=create- Body markers
username=password=token=login=Loginupload=Uploadtype=posttitle=Security Testdescr=POCkeywords=content=permalink=rce_pagetpl=../../media/shell.gifthumb=date=pub=truecreate=Createinapplication/x-www-form-urlencoded- Seen in
- 1 repo: xp1tr/CVE-2026-39387
- Evidence
- xp1tr/CVE-2026-39387/CVE-2026-39387.py:47 xp1tr/CVE-2026-39387/CVE-2026-39387.py:60 xp1tr/CVE-2026-39387/CVE-2026-39387.py:85
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/[^/?#]*\?(?:.*&)?cmd=
(?i)^/admin\?(?:.*&)?page=media.*page=create
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2026-39387 BoidCMS BoidCMS exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"cmd="; reference:url,poc.griffinguard.io/cve/CVE-2026-39387; classtype:web-application-attack; sid:9652949; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2026-39387 BoidCMS BoidCMS exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"/admin"; http.uri; content:"page=media"; http.uri; content:"page=create"; http.request_body; content:"username="; http.request_body; content:"password="; http.request_body; content:"token="; http.request_body; content:"login=Login"; http.request_body; content:"upload=Upload"; http.request_body; content:"type=post"; http.request_body; content:"title=Security Test"; http.request_body; content:"descr=POC"; http.request_body; content:"keywords="; http.request_body; content:"content="; http.request_body; content:"permalink=rce_page"; http.request_body; content:"tpl=../../media/shell.gif"; http.request_body; content:"thumb="; http.request_body; content:"date="; http.request_body; content:"pub=true"; http.request_body; content:"create=Create"; reference:url,poc.griffinguard.io/cve/CVE-2026-39387; classtype:web-application-attack; sid:9081295; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: BoidCMS BoidCMS exploit attempt (CVE-2026-39387)
id: gg-pocmon-cve-2026-39387-9652949
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-39387. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-39387
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-query|contains|all:
- 'cmd='
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.39387
title: BoidCMS BoidCMS exploit attempt (CVE-2026-39387)
id: gg-pocmon-cve-2026-39387-9081295
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-39387. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2026-39387
logsource:
category: webserver
detection:
selection:
cs-method: POST
cs-uri-stem|contains|all:
- '/admin'
cs-uri-query|contains|all:
- 'page=media'
- 'page=create'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2026.39387