[Bug 78672] entries in custom upload tarballs with long names don't get extracted
Colin Watson
cjwatson at canonical.com
Wed Jan 10 11:16:49 GMT 2007
Public bug reported:
Python's tarfile module behaves slightly differently for names over a
certain length, due to a quirk of the format. As a demonstration:
>>> import tarfile
>>> tar = tarfile.open('/tmp/debian-installer-images_20061102ubuntu10_i386.tar.gz')
>>> for tarinfo in tar:
... print tarinfo
...
<TarInfo './' at 0x2aaaab7b5250>
<TarInfo 'installer-i386/' at 0x2aaaaab39850>
<TarInfo 'installer-i386/20061102ubuntu10/' at 0x2aaaab7b52d0>
[...]
<TarInfo 'installer-i386/20061102ubuntu10/images/netboot/ubuntu-installer/i386/pxelinux.cfg.serial-9600/' at 0x2aaaab7b58d0>
<TarInfo './installer-i386/20061102ubuntu10/images/netboot/ubuntu-installer/i386/pxelinux.cfg.serial-9600/default' at 0x2aaaab7b5950>
<TarInfo 'installer-i386/20061102ubuntu10/images/netboot/ubuntu-installer/i386/boot-screens/' at 0x2aaaab7b5910>
Note the extra "./" at the start of the pxelinux.cfg.serial-9600/default
file name. Some of the custom upload handlers don't deal with this
correctly because they check the prefix of the file name without
normalising the path. The following (untested) patch corrects this by
applying os.path.normpath:
https://devpad.canonical.com/~andrew/paste/fileUqF88V.html
Please consider this so that certain files stop going missing from the
dists tree in the archive. Fortunately the files in question aren't
critically important.
** Affects: soyuz (upstream)
Importance: Undecided
Status: Unconfirmed
--
entries in custom upload tarballs with long names don't get extracted
https://launchpad.net/bugs/78672
More information about the ubuntu-archive
mailing list