<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>207331</bug_id>
          <alias>CVE-2008-0386</alias>
          <creation_ts>2008-01-25 00:42 0000</creation_ts>
          <short_desc>x11-misc/xdg-utils &lt; 1.0.2-r1: xdg-open/email URL arbitrary command execution (CVE-2008-0386)</short_desc>
          <delta_ts>2008-01-30 23:14:29 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Security</product>
          <component>Vulnerabilities</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          <bug_file_loc>https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2008-0386</bug_file_loc>
          <status_whiteboard>A2 [glsa]</status_whiteboard>
          
          <priority>P2</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>rbu@gentoo.org</reporter>
          <assigned_to>security@gentoo.org</assigned_to>
          <cc>pva@gentoo.org</cc>
    
    <cc>ssuominen@gentoo.org</cc>

      

      
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-25 00:42:09 0000</bug_when>
            <thetext>Miroslav Lichvar discovered that xdg-open allows for arbitrary command
execution in case the URL can not be handled by KDE, GNOME, XFCE or
mimeopen.

The vulnerable line:
  browser_with_arg=`echo &quot;$browser&quot; | sed s#%s#&quot;$1&quot;#`
should be rewritten as:
  browser_with_arg=${browser//&apos;%s&apos;/&quot;$1&quot;}

according to upstream.

This issue is under embargo until Monday, Jan 28. Drac and pva, please create an updated ebuild and attach it to this bug if you want pre-stable testing to commit straight to stable on the date of the disclosure.
Do not commit anything to CVS yet.

If you want someone else to take care of this issue, please cc him/her on this bug.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-25 00:43:36 0000</bug_when>
            <thetext>This affects xdg-email, too.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-25 00:54:45 0000</bug_when>
            <thetext>That ${} is bash only, in case that is relevant (might need editing the #!)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-25 14:25:58 0000</bug_when>
            <thetext>Patches are upstream, so this is semi-public. Please commit patches in the tree.

http://webcvs.freedesktop.org/portland/portland/xdg-utils/scripts/xdg-open.in?r1=1.17&amp;r2=1.18&amp;view=patch
http://webcvs.freedesktop.org/portland/portland/xdg-utils/scripts/xdg-open?r1=1.32&amp;r2=1.33&amp;view=patch
http://webcvs.freedesktop.org/portland/portland/xdg-utils/scripts/xdg-email.in?r1=1.24&amp;r2=1.25&amp;view=patch
http://webcvs.freedesktop.org/portland/portland/xdg-utils/scripts/xdg-email?r1=1.36&amp;r2=1.37&amp;view=patch
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>pva@gentoo.org</who>
            <bug_when>2008-01-26 09:31:31 0000</bug_when>
            <thetext>xdg-utils-1.0.2-r1.ebuild with fix applied commited.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-26 12:16:02 0000</bug_when>
            <thetext>The &quot;commit straight to stable&quot; part in my original message was meant as in &quot;if you attach the ebuild here, Arch Liaisons can test it and we can commit to stable afterwards&quot;.

Moving to [glsa] then.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rbu@gentoo.org</who>
            <bug_when>2008-01-29 04:03:29 0000</bug_when>
            <thetext>public via $url</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>py@gentoo.org</who>
            <bug_when>2008-01-30 23:14:29 0000</bug_when>
            <thetext>GLSA 200801-21</thetext>
          </long_desc>
      
    </bug>

</bugzilla>