Skip to content

LibSandbox: Report sandbox violations instead of killing the process#10240

Merged
gmta merged 1 commit into
LadybirdBrowser:masterfrom
sideshowbarker:macos-sandbox-report-violations
Jul 14, 2026
Merged

LibSandbox: Report sandbox violations instead of killing the process#10240
gmta merged 1 commit into
LadybirdBrowser:masterfrom
sideshowbarker:macos-sandbox-report-violations

Conversation

@sideshowbarker

@sideshowbarker sideshowbarker commented Jun 23, 2026

Copy link
Copy Markdown
Member

Problem: Crash on macOS 15 and 27 beta due to the sandbox code.

Cause: A helper symbolizes its own startup backtraces by reading its object files, which pulls in a code-signing check that macOS 15 (and 27?) denies. send-signal SIGSYS on the deny-default makes that process-killing fatal.

Fix: Drop send-signal from the catch-all deny-default, so a violation is just denied+logged (the call returns EPERM), rather than fatally killing the process. That matches Chrome and Firefox: both make the deny-default non-fatal. The syscall-unix SIGKILL still hard-kills the real vectors.

Hit this on my PR #9156 branch, which adds a GitHub-hosted macOS 15 (Sanitizer) CI job for AppKit+VoiceOver testing.

Also fixes #10379, which the issue reporter independently hit in a macOS 27 Golden Gate Developer Beta 2 environment. So perhaps this is somehow not actually related to the OS version. Or else I guess maybe the made some system change in the 27 beta that flipped it back to how it was in 15.

@github-actions github-actions Bot added the conflicts Pull request has merge conflicts that need resolution label Jun 26, 2026
@LadybirdBrowser LadybirdBrowser deleted a comment from github-actions Bot Jun 27, 2026
Problem: Crash on macOS 15 due to the sandbox code.

Cause: A helper symbolizes its own startup backtraces by reading its
object files, which pulls in a code-signing check that macOS 15 denies.
send-signal SIGSYS on the deny-default makes that process-killing fatal.

Fix: Drop send-signal from the catch-all deny-default, so a violation is
just denied+logged (the call returns EPERM), rather than fatally killing
the process. That matches Chrome and Firefox: both make the deny-default
non-fatal. The syscall-unix SIGKILL still hard-kills the real vectors.
@sideshowbarker
sideshowbarker force-pushed the macos-sandbox-report-violations branch from 0c67c12 to 078e778 Compare June 27, 2026 02:06
@github-actions github-actions Bot removed the conflicts Pull request has merge conflicts that need resolution label Jun 27, 2026
@gmta
gmta merged commit 3738371 into LadybirdBrowser:master Jul 14, 2026
13 checks passed
@sideshowbarker
sideshowbarker deleted the macos-sandbox-report-violations branch July 14, 2026 10:22
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.

Ladybird crashing when opening on macOS

2 participants