Skip to content
Heist/ feed
Back to feed
Medium

Security advisory

Type: advisorySources: OSVCVE: CVE-2019-14827

A vulnerability was found in Moodle where javaScript injection was possible in some Mustache templates via recursive rendering from contexts. Mustache helper tags that were included in template contexts were not being escaped before that context was injected into another Mustache helper, which could result in script injection in some templates. This affects versions 3.7 to 3.7.1, 3.6 to 3.6.5, 3.5 to 3.5.7 and earlier unsupported versions.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2019-14827
Confirmed fixed CVEs
Not specified
Updated in this feed
1 Nov 2026, 07:33 UTC · Revision 1

Source evidence

CVE-2019-14827

core-osv · Original source

Published 17 May 2021, 16:15 UTC

A vulnerability was found in Moodle where javaScript injection was possible in some Mustache templates via recursive rendering from contexts. Mustache helper tags that were included in template contexts were not being escaped before that context was injected into another Mustache helper, which could result in script injection in some templates. This affects versions 3.7 to 3.7.1, 3.6 to 3.6.5, 3.5 to 3.5.7 and earlier unsupported versions.

osv:CVE-2019-14827
Complete source record
{
  "id": "368717ec8c652ed188bb60250286fadabaaa3aa065efc727738026f0a0cebf92",
  "url": "https://osv.dev/vulnerability/CVE-2019-14827",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "CVE-2019-14827",
    "summary": "A vulnerability was found in Moodle where javaScript injection was possible in some Mustache templates via recursive rendering from contexts. Mustache helper tags that were included in template contexts were not being escaped before that context was injected into another Mustache helper, which could result in script injection in some templates. This affects versions 3.7 to 3.7.1, 3.6 to 3.6.5, 3.5 to 3.5.7 and earlier unsupported versions.",
    "evidence": "osv:CVE-2019-14827",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2019-14827",
      "aliases": [
        "CVE-2019-14827"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/moodle/moodle",
              "type": "GIT",
              "events": [
                {
                  "introduced": "46574904afd39578fa4146bf1fc5c401ac680aa6"
                },
                {
                  "last_affected": "5725188035223fe8d8cf1c4a7c1af361a43ca6b6"
                },
                {
                  "introduced": "cb628a9a08933c2a9f1eae2f3be70ea5d343b419"
                },
                {
                  "last_affected": "c88d732e399b816b69010c2c6ee7deb2da268681"
                },
                {
                  "introduced": "89457b26d192c06325bb6782b85d1025dafbefe9"
                },
                {
                  "last_affected": "b198428e41b0f2fafe4bb0e6db6e53f5b9eda212"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:moodle:moodle:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "3.5.0"
                      },
                      {
                        "last_affected": "3.5.7"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:moodle:moodle:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "3.6.0"
                      },
                      {
                        "last_affected": "3.6.5"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:moodle:moodle:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "3.7.0"
                      },
                      {
                        "last_affected": "3.7.1"
                      }
                    ],
                    "source": "CPE_RANGE"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v3.7.0",
            "v3.6.5",
            "v3.5.7",
            "v3.7.1",
            "v3.5.6",
            "v3.6.4",
            "v3.5.5",
            "v3.6.3",
            "v3.5.4",
            "v3.6.2",
            "v3.6.0",
            "v3.6.1",
            "v3.5.3",
            "v3.5.2",
            "v3.5.1",
            "v3.5.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2019-14827.json"
          }
        }
      ],
      "modified": "2026-10-24T10:30:54.711394310Z",
      "provider": "osv",
      "references": [
        "https://git.moodle.org/gw?p=moodle.git&a=search&h=HEAD&st=commit&s=MDL-62284",
        "https://moodle.org/mod/forum/discuss.php?d=391030"
      ],
      "provider_metadata": {}
    },
    "related_cves": [
      {
        "value": "CVE-2019-14827",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 438263,
  "published_at": "2021-05-17T16:15:07.51+00:00"
}