Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 316078 Details for
Bug 461477
CVE-2008-3521 jasper: temporary file creation race in jas_stream_tmpfile()
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
OpenBSD patch
jasper-CVE-2008-3521.diff (text/plain), 1.33 KB, created by
Tomas Hoger
on 2008-09-08 13:35:29 UTC
(
hide
)
Description:
OpenBSD patch
Filename:
MIME Type:
Creator:
Tomas Hoger
Created:
2008-09-08 13:35:29 UTC
Size:
1.33 KB
patch
obsolete
>diff -pruN jasper-1.900.1.orig2/src/libjasper/base/jas_stream.c jasper-1.900.1/src/libjasper/base/jas_stream.c >--- jasper-1.900.1.orig2/src/libjasper/base/jas_stream.c 2008-09-08 14:58:16.000000000 +0200 >+++ jasper-1.900.1/src/libjasper/base/jas_stream.c 2008-09-08 14:58:59.000000000 +0200 >@@ -361,28 +361,22 @@ jas_stream_t *jas_stream_tmpfile() > } > obj->fd = -1; > obj->flags = 0; >- obj->pathname[0] = '\0'; > stream->obj_ = obj; > > /* Choose a file name. */ >- tmpnam(obj->pathname); >+ snprintf(obj->pathname, L_tmpnam, "%stmp.XXXXXXXXXX", P_tmpdir); > > /* Open the underlying file. */ >- if ((obj->fd = open(obj->pathname, O_CREAT | O_EXCL | O_RDWR | O_TRUNC | O_BINARY, >- JAS_STREAM_PERMS)) < 0) { >+ if ((obj->fd = mkstemp(obj->pathname)) < 0) { > jas_stream_destroy(stream); > return 0; > } > > /* Unlink the file so that it will disappear if the program > terminates abnormally. */ >- /* Under UNIX, one can unlink an open file and continue to do I/O >- on it. Not all operating systems support this functionality, however. >- For example, under Microsoft Windows the unlink operation will fail, >- since the file is open. */ > if (unlink(obj->pathname)) { >- /* We will try unlinking the file again after it is closed. */ >- obj->flags |= JAS_STREAM_FILEOBJ_DELONCLOSE; >+ jas_stream_destroy(stream); >+ return 0; > } > > /* Use full buffering. */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 461477
: 316078