Skip to content

feat(tools): inspect PS5 USB copies without modifying source data - #3

Open
joedeangelis533-bot wants to merge 1 commit into
review/usb-copy-inspector-base-20261025from
feat/usb-copy-inspector-20261025
Open

joedeangelis533-bot wants to merge 1 commit into
review/usb-copy-inspector-base-20261025from
feat/usb-copy-inspector-20261025

Conversation

@joedeangelis533-bot

Copy link
Copy Markdown
Owner

What

Add a dependency-free, read-only preflight inspector for a readable game folder, console backup file or explicitly selected block device. It identifies ELF/SELF and selected container/storage signatures, checks limited ELF structure, inventories standard module directories and declared dependencies, and reports observed blockers separately from unknowns. It writes reports only to stdout and never extracts, stages, converts, mounts, decrypts or executes source content.

Image/archive/device support is header-only; the inspector does not traverse their filesystems or establish decryption status. Header success does not establish complete assets, full relinker acceptance or game playability. No retail game files were accessible or examined.

Related upstream #9650 handles staging/conversion/import audits of an extracted dump. This preflight tool does not require a relinker or built runtime. Its CMake registration is placed separately to avoid the original insertion conflict. This fork draft is a review venue; upstream shared-file comparisons and any remaining overlaps are documented below.

Tested

Windows 11 Pro 26300, Python 3.12, WinLibs GCC 15.2 UCRT, Release relinker-only build. The 35-test inspector suite passes (34 passed, one symlink-creation test skipped because the account lacks the required Windows privilege). Tests cover unchanged input hashes/mtime, read-only open flags, mocked raw-device reads, malformed/oversized inputs, read/depth/entry limits, module dependency chains, ambiguous layouts, path replacement and conservative unknowns.

A real 1 TB Seagate USB SSD was identified by model, size, USB bus and non-system/non-boot status, then rechecked before an administrator read. The inspector read exactly 8192 bytes, found no recognized header signature and returned incomplete; Windows reported RAW with no mounted filesystem. No device writes, formatting, initialization or filesystem mounting were performed. This validates raw header I/O, not PS5 filesystem parsing or content decryption. The device report and header bytes are not included in this PR.

All five focused CTest checks pass: inspect_ps5_copy, unwrap_self, import_audit, test_registration and test_script_registration. Existing hard-link tests require an unsandboxed temporary directory on this host. Native relinker builds successfully. A separate smoke test uses the project's existing synthetic relinker ELF fixture; source hashes and mtime remain unchanged after inspection, and a separate conversion of the fixture with relinker --windows --registry succeeds. No game-boot, graphics, performance or firmware-support claim.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

Review snapshot: upstream base 732ab06f41772c1d805cf58193d1682616ee88d8, inspector head 2e6362b7ca146b9aa64d02a8f253a4cd474a58de.

Upstream overlap check (shared files of already conflicting pull requests still require review):

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 674 CMakeLists.txt
PR 1835 CMakeLists.txt
PR 3786 CMakeLists.txt
docs/user/USAGE.md
PR 5021 CMakeLists.txt
docs/user/USAGE.md
PR 5925 docs/user/USAGE.md
PR 6171 docs/user/USAGE.md
PR 6924 docs/user/USAGE.md
PR 7201 CMakeLists.txt
PR 7642 docs/user/USAGE.md
PR 8161 CMakeLists.txt
PR 9345 docs/user/USAGE.md
PR 9508 CMakeLists.txt
docs/user/USAGE.md
PR 10193 docs/user/USAGE.md

@joedeangelis533-bot
joedeangelis533-bot marked this pull request as ready for review October 26, 2026 01:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant