How webMAN MOD Implements Its File Manager for PS3 Filesystem Access
webMAN MOD implements its file manager as a unified HTML generator that serves both web and VSH-Menu interfaces, routing all filesystem operations through HTTP endpoints that ultimately invoke the PS3's explore-plugin callbacks to manipulate the XMB.
The webMAN MOD plugin for PlayStation 3 provides a comprehensive file management system capable of browsing local storage, NTFS volumes, and network shares. According to the aldostools/webman-mod source code, the implementation centers on a shared add_list_entry routine that generates directory listings for both the web interface and the on-screen VSH-Menu display. This architecture ensures consistent behavior across all entry points while leveraging the PS3's native cellFsReaddir API and explore-plugin interface for actual filesystem operations.
Architecture: Three Entry Points to the Same Core
webMAN MOD exposes its file manager functionality through three distinct interfaces that converge on the same backend logic:
- Web Interface – Accessible via
http://<PS3_IP>/fm.ps3?<path>, generating HTML directory trees with mount, copy, and install actions - VSH-Menu UI – Activated by pressing START in the VSH-Menu, providing controller-driven navigation with cut, copy, paste, and delete operations
- Explore-Plugin API – Internal XMB integration via
exec_xmb_commandthat performs actions directly from the XMB browser or VSH-Menu selections
All three paths ultimately call the same folder_listing() dispatcher and add_list_entry() HTML builder found in include/file_manager.h.
Web Interface Implementation
When the embedded web server receives a request for /fm.ps3, it forwards the call to folder_listing() (defined at line 6012 in include/www/www_page.h). This function opens the requested directory—whether local, network, or NTFS—and iterates over entries using cellFsReaddir() or NTFS equivalents.
For each directory entry, folder_listing() invokes add_list_entry() (lines 40-120 in include/file_manager.h) to construct a single HTML table row:
- File type classification via
set_file_type()(lines 18-38) assigns CSS classes (ps3,ps2,psx,psp,dvd,rom) based on file extensions - Metadata formatting converts raw sizes to human-readable
B/KB/MB/GBunits and appends optional PARAM.SFO and ICON0 links for game directories (lines 56-99) - Action link generation creates contextual hyperlinks (
/mount.ps3…,/copy.ps3…,/install.ps3…,/view.ps3…) depending on the file type and current view (lines 190-260)
The resulting HTML follows this structure:
<tr><td><a class="ps3" href="/mount.ps3/dev_hdd0/GAMES/ABCD12345">Game Folder</a>
<td>4.2 GB</td><td>01-Jan-2024 12:34</td></tr>
After collecting all rows, the system applies qsort according to the requested sort parameter and concatenates the results into the HTTP response using _concat(&sout, TABLE_ITEM_PREFIX).
VSH-Menu File Manager UI
The VSH-Menu file manager view (triggered from XMB via SELECT + hold) renders a scrollable on-screen file list using draw_frame() (lines 6728-6776 in _Projects_/vsh_menu/main.c). The current directory contents are stored in the global arrays items[] and items_isdir[].
Controller input handling occurs in do_file_manager_action(curpad) starting at line 628 of _Projects_/vsh_menu/main.c. The function maps button combinations to specific filesystem operations:
- Cross Button: Mounts ISOs or PS3_GAME directories, installs PKG files, or opens images/text files by building URLs like
/mount_ps3<url>or/install.ps3<url>and sending them viasend_wm_request() - Square Button: Initiates copy/cut/paste operations by encoding paths with
urlenc()and dispatching/cpy.ps3,/cut.ps3, or/paste.ps3requests - L2 + Square: Deletes files or folders recursively using
del(tempstr, true), which internally callscellFsUnlinkandcellFsRmdir - Triangle: Navigates up one directory level by adjusting the
curdirvariable and reloading the list
All VSH-Menu actions generate HTTP requests to the internal web server, ensuring that the same folder_listing() validation and mount logic (mount_game(), mount_ps_disc_image() at line 5140 in main.c) executes regardless of whether the user interacts via browser or controller.
XMB Integration via Explore Plugin
To synchronize file operations with the PlayStation 3's native interface, webMAN MOD utilizes the explore-plugin API defined in vsh/explore_plugin.h. When a mount or copy command completes, the code invokes:
explore_interface->ExecXMBcommand("open_list nocheck/...", NULL, 0);
The explore_interface pointer is obtained at runtime in include/init/vsh.h (lines 58-66) through the PS3's VSH system. This interface provides callbacks such as DoUnk5 and ExecXMBcommand that instruct the XMB to refresh its view, focus specific segments, or launch mounted discs.
Thus, any /mount.ps3 or /copy.ps3 command processed through the web or VSH-Menu ultimately triggers an explore-plugin callback, ensuring the XMB remains aware of filesystem changes and can launch games immediately after mounting.
NTFS and Network Filesystem Support
The file manager transparently handles non-native filesystems through conditional logic in folder_listing(). When a path begins with /net or references a mounted NTFS volume (/dev_ntfs*), the system activates NTFS helpers defined in include/scan/prepntfs.h (lines 24-28).
The same add_list_entry() routine processes these entries unchanged; only the underlying size and timestamp retrieval switches to NTFS-specific calls (ps3ntfs_*). This abstraction allows users to browse external USB drives with NTFS partitions or network shares via the same HTML interface and controller navigation used for the internal PS3 hard drive.
Summary
- Unified Backend: Both web and VSH-Menu interfaces rely on
add_list_entry()ininclude/file_manager.hto generate directory listings and action links - HTTP Routing: All file operations route through
/fm.ps3,/mount.ps3, and/copy.ps3endpoints handled byfolder_listing()ininclude/www/www_page.h - Controller Mapping: The VSH-Menu maps physical buttons to HTTP requests in
do_file_manager_action()within_Projects_/vsh_menu/main.c - XMB Synchronization: Filesystem changes propagate to the XMB via
explore_interface->ExecXMBcommand()calls throughvsh/explore_plugin.h - Extended Storage: NTFS and network paths integrate transparently via
include/scan/prepntfs.hwithout requiring separate UI code paths
Frequently Asked Questions
How does webMAN MOD read directory contents from the PS3 filesystem?
webMAN MOD uses the standard PlayStation 3 system call cellFsReaddir() to iterate over local directories, as implemented in the folder_listing() function at line 6012 of include/www/www_page.h. For NTFS volumes, it substitutes NTFS-specific helper functions from include/scan/prepntfs.h while maintaining the same iteration pattern.
Can the webMAN MOD file manager delete files recursively?
Yes. When the user presses L2 + Square in the VSH-Menu file manager view, the system calls del(tempstr, true) from _Projects_/vsh_menu/main.c. This function performs recursive deletion by combining cellFsUnlink for files and cellFsRmdir for empty directories, with the boolean parameter enabling recursive traversal.
What is the relationship between the web interface and VSH-Menu file manager?
Both interfaces generate identical HTTP requests to the internal web server. The VSH-Menu constructs URLs like /mount_ps3<encoded_path> and sends them via send_wm_request(), while the web interface generates clickable links to /mount.ps3/<path>. Both requests hit the same folder_listing() dispatcher in include/www/www_page.h, ensuring consistent behavior across input methods.
How does webMAN MOD mount games from the file manager?
Mounting occurs through a chain starting at the user interface (web or VSH-Menu), proceeding through folder_listing(), and culminating in mount_game() or mount_ps_disc_image() in main.c. After loading the disc image or game folder, the system calls explore_interface->ExecXMBcommand() to notify the XMB, making the mounted content appear as a playable disc in the system menu.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →