
report at bugs
Jun 24, 2012, 4:27 PM
Post #23 of 37
(249 views)
Permalink
|
|
[issue4489] shutil.rmtree is vulnerable to a symlink attack
[In reply to]
|
|
Arfrever Frehtes Taifersar Arahesis <Arfrever.FTA [at] GMail> added the comment: The fix for this issue broke support for bytes in shutil.rmtree: $ mkdir -p /tmp/a/b $ python3.2 -c 'import shutil; shutil.rmtree(b"/tmp/a")' $ mkdir -p /tmp/a/b $ python3.3 -c 'import shutil; shutil.rmtree(b"/tmp/a")' Traceback (most recent call last): File "<string>", line 1, in <module> File "/usr/lib64/python3.3/shutil.py", line 444, in rmtree _rmtree_safe_fd(fd, path, onerror) File "/usr/lib64/python3.3/shutil.py", line 381, in _rmtree_safe_fd fullname = os.path.join(path, name) File "/usr/lib64/python3.3/posixpath.py", line 78, in join if b.startswith(sep): TypeError: startswith first arg must be str or a tuple of str, not bytes $ ---------- priority: normal -> release blocker resolution: fixed -> stage: committed/rejected -> status: closed -> open _______________________________________ Python tracker <report [at] bugs> <http://bugs.python.org/issue4489> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com
|