Skip to content
Heist/ feed
Back to feed
Critical

Masa CMS unauthenticated SQL injection via altTable parameter in JSON API

Type: advisorySources: OSV

Masa CMS is an open source content management system. In versions 7.2.0 through 7.2.9, 7.3.0 through 7.3.14, 7.4.0 through 7.4.9, and 7.5.0 through 7.5.2, the unauthenticated JSON API accepts an altTable parameter that is stored via the setAltTable() method without validation or sanitization. This value is injected directly into a SQL FROM clause within feedGateway.cfc. An unauthenticated attacker can pass an arbitrary subquery into the altTable parameter to read sensitive data from any table in the database in a single HTTP request, including administrative credentials and password reset tokens. This issue has been fixed in versions 7.2.10, 7.3.15, 7.4.10, and 7.5.3. As a workaround, apply validation to the setAltTable function in core/mura/content/feed/feedBean.cfc to restrict input to simple alphanumeric table names, or disable the JSON API if it is not required.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-40331
Confirmed fixed CVEs
Not specified
Updated in this feed
3 Nov 2026, 17:48 UTC · Revision 1

Source evidence

Masa CMS unauthenticated SQL injection via altTable parameter in JSON API

core-osv · Original source

Published 5 May 2026, 19:48 UTC

Masa CMS is an open source content management system. In versions 7.2.0 through 7.2.9, 7.3.0 through 7.3.14, 7.4.0 through 7.4.9, and 7.5.0 through 7.5.2, the unauthenticated JSON API accepts an altTable parameter that is stored via the setAltTable() method without validation or sanitization. This value is injected directly into a SQL FROM clause within feedGateway.cfc. An unauthenticated attacker can pass an arbitrary subquery into the altTable parameter to read sensitive data from any table in the database in a single HTTP request, including administrative credentials and password reset tokens. This issue has been fixed in versions 7.2.10, 7.3.15, 7.4.10, and 7.5.3. As a workaround, apply validation to the setAltTable function in core/mura/content/feed/feedBean.cfc to restrict input to simple alphanumeric table names, or disable the JSON API if it is not required.

osv:CVE-2026-40331
Complete source record
{
  "id": "dcdfe01944d2728ff849216a51cb8678214046439603e8b493682c634bd09fad",
  "url": "https://osv.dev/vulnerability/CVE-2026-40331",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Masa CMS unauthenticated SQL injection via altTable parameter in JSON API",
    "summary": "Masa CMS is an open source content management system. In versions 7.2.0 through 7.2.9, 7.3.0 through 7.3.14, 7.4.0 through 7.4.9, and 7.5.0 through 7.5.2, the unauthenticated JSON API accepts an altTable parameter that is stored via the setAltTable() method without validation or sanitization. This value is injected directly into a SQL FROM clause within feedGateway.cfc. An unauthenticated attacker can pass an arbitrary subquery into the altTable parameter to read sensitive data from any table in the database in a single HTTP request, including administrative credentials and password reset tokens. This issue has been fixed in versions 7.2.10, 7.3.15, 7.4.10, and 7.5.3. As a workaround, apply validation to the setAltTable function in core/mura/content/feed/feedBean.cfc to restrict input to simple alphanumeric table names, or disable the JSON API if it is not required.",
    "evidence": "osv:CVE-2026-40331",
    "products": [],
    "severity": "critical",
    "structured": {
      "id": "CVE-2026-40331",
      "aliases": [
        "CVE-2026-40331",
        "GHSA-jphh-r686-6w7j"
      ],
      "metrics": [
        {
          "type": "CVSS_V4",
          "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/masacms/masacms",
              "type": "GIT",
              "events": [
                {
                  "introduced": "ea9dd65d88ba55d5b41131cf355778a6529ff42a"
                },
                {
                  "last_affected": "860e7ce75059195f25bc0ccc6e44a464e05a56fb"
                },
                {
                  "introduced": "0"
                },
                {
                  "fixed": "32e14628f9784ab4059cc77d89e21222129c02a1"
                },
                {
                  "introduced": "53d53e7c120068ce1102215805238ab19027fb58"
                },
                {
                  "last_affected": "86f9490fd0dbbcd5c5c4848f908b84bd38c5a6bd"
                },
                {
                  "introduced": "0587433f237af2b04cc2e03e5f08f0300f36d253"
                },
                {
                  "last_affected": "44815bfe904a6470d977de4b776bea0cf913a13c"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "range": [
                      {
                        "introduced": "7.2.0"
                      },
                      {
                        "last_affected": "7.2.9"
                      }
                    ],
                    "source": "DESCRIPTION"
                  },
                  {
                    "range": [
                      {
                        "introduced": "7.3.0"
                      },
                      {
                        "last_affected": "7.3.14"
                      }
                    ],
                    "source": "DESCRIPTION"
                  },
                  {
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "7.2.10"
                      }
                    ],
                    "source": "DESCRIPTION"
                  },
                  {
                    "range": [
                      {
                        "introduced": "7.4.0"
                      },
                      {
                        "last_affected": "7.4.9"
                      }
                    ],
                    "source": "DESCRIPTION"
                  },
                  {
                    "range": [
                      {
                        "introduced": "7.5.0"
                      },
                      {
                        "last_affected": "7.5.2"
                      }
                    ],
                    "source": "DESCRIPTION"
                  }
                ]
              }
            }
          ],
          "versions": [
            "7.2.9",
            "7.4.9",
            "7.5.2",
            "7.2.8",
            "7.4.8",
            "7.5.1",
            "7.5.0",
            "7.4.7",
            "7.4.6",
            "7.2.7",
            "7.4.4",
            "7.2.6",
            "7.4.3",
            "7.4.2",
            "7.4.1",
            "7.2.5",
            "7.4.0",
            "7.2.4",
            "7.2.3",
            "7.2.2",
            "7.2.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-40331.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:31.013983462Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/40xxx/CVE-2026-40331.json",
        "https://github.com/MasaCMS/MasaCMS/security/advisories/GHSA-jphh-r686-6w7j",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-40331"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-89"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/40xxx/CVE-2026-40331.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-40331",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 498005,
  "published_at": "2026-05-05T19:48:07.898+00:00"
}