Bug 1597617

Summary: crash in libarchive from python
Product: [Fedora] Fedora Reporter: Zbigniew Jędrzejewski-Szmek <zbyszek>
Component: python-libarchiveAssignee: Dhiru Kholia <dhiru>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: besser82, dhiru, moez.roy
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-05-28 20:50:19 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
crash reproducer none

Description Zbigniew Jędrzejewski-Szmek 2018-07-03 10:06:53 UTC
Created attachment 1456164 [details]
crash reproducer

Description of problem:
Please see the attached reproducer. This crashes both in rawhide mock and in F28.

Version-Release number of selected component (if applicable):
libarchive-3.3.2-1.fc29.x86_64
python3-libarchive-c-2.8-1.fc29.noarch

How reproducible:
100%

Steps to Reproduce:
1. python3 test1.py

Comment 1 Zbigniew Jędrzejewski-Szmek 2018-07-03 10:11:40 UTC
$ gdb --args python3 test1.py
(gdb) r
Program received signal SIGSEGV, Segmentation fault.
0x00005555557f2080 in ?? ()
(gdb) bt
#0  0x00005555557f2080 in ?? ()
#1  0x00007fffef89ad1e in ffi_call_unix64 () at ../src/x86/unix64.S:76
#2  0x00007fffef89a68f in ffi_call (cif=<optimized out>, fn=<optimized out>, rvalue=<optimized out>, avalue=<optimized out>) at ../src/x86/ffi64.c:525
#3  0x00007fffefaae90b in _call_function_pointer (argcount=2, resmem=0x7fffffffd520, restype=<optimized out>, atypes=0x7fffffffd4e0, avalues=0x7fffffffd500, pProc=0x7fffecaf7a30 <archive_read_next_header2>, flags=4353) at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Modules/_ctypes/callproc.c:809
#4  _ctypes_callproc () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Modules/_ctypes/callproc.c:1166
#5  0x00007fffefaaf314 in PyCFuncPtr_call () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Modules/_ctypes/_ctypes.c:3962
#6  0x00007ffff79980f4 in _PyObject_FastCallDict () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Objects/abstract.c:2331
#7  0x00007ffff7a06d8d in call_function () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:4848
#8  0x00007ffff7a30e9a in _PyEval_EvalFrameDefault () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:3322
#9  0x00007ffff79f9872 in gen_send_ex () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Objects/genobject.c:189
#10 0x00007ffff79f9fb1 in gen_iternext (gen=<optimized out>) at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Objects/genobject.c:563
#11 builtin_next () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/bltinmodule.c:1330
#12 0x00007ffff79f918f in _PyCFunction_FastCallDict () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Objects/methodobject.c:234
#13 0x00007ffff7a06c5a in call_function () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:4824
#14 0x00007ffff7a30e9a in _PyEval_EvalFrameDefault () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:3322
#15 0x00007ffff7a0fb38 in _PyEval_EvalCodeWithName (qualname=0x0, name=<optimized out>, closure=<optimized out>, kwdefs=<optimized out>, defcount=0, defs=<optimized out>, kwstep=2, kwcount=<optimized out>, kwargs=0x0, kwnames=0x0, argcount=0, args=0x0, locals={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='test1.py') at remote 0x7ffff7efeac8>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7ffff7fc5638>, '__file__': 'test1.py', '__cached__': None, 'libarchive': <module at remote 0x7fffefcd75e8>, 'os': <module at remote 0x7ffff7e8e138>, 'path': 'test1.tar', 'archive': <ArchiveRead(_pointer=93824995752368) at remote 0x7fffefcd05c0>}, globals={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='test1.py') at remote 0x7ffff7efeac8>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7ffff7fc5638>, '__file__': 'test1.py', '__cached__': None, 'libarchive': <module at remote 0x7fffefcd75e8>, 'os': <module at remote 0x7ffff7e8e138>, 'path': 'test1.tar', 'archive': <ArchiveRead(_pointer=93824995752368) at remote 0x7fffefcd05c0>}, _co=<code at remote 0x7ffff7f018a0>) at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:4153
#16 PyEval_EvalCodeEx () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:4174
#17 0x00007ffff7a108bb in PyEval_EvalCode (co=co@entry=<code at remote 0x7ffff7f018a0>, globals=globals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='test1.py') at remote 0x7ffff7efeac8>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7ffff7fc5638>, '__file__': 'test1.py', '__cached__': None, 'libarchive': <module at remote 0x7fffefcd75e8>, 'os': <module at remote 0x7ffff7e8e138>, 'path': 'test1.tar', 'archive': <ArchiveRead(_pointer=93824995752368) at remote 0x7fffefcd05c0>}, locals=locals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='test1.py') at remote 0x7ffff7efeac8>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7ffff7fc5638>, '__file__': 'test1.py', '__cached__': None, 'libarchive': <module at remote 0x7fffefcd75e8>, 'os': <module at remote 0x7ffff7e8e138>, 'path': 'test1.tar', 'archive': <ArchiveRead(_pointer=93824995752368) at remote 0x7fffefcd05c0>}) at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/ceval.c:730
#18 0x00007ffff7a9c692 in run_mod () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/pythonrun.c:1025
#19 0x00007ffff7a9d35d in PyRun_FileExFlags () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/pythonrun.c:978
#20 0x00007ffff7a9eee7 in PyRun_SimpleFileExFlags () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/pythonrun.c:420
#21 0x00007ffff7a9efb7 in PyRun_AnyFileExFlags () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Python/pythonrun.c:81
#22 0x00007ffff7a9fe7c in run_file (p_cf=0x7fffffffdd5c, filename=0x5555557584d0 L"test1.py", fp=0x55555580a220) at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Modules/main.c:344
#23 Py_Main () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Modules/main.c:814
#24 0x0000555555554d45 in main () at /usr/src/debug/python3-3.6.5-1.fc27.x86_64/Programs/python.c:102
#25 0x00007ffff6b73f2a in __libc_start_main () from /lib64/libc.so.6
#26 0x0000555555554eba in _start ()


Reproducer works in F27 too ;)

Comment 2 Ben Cotton 2019-05-02 21:29:45 UTC
This message is a reminder that Fedora 28 is nearing its end of life.
On 2019-May-28 Fedora will stop maintaining and issuing updates for
Fedora 28. It is Fedora's policy to close all bug reports from releases
that are no longer maintained. At that time this bug will be closed as
EOL if it remains open with a Fedora 'version' of '28'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 28 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 3 Ben Cotton 2019-05-28 20:50:19 UTC
Fedora 28 changed to end-of-life (EOL) status on 2019-05-28. Fedora 28 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.