Skip to content

fix: prove a nested object's callees, the built-ins a fold reads, and Annex B block functions - #454

Open
Sorte1 wants to merge 2 commits into
mainfrom
fix/ox2-e2
Open

Sorte1 wants to merge 2 commits into
mainfrom
fix/ox2-e2

Conversation

@Sorte1

@Sorte1 Sorte1 commented Nov 19, 2026

Copy link
Copy Markdown
Owner

Fixes F1 to F3 from the R5 review of #451 (default-lane wrong output).

  • F1: a call or tagged template through an own key of a nested object now counts as a harmless read only when that key's value is a function or arrow written in the literal. A value bound by name, a member, a call result, a parameter or a built-in refuses the object. An own key named like an Object.prototype member (valueOf, defineGetter, ...) refuses it as well.
  • F2: in the default lane, a fold that calls anything, reads a member or names a global other than undefined, NaN or Infinity now needs the fail-closed built-in scan (from fix: make the built-in patch scan fail-closed by structure #447) to prove every built-in root unpatched. Without that proof the fold is refused. This covers nested-object function bodies and the value fallback that the owner-only path also uses. --unsafe keeps the README premise.
  • F3: every object in Branches.objects goes through the Annex B check, so a sloppy block function with the same name (in a block, an if or a switch) refuses the var object.

The new code lives in control_flow_object/nested_proof.rs, which keeps dead.rs under 700 lines. obfuscator_sweep_rows.rs gets one row per repro and per variant the review lists: 15 compared with node in both lanes, 20 in the default lane.

Gates: full sweep (3,465 cases) against main @06800091 with every verdict identical in both lanes, so no pass to fail and no kept to fail. Krunker samples are byte-identical to main in both lanes. BASELINE drift tests pass. Full untwist-ci passes; one Firefox e2e spec (parity presets) flaked and passed when rerun alone. Wasm is 16,156,509 bytes, so the baseline goes to 14,700,000.

… Annex B block functions before deciding a dead branch through it

This branch is being deployed

1 in progress deployment
preview — e5a53f54 Deployed Nov 19, 2026 by Sorte1 via deploy #1306
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