mirror of
https://github.com/MacosPorters/betterxen.git
synced 2026-11-27 04:35:27 +00:00
Add crates/loader/src/x86_decode.rs with the shared architectural limit MAX_INSTRUCTION_LEN (15 bytes) and segment_prefix_len. Bounded the legacy segment prefix runs in the static probe, the software interpreter and the native DBT so overlong prefix runs decode as illegal instructions instead of consuming past the architectural limit, and the probe now rejects any decoded record longer than 15 bytes. Regression tests cover the overlong prefix run, prefix-count lengths, the minimized fuzz-artifact input, and interpreter and DBT rejections (issue #69). Signed-off-by: Ranveer Soni <git@ranveersoni.me>