bytecodealliance / lucet

Lucet, the Sandboxing WebAssembly Compiler.
Apache License 2.0
4.06k stars 165 forks source link

lucetc: add command line option to disable wat translation #571

Closed pchickey closed 4 years ago

pchickey commented 4 years ago

wat translation is a potential attack vector, since it happens in the C++ wabt library, so we want a way to turn it off if required.

[lucet]% cargo run -p lucetc -- lucetc/tests/wasm/globals_export.wat --no-translate-wat
    Finished dev [unoptimized + debuginfo] target(s) in 0.06s
     Running `target/debug/lucetc lucetc/tests/wasm/globals_export.wat --no-translate-wat`
Error: Input does not have Wasm preamble