CVE-2021-44965

7.5 HIGH

📋 TL;DR

This directory traversal vulnerability in PHPGURUKUL Employee Record Management System 1.2 allows attackers to access sensitive files outside the intended directory structure via the /admin/includes/ path. Attackers can retrieve and download confidential information from the server. Organizations using this specific version of the software are affected.

💻 Affected Systems

Products:
  • PHPGURUKUL Employee Record Management System
Versions: Version 1.2
Operating Systems: Any OS running PHP web server
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability exists in the default installation. Requires PHP environment with web server access to /admin/includes/ directory.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete server compromise through retrieval of configuration files containing database credentials, followed by database access and potential lateral movement.

🟠

Likely Case

Exfiltration of sensitive employee records, configuration files, and other confidential data stored on the server.

🟢

If Mitigated

Limited information disclosure if proper file permissions and web server configurations restrict access to sensitive directories.

🌐 Internet-Facing: HIGH - Web applications exposed to the internet are directly accessible to attackers without authentication requirements.
🏢 Internal Only: MEDIUM - Internal attackers or compromised internal systems could exploit this vulnerability to access sensitive data.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Directory traversal attacks are well-understood and easy to execute. Public GitHub repositories contain demonstration of the vulnerability.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Unknown

Vendor Advisory: No official vendor advisory found

Restart Required: No

Instructions:

1. Check vendor website for updated version. 2. If no patch available, implement workarounds. 3. Consider migrating to alternative software if vendor is unresponsive.

🔧 Temporary Workarounds

Web Server Directory Restriction

all

Configure web server to deny direct access to /admin/includes/ directory

# Apache: Add to .htaccess in admin/includes/
<Files *>
Order Allow,Deny
Deny from all
</Files>
# Nginx: Add to server block
location /admin/includes/ {
    deny all;
    return 403;
}

Input Validation in PHP

all

Add path traversal validation to PHP scripts accessing files

// Add to PHP scripts that handle file operations
$filename = basename($_GET['file']);
$path = '/admin/includes/' . $filename;
if (strpos(realpath($path), '/admin/includes/') !== 0) {
    die('Invalid file path');
}

🧯 If You Can't Patch

  • Implement strict network segmentation to isolate the vulnerable system from sensitive data stores.
  • Deploy web application firewall (WAF) with directory traversal protection rules.

🔍 How to Verify

Check if Vulnerable:

Attempt to access files outside the intended directory using traversal sequences like ../../../../etc/passwd via /admin/includes/ endpoint.

Check Version:

Check version.php or similar configuration files in the application root directory

Verify Fix Applied:

Test that directory traversal attempts return error messages or are blocked, and that legitimate file access within /admin/includes/ still functions.

📡 Detection & Monitoring

Log Indicators:

  • Multiple 403/404 errors for traversal patterns in /admin/includes/ access logs
  • Unusual file access patterns from single IP addresses

Network Indicators:

  • HTTP requests containing ../ sequences targeting /admin/includes/ paths
  • Unusual outbound data transfers following traversal attempts

SIEM Query:

source="web_access.log" AND (uri="/admin/includes/*" AND (uri="*../*" OR uri="*..\\*"))

🔗 References

📤 Share & Export