Skip to content

Fix cross-platform injection and launcher compatibility - #110

Open
mohui666 wants to merge 1 commit into
NeighTools:masterfrom
mohui666:fix/open-issues-compatibility
Open

Fix cross-platform injection and launcher compatibility#110
mohui666 wants to merge 1 commit into
NeighTools:masterfrom
mohui666:fix/open-issues-compatibility

Conversation

@mohui666

Copy link
Copy Markdown

Summary

This consolidates the reproducible cross-platform compatibility fixes from the current issue backlog.

  • scope Unix stdout/fclose hooks to UnityPlayer so inherited LD_PRELOAD no longer breaks shell command substitution or file redirection
  • preserve empty target assemblies for debug-only mode and allow dnSpy/debug hooks without a managed entrypoint
  • resolve Unix executable, target, and Mono search paths relative to run.sh
  • isolate DYLD_INSERT_LIBRARIES from the Apple Silicon arch helper
  • use guarded dyld interposition for modern chained-fixup Mach-O images while keeping unsafe slot guessing fail-closed
  • preserve pre-existing Windows GetProcAddress IAT hooks and harden PE/CLI/path parsing
  • support restart-marker opt-out, localhost debugger normalization, and the documented Windows proxy alternatives

Fixes#88.
Addresses #24, #34, #47, #67, #73, #84, #94, #98, #102, #107, and #108.

Safety and compatibility

The macOS chained-fixups path no longer maps import ordinals to guessed GOT indices. dlsym, boot.config access, and stdout protection use dyld interposition instead; stdio interception checks that the direct caller is UnityPlayer, so inherited injection does not affect launchers or shells.

Missing target assemblies now skip only managed entrypoint execution. They no longer disable independent debugger, boot.config, and search-path functionality.

Verification

  • Windows regression tests
  • Windows x86 and x64 Release builds
  • Linux x64 Release build
  • Linux process-level LD_PRELOAD, shell redirection, UnityPlayer dup2, path, and restart-marker regressions
  • Unix shell syntax checks and strict C fixture compilation
  • git diff --check

CI additionally runs the real macOS dyld interposition smoke test and the normal Linux x86 build in its multilib runner.

Sign up for freeto 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.

Doorstop breaks output redirection in sh

1 participant

@mohui666