Skip to content
This repository has been archived by the owner on May 11, 2020. It is now read-only.

function DecodeModule implementation is not consistent with the wasm specification #144

Closed
laizy opened this issue Jul 30, 2019 · 0 comments · Fixed by #151
Closed

function DecodeModule implementation is not consistent with the wasm specification #144

laizy opened this issue Jul 30, 2019 · 0 comments · Fixed by #151

Comments

@laizy
Copy link
Member

laizy commented Jul 30, 2019

from the WebAssembly Specifications

The preamble is followed by a sequence of sections. Custom sections may be inserted at any place in this sequence, while other sections must occur at most once and in the prescribed order. All sections can be empty.

the current implementation use a for loop to decode the section data. so the prescribed order is not checked.

A similar processing logic as a reference is at https://github.com/CraneStation/cranelift/blob/master/cranelift-wasm/src/module_translator.rs#L14

sbinet pushed a commit that referenced this issue Aug 1, 2019
laizy added a commit to ontio/wagon that referenced this issue Aug 5, 2019
laizy added a commit to ontio/wagon that referenced this issue Aug 5, 2019
laizy added a commit to laizy/wagon that referenced this issue Oct 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant