{"id":"CVE-2026-25525","aliases":["CVE-2026-25525","GHSA-6vqf-6fhm-7rc6"],"related":[],"kind":"vulnerability","state":"published","title":"OpenMage LTS has Path Traversal Filter Bypass in Dataflow Module","summary":"Magento Long Term Support (LTS) is an unofficial, community-driven project provides an alternative to the Magento Community Edition e-commerce platform with a high level of backward compatibility. Prior to version 20.17.0, the Dataflow module in OpenMage LTS uses a weak blacklist filter (`str_replace('../', '', $input)`) to prevent path traversal attacks. This filter can be bypassed using patterns like `..././` or `....//`, which after the replacement still result in `../`. An authenticated administrator can exploit this to read arbitrary files from the server filesystem. Version 20.17.0 patches the issue.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Magento Long Term Support (LTS) is an unofficial, community-driven project provides an alternative to the Magento Community Edition e-commerce platform with a high level of backward compatibility. Prior to version 20.17.0, the Dataflow module in OpenMage LTS uses a weak blacklist filter (`str_replace('../', '', $input)`) to prevent path traversal attacks. This filter can be bypassed using patterns like `..././` or `....//`, which after the replacement still result in `../`. An authenticated administrator can exploit this to read arbitrary files from the server filesystem. Version 20.17.0 patches the issue.","source":"cvelist"},{"lang":"en","text":"The Dataflow module in OpenMage LTS uses a weak blacklist filter (`str_replace('../', '', $input)`) to prevent path traversal attacks. This filter can be bypassed using patterns like `..././` or `....//`, which after the replacement still result in `../`. An authenticated administrator can exploit this to read arbitrary files from the server filesystem.\n\n\n| Metric                   | Value     | Justification                         |\n| ------------------------ | --------- | ------------------------------------- |\n| Attack Vector (AV)       | Network   | Exploitable via admin panel           |\n| Attack Complexity (AC)   | Low       | Simple bypass pattern                 |\n| Privileges Required (PR) | High      | Requires admin authentication         |\n| User Interaction (UI)    | None      | No additional user interaction needed |\n| Scope (S)                | Unchanged | Impacts the vulnerable component      |\n| Confidentiality (C)      | High      | Can read sensitive system files       |\n| Integrity (I)            | None      | Read-only vulnerability               |\n| Availability (A)         | None      | No impact on availability             |\n\n## Affected Products\n\n- OpenMage LTS versions < 20.16.1\n- All versions derived from Magento 1.x with these code paths\n\n## Affected Files\n\n| File                                                         | Line | Vulnerable Code                          |\n| ------------------------------------------------------------ | ---- | ---------------------------------------- |\n| `app/code/core/Mage/Dataflow/Model/Convert/Parser/Csv.php`   | 67   | `str_replace('../', '', urldecode(...))` |\n| `app/code/core/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php` | 63   | `str_replace('../', '', urldecode(...))` |\n\n## Vulnerability Details\n\nThe Dataflow module allows administrators to import data from files. The `files` parameter specifies which file to import from the `var/import/` directory. To prevent path traversal, the code uses `str_replace()` to remove `../` sequences:\n\n```php\n$file = Mage::app()->getConfig()->getTempVarDir() . '/import/'\n    . str_replace('../', '', urldecode(Mage::app()->getRequest()->getParam('files')));\n```\n\nHowever, `str_replace()` only performs a single pass, making it trivially bypassable:\n\n### Bypass Examples\n\n| Input                          | After `str_replace('../', '', ...)` | Result    |\n| ------------------------------ | ----------------------------------- | --------- |\n| `..././`                       | `../`                               | Bypass    |\n| `....//`                       | `../`                               | Bypass    |\n| `..././..././..././etc/passwd` | `../../../etc/passwd`               | File read |\n\n### Attack Scenario\n\n1. Attacker gains admin access (via compromised credentials, social engineering, etc.)\n2. Navigate to System > Import/Export > Dataflow Profiles\n3. Create or modify an import profile\n4. Set the `files` parameter to: `..././..././..././etc/passwd`\n5. Run the profile to read the contents of `/etc/passwd`\n\n### Proof of Concept\n\n```\n# Request to Dataflow with bypass pattern\nGET /admin/system_convert_gui/run/id/1/?files=..././..././..././etc/passwd\n\n# The str_replace removes '../' leaving:\n# ..././..././..././etc/passwd -> ../../../etc/passwd\n\n# Final path resolves to:\n# /var/www/html/var/import/../../../etc/passwd -> /etc/passwd\n```\n\n## Remediation\n\nReplace the weak `str_replace()` filter with `basename()` to extract only the filename:\n\n```php\n// Before (vulnerable)\n$file = Mage::app()->getConfig()->getTempVarDir() . '/import/'\n    . str_replace('../', '', urldecode(Mage::app()->getRequest()->getParam('files')));\n\n// After (fixed)\n$file = Mage::app()->getConfig()->getTempVarDir() . '/import/'\n    . basename(urldecode(Mage::app()->getRequest()->getParam('files')));\n```\n\nUsing `basename()` ensures only the filename portion is used, completely preventing any path traversal regardless of the input pattern.\n\n## Workarounds\n\nIf immediate upgrade is not possible:\n\n1. **Restrict admin access**: Limit Dataflow access to trusted administrators only\n2. **Disable Dataflow**: If not in use, disable the Dataflow module entirely\n3. **Web Application Firewall**: Block requests containing path traversal patterns\n4. **File permissions**: Ensure the web server user has minimal filesystem permissions\n5. **Monitor admin activity**: Alert on suspicious Dataflow profile execution\n\n## Impact\n\nAn attacker with admin access can read sensitive files including:\n\n- `/etc/passwd` - System user information\n- `app/etc/local.xml` - Database credentials\n- `.env` files - Environment secrets\n- Log files - Potentially sensitive application data\n- Configuration files - Server and application configuration\n\n## Credit\n\nThis vulnerability was discovered and responsibly disclosed by [blackhat2013](https://hackerone.com/blackhat2013) through HackerOne.\n\n## Timeline\n\n- **2025-12-31**: Vulnerability reported via HackerOne\n- **2026-01-21**: Fix developed and tested","format":"markdown","source":"ghsa"},{"lang":"es","text":"Magento Long Term Support (LTS) es un proyecto no oficial, impulsado por la comunidad, que proporciona una alternativa a la plataforma de comercio electrónico Magento Community Edition con un alto nivel de compatibilidad con versiones anteriores. Antes de la versión 20.17.0, el módulo Dataflow en OpenMage LTS utiliza un filtro de lista negra débil (’str_replace(’.. / ’, ’’, $input)’) para prevenir ataques de salto de ruta. Este filtro puede ser eludido utilizando patrones como ’... / ./’ o ’.... / /’, que después del reemplazo aún resultan en ’.. / ’. Un administrador autenticado puede explotar esto para leer archivos arbitrarios del sistema de archivos del servidor. La versión 20.17.0 corrige el problema.","source":"nvd"}],"published":"2026-04-20T16:14:14.366Z","modified":"2026-10-26T21:10:00.170Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"rating":"MEDIUM"}],"cwes":["CWE-22","CWE-184"],"affected":[{"ranges":[{"version":"< 20.17.0","status":"affected"}],"vendor":"OpenMage","product":"magento-lts","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"20.17.0"}],"ecosystem":"Packagist","package":"openmage/magento-lts","purl":"pkg:composer/openmage/magento-lts","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"20.17.0"}],"vendor":"openmage","product":"magento","cpe":"cpe:2.3:a:openmage:magento:*:*:*:*:lts:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/OpenMage/magento-lts/security/advisories/GHSA-6vqf-6fhm-7rc6","tags":["exploit","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-25525","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/OpenMage/magento-lts/pull/5445","tags":["web"],"sources":["ghsa"]},{"url":"https://hackerone.com/reports/3482926","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/OpenMage/magento-lts","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/OpenMage/magento-lts/releases/tag/v20.17.0","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"partial","date":"2026-04-21T13:27:13.684Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-25525","url":"https://www.cve.org/CVERecord?id=CVE-2026-25525","licence":"CVE Terms of Use","modified":"2026-04-21T13:27:55.707Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-6vqf-6fhm-7rc6","url":"https://github.com/advisories/GHSA-6vqf-6fhm-7rc6","licence":"CC-BY-4.0","modified":"2026-04-21T14:56:36.782Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-25525","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-25525","licence":"Public domain","modified":"2026-10-26T21:10:00.170Z"}],"updatedAt":"2026-11-25T22:59:19.047Z","epss":{"score":0.00521,"percentile":0.45748,"date":"2026-12-01T12:00:22.000Z"}}