Skip to content

Latest commit

Β 

History

25 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“ Hosting File Manager & ZIP Extractor

🌐 Language: English | Bahasa Indonesia

PHP Version License: MIT Zero Dependencies Security: 100% Clean Zero Backdoor Release PRs Welcome

Hosting File Manager is a modern, lightweight, standalone web file manager built with pure Native PHP. It is specifically designed to manage web hosting files and directories (public_html, subdomains, VPS directories, etc.) directly from your browser without any dependency on cPanel API, MySQL database, Composer, or external frameworks.

Featuring an authentic cPanel-inspired interface, robust ZIP extraction & compression, an in-browser code editor, a Recycle Bin, a real-time Activity Log Viewer, persistent 30-day sessions, and an administrative settings UI.

Hosting File Manager Dark Mode

Important

πŸ›‘οΈ Security & Transparency Guarantee: 100% Clean Code (No Backdoors / No Telemetry)

Given the prevalence of malicious PHP scripts (web shells / credential stealers) on the web, we provide complete, verifiable transparency:

  • ❌ NOT a Backdoor or Web Shell: No hidden payloads, zero code obfuscation, and absolutely no dangerous system execution functions such as eval(), base64_decode(), shell_exec(), or system().
  • ❌ NO Data or cPanel Credential Theft: This application performs zero outgoing network calls (no outgoing HTTP/cURL callbacks) and contains no telemetry. All your files and credentials remain 100% on your own server. It never requests, accesses, or touches your server's cPanel/WHM root credentials.
  • βœ… 100% Open Source & Auditable: Written in clean, readable native PHP. Anyone can inspect and audit every line of code before deploying it to production.

πŸ” Quick Self-Audit Command (Verify for Yourself):

# Verify there are no dangerous execution functions across the codebase:
grep -rnE "eval\(|shell_exec\(|system\(|passthru\(|base64_decode\(" app/ index.php
# Result: 0 matches found (100% Clean & Safe)

🎯 What Is This For? (Use Cases & Problem Solved)

Many developers ask: "My hosting already has a default cPanel File Manager, why should I use this?"

Here are the real-world problems and scenarios solved by Hosting File Manager:

  1. πŸ‘₯ Secure Client / Team File Access (Without Sharing Master cPanel Credentials)
    If you are a freelancer or agency, clients or junior team members often need to upload or tweak website files. Giving them master cPanel access is dangerous because they might accidentally delete MySQL databases, alter DNS records, or compromise email accounts. With this tool, you can deploy it to a dedicated subdomain (e.g., files.clientdomain.com) with isolated access restricted only to that website's directory.

  2. ⚑ Lightweight & Fast Alternative When cPanel Is Sluggish
    Default cPanel File Managers can feel heavy, slow to load, or frequently trigger annoying session timeouts while you are working. Hosting File Manager is built with 100% Native PHP without a database, making it snappy, instant to load, and equipped with a 30-day persistent session.

  3. πŸ–₯️ Web File Manager for VPS / Servers Without a Control Panel
    If you manage a VPS (Ubuntu, Debian, AlmaLinux) running a plain LEMP/LAMP stack (Nginx/Apache) without a paid control panel like cPanel or Plesk, managing files solely via terminal SSH and SFTP can be tedious. This tool gives you a full-featured, modern web GUI explorer out of the box.

  4. πŸ” Productivity Features Missing in Stock cPanel

    • Find in Files: Recursively search text strings or code snippets across dozens of files simultaneously with full Regex support, and jump directly to the matched line in the editor in 1 click.
    • Recycle Bin (Trash): Deleted files are not immediately lost forever; they go to Trash and can be restored back to their original paths with a single click.
    • Activity Audit Log: Transparent real-time record of who did what (uploads, renames, edits, extractions, deletions).
    • Mobile Touch Friendly: Responsive grid cards and haptic long-press context menus for easy mobile troubleshooting.
  5. πŸ†˜ Emergency Recovery Access When cPanel Is Down or Ports Are Blocked
    When your cPanel dashboard is experiencing issues, license errors, or port 2083/2082 is blocked by corporate or campus firewalls, you can still manage your files over standard HTTP/HTTPS ports (80/443).


✨ Key Features

  • πŸ–₯️ Modern cPanel-Style Interface β€” Responsive, clean dark/light themes, crisp SVG icons.
  • πŸŒ“ Dark / Light Theme Toggle β€” 1-click switch, automatically saved in localStorage.
  • πŸ“Š Disk Usage / Quota Meter β€” Real-time visual disk quota indicator (Green / Orange / Red).
  • ⚑ Zero Dependencies β€” 100% Native PHP. No Composer, Node.js, or database required.
  • πŸ“¦ ZIP Extractor & Compressor β€” Anti-Zip Slip security, conflict resolution (Overwrite / Skip / Rename).
  • πŸ—‘οΈ Recycle Bin / Trash β€” Deletions are sent to Trash first. 1-click restore, permanent delete, empty trash. Real-time badge counter.
  • πŸ“œ Activity Log Viewer β€” Detailed audit log: upload, rename, edit, trash, extract, etc. Filter by action & text with color-coded status badges.
  • πŸ” Find in Files β€” Fast recursive text/code search across files, Regex support, 1-click jump to editor.
  • 🌈 In-Browser Code Editor β€” Syntax highlighting for PHP, JS, HTML, CSS, SQL, Bash. Fullscreen, Word Wrap, Ctrl+S save.
  • ⌨️ Desktop Keyboard Shortcuts β€” F2 Rename, Del Delete, Ctrl+A Select All, Ctrl+F Search, Ctrl+Shift+F Find in Files.
  • πŸ“± Responsive Mobile Experience β€” Adaptive grid tiles, long-press context menus (haptic feedback), scrollable toolbars.
  • πŸ“‘ 1-Click Duplicate β€” Instantly duplicate files or folders within the same directory.
  • πŸš€ Large File Uploads (> 100 MB) β€” Multi-file uploads with real-time progress bars.
  • πŸ”’ Server-Grade Security β€” Path traversal protection, brute-force rate limiter, CSRF token validation, and audit logs.
  • βš™οΈ Web Admin Settings UI β€” Modify username, password, allowed root directory, upload limit, and session timeout from the browser.
  • 🌐 Smart cPanel Directory Detection β€” Automatically detects parent directories when deployed on a subdomain.

πŸ“‹ Server Requirements

Component Minimum Requirement
PHP 7.4 / 8.0 / 8.1 / 8.2 / 8.3+
PHP Extensions ext-zip, ext-session, ext-json
Web Server Apache / LiteSpeed / Nginx / IIS
Database ❌ Not required (Zero Database)

πŸš€ Quick Start Guide

⚠️ IMPORTANT β€” Do NOT place this in an existing website directory!

Hosting File Manager uses index.php as its main entry point. If you extract it directly into public_html/ where an existing index.php (such as WordPress, Laravel, etc.) already lives, your existing website file will be overwritten and damaged.

βœ… Always deploy into a dedicated subfolder or a separate subdomain as illustrated below.


πŸ“ Option A: Subfolder on Hosting (Easiest)

public_html/
β”œβ”€β”€ index.php         ← Your main website (UNTOUCHED)
β”œβ”€β”€ wp-content/       ← e.g. WordPress / Laravel
└── filemanager/      ← βœ… Extract Hosting File Manager HERE
    β”œβ”€β”€ index.php
    β”œβ”€β”€ config.php
    β”œβ”€β”€ app/
    β”œβ”€β”€ assets/
    └── storage/

Steps:

  1. Download hosting-file-manager.zip from the Releases tab.
  2. Upload it to your hosting via FTP or cPanel File Manager.
  3. Extract it into public_html/filemanager/.
  4. Open your browser: https://yourdomain.com/filemanager/.
  5. Complete the Setup Wizard to create your administrator username and password.

πŸ’‘ Security tip: Use an unguessable folder name, such as /manage-X9K/ or /cpanel-tools/.


🌐 Option B: Dedicated Subdomain (Recommended & Most Professional)

yourdomain.com/           ← Your main website (UNTOUCHED)
manager.yourdomain.com/   ← βœ… Dedicated subdomain for File Manager

Steps in cPanel:

  1. In cPanel, navigate to Subdomains β†’ create a subdomain, e.g., manager.yourdomain.com.
  2. Set the Document Root to: /home/username/manager.yourdomain.com/.
  3. Upload and extract hosting-file-manager.zip into that document root folder.
  4. Visit: https://manager.yourdomain.com/.
  5. Complete the Setup Wizard.

Subdomain Advantages:

  • βœ… Zero risk of file conflicts with other projects
  • βœ… Independent SSL certificate
  • βœ… Easy to disable or password-protect anytime
  • βœ… Clean, memorable URL

πŸ–₯️ Option C: Localhost XAMPP / Laragon (Development)

C:\xampp\htdocs\
β”œβ”€β”€ myproject\        ← Your project
└── filemanager\      ← βœ… Extract here

Access: http://localhost/filemanager/


⚑ Option D: Git Clone (Developer)

git clone https://github.com/kazuhamoe/Hosting-File-Manager.git filemanager
# Access: http://localhost/filemanager/

πŸ”‘ Authentication & Security Architecture

Hosting File Manager features an automated First-Time Setup Wizard:

  • On initial launch, the user is presented with the Administrator Setup form to create their credentials.
  • Passwords are encrypted with Bcrypt (PASSWORD_BCRYPT) and stored in storage/credentials.json.
  • Anti Re-Setup Lock: Permanently locks setup mode once credentials are established.
  • Brute-Force Rate Limiter: Protects against automated dictionary attacks.
  • CSRF Tokens: Enforced across all mutating operations (delete, upload, edit, rename, move).

βš™οΈ Configuration (config.php)

define('ALLOWED_ROOT', dirname(__DIR__));    // Boundary directory accessible by users
define('SESSION_TIMEOUT', 2592000);          // Session lifetime (seconds) β€” default 30 days
define('MAX_UPLOAD_SIZE', 200 * 1024 * 1024); // Maximum upload size (200 MB)
define('SHOW_DISK_USAGE', false);            // Display disk quota meter
define('AUTH_PASS_HASH', '');                // Empty = enable Setup Wizard

πŸ’‘ Settings modified via the web UI are saved in storage/settings.json and persist across updates.


πŸ“‚ Directory Structure

β”œβ”€β”€ app/                  # Core PHP backend (Auth, FileManager, Security, ZipManager, Logger)
β”œβ”€β”€ assets/
β”‚   β”œβ”€β”€ css/style.css     # Responsive styles & themes
β”‚   β”œβ”€β”€ js/app.js         # Frontend application engine
β”‚   └── icons/            # SVG, ICO, and PNG favicons
β”œβ”€β”€ storage/
β”‚   β”œβ”€β”€ logs/audit.log    # Activity audit log
β”‚   β”œβ”€β”€ trash/            # πŸ—‘οΈ Recycle Bin storage
β”‚   └── temp/             # Temporary files
β”œβ”€β”€ index.php             # Application entry point
β”œβ”€β”€ config.php            # Primary configuration
β”œβ”€β”€ favicon.ico           # Browser fallback icon
└── updater.php           # 1-click update script

πŸ“¦ Release History (Changelog)

πŸŽ‰ v2.0.0 β€” September 12, 2026

  • βœ… Recycle Bin / Trash: Soft delete, 1-click restore, badge counter, empty trash.
  • βœ… Activity Log Viewer: Audit logs, text & action filters, color status badges, clear logs.
  • βœ… Enhanced Mobile UI/UX: Grid cards, long-press haptic context menus, scrollable toolbars.
  • βœ… Find in Files: Recursive text/code search across files, Regex support, jump to editor.
  • βœ… Keyboard Shortcuts: F2, Del, Ctrl+A, Ctrl+F, Ctrl+Shift+F, Esc.
  • βœ… Config Settings Manager: Edit runtime settings directly from the web UI.
  • βœ… Grid View Mode: Toggleable card/tile view alongside standard table view.
  • βœ… Automatic 0777 Permissions: Automatic permission setting on upload and extraction.
  • βœ… 75 automated test assertions passed.

v1.0.0 β€” Initial Release

  • Core file management: upload, download, rename, delete, ZIP extraction/compression, code editor, dark mode.

🀝 Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'feat: add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“„ License

Distributed under the MIT License. Free for personal and commercial use.

About

100% Clean, Open-Source & Standalone PHP Web File Manager. Zero backdoors, zero telemetry, zero database. Transparent & secure cPanel alternative.

Topics

Resources

Contributing

Security policy

Stars

11 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages