[issue6196] tarfile.extractall(readaccess=True)

2009-06-06 Thread Lars Gustäbel
Lars Gustäbel added the comment: I close this issue then. -- resolution: -> rejected status: open -> closed ___ Python tracker ___ __

[issue6196] tarfile.extractall(readaccess=True)

2009-06-05 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: [Lars] Sure, there is some functionality in extractall() that addresses issues with inappropriate permissions, but without this functionality the archive would not even *extract* cleanly. That is very different from your problem. Fair enough. 'tis time to

[issue6196] tarfile.extractall(readaccess=True)

2009-06-05 Thread Lars Gustäbel
Lars Gustäbel added the comment: Sure, tarfile contains numerous work-arounds for quirky and buggy archives. Otherwise, it would not be usable in real-life. But we should not mix up different issues here. tarfile reads and extracts your generator_tools.tar just fine. Formally, the data is okay.

[issue6196] tarfile.extractall(readaccess=True)

2009-06-05 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: [Lars] (...) We talk about a very small number of cases here and the generator_tools-0.3.5.tar.gz is really broken beyond repair. It is the only thing that should be fixed here IMO ;-) Sure, that is what the pyopenssl folks did - fix their tarball. However,

[issue6196] tarfile.extractall(readaccess=True)

2009-06-05 Thread Lars Gustäbel
Lars Gustäbel added the comment: I am still not convinced why tarfile needs this kind of a work-around built in. We talk about a very small number of cases here and the generator_tools-0.3.5.tar.gz is really broken beyond repair. It is the only thing that should be fixed here IMO ;-) I agree wit

[issue6196] tarfile.extractall(readaccess=True)

2009-06-04 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: [David] I don't see why the tarfile case should be different from the tar case. (...) As I explained, Viz: [quote]'(...)the very reason to write a program to extract tarball (instead of doing it manually) is to automate it .. which automation is *more effe

[issue6196] tarfile.extractall(readaccess=True)

2009-06-04 Thread R. David Murray
R. David Murray added the comment: I don't see why the tarfile case should be different from the tar case. You can "always chmod it later" in python, too (with os.walk and os.chmod). Perhaps the real need is for a recursive chmod in shutil? -- nosy: +r.david.murray priority: -> low

[issue6196] tarfile.extractall(readaccess=True)

2009-06-04 Thread Sridhar Ratnakumar
New submission from Sridhar Ratnakumar : If a tarball has a-x perms set on its root directory, one cannot access its contents. $ tar zxf generator_tools-0.3.5.tar.gz. $ ls generator_tools-0.3.5/ ls: cannot access generator_tools-0.3.5/README.txt: Permission denied ... sridh...@double:/tmp/i$

[issue6196] tarfile.extractall(readaccess=True)

2009-06-04 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: Considering this bug where tarfile fails to set g+s, https://bugs.launchpad.net/pyopenssl/+bug/236190 a more general approach could be: tarfile.extractall(safe_perms=True) where if safe_perms is set, tarfile can 1) ignore +/-s on all files, 2) ignore

[issue6196] tarfile.extractall(readaccess=True)

2009-06-04 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: Here's a test data from PyPI: http://pypi.python.org/packages/source/g/generator_tools/generator_tools-0.3.5.tar.gz -- ___ Python tracker __