Debian/Etch, Python 2.4.4
When trying to install AddApp with:
0launch http://rox.sourceforge.net/2005/interfaces/AddApp the progressbar of the download freezes and stderr displays the following:
WARNING:root:Leaving extracted directory as /home/mkiefer/.cache/0install.net/implementations/tmp-ZWytdA
Traceback (most recent call last):
File "/usr/lib/python2.4/site-packages/zeroinstall/0launch-gui/gui.py", line 70, in error_ready
dl.error_stream_closed()
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/download.py", line 148, in error_stream_closed
x(stream)
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/policy.py", line 492, in archive_ready
iface_cache.add_to_cache(retrieval_method, stream)
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/iface_cache.py", line 388, in add_to_cache
type = source.type, start_offset = source.start_offset or 0)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 246, in add_archive_to_cache
self._write_store(lambda store, **kwargs: store.add_archive_to_cache(required_digest,
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 258, in _write_store
fn(self.stores[0], try_helper = True)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 247, in <lambda>
data, url, extract, type = type, start_offset = start_offset, **kwargs))
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 106, in add_archive_to_cache
self.check_manifest_and_rename(required_digest, tmp, extract, try_helper = try_helper)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 174, in check_manifest_and_rename
manifest.fixup_permissions(extracted)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/manifest.py", line 478, in fixup_permissions
raise Exception("Unsafe mode: extracted file '%s' had special bits set in mode '%s'" % (full, oct(mode)))
Exception: Unsafe mode: extracted file '/home/mkiefer/.cache/0install.net/implementations/tmp-ZWytdA/addapp-0.7/.' had special bits set in mode '02755'
WARNING:root:Leaving extracted directory as /home/mkiefer/.cache/0install.net/implementations/tmp-sJRTQS
Traceback (most recent call last):
File "/usr/lib/python2.4/site-packages/zeroinstall/0launch-gui/gui.py", line 70, in error_ready
dl.error_stream_closed()
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/download.py", line 148, in error_stream_closed
x(stream)
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/policy.py", line 492, in archive_ready
iface_cache.add_to_cache(retrieval_method, stream)
File "/usr/lib/python2.4/site-packages/zeroinstall/injector/iface_cache.py", line 388, in add_to_cache
type = source.type, start_offset = source.start_offset or 0)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 246, in add_archive_to_cache
self._write_store(lambda store, **kwargs: store.add_archive_to_cache(required_digest,
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 258, in _write_store
fn(self.stores[0], try_helper = True)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 247, in <lambda>
data, url, extract, type = type, start_offset = start_offset, **kwargs))
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 106, in add_archive_to_cache
self.check_manifest_and_rename(required_digest, tmp, extract, try_helper = try_helper)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/__init__.py", line 174, in check_manifest_and_rename
manifest.fixup_permissions(extracted)
File "/usr/lib/python2.4/site-packages/zeroinstall/zerostore/manifest.py", line 478, in fixup_permissions
raise Exception("Unsafe mode: extracted file '%s' had special bits set in mode '%s'" % (full, oct(mode)))
Exception: Unsafe mode: extracted file '/home/mkiefer/.cache/0install.net/implementations/tmp-sJRTQS/rox-lib2-2.0.4/.' had special bits set in mode '02755'
Logged In: YES
user_id=40461
Originator: NO
------------------------------------------------------------------------
r1872 | tal197 | 2007-06-13 18:14:51 +0100 (Wed, 13 Jun 2007) | 5 lines
When creating a temporary directory for extracting an archive, always clear
any special bits. Otherwise, if the parent is set-guid then the tmp directory
will be too, and the post-extraction check will fail because the permissions
are wrong (reported by Markus Kiefer).
------------------------------------------------------------------------
Thanks. You can work around the problem in your current version by ensuring
that your cache directory is not setguid. e.g.:
$ chmod g-s /home/mkiefer/.cache/0install.net/implementations
Logged In: YES
user_id=1312539
Originator: NO
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).