Repository navigation
iOS Simulator: sandboxed helper, Desktop zero-copy view, macOS test fixes - #139
Merged
Merged
Conversation
…ixes Sandbox the acecode-ios-sim helper with an ACECode-authored Seatbelt profile (no IP networking, no reading personal files, writes only to simulator data and temp folders). CFBundle must be able to list the helper's ancestor directories and the profile follows the user-record home, as CoreSimulator does. When sandbox-exec cannot apply the profile the helper runs unconfined and status/settings say why. Draw the simulator in ACECode Desktop on macOS natively: the simulator's IOSurface becomes the contents of a click-through layer over the panel, so frames skip readback and JPEG encoding. Desktop loads only the system CoreSimulator through a static library shared with the helper. The panel stops the JPEG stream with a new WebSocket frames message while the native view renders and falls back when it cannot. Move the dtuhidd message builders into a header shared by the helper and unit tests. Live verification on Xcode 27 is still outstanding. Fix the macOS-only unit failures: the remote Web proxy could not bind its 127.0.0.2 source address on macOS (remote Web never worked on Macs), and several tests depended on Linux/Windows behaviour (serialized system(), Crow shutdown race, autofs /home, browser tools, label width, a dangling pointer). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Builds the helper, the Seatbelt argv printer and the native view smoke with clang++ and drives a booted simulator: touch, drag, keyboard and button input checked through the accessibility tree, screenshots, the JPEG stream, sandbox denials and the Desktop native view. GitHub's xcode-27 image (CoreSimulator 1155.4+) exercises the dtuhidd transport. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Xcode 27's display-info reply (verified on the xcode-27 runner) carries displays[].currentOrientation = rot0/rot90/rot180/rot270. Anything else now counts as no answer and falls back to Simulator.app's orientation, and a provider that timed out is retried every 5 s instead of blocking input for 2 s every 600 ms. The live check retries typing once when the first tap only stopped a coasting list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
On a busy Mac the CoreDevice provider often misses a 2 s window, mostly because every lookup opened a new guest connection. The connection is now kept per device, the first lookup answers synchronously (5 s), later lookups return the last answer at once and refresh in the background, and a timed-out refresh keeps the last good rotation instead of dropping to Simulator.app's window orientation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Finishes the iOS Simulator follow-ups and the macOS-only test failures found during v1.0.8.
What changes
acecode-ios-simnow runs under an ACECode-authored Seatbelt profile (helper_sandbox.cpp, every path passed as asandbox-exec -Dparameter):sandbox-execcannot apply the profile, the helper runs unconfined and status/Settings say why.ACECODE_IOS_SIM_SANDBOX=0turns it off for diagnosis.acecode_ios_sim_nativestatic library shared with the helper. It never loads code from the web-supplied developer directory.{type:"frames"}message, or?frames=0, and falls back automatically. Input still goes through the panel.dtuhid_messages.hpp, shared by the helper and unit tests. A new opt-inios-simulator-liveworkflow runsscripts/ios_simulator/live_check.pyon GitHub'sxcode-27runner. It builds the helper with clang++, boots a simulator and checks through the accessibility tree that input really takes effect.dtuhidtransport. Taps, drags, typing and Home all work, as do orientation, the stream, the sandbox and the native view.displays[].currentOrientation = rotN.describe.CMakeLists.txt,vcpkg.json).posix_spawn, because macOS serializessystem()./home.Verification (Intel Mac, Xcode 26.6 green install, iOS 26.5)
Full unit suite: 6326 passed, 0 failed (previously 11 failures plus a crash on macOS).
Web:
pnpm test(3215 passed),pnpm build, i18n catalog regenerated. All CI lint checks clean.Every helper operation runs under the sandbox; the same profile refuses home reads, network access and home writes.
IosSimulatorE2E.*passes and asserts the helper is sandboxed.Native view:
ios_simulator_view_mac_smokepasses on a booted simulator, checking IOSurface contents, geometry, mask, click-through, hide/show, unmount and the unknown-device error.The WebSocket frames toggle was checked live against a daemon.
Xcode 27 live check (
ios-simulator-live,xcode-27runner): 16/16 passed, as listed above.Not verified
rotNparse shares code withrot0, and older runtimes were verified in landscape locally.🤖 Generated with Claude Code