After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 569226 - gedit: untrusted python modules search path
gedit: untrusted python modules search path
Status: RESOLVED NOTGNOME
Product: totem
Classification: Core
Component: Plugins
unspecified
Other Linux
: Normal normal
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks: 569273
 
 
Reported: 2009-01-26 18:23 UTC by Bastien Nocera
Modified: 2009-02-02 14:30 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix the search path vulnerability (441 bytes, patch)
2009-01-26 23:21 UTC, Philip Withnall
rejected Details | Review

Description Bastien Nocera 2009-01-26 18:23:10 UTC
+++ This bug was initially created as a clone of Bug #569214 +++

(From Jan Lieskovsky, https://bugzilla.redhat.com/show_bug.cgi?id=481556)

"Untrusted search path vulnerability in gedit's Python module allows local
users to execute arbitrary code via a Trojan horse Python file in the
current working directory, related to an erroneous setting of sys.path
by the PySys_SetArgv function.

References:
http://www.nabble.com/Bug-484305%3A-bicyclerepair%3A-bike.vim-imports-untrusted-python-files-from-cwd-td18848099.html

Debian bug report for similar eog issue:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=504352#4

Proposed patch:
Not sure, if gedi'ts upstream has been reported about this issue.
The Debian patch for similar eog's Python related issue,
available at:

http://bugs.debian.org/cgi-bin/bugreport.cgi?msg=5;filename=02_sanitize_sys.path.patch;att=1;bug=504352

should be sufficient to resolve this issue."

There's no CVE assigned yet, but one has been requested.  The security severity is considered "low".
Comment 1 Philip Withnall 2009-01-26 23:21:23 UTC
Created attachment 127299 [details] [review]
Fix the search path vulnerability

Patch based on Ray Strode's gedit patch here: http://bugzilla.gnome.org/show_bug.cgi?id=569214#c5

Tested to work with his test case, which previously successfully exploited the vulnerability in Totem.

Should we also commit this to gnome-2-24?
Comment 2 Bastien Nocera 2009-02-02 14:30:58 UTC
Bug in Python really, won't be working around it.