CVE-2026-24420: phpMyFAQ Attachment Download Allowed Without Dlattachment Vulnerability

MODERATE
Advisory Identifier: GHSA-7p9h-m7m8-vhhv
CVSS 6.5
CWE-284
Published
Advisory Summary

CVE-2026-24420 is a MODERATE (CVSS 6.5) attachment download allowed without dlattachment vulnerability (CWE-284: Improper Access Control) affecting phpMyFAQ libraries in the Packagist ecosystem. The issue involves attachment download allowed without dlattachment right (broken access control). Remediation is available by upgrading affected packages to version 4.0.17.

CVE-2026-24420 at a Glance

CVE Identifier CVE-2026-24420
GHSA Identifier GHSA-7p9h-m7m8-vhhv
Severity MODERATE
CVSS v3.1 Base Score 6.5
CWE Classification CWE-284: Improper Access Control
Affected Product phpMyFAQ
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 6.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2026-24420

To remediate this vulnerability, upgrade all affected phpMyFAQ dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

phpmyfaq/phpmyfaq fixed: 4.0.17
Upgrade phpmyfaq/phpmyfaq to 4.0.17
thorsten/phpmyfaq fixed: 4.0.17
Upgrade thorsten/phpmyfaq to 4.0.17
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for phpmyfaq/phpmyfaq

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-24420, inspect your project dependencies for phpMyFAQ:

inspect dependencies for phpmyfaq/phpmyfaq

Analyze the terminal output to locate any version of phpMyFAQ in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.0.17), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In phpMyFAQ, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary A logged‑in user without the dlattachment right can download FAQ attachments. This is due to a permissive permission check in attachment.php that treats the mere presence of a right key as authorization and a flawed group/user logic expression. ### Details In attachment.php, the access decision uses: ```($groupPermission || ($groupPermission && $userPermission)) && isset($permission['dlattachment'])``` isset() returns true even when the right value is false, and the logic simplifies to $groupPermission for some permission modes. As a result, a user without dlattachment can still access the attachment. ### PoC Precondition: A non‑admin user exists; an attachment is associated to a FAQ record; records.allowDownloadsForGuests = false. Log in as a non‑admin user without dlattachment. Request the attachment download endpoint. ``` curl -c /tmp/pmf_api_cookies.txt \ -H 'Content-Type: application/json' \ -d '{"username":"tester","password":"Test1234!"}' \ http://192.168.40.16/phpmyfaq/api/v3.0/login curl -i -b /tmp/pmf_api_cookies.txt \ "http://192.168.40.16/phpmyfaq/index.php?action=attachment&id=1" ``` ### Impact Unauthorized users can download attachments (confidentiality breach). Depending on content, this may expose sensitive documents.

CVE-2026-24420 Affected phpMyFAQ Versions

2 component(s)
Fixed Versions:
4.0.17
Product / Package Ecosystem Affected Versions Fixed Version
phpmyfaq/phpmyfaq
Packagist
< 4.0.17
4.0.17
thorsten/phpmyfaq
Packagist
< 4.0.17
4.0.17

References

Frequently Asked Questions

What is CVE-2026-24420?
CVE-2026-24420 is a security vulnerability in phpMyFAQ involving Attachment download allowed without dlattachment right (broken access control) under CWE-284: Improper Access Control.
Which phpMyFAQ versions are affected?
Affected versions include releases prior to 4.0.17 across affected packages: phpmyfaq/phpmyfaq, thorsten/phpmyfaq.
What version fixes CVE-2026-24420?
Upgrading to 4.0.17 (or the latest patched release for your respective branch) resolves the vulnerability.
Is phpmyfaq/phpmyfaq affected?
Yes, phpmyfaq/phpmyfaq is affected in releases prior to 4.0.17. Upgrade your dependency to 4.0.17 or later.
Is thorsten/phpmyfaq affected?
Yes, thorsten/phpmyfaq is affected in releases prior to 4.0.17. Upgrade your dependency to 4.0.17 or later.
What is the CVSS score of CVE-2026-24420?
CVE-2026-24420 has a CVSS v3.1 base score of 6.5 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2026-24420?
CVE-2026-24420 is classified under CWE-284: Improper Access Control (The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.).
How can I check Packagist dependencies for CVE-2026-24420?
Run the dependency tree command: 'inspect dependencies for phpmyfaq/phpmyfaq'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-7p9h-m7m8-vhhv",
  "modified" : "2026-01-28T04:43:20Z",
  "published" : "2026-01-23T20:17:16Z",
  "aliases" : [ "CVE-2026-24420" ],
  "summary" : "phpMyFAQ: Attachment download allowed without dlattachment right (broken access control)",
  "details" : "### Summary\nA logged‑in user without the dlattachment right can download FAQ attachments. This is due to a permissive permission check in attachment.php that treats the mere presence of a right key as authorization and a flawed group/user logic expression.\n\n### Details\nIn attachment.php, the access decision uses:\n```($groupPermission || ($groupPermission && $userPermission)) && isset($permission['dlattachment'])```\nisset() returns true even when the right value is false, and the logic simplifies to $groupPermission for some permission modes. As a result, a user without dlattachment can still access the attachment.\n\n### PoC\nPrecondition: A non‑admin user exists; an attachment is associated to a FAQ record; records.allowDownloadsForGuests = false.\nLog in as a non‑admin user without dlattachment.\nRequest the attachment download endpoint.\n```\ncurl -c /tmp/pmf_api_cookies.txt \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"username\":\"tester\",\"password\":\"Test1234!\"}' \\\n  http://192.168.40.16/phpmyfaq/api/v3.0/login\n\ncurl -i -b /tmp/pmf_api_cookies.txt \\\n  \"http://192.168.40.16/phpmyfaq/index.php?action=attachment&id=1\"\n```\n\n### Impact\nUnauthorized users can download attachments (confidentiality breach). Depending on content, this may expose sensitive documents.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "phpmyfaq/phpmyfaq"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "4.0.17"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 4.0.16"
    }
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "thorsten/phpmyfaq"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "4.0.17"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 4.0.16"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/thorsten/phpMyFAQ/security/advisories/GHSA-7p9h-m7m8-vhhv"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-24420"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/thorsten/phpMyFAQ"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-01-23T20:17:16Z",
    "nvd_published_at" : "2026-01-24T03:16:00Z"
  }
}