Assertion failure: inputSizeChecked.isValid(), at mfbt/Compression.cpp:25
Categories
(Core :: JavaScript Engine, defect, P3)
Tracking
()
People
(Reporter: sm-bugs, Assigned: mccr8)
References
(Blocks 2 open bugs, Regression)
Details
(Keywords: regression)
Attachments
(3 files)
Steps to reproduce:
Steps to reproduce:
Checkout commit d9496bfef09039b2642da45585ca821c36917c6d and invoke the js shell as follows:
./js-spidermonkey-shell --fast-warmup --fuzzing-safe input_size_checked_01.js
Actual results:
Assertion failure: inputSizeChecked.isValid(), at mfbt/Compression.cpp:25
Comment 1•1 year ago
|
||
This looks like a problem with the compressLZ4 shell function. We probably need to ensure the size doesn't overflow INT32_MAX. Not security-sensitive if it only affects the shell function.
Updated•1 year ago
|
Comment 2•1 year ago
|
||
Set release status flags based on info from the regressing bug 1856635
Updated•1 year ago
|
Updated•1 year ago
|
Updated•1 year ago
|
| Assignee | ||
Updated•1 year ago
|
| Assignee | ||
Updated•1 year ago
|
Comment 3•1 year ago
|
||
This only affects the JS shell and therefore is not a security issue.
Updated•1 year ago
|
Comment 4•1 year ago
|
||
Set release status flags based on info from the regressing bug 1856635
Updated•1 year ago
|
Comment 5•7 months ago
•
|
||
compressLZ4(new ArrayBuffer(2**31));
$ ~/shell-cache/js-dbg-64-linux-x86_64-c0927f7f515e-582651/js-dbg-64-linux-x86_64-c0927f7f515e-582651 --fuzzing-safe --no-threads --no-baseline --no-ion testcase.js
[297253] Assertion failure: inputSizeChecked.isValid(), at /home/msf2/trees/firefox/mozglue/static/Compression.cpp:25
Tested with gh rev c0927f7f515e.
(gdb) bt
#0 0x00005555589ce57f in MOZ_CrashSequence (aAddress=0x0, aLine=25) at /home/msf2/shell-cache/js-dbg-64-linux-x86_64-c0927f7f515e-582651/objdir-js/dist/include/mozilla/Assertions.h:248
#1 mozilla::Compression::LZ4::compress (aSource=<optimized out>, aInputSize=<optimized out>, aDest=<optimized out>) at /home/msf2/trees/firefox/mozglue/static/Compression.cpp:25
#2 0x00005555571d90f1 in CompressLZ4 (cx=cx@entry=0x7ffff5e3c200, argc=<optimized out>, vp=<optimized out>) at /home/msf2/trees/firefox/js/src/shell/js.cpp:9368
#3 0x00005555572f1be5 in CallJSNative (cx=cx@entry=0x7ffff5e3c200, native=0x5555571d8de0 <CompressLZ4(JSContext*, unsigned int, JS::Value*)>, reason=<optimized out>, args=...)
at /home/msf2/trees/firefox/js/src/vm/Interpreter.cpp:501
#4 0x00005555572cdfa6 in js::InternalCallOrConstruct (cx=0x7ffff5e3c200, args=..., construct=construct@entry=js::NO_CONSTRUCT, reason=js::CallReason::Call)
at /home/msf2/trees/firefox/js/src/vm/Interpreter.cpp:597
#5 0x00005555572ced08 in InternalCall (cx=<optimized out>, args=..., reason=25) at /home/msf2/trees/firefox/js/src/vm/Interpreter.cpp:664
/snip
Jan, this is an updated testcase. With the simplicity, it's really easy to trigger. If it is not a priority, can we please get at least a patch or ignore it under --fuzzing-safe for now?
| Assignee | ||
Comment 7•6 months ago
|
||
compressLZ4 has some unfixed overflow integer issues that at least 3
different fuzzing people have stumbled over. Given that this was first reported
more than a year ago without being fixed, let's at least keep fuzzing people
from hitting this.
Updated•6 months ago
|
| Assignee | ||
Comment 8•6 months ago
|
||
I tested load-mod.js and compression.js in a shell build and they still seem to pass.
| Assignee | ||
Updated•6 months ago
|
Comment 10•6 months ago
|
||
| bugherder | ||
Updated•6 months ago
|
Updated•6 months ago
|
Description
•