Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Program(wasm3) DoS #464

Open
haruki3hhh opened this issue Feb 19, 2024 · 1 comment
Open

Program(wasm3) DoS #464

haruki3hhh opened this issue Feb 19, 2024 · 1 comment

Comments

@haruki3hhh
Copy link

version

139076a

build

cmake -DCMAKE_C_COMPILER="gcc" -DCMAKE_C_FLAGS="-g -fsanitize=address -fno-omit-frame-pointer" -DCMAKE_EXE_LINKER_FLAGS="-g -fsanitize=address -fno-omit-frame-pointer" .
make

reproduce

./wasm3 <PoC> ## program will DoS and block here.

PoC

PoC

@tommie
Copy link

tommie commented May 31, 2024

wasm2wat says

0002455: error: memory.grow reserved value must be 0

With --enable-all it says

0002455: error: memory index 33 out of range

Looking at a trace, it seems to end up looping in dlmalloc between 1643 and 1662.

There's way too much inlined C code here to be reproducible without debug info (hence wasm2wat.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants