Repository navigation
Port upstream game fixes: Linux TLS, saves across drives, controllers, alarms - #7
Merged
Merged
Conversation
* Fix NAND moves across mount points * Harden cross-mount NAND move fallback * Preserve directory copy on NAND move cleanup failure * Clarify NAND move cleanup behavior * Use exclusive scratch paths for NAND moves * Copy NAND move directories into reserved destination * Publish NAND move directories without replacement (cherry picked from commit 8346376) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
patchzyy#251) * Fix macOS controller platform, sync player indices, and preserve socket send error - Preserve captured socket send error across diagnostic logging in network_socket.cpp - Use SDL_GetPlatform() instead of hardcoded Windows in controller mapping wizard - Synchronize Aurora and SDL player indices on port assignment and clear in pad.cpp - Auto-assign Player 1 on macOS when unconfigured in input.cpp * fix(input): refine macOS port 0 assignment and persistence logic - Persist port 0 preference for newly connected controller even if already assigned player index 0 - Verify controller has no preference on other ports before assigning to port 0 (cherry picked from commit 85f2501) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
(cherry picked from commit 583e702) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
* Implement real TLS for non-Windows via vendored mbed TLS Windows gets TLS for the guest network HLE's SSL ioctlvs for free from Schannel; every other platform fell into a stub that always returned failure, meaning any HTTPS-based network feature (WFC login, fetching the Retro-WFC payload) silently could not work at all on those platforms regardless of server availability. Vendors mbed TLS 3.6.7 LTS under runtime/third_party/mbedtls (same convention as Crypto++/pugixml - a real source checkout, not a submodule/FetchContent download) and a standard Mozilla CA bundle (runtime/assets/certs/cacert.pem, via curl.se's redistribution) copied next to the built product the same way dsp_coef.bin already is. Verified against real HTTPS servers: a valid certificate completes the handshake and an HTTP round-trip; a known-expired certificate is correctly rejected with a real X509 verification failure, not silently accepted. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Qmdewk7VfVVJTfCVd2WStu * Fix TLS handshake hang and partial-write truncation on non-Windows Add a POSIX socket timeout to match Windows' existing 15s one, plus a deadline on the handshake retry loop itself, so a peer that accepts the TCP connection but never sends TLS data can no longer hang the thread forever. Also fix SslWrite to loop on partial mbedTLS writes instead of returning the first partial count, and add mbedTLS to THIRD-PARTY-NOTICES.md. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * Fetch mbedTLS from a pinned, checksum-verified release instead of vendoring it Replace the committed mbedTLS source tree with a CMake FetchContent download of the official mbedtls-3.6.7 release tarball, verified against its signed SHA-256, matching how aurora-main's own dependencies (SDL, zlib, etc.) are pulled in. Ships the compiled dependency instead of ~280 tracked upstream files. CA bundle packaging and THIRD-PARTY-NOTICES.md coverage are unchanged. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * Limit the mbedTLS dependency to the platforms that use it The FetchContent block ran on every platform, including Windows, whose builds configure with FETCHCONTENT_FULLY_DISCONNECTED=ON against the offline dependency set from Launcher/Prepare-Dependencies.ps1 - which has no mkw_mbedtls_upstream entry, so a clean Windows configure failed. Windows compiles the Schannel path (network_ssl.cpp is `#ifndef _WIN32` for mbed TLS) and never links mbed TLS, so nothing needs preparing there: the fetch, the linkage and the cacert.pem copy are now guarded to non-Windows, while the mkw::mbedtls alias stays defined everywhere so the link lines in PublicProducts.cmake remain platform-independent. Also copy cacert.pem alongside the installed executable in the Linux and macOS publication paths (Launcher/local-build.sh and Launcher/macos/publish-app.command), which already copied the other runtime assets but left the TLS root bundle in the build directory, so published builds could not verify any certificate. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> * Harden mbed TLS socket I/O handling * delete wii socket --------- Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> Co-authored-by: patchzyy <64382339+patchzyy@users.noreply.github.com> (cherry picked from commit b59e035) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
From patchzyy/Wiicompiled 6f14bde (patchzyy#244), runtime and translator parts only: - Keep KD and NCD devices available while networking is off; only IP and SSL need the network. - Run RFLiIsWorking's alarm pump in a private interrupt context so callback register writes don't clobber the caller, and release the alarm recursion guard before rescheduling. - Share one LR continuation dispatch per translated function when it has several continuation calls. The renderer half of that commit is left out: it conflicts with the stereo renderer, and upstream reverted part of it (e409d9f) for stutters. (cherry picked from part of commit 6f14bde) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
The mbed TLS path looks for cacert.pem in the runtime resources folder on Android, the same place as dsp_coef.bin. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F
mitch030504
force-pushed
the
claude/project-thread-ix2nko
branch
from
October 5, 2026 12:58
8ae1cd6 to
cfb9623
Compare
mitch030504
marked this pull request as ready for review
October 5, 2026 13:14
mitch030504
pushed a commit
that referenced
this pull request
Oct 5, 2026
Bootstrap seeding only created missing files, so a WC24 file that had been emptied (nwc24dl.bin, nwc24fl.bin, misc.bin) stayed at zero bytes on every boot. WC24 rejects a zero-length download or friend list and MKW reports that as a save error, which matters now that #7 lets KD open while offline. A file is re-copied only when it is empty and the payload's copy is not, so player data is never replaced. Adapted from nx-mod/wiicompiled-nx d0149e6. That version falls through to copy_file with copy_options::none, which fails on the existing empty file; this one overwrites in that case only. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018NKSMYZU43wUfYtm1sxGsC
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Mitch · project thread
Before: on SteamOS and Android, every SSL session the game opens fails. That includes Retro Rewind's login and GameSpy connections, which the fork reroutes to plaintext port 80: the reroute happens at connect time, but the plaintext handshake, read and write existed only in the Windows code. On Linux the stub returned
SSL_ERR_FAILEDfor every session. A save the game moves from its temp folder to a folder on another drive (for example a Retro Rewind save redirected to the SD card) also fails.After: Linux and Android handle the plaintext Retro sessions and do real TLS for everything else, through mbed TLS 3.6.7 and a bundled Mozilla CA file. Moves across mount points fall back to copying. Several smaller runtime and translator fixes are also included.
How: these are cherry-picks from patchzyy/Wiicompiled since the fork split at 7e6604c, each with
-xso the upstream commit is recorded:platform:change is cosmetic on Linux, becauseSDL_AddGamepadMappingdoesn't check that field.bltlin the PPC lifter.cacert.pemis copied next to the executable, andlocal-build.shpublishes it, so the Steam Frame install carries it. The link-line conflict inPublicProducts.cmakewas resolved so the fork's OpenXR andMKW_PRODUCT_WITHOUT_GAMEbranches are kept. Upstream's native-prebuilt follow-ups (Bundle mbed TLS in Linux native prebuilt patchzyy/Wiicompiled#272, Handle extra Mbed TLS archives patchzyy/Wiicompiled#275) are left out: the Frame build always passes--dawn-package, which can't be combined with a native prebuilt.RFLiIsWorkingpumps alarms in a private interrupt context. LR continuation dispatch is shared. The renderer half is left out because it conflicts with the stereo renderer, and upstream reverted part of it (e409d9f) for stutters.cacert.peminruntime_resources, the folder the TLS code looks in.Validation:
dotnet test translator/Translator.sln -c Release).network_ssl.cpp,network_core.cpp,network_socket.cpp,nand_api.cpp,os_alarm.cpp) compile withclang++ -fsyntax-only, using the mbed TLS 3.6.7 headers.🤖 Generated with Claude Code
https://claude.ai/code/session_011tcyLz63pXjoYEwsFjfg8F