Skip to content

Hardening: native engine, desktop app and Web server fail closed on malformed input - #4381

Merged
ashhart merged 8 commits into
mainfrom
lead/harden-native-app
Nov 21, 2026
Merged

ashhart merged 8 commits into
mainfrom
lead/harden-native-app

Conversation

@ashhart

@ashhart ashhart commented Nov 21, 2026

Copy link
Copy Markdown
Owner

Hardening from an internal review of the native engine, the desktop app and the Web server. Each change fails closed where a malformed or unexpected input could previously go further than intended:

  • Cluster launch quotes every argument it passes to remote shells.
  • Session restore refuses duplicate blob names.
  • The desktop app's shell-command policy classifies each command position, so a path-prefixed program gets the same approval as its bare name; SSH is refused when network access is denied.
  • Hub pulls bound the size of JSON metadata and recheck a cached blob's digest before trusting it.
  • The Web server caps request bodies before pairing, removes partial media downloads on failure, and no longer puts the long-lived authority token in the browser launch URL.
  • Native video seek and Cortheon network deadlines handle their failure paths.
  • CI: the landing-train job skips apply only to branches in this repository, never to a fork's branch of the same name.

Two follow-up commits keep zig/src/sessions/disk.zig under the 600-line cap and tidy a cluster comment. Focused Zig, Electron and Web tests pass on the changed code.

Resolve 11 local findings across cluster launch, sessions, shell policy, Hub pulls, Web auth and native video/network lifecycles.
- Quote cluster arguments and reject duplicate session restore names.
- Classify shell command positions and fail closed for denied-network SSH.
- Bound Hub JSON and verify cached blob digests.
- Cap pairing requests before authentication and clean streamed media temporaries.
- Retire durable browser launch tokens and harden seek/Cortheon failure paths.
Focused Zig, Electron, Web UI/server and CI workflow regressions passed; changed-file Zig formatting and diff checks passed.
@ashhart
ashhart force-pushed the lead/harden-native-app branch from d7eaf8c to e36d0b4 Compare November 21, 2026 20:21
@ashhart
ashhart merged commit 31c24d8 into main Nov 21, 2026
4 of 10 checks passed
@ashhart
ashhart deleted the lead/harden-native-app branch November 21, 2026 20:21
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