Skip to content

fix: shared-global machinery and wrapper names under observation - #436

Merged
Sorte1 merged 4 commits into
mainfrom
fix/r51-ml4
Nov 17, 2026
Merged

Sorte1 merged 4 commits into
mainfrom
fix/r51-ml4

Conversation

@Sorte1

@Sorte1 Sorte1 commented Nov 17, 2026

Copy link
Copy Markdown
Owner

Fixes from review r3-a35r5 and r3-a42r2.

  • With several inputs, a string array, decoder, legacy array, dead decoder alias or protection that another input names is now kept and nothing is decoded through it. This applies in both lanes. Stamping refuses it with a new note, and decode, removal, dead-alias and protection checks now also ask is_shared_global, using the original names.
  • A root wrapper function is no longer removed while the program tests or lists global names (in, hasOwnProperty, Object.hasOwn, Reflect.has, Object.keys, ...). The default lane judges this with observation. Inside a stage the observation is deferred and judged again at the stage end, so encoded keys do not block decoding.
  • r3-a42r2 finding 1: observation is now recorded past a reach. Removal also treats a reach as an observation, so the outer layer's machinery is no longer dropped under a later name test.
  • r3-a42r2 finding 3: drop_layered drops only the latest speculation of a token. Unit test added.
  • README: the --unsafe premise now has the Annex B item, and the multi-input premise says machinery is kept in both lanes.
  • Tests: multi-input rows (y8-y10, v1, v3, v8, u1, v10, y3), node rows for w01/w04-w06, min2/min11/min18, w1-wrap-inlit-end, the 2- and 3-layer wrapper rows, and ln2-*/e6. Two existing tests were updated: kd01/ke01/kf01 are now also kept by the removal observation, and the multi-input refusal-span row now refuses through a module.

Gates: the obfuscator-io, obfuscator-versions and relayer BASELINEs are byte-equal. The game and Krunker samples give identical output in default, --unsafe and --rename smart; instructions are within ±0.1%, except Krunker 0.20 (+1.1%) and 2.6.9 (+0.9%) in default and smart. The wasm baseline moves to 14,365,000 for 15,797,167 bytes (+4.3 KB). Local untwist-ci is green.

…bservation

Shared globals from other inputs now stop stamping, decoding, legacy array lifting,
dead alias and protection removal in both lanes. A root wrapper function is kept when
the program tests or lists global names, judged again at the stage end. Observation is
recorded past a reach, a reach at removal counts as an observation, and dropping a later
speculation keeps an earlier obligation. README: Annex B item in the --unsafe premise.
…es with the shared-global and observation checks
@Sorte1
Sorte1 merged commit 57ad8f8 into main Nov 17, 2026
9 checks passed
@Sorte1
Sorte1 deleted the fix/r51-ml4 branch November 17, 2026 19:27

This branch was successfully deployed

1 active deployment
preview — 0cf7e2c7 Deployed Nov 17, 2026 by Sorte1 via deploy #1255
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