Skip to content

SEGV at xs/sources/xsAll.c:161 #484

Description

@kvenux

Build environment:

Ubuntu 16.04
gcc 5.4.0
xst version: 748fda9
build command:
cd /path/to/moddable/xs/makefiles/lin
make
test command: ./xst poc

Target device:

Desktop Linux

POC

xs-new-000040.txt

Description

Below is the ASAN outputs.

ASAN:SIGSEGV

==91961==ERROR: AddressSanitizer: SEGV on unknown address 0x0000ffffffc0 (pc 0x7f9f2bbbd834 bp 0x7ffe70dbddd0 sp 0x7ffe70dbd558 T0)
#0 0x7f9f2bbbd833 in strlen (/lib/x86_64-linux-gnu/libc.so.6+0x8b833)
#1 0x7f9f2c4921a5 in __interceptor_strlen (/usr/lib/x86_64-linux-gnu/libasan.so.2+0x701a5)
#2 0x41d719 in fxConcatString /home/keven/Fuzzing/moddable-new/xs/sources/xsAll.c:161
#3 0x7c9c4d in fx_RegExp_prototype_toString /home/keven/Fuzzing/moddable-new/xs/sources/xsRegExp.c:1082
#4 0x7e7d41 in fxRunID /home/keven/Fuzzing/moddable-new/xs/sources/xsRun.c:769
#5 0x6303c4 in fx_Function_prototype_call /home/keven/Fuzzing/moddable-new/xs/sources/xsFunction.c:518
#6 0x7e7d41 in fxRunID /home/keven/Fuzzing/moddable-new/xs/sources/xsRun.c:769
#7 0x850672 in fxRunScript /home/keven/Fuzzing/moddable-new/xs/sources/xsRun.c:4606
#8 0xa31992 in fxRunProgramFile /home/keven/Fuzzing/moddable-new/xs/tools/xst.c:1398
#9 0x41902a in main /home/keven/Fuzzing/moddable-new/xs/tools/xst.c:290
#10 0x7f9f2bb5283f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2083f)
#11 0x41bb98 in _start (/home/keven/Fuzzing/moddable-new/build/bin/lin/debug/xst+0x41bb98)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV ??:0 strlen
==91961==ABORTING

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmedissue reported has been reproducedfixed - please verifyIssue has been fixed. Please verify and close.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions