CVE-2026-138112 — Metadist Synaplan — CWE-862 · CWE-863
A vulnerability was detected in metadist synaplan up to 5.6.6. This affects the function createApiKey of the file backend/src/Controller/LegacyApiController.php of the component Legacy API Endpoint. Performing a manipulation results in missing authorization. It is possible to initiate the attack remotely. The exploit is now public and may be used. Upgrading to version 5.6.7 is able to mitigate this issue. The patch is named 644267a350db537327acb719bb1e21de28d8e179. It is suggested to upgrade the affected component.
A vulnerability was detected in metadist synaplan up to 5.6.6. This affects the function createApiKey of the file backend/src/Controller/LegacyApiController.php of the component Legacy API Endpoint. Performing a manipulation results in missing authorization. It is possible to initiate the attack remotely. The exploit is now public and may be used. Upgrading to version 5.6.7 is able to mitigate this issue. The patch is named 644267a350db537327acb719bb1e21de28d8e179. It is suggested to upgrade the affected component.
🎯 What is this vulnerability?
| Item | Detail |
|---|---|
| CVE | CVE‑2026‑138112 |
| Product | *metadist:synaplan* (versions ≤ 5.6.6) |
| Component | LegacyApiController::createApiKey (file backend/src/Controller/LegacyApiController.php) |
| CWE | CWE‑862 Missing Authorization, CWE‑863 Incorrect Authorization |
| CVSS v4.0 Vector | AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P |
| Score | 7.3 (MEDIUM) |
Technical root‑cause
createApiKey is an endpoint that generates a new API‑key object and stores it in the database.
The function performs input validation (e.g., checks that the request body contains a name field) but does not verify that the caller is authorized to create an API key on behalf of the target user or tenant.
Typical flow (simplified):
public function createApiKey(Request $request): JsonResponse
{
// 1. Decode JSON payload
$data = json_decode($request->getContent(), true);
// 2. Basic sanity checks – e.g. $data['name'] must be present
if (empty($data['name'])) {
return $this->json(['error' => 'Name required'], 400);
}
// 3. **Missing step** – no check that the authenticated principal
// (or lack thereof) is allowed to create a key for the supplied
// tenant/user identifier.
// 4. Persist the new key
$apiKey = new ApiKey();
$apiKey->setName($data['name']);
$apiKey->setOwnerId($data['ownerId'] ?? $this->getCurrentUserId());
$apiKey->setToken(bin2hex(random_bytes(32)));
$this->entityManager->persist($apiKey);
$this->entityManager->flush();
// 5. Return the newly created key
return $this->json(['apiKey' => $apiKey->getToken()], 201);
}- The authorization gate that should compare the caller’s privileges (e.g.,
isGranted('ROLE_ADMIN')or a tenant‑ownership check) is absent. - Because the controller is reachable via the public “Legacy API” route, an unauthenticated attacker can invoke it directly (
PR:N,UI:N). - The result is unauthorized creation of API keys that can later be used to call any other protected endpoint that trusts the API‑key authentication mechanism.
Hence the vulnerability is a classic Missing/Incorrect Authorization (CWE‑862/863) that leads to privilege escalation from “no access” to “full API access”.
⚡ Attack Chain
Below is a realistic, step‑by‑step exploitation path. All commands are illustrative – the exact URI path and JSON field names are inferred from the source file name and typical Synaplan conventions. If the real endpoint differs, replace the placeholders accordingly.
1. Discovery & Reconnaissance
| Step | Technique | Expected artefacts |
|---|---|---|
| Version fingerprint | Grab the public composer.json or /api/status endpoint, or inspect HTTP Server header. Many Synaplan installations expose a /version endpoint that returns {"product":"synaplan","version":"5.6.4"}. | Confirms the target runs ≤ 5.6.6. |
| Endpoint enumeration | Use a web‑application scanner (e.g., nikto, ffuf) against /api/legacy/* or read the open‑source repository to locate LegacyApiController. | Reveals a POST route such as /api/legacy/apikey/create. |
| Authentication check | Send a request without any auth token; a 200 or 201 response indicates the endpoint is reachable anonymously. | Confirms missing auth enforcement. |
2. Exploitation
Goal: Create a new API key that the attacker controls.
# -------------------------------------------------
# Illustrative PoC – replace <HOST> with the target
# -------------------------------------------------
curl -sk -X POST "https://<HOST>/api/legacy/apikey/create" \
-H "Content-Type: application/json" \
-d '{
"name": "attacker-key",
"ownerId": "[email protected]"
}'name – arbitrary label for the key (required by the controller).
* ownerId – optional; if supplied the controller will bind the key to that identifier. Because there is no ownership check, any identifier can be used, including privileged service accounts.{
"apiKey": "a1b2c3d4e5f6... (64‑hex chars)"
}Authorization: Bearer <apiKey>.3. Post‑exploitation
| Phase | Action | Result |
|---|---|---|
| API key abuse | Use the stolen key to call privileged endpoints, e.g. GET /api/v1/users, POST /api/v1/projects/create. | Full read/write access to data the API key is authorized for (often admin‑level because the key is not bound to a specific role). |
| Persistence | Store the key in a configuration file or secret manager used by the attacker’s tooling. | Long‑term access even after the initial PoC is removed. |
| Lateral movement | If the platform integrates with external services (webhooks, CI/CD), the key can be used to exfiltrate data or trigger actions in those services. | Potential data breach or supply‑chain compromise. |
| Cleanup / covering tracks | Delete the key via the (unprotected) DELETE /api/legacy/apikey/{id} endpoint, if it exists, to hide the artefact. | Reduces chance of detection. |
🌍 Real‑World Impact
| CIA | CVSS vector component | Practical effect |
|---|---|---|
| Confidentiality (C) | VC:L (Low) | The attacker can read data that the newly‑created API key is allowed to access. In many deployments the default role for API keys is *admin*, so the confidentiality impact can be significant even though the CVSS scores it “low”. |
| Integrity (I) | VI:L (Low) | The attacker can modify or delete resources (e.g., create/alter projects, change user attributes). |
| Availability (A) | VA:L (Low) | The attacker could delete critical objects or flood the system with bogus requests, causing a mild denial‑of‑service. |
Overall consequence: An unauthenticated remote attacker can bootstrap privileged access to the entire Synaplan installation without any prior foothold. This is a classic “privilege‑escalation via missing auth” that can lead to full system compromise, data exfiltration, and potential ransomware or supply‑chain attacks downstream.
🛡️ Remediation & Mitigation
1. Patch / Upgrade
| Item | Action |
|---|---|
| Affected versions | metadist:synaplan ≤ 5.6.6 |
| Fixed version | 5.6.7 (released 2026‑11‑28) |
| Patch identifier | Git commit 644267a350db537327acb719bb1e21de28d8e179 – adds an explicit authorization check before persisting the API key. |
| Upgrade path | Run composer update metadist/synaplan:^5.6.7 or apply the vendor‑provided binary. Verify the composer.lock hash matches the vendor’s checksum. |
2. Immediate Workarounds (if patch cannot be applied immediately)
| Technique | Implementation Details |
|---|---|
| Restrict network access | Block inbound traffic to the legacy API namespace (/api/legacy/*) at the perimeter firewall or cloud security group. Only allow trusted internal IP ranges. |
| Disable the Legacy API component | In config/services.yaml set legacy_api.enabled: false (or comment out the route registration in routes.yaml). This removes the vulnerable endpoint without affecting the modern API. |
| WAF / ModSecurity rule | Block POST requests to the vulnerable path unless a valid authentication header is present. Example ModSecurity rule (valid syntax):
# -------------------------------------------------
# ModSecurity rule to enforce auth on Legacy API key creation
# -------------------------------------------------
SecRule REQUEST_URI "@beginsWith /api/legacy/apikey/create" \
"id:2026138,\
phase:2,\
t:none,\
chain,\
SecRule &REQUEST_HEADERS:Authorization \"@eq 0\" \
\"t:none,\
deny,\
status:403,\
msg:'Legacy API key creation blocked – missing Authorization header',\
log\""Note – Adjust the URI (/api/legacy/apikey/create) to match the actual route discovered during reconnaissance. | |
|---|---|
| Rate‑limit | Apply a strict request‑rate limit (e.g., 1 request per minute per IP) on the legacy endpoint to make automated key‑generation attempts noisy and detectable. |
| Audit logging | Enable detailed request logging for the legacy controller (logger.level: debug) and forward logs to a SIEM. |
3. Detection – Indicators of Compromise
| Log source | Typical pattern |
|---|---|
| Web server access log (Apache/Nginx) | POST /api/legacy/apikey/create 201 without an Authorization: header. |
Application log (var/log/app.log) | Created new API key for [email protected] – look for unexpected ownerId values or a sudden spike in createApiKey calls. |
| Database audit (if enabled) | INSERT into api_keys where created_by is NULL or a system account that should never be used. |
| SIEM correlation | Multiple POST /api/legacy/apikey/create from the same source IP within a short window, followed by privileged API calls (/api/v1/*) using the newly returned token. |
Sample grep command (Linux) to spot suspicious activity:
grep -E "POST /api/legacy/apikey/create.* 201" /var/log/nginx/access.log \
| awk '{print $1,$4,$7}' | sort | uniq -c | sort -nr | head⚠️ Urgency
CVSS 7.3 (Medium) – The exploit is network‑reachable, low‑complexity, and requires no authentication. The impact is “low” per CVSS, but the real‑world* impact (full API‑key compromise) is high because the platform’s API keys grant broad privileges.
Recommendation:
Given the ease of exploitation and the potential for full system compromise, treat this as a high‑priority remediation item despite the “Medium” CVSS label.
[🤖 CVE Professor AI Security Engine]
FOFA Query