Bug 581416 - [fix available] tmp files written to / (mktemp unsupported --tmpdir)
Summary: [fix available] tmp files written to / (mktemp unsupported --tmpdir)
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: openoffice.org
Version: 5.5
Hardware: All
OS: Linux
low
high
Target Milestone: rc
: ---
Assignee: Caolan McNamara
QA Contact: desktop-bugs@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-04-12 08:17 UTC by Tuomo Soini
Modified: 2012-06-08 15:36 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-08 15:36:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
proposed patch (715 bytes, patch)
2010-04-12 09:16 UTC, Tuomo Soini
no flags Details | Diff

Description Tuomo Soini 2010-04-12 08:17:27 UTC
Description of problem:

openoffice.org-3.1.1 has program unopkg which is used when 3rd party components like openoffice.org-voikko are installed.

/usr/lib64/openoffice.org3/program/unopkg has wrong arguments to mktemp causing empty variable for temporary directory.

INSTDIR=`/bin/mktemp -d --tmpdir unoinstall.XXXXXX`

--tmpdir is not valid option and this causes variable INSTDIR being empty.

This means that temporary files are written to /.

At the end of the unopkg there is another failure caused by this, only -n check is preventing removing whatever...

if [ -n "$INSTDIR" ]; then
   rm -rf $INSTDIR
fi

Suggested fix:

INSTDIR=`/bin/mktemp -d /tmp/unoinstall.XXXXXX`
[ $? -gt 0 ] && INSTDIR=/tmp/unoinstall.$$

That would make sure that wrong parameters for mktemp cause at least some randomization and make sure there is no possibility for empty install dir.

Comment 1 Caolan McNamara 2010-04-12 08:31:01 UTC
RHEL-5's mktemp doesn't support --tmpdir, should use -t instead on RHEL-5

Comment 2 Tuomo Soini 2010-04-12 09:16:54 UTC
Created attachment 405913 [details]
proposed patch

Comment 3 Tuomo Soini 2010-04-12 09:18:37 UTC
I guess it's best option to refuse to run command if tmpdir creation fail.

Comment 5 RHEL Program Management 2010-08-09 18:30:23 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 6 RHEL Program Management 2011-01-11 20:49:47 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 7 RHEL Program Management 2011-01-11 23:17:08 UTC
This request was erroneously denied for the current release of
Red Hat Enterprise Linux.  The error has been fixed and this
request has been re-proposed for the current release.

Comment 8 RHEL Program Management 2011-05-31 13:31:06 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 10 RHEL Program Management 2011-09-23 00:15:38 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 12 Caolan McNamara 2012-06-08 15:36:02 UTC
This should be fixed as a side effect of rebasing to LibreOffice 3.4.5


Note You need to log in before you can comment on or make changes to this bug.