After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 707875 - Segfault on a fuzzed .xls file
Segfault on a fuzzed .xls file
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: import/export MS Excel (tm)
git master
Other Linux
: Normal critical
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2013-09-10 18:32 UTC by jutaky
Modified: 2013-09-13 14:08 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description jutaky 2013-09-10 18:32:10 UTC
Segfault on a fuzzed .xls file.

Git versions of glib, goffice, gnumeric, libgsf and libxml2.

Test case: http://jutaky.com/fuzzing/gnumeric_case_17766_49314.xls

Program received signal SIGSEGV, Segmentation fault.
0x00007fffe61edc45 in excel_externsheet_v7 (container=0x7fffffffe080, idx=1) at ms-excel-read.c:6108
6108		g_return_val_if_fail (idx <= (int)externsheets->len, NULL);
(gdb) bt
  • #0 excel_externsheet_v7
    at ms-excel-read.c line 6108
  • #1 excel_parse_formula1
    at ms-formula-read.c line 1690
  • #2 excel_parse_formula
    at ms-formula-read.c line 1844
  • #3 ms_sheet_parse_expr_internal
    at ms-excel-read.c line 302
  • #4 ms_wb_parse_expr
    at ms-excel-read.c line 3223
  • #5 ms_container_parse_expr
    at ms-container.c line 188
  • #6 ms_obj_read_expr
    at ms-obj.c line 519
  • #7 read_pre_biff8_read_expr
    at ms-obj.c line 619
  • #8 read_pre_biff8_read_name_and_fmla
    at ms-obj.c line 653
  • #9 ms_obj_read_pre_biff8_obj
    at ms-obj.c line 757
  • #10 ms_read_OBJ
    at ms-obj.c line 1279
  • #11 excel_read_workbook
    at ms-excel-read.c line 7183
  • #12 excel_enc_file_open
    at boot.c line 193
  • #13 excel_file_open
    at boot.c line 250
  • #14 go_plugin_loader_module_func_file_open
    at app/go-plugin-loader-module.c line 282
  • #15 go_plugin_file_opener_open
    at app/go-plugin-service.c line 685
  • #16 go_file_opener_open
    at app/file.c line 417
  • #17 workbook_view_new_from_input
    at workbook-view.c line 1277
  • #18 workbook_view_new_from_uri
    at workbook-view.c line 1337
  • #19 main
    at main-application.c line 321


--
Juha Kylmänen
Research Assistant, OUSPG
Comment 1 Morten Welinder 2013-09-12 20:03:50 UTC
While I don't see a crash, I do see this.  And that's bad.

==21905== Conditional jump or move depends on uninitialised value(s)
==21905==    at 0x152D86A0: excel_externsheet_v7 (ms-excel-read.c:6106)
==21905==    by 0x152EF039: excel_parse_formula1 (ms-formula-read.c:1690)
==21905==    by 0x152F061D: excel_parse_formula (ms-formula-read.c:1844)
==21905==    by 0x152CFDCB: ms_sheet_parse_expr_internal (ms-excel-read.c:302)
==21905==    by 0x152CFEB3: ms_wb_parse_expr (ms-excel-read.c:3223)
==21905==    by 0x152F31C9: ms_obj_read_expr.isra.8 (ms-obj.c:519)
==21905==    by 0x152F3636: read_pre_biff8_read_name_and_fmla (ms-obj.c:619)
==21905==    by 0x152F471E: ms_read_OBJ (ms-obj.c:749)
==21905==    by 0x152DEA05: excel_read_workbook (ms-excel-read.c:7183)
==21905==    by 0x152C7DEE: excel_enc_file_open (boot.c:193)
==21905==    by 0x53C6D72: go_plugin_file_opener_open (go-plugin-service.c:685)
==21905==    by 0x4F9E03E: workbook_view_new_from_input (workbook-view.c:1277)
==21905==    by 0x4F9E28C: workbook_view_new_from_uri (workbook-view.c:1337)
==21905==    by 0x40392C: main (main-application.c:321)
Comment 2 Morten Welinder 2013-09-13 14:08:26 UTC
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report.