This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author jvoisin
Recipients jvoisin
Date 2019-12-16.10:43:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1576493016.16.0.2184811666.issue39062@roundup.psfhosted.org>
In-reply-to
Content
The attached file produces the following stacktrace when opened via `tarfile.open`  and iterated with `TarFile.getmembers`, on Python 3.7.5rc1:

```
$ cat tarrepro.py
import tarfile
import sys

with tarfile.open(sys.argv[1]) as t:
  for member in t.getmembers():
    pass
```

```
$ python3 tarrepro.py crash-7221297307ab37ac87be6ea6dd9b28d4d453c557aa3da8a2138ab98e015cd42a
Traceback (most recent call last):
  File "tarrepro.py", line 5, in <module>
    for member in t.getmembers():
  File "/usr/lib/python3.7/tarfile.py", line 1763, in getmembers
    self._load()        # all members, we first have to
  File "/usr/lib/python3.7/tarfile.py", line 2350, in _load
    tarinfo = self.next()
  File "/usr/lib/python3.7/tarfile.py", line 2281, in next
    self.fileobj.seek(self.offset - 1)
ValueError: cannot fit 'int' into an offset-sized integer
```

This file isn't a valid tar file, it was created by a fuzzer.
History
Date User Action Args
2019-12-16 10:43:36jvoisinsetrecipients: + jvoisin
2019-12-16 10:43:36jvoisinsetmessageid: <1576493016.16.0.2184811666.issue39062@roundup.psfhosted.org>
2019-12-16 10:43:36jvoisinlinkissue39062 messages
2019-12-16 10:43:35jvoisincreate