Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 114499
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo's Team for Core System packages <base-system@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Sune Kloppenborg Jeppesen <jaervosz@gentoo.org>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
texinfo-4.8-owl-texindex-tmp.diff texinfo-4.8-owl-texindex-tmp.diff patch Thierry Carrez (RETIRED) 2005-12-20 04:07 0000 2.60 KB Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 114499 depends on: Show dependency tree
Bug 114499 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-12-04 22:06 0000
Seems like there might be problems with the patch on bug #106105 
 
It looks like the fix for CAN-2005-3011 (texinfo predictable temporary  
files issue) being used by ubuntu and others is incorrect (see below).  
  
Does anyone have a better and/or officially blessed (does texinfo have  
a maintainer?) patch for this?  
  
Colin Percival  
  
-------- Original Message --------  
Subject: [csjp@FreeBSD.org: Re: Ubuntu patch for texinfo (CAN-2005-3011)]  
Date: Sat, 3 Dec 2005 19:11:12 +0000  
From: Christian S.J. Peron <csjp@freebsd.org>  
To: secteam@freebsd.org  
  
Colin / team  
  
I sent this message to Martin Pitt a while ago, but I have not recieved  
any response. Who owns texinfo?  
  
I am sure we can roll our own fix but I would rather whoever maintains this  
program provide a security fix.  
  
  
Any ideas?  
  
----- Forwarded message from "Christian S.J. Peron" <csjp@FreeBSD.org> -----  
  
From: "Christian S.J. Peron" <csjp@FreeBSD.org>  
To: martin.pitt@canonical.com  
Date: Sun, 13 Nov 2005 05:43:34 +0000  
Subject: Re: Ubuntu patch for texinfo (CAN-2005-3011)  
  
On Don, 06 Okt 2005, Martin Pitt wrote:  
> Since the previously proposed patch is very intrusive and not really  
> appropriate for a security update, I created my own minimal patch:  
>   
>   http://patches.ubuntu.com/patches/texinfo.CAN-2005-3011.diff  
  
After discussing this fix with some of my colleagues, it appears that  
your fix makes it impossible to unlink the temporary files.  
  
void  
flush_tempfiles (int to_count)  
{  
  if (keep_tempfiles)  
    return;  
  while (last_deleted_tempcount < to_count)  
    unlink (maketempname (++last_deleted_tempcount));  
}  
  
flush_tempfiles would result in texindex exiting via EEXIST, because now  
maketempname actually creates the files with the O_EXCL flag. Although  
this fixes the race condition, it changes the behavior of the program.  
  
Was this intentional or am I missing something here?  
  
--   
Christian S.J. Peron  
csjp@FreeBSD.ORG  
FreeBSD Committer  
FreeBSD Security Team  
  
----- End forwarded message -----  
  
--   
Christian S.J. Peron  
csjp@FreeBSD.ORG  
FreeBSD Committer  
FreeBSD Security Team  
_______________________________________________________  
Please think twice when forwarding, cc:ing, or bcc:ing  
security-team messages.  Ask if you are unsure.

------- Comment #1 From Sune Kloppenborg Jeppesen 2005-12-05 00:34:04 0000 -------
http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/texinfo/ 
 
texinfo-4.8-owl-texindex-tmp.diff is our current patch.  Older versions 
of it (for older versions of texinfo) may be found in the Attic. 
Originally, this was a part of texinfo-4.0-owl-tmp.diff, which I entered 
with this comment: 
 
* Wed Jan 03 2001 Solar Designer <solar-at-owl.openwall.com> 
- Patch to create temporary files safely. 
- Give offline sorting in texindex a chance to work (fixed a bug in there; 
did anyone ever test that code, it certainly looks like not). 
 
This patch has the disadvantage of producing a spurious link-time warning 
about mktemp() (although the surrounding code makes this call safe). 
This is because we still had glibc 2.1.3 at the time.  This should be 
updated to use mkdtemp() now (the change is trivial). 
 
--  
/sd 

------- Comment #2 From Thierry Carrez (RETIRED) 2005-12-09 06:56:41 0000 -------
Ccing vapier so that he doublechecks Gentoo's status on this.

------- Comment #3 From Thierry Carrez (RETIRED) 2005-12-13 10:18:01 0000 -------
vapier: any hint on our vulnerability status here ?

------- Comment #4 From Thierry Carrez (RETIRED) 2005-12-20 04:06:19 0000 -------
We use a patch based on Martin Pitt's one.
Apparently would be better to use the patch from Openwall, which I'll attach
here.

Note that this is not a security issue, since Martin Pitt's patch solves the
security problem, it just changes the way texindex is supposed to work, so it
would be a bug.

------- Comment #5 From Thierry Carrez (RETIRED) 2005-12-20 04:07:41 0000 -------
Created an attachment (id=75188) [details]
texinfo-4.8-owl-texindex-tmp.diff

New patch, from Owl

------- Comment #6 From SpanKY 2006-02-07 22:30:54 0000 -------
4.8-r3 uses the patch here

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug