<?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>66355</bug_id>
          
          <creation_ts>2004-10-04 15:00 0000</creation_ts>
          <short_desc>sys-devel/gettext: Insecure tempfile handling</short_desc>
          <delta_ts>2004-10-16 22:16:51 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Security</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          <bug_file_loc>http://www.securityfocus.com/advisories/7263</bug_file_loc>
          <status_whiteboard>A3 [glsa] lewk</status_whiteboard>
          
          <priority>P2</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>lewk@gentoo.org</reporter>
          <assigned_to>security@gentoo.org</assigned_to>
          <cc>gentoo@geb.ep.wisc.edu</cc>

      

      
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-04 15:00:47 0000</bug_when>
            <thetext>Problem description:

  Trustix Security Engineers identified that all these packages had one or
  more script(s) that handled temporary files in an insecure manner.  While
  it is not believed that any of these holes could lead to privilege
  escalation, it would be possible to trick the scripts to overwrite data
  writable by the user that invokes the script.

  These problems can only be exploited by local users, and they would have to
  wait for someone else, preferably root, to run the vulnerable scripts.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-04 15:01:52 0000</bug_when>
            <thetext>Created an attachment (id=41095)
gettext-0.14.1-tempfile.patch

Patch from Trustix to fix tempfile insecurities.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-04 15:04:34 0000</bug_when>
            <thetext>base-system guys,

please verify and apply patch if necessary.  The stable version of gettext, 0.12.1, seems to be vulnerable to this as well.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>solar@gentoo.org</who>
            <bug_when>2004-10-04 21:36:23 0000</bug_when>
            <thetext>The newest revision we have in portage right now is gettext-0.12.1-r1 looks like we might want to consider a newer version all together. 
testing..</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>solar@gentoo.org</who>
            <bug_when>2004-10-04 21:41:07 0000</bug_when>
            <thetext>Oh even better Mike Frysinger just told me he is already working on this one.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-05 05:43:07 0000</bug_when>
            <thetext>version bumped in cvs; everyone needs loving on this one</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-05 06:11:46 0000</bug_when>
            <thetext>archs, please mark gettext-0.14.1 stable.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lv@gentoo.org</who>
            <bug_when>2004-10-05 08:04:17 0000</bug_when>
            <thetext>stable on amd64...</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>kloeri@gentoo.org</who>
            <bug_when>2004-10-05 08:39:40 0000</bug_when>
            <thetext>Stable on alpha.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-05 15:50:22 0000</bug_when>
            <thetext>arm/hppa/ia64/s390 == OUTTA SIGHT</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>gustavoz@gentoo.org</who>
            <bug_when>2004-10-05 18:51:55 0000</bug_when>
            <thetext>I&apos;m getting failed tests: format-java-1 and format-java-2 with bus errors.
This passed on gettext-0.12.1 so it&apos;s somewhat suspicious, did anyone test this on != sparc?
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>sejo@gentoo.org</who>
            <bug_when>2004-10-06 01:40:29 0000</bug_when>
            <thetext>stable on ppc</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>sejo@gentoo.org</who>
            <bug_when>2004-10-06 04:52:17 0000</bug_when>
            <thetext>Since i installed gettext 0.14.1 i get this error, can someone see to this?

/usr/bin/xgettext: error while loading shared libraries: libgettextlib-0.12.1.so: cannot open shared object file: No such file or directory

putted back to ~ppc untill the problem is solved
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-06 05:53:33 0000</bug_when>
            <thetext>/usr/bin/xgettext: error while loading shared libraries: libgettextlib-0.12.1.so: cannot open shared object file: No such file or directory

the fix is to run revdep-rebuild :P</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>gustavoz@gentoo.org</who>
            <bug_when>2004-10-06 06:10:33 0000</bug_when>
            <thetext>sparc stable, with conjured patch for the java tests.
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tester@gentoo.org</who>
            <bug_when>2004-10-06 07:08:21 0000</bug_when>
            <thetext>well, xgettext is part of gettext.. So revdep-rebuild doesnt help much here.. Is it being built against the system installed gettext instead of the version in its own directory? Btw, it seems to have built correctly here. 
I think 66485 is a dupe... and this one is on x86.. I&apos;m holding it off on stabilizing on x86 until this is sorted out.. </thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tester@gentoo.org</who>
            <bug_when>2004-10-06 16:48:12 0000</bug_when>
            <thetext>*** Bug 66485 has been marked as a duplicate of this bug. ***</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-06 22:08:16 0000</bug_when>
            <thetext>masked 0.14.1 ... i&apos;ll release a new 0.12.1-r# with the patch</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>koon@gentoo.org</who>
            <bug_when>2004-10-07 01:40:04 0000</bug_when>
            <thetext>Back to ebuild status, current ebuild breaks things.
NB to sec team: tempfile attacks are &quot;3&quot; not &quot;4&quot;.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-07 16:59:33 0000</bug_when>
            <thetext>ok, i&apos;ve added gettext-0.12.1-r2 to portage with the patch posted here ... one of the hunks is not relevant to 0.12.1 since it removes code that was added to gettext after this release

lets try stablizing again shall we</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-07 18:06:52 0000</bug_when>
            <thetext>archs, please mark gettext-0.12.1-r2 stable.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>eradicator@gentoo.org</who>
            <bug_when>2004-10-07 22:02:07 0000</bug_when>
            <thetext>stable x86 and amd64</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>eradicator@gentoo.org</who>
            <bug_when>2004-10-07 23:08:46 0000</bug_when>
            <thetext>stable on sparc</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>sejo@gentoo.org</who>
            <bug_when>2004-10-08 02:07:56 0000</bug_when>
            <thetext>stable on ppc
but QA isn&apos;t ok: The patch is bigger then 20K!!!

</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>gmsoft@gentoo.org</who>
            <bug_when>2004-10-08 07:34:03 0000</bug_when>
            <thetext>done on hppa.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>kloeri@gentoo.org</who>
            <bug_when>2004-10-09 02:37:17 0000</bug_when>
            <thetext>Stable on alpha.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-10-09 18:01:57 0000</bug_when>
            <thetext>arm/ia64/s390 done</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tgall@gentoo.org</who>
            <bug_when>2004-10-09 19:41:58 0000</bug_when>
            <thetext>stable on ppc64, thanks!</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>lewk@gentoo.org</who>
            <bug_when>2004-10-10 15:32:37 0000</bug_when>
            <thetext>GLSA 200410-10

mips, please mark stable to benefit from GLSA.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>hardave@gentoo.org</who>
            <bug_when>2004-10-16 22:16:51 0000</bug_when>
            <thetext>Stable on mips.</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>41095</attachid>
            <date>2004-10-04 15:01 0000</date>
            <desc>gettext-0.14.1-tempfile.patch</desc>
            <filename>gettext-0.14.1-tempfile.patch</filename>
            <type>text/plain</type>
            <data encoding="base64">ZGlmZiAtdXIgZ2V0dGV4dC0wLjE0LjEub3JpZy9nZXR0ZXh0LXRvb2xzL21pc2MvYXV0b3BvaW50
LmluIGdldHRleHQtMC4xNC4xL2dldHRleHQtdG9vbHMvbWlzYy9hdXRvcG9pbnQuaW4KLS0tIGdl
dHRleHQtMC4xNC4xLm9yaWcvZ2V0dGV4dC10b29scy9taXNjL2F1dG9wb2ludC5pbgkyMDA0LTAx
LTI5IDIwOjE3OjI3LjAwMDAwMDAwMCArMDEwMAorKysgZ2V0dGV4dC0wLjE0LjEvZ2V0dGV4dC10
b29scy9taXNjL2F1dG9wb2ludC5pbgkyMDA0LTA5LTIwIDEwOjI2OjE0LjAwMDAwMDAwMCArMDIw
MApAQCAtMzksMTQgKzM5LDcgQEAKICAgICAqLyogfCAqXFwqKSA7OwogICAgICopICMgTmVlZCB0
byBsb29rIGluIHRoZSBQQVRILgogICAgICAgaWYgdGVzdCAiJHtQQVRIX1NFUEFSQVRPUitzZXR9
IiAhPSBzZXQ7IHRoZW4KLSAgICAgICAgeyBlY2hvICIjISAvYmluL3NoIjsgZWNobyAiZXhpdCAw
IjsgfSA+IC90bXAvY29uZiQkLnNoCi0gICAgICAgIGNobW9kICt4IC90bXAvY29uZiQkLnNoCi0g
ICAgICAgIGlmIChQQVRIPSIvbm9uZXhpc3RlbnQ7L3RtcCI7IGNvbmYkJC5zaCkgPi9kZXYvbnVs
bCAyPiYxOyB0aGVuCi0gICAgICAg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0ICIke1BBVEhfU0VQQVJBVE9S
K3NldH0iICE9IHNldDsgdGhlbgotICAgICAgICB7IGVjaG8gIiMhIC9iaW4vc2giOyBlY2hvICJl
eGl0IDAiOyB9ID4gL3RtcC9jb25mJCQuc2gKLSAgICAgICAgY2htb2QgK3ggL3RtcC9jb25mJCQu
c2gKLSAgICAgICAgaWYgKFBBVEg9Ii9ub25leGlzdGVudDsvdG1wIjsgY29uZiQkLnNoKSA+L2Rl
di9udWxsIDI+JjE7IHRoZW4KLSAgICAgICAgICBQQVRIX1NFUEFSQVRPUj0nOycKLSAgICAgICAg
ZWxzZQotICAgICAgICAgIFBBVEhfU0VQQVJBVE9SPToKLSAgICAgICAgZmkKLSAgICAgICAgcm0g
LWYgL3RtcC9jb25mJCQuc2gKKyAgICAgICAgUEFUSF9TRVBBUkFUT1I9OgogICAgICAgZmkKICAg
ICAgIHNhdmVfSUZTPSIkSUZTIjsgSUZTPSIkUEFUSF9TRVBBUkFUT1IiCiAgICAgICBmb3IgZGly
IGluICRQQVRIOyBkbwo=
</data>        

          </attachment>
    </bug>

</bugzilla>