Bug 528000
| Summary: | Tainted variables in sprintf format | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Patrick Monnerat <patrick> |
| Component: | perl-Image-ExifTool | Assignee: | Tom "spot" Callaway <tcallawa> |
| Status: | CLOSED WONTFIX | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | medium | Docs Contact: | |
| Priority: | low | ||
| Version: | 10 | CC: | boardhead62, perl-devel, tcallawa |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2009-12-18 09:44:35 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Patrick Monnerat
2009-10-08 15:05:04 UTC
Hrm. This will be tough to fix/report upstream without a way to reproduce it. There was problem with spamassasin which was workaround with rebuild of perl. But I made the change only in F-12 build. Could be the same issue? #510127 Here are some details. The lines causing the trouble are:
$format and $exifTool->Warn(
sprintf("Unknown format ($format) for $dirName tag 0x%x",$tagID));
So $format and/or $dirName are tainted. I'm not a Perl guy, so I can hardly backtrack these variable's sources (it even comes from out of the module), but I think the faulty statement can be rewritten as:
$format and $exifTool->Warn(
sprintf("Unknown format (%d) for %s tag 0x%x",$format,$dirName,$tagID));
in a more secure way that does not cause the taint problem, but at the expense of poorer readability, I agree.
From what I can see by examining Exif.pm, some other sprintf statements might be subject to similar problems (i.e.: lines 2918, 2941, 2972, ...).
I apologize for not being able to reproduce, but the line is reached when there is an unknown format in an Exif directory of a picture that I do not have anymore (rejected by SpamAssassin!)
Whether the current bug is related to bug 510127 or not is out of my Perl understanding... and since I do not know how to reproduce, I cannot even test it on rawhide :-( Sorry and thanks for the proposal.
You can try latest rebuild of perl for F-10. It will be in testing updates in few days or download from: http://koji.fedoraproject.org/koji/buildinfo?buildID=135920 If this generates taint errors, I'm surprised that exiftool doesn't
generate more. The value of $format is obtained from an unpack('S',...)
call, so the result is guaranteed to be either undefined or a number
in the range 0 to 65535. How is this a security problem when used
in a sprintf format string?
This message is a reminder that Fedora 10 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 10. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '10'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 10's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 10 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping Fedora 10 changed to end-of-life (EOL) status on 2009-12-17. Fedora 10 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. Thank you for reporting this bug and we are sorry it could not be fixed. |