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

Segfault(SIGSEV) from CSVStat::get_mins #72

Open
jihyunhillpark opened this issue Jan 26, 2020 · 0 comments
Open

Segfault(SIGSEV) from CSVStat::get_mins #72

jihyunhillpark opened this issue Jan 26, 2020 · 0 comments

Comments

@jihyunhillpark
Copy link

jihyunhillpark commented Jan 26, 2020

Hi, I found returning the number of columns in CSVStat::get_ mins of include/internal/csv_stat.cpp’(commit 6323ff8) crashes with the attached .csv file (test.csv). I think this may be related to the line #41-42 of include/internal/csv_stat.cpp. The crash was observed on Ubuntu 18.04.3 with kernel 4.15.0-72-generic and x86_64.

The crash can be reproduced by the following command:
$./csv_stat test.csv

Here’s the the crash stack trace taken with GDB:

#0 0x00005555555da731 in std::__1::allocator::construct<long double, long double const&> (this=,
__p=0x555555a2e520, __args=) at /home/cockatiel01/LLVM/bin/../include/c++/v1/memory:1811
#1 std::__1::allocator_traits<std::__1::allocator >::__construct<long double, long double const&> (__a=...,
__p=0x555555a2e520, __args=) at /home/cockatiel01/LLVM/bin/../include/c++/v1/memory:1716
#2 std::__1::allocator_traits<std::__1::allocator >::construct<long double, long double const&> (__a=...,
__p=0x555555a2e520, __args=) at /home/cockatiel01/LLVM/bin/../include/c++/v1/memory:1562
#3 std::__1::vector<long double, std::__1::allocator >::__push_back_slow_path<long double const&> (
this=0x7fffffffdbc0, __x=) at /home/cockatiel01/LLVM/bin/../include/c++/v1/vector:1613
#4 0x00005555555c5821 in std::__1::vector<long double, std::__1::allocator >::push_back (this=,
__x=) at /home/cockatiel01/LLVM/bin/../include/c++/v1/vector:1632
#5 csv::CSVStat::get_mins (this=0x7fffffffdc50)
at /home/jihyunee/ang-csv-parser/csv-parser-fast/include/internal/csv_stat.cpp:52
#6 0x0000555555570604 in main (argc=, argv=)
at /home/jihyunee/ang-csv-parser/csv-parser-fast/programs/csv_stats.cpp:15

This crash was found with Angora fuzzer, and test.csv is originated from ints_join.csv
in tests/data/fake_data directory.

Hope this help.
test.csv.zip

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

No branches or pull requests

1 participant