Skip to content
Heist/ feed
Back to feed
Medium

Path traversal of collection names during file system lookup

Type: advisorySources: OSV

Kirby is an open-source content management system. A vulnerability in versions prior to 3.9.8.3, 3.10.1.2, and 4.7.1 affects all Kirby sites that use the `collection()` helper or `$kirby->collection()` method with a dynamic collection name (such as a collection name that depends on request or user data). Sites that only use fixed calls to the `collection()` helper/`$kirby->collection()` method (i.e. calls with a simple string for the collection name) are *not* affected. A missing path traversal check allowed attackers to navigate and access all files on the server that were accessible to the PHP process, including files outside of the collections root or even outside of the Kirby installation. PHP code within such files was executed. Such attacks first require an attack vector in the site code that is caused by dynamic collection names, such as `collection('tags-' . get('tags'))`. It generally also requires knowledge of the site structure and the server's file system by the attacker, although it can be possible to find vulnerable setups through automated methods such as fuzzing. In a vulnerable setup, this could cause damage to the confidentiality and integrity of the server. The problem has been patched in Kirby 3.9.8.3, Kirby 3.10.1.2, and Kirby 4.7.1. In all of the mentioned releases, the maintainers of Kirby have added a check for the collection path that ensures that the resulting path is contained within the configured collections root. Collection paths that point outsi

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2025-31493
Confirmed fixed CVEs
Not specified
Updated in this feed
4 Nov 2026, 23:53 UTC · Revision 1

Source evidence

Path traversal of collection names during file system lookup

core-osv · Original source

Published 13 May 2025, 15:24 UTC

Kirby is an open-source content management system. A vulnerability in versions prior to 3.9.8.3, 3.10.1.2, and 4.7.1 affects all Kirby sites that use the `collection()` helper or `$kirby->collection()` method with a dynamic collection name (such as a collection name that depends on request or user data). Sites that only use fixed calls to the `collection()` helper/`$kirby->collection()` method (i.e. calls with a simple string for the collection name) are *not* affected. A missing path traversal check allowed attackers to navigate and access all files on the server that were accessible to the PHP process, including files outside of the collections root or even outside of the Kirby installation. PHP code within such files was executed. Such attacks first require an attack vector in the site code that is caused by dynamic collection names, such as `collection('tags-' . get('tags'))`. It generally also requires knowledge of the site structure and the server's file system by the attacker, although it can be possible to find vulnerable setups through automated methods such as fuzzing. In a vulnerable setup, this could cause damage to the confidentiality and integrity of the server. The problem has been patched in Kirby 3.9.8.3, Kirby 3.10.1.2, and Kirby 4.7.1. In all of the mentioned releases, the maintainers of Kirby have added a check for the collection path that ensures that the resulting path is contained within the configured collections root. Collection paths that point outsi

osv:CVE-2025-31493
Complete source record
{
  "id": "f8ce5793d00cd642d51a046fb581413c7aa5bf96731d0f954dfb65b9d74d7b5f",
  "url": "https://osv.dev/vulnerability/CVE-2025-31493",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Path traversal of collection names during file system lookup",
    "summary": "Kirby is an open-source content management system. A vulnerability in versions prior to 3.9.8.3, 3.10.1.2, and 4.7.1 affects all Kirby sites that use the `collection()` helper or `$kirby->collection()` method with a dynamic collection name (such as a collection name that depends on request or user data). Sites that only use fixed calls to the `collection()` helper/`$kirby->collection()` method (i.e. calls with a simple string for the collection name) are *not* affected. A missing path traversal check allowed attackers to navigate and access all files on the server that were accessible to the PHP process, including files outside of the collections root or even outside of the Kirby installation. PHP code within such files was executed. Such attacks first require an attack vector in the site code that is caused by dynamic collection names, such as `collection('tags-' . get('tags'))`. It generally also requires knowledge of the site structure and the server's file system by the attacker, although it can be possible to find vulnerable setups through automated methods such as fuzzing. In a vulnerable setup, this could cause damage to the confidentiality and integrity of the server. The problem has been patched in Kirby 3.9.8.3, Kirby 3.10.1.2, and Kirby 4.7.1. In all of the mentioned releases, the maintainers of Kirby have added a check for the collection path that ensures that the resulting path is contained within the configured collections root. Collection paths that point outsi",
    "evidence": "osv:CVE-2025-31493",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2025-31493",
      "aliases": [
        "CVE-2025-31493",
        "GHSA-x275-h9j4-7p4h"
      ],
      "metrics": [
        {
          "type": "CVSS_V4",
          "score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/getkirby/kirby",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "4bbb48998cbe20dbe08b9b15aa0df5a898402959"
                },
                {
                  "introduced": "d2e98d7bc032d3a7d6dc0687de7d0b88140e8497"
                },
                {
                  "fixed": "dba5ea8ea7fd468190a401cc37d6032ec717cac8"
                },
                {
                  "introduced": "40eae8e8a4e1705412c64de63984376eeaa8b259"
                },
                {
                  "fixed": "053f21f45a53b96ab623fba4345e129388a983cb"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:getkirby:kirby:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "3.9.8.3"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:getkirby:kirby:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "3.10.0"
                      },
                      {
                        "fixed": "3.10.1.2"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:getkirby:kirby:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "4.0.0"
                      },
                      {
                        "fixed": "4.7.1"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "dba5ea8ea7fd468190a401cc37d6032ec717cac8"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "3.10.1.2"
                  },
                  {
                    "range": [
                      {
                        "fixed": "4bbb48998cbe20dbe08b9b15aa0df5a898402959"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "3.9.8.3"
                  },
                  {
                    "range": [
                      {
                        "fixed": "053f21f45a53b96ab623fba4345e129388a983cb"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "4.7.1"
                  }
                ]
              }
            }
          ],
          "versions": [
            "4.7.0",
            "3.9.8.2",
            "3.10.1.1",
            "4.6.1",
            "4.6.0",
            "4.5.0",
            "4.4.1",
            "4.4.0",
            "4.3.1",
            "4.3.0",
            "3.10.1",
            "3.9.8.1",
            "3.10.0.1",
            "4.2.0",
            "4.1.2",
            "4.1.1",
            "4.1.0",
            "3.9.8",
            "3.10.0",
            "4.0.3",
            "4.0.2",
            "4.0.1",
            "4.0.0",
            "3.9.7",
            "3.9.6.1",
            "3.9.6",
            "3.8.4",
            "3.9.6-rc.1",
            "3.9.5",
            "3.9.4",
            "3.9.3",
            "3.9.2",
            "3.9.1",
            "3.9.0",
            "3.8.3",
            "3.8.2",
            "3.8.1.1",
            "3.8.1",
            "3.8.0",
            "3.7.5",
            "3.7.4",
            "3.7.3",
            "3.6.6",
            "3.7.4-rc.1",
            "3.5.7.1",
            "3.7.2.1",
            "3.7.2",
            "3.7.1",
            "3.7.0.2",
            "3.7.0.1",
            "3.7.0",
            "3.6.5",
            "3.6.4",
            "3.6.3.1",
            "3.6.3",
            "3.6.2",
            "3.6.2-rc.3",
            "3.6.2-rc.2",
            "3.6.2-rc.1",
            "3.6.1.1",
            "3.6.0",
            "3.5.7",
            "3.5.6",
            "3.5.5",
            "3.5.4",
            "3.5.3.1",
            "3.5.3",
            "3.5.2",
            "3.5.1",
            "3.5.1-rc.1",
            "3.5.0",
            "3.5.0-rc.7",
            "3.5.0-rc.6",
            "3.5.0-rc.5",
            "3.5.0-rc.4",
            "3.5.0-rc.3",
            "3.5.0-rc.2",
            "3.5.0-rc.1",
            "3.4.2",
            "3.4.1",
            "3.4.0",
            "3.3.6",
            "3.3.5",
            "3.3.4",
            "3.3.3",
            "3.3.2",
            "3.3.1",
            "3.3.0",
            "3.2.5",
            "3.2.5-rc.2",
            "3.2.5-rc.1",
            "3.2.3-rc.1",
            "3.2.2",
            "3.2.1",
            "3.2.1-rc.1",
            "3.2.0",
            "3.2.0-rc.4",
            "3.2.0-rc.3",
            "3.2.0-rc.2",
            "3.2.0-rc.1",
            "3.1.4",
            "3.1.4-rc.1",
            "3.1.3",
            "3.1.3-rc.1",
            "3.1.2",
            "3.1.2-rc.1",
            "3.1.1",
            "3.1.0",
            "3.1.0-rc.1",
            "3.0.3",
            "3.0.3-rc.3",
            "3.0.3-rc.2",
            "3.0.3-rc.1",
            "3.0.2",
            "3.0.2-rc.1",
            "3.0.1",
            "3.0.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-31493.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:40.358359048Z",
      "provider": "osv",
      "references": [
        "https://github.com/getkirby/kirby/releases/tag/3.10.1.2",
        "https://github.com/getkirby/kirby/releases/tag/3.9.8.3",
        "https://github.com/getkirby/kirby/releases/tag/4.7.1",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/31xxx/CVE-2025-31493.json",
        "https://github.com/getkirby/kirby/security/advisories/GHSA-x275-h9j4-7p4h",
        "https://nvd.nist.gov/vuln/detail/CVE-2025-31493"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-22",
          "CWE-23"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/31xxx/CVE-2025-31493.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2025-31493",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 508165,
  "published_at": "2025-05-13T15:24:40.178+00:00"
}