Bug 985633 (CVE-2013-4136)

Summary: CVE-2013-4136 rubygem-passenger: insecure temporary directory usage due to reuse of existing server instance directories
Product: [Other] Security Response Reporter: Vincent Danen <vdanen>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: bleanhar, brett.lentz, ccoleman, dmcphers, jialiu, lmeyer, tdawson, tkramer, vanmeeuwen+fedora
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard: impact=moderate,public=20130620,reported=20130715,source=oss-security,cvss2=4.6/AV:L/AC:L/Au:N/C:P/I:P/A:P,fedora-all/rubygem-passenger=affected,epel-6/rubygem-passenger=affected,openshift-1/rubygem-passenger=affected,openshift-1/ruby193-rubygem-passenger=affected,openshift-enterprise-1/rubygem-passenger=affected,openshift-enterprise-1/ruby193-rubygem-passenger=affected
Fixed In Version: Phusion Passenger 4.0.8 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-07 01:14:05 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On: 985634, 988512, 988513    
Bug Blocks: 892814    
Attachments:
Description Flags
4.0.8 commits backported to 3.0.21 none

Description Vincent Danen 2013-07-17 20:09:32 EDT
It was reported [1],[2] that Phusion Passenger would reuse existing server instance directories (temporary directories) which could cause Passenger to remove or overwrite files belonging to other instances.  This has been corrected in upstream version 4.0.8 [3] via two fixes (the initial fix [4] and a regression fix [5]; both are required to fully fix the issue).  This is an issue similar to CVE-2013-2119.

[1] http://www.openwall.com/lists/oss-security/2013/07/15/2
[2] https://code.google.com/p/phusion-passenger/issues/detail?id=910
[3] http://blog.phusion.nl/2013/07/09/phusion-passenger-4-0-8-released/
[4] https://github.com/phusion/passenger/commit/5483b3292cc2af1c83033eaaadec20dba4dcfd9b
[5] https://github.com/phusion/passenger/commit/9dda49f4a3ebe9bafc48da1bd45799f30ce19566
Comment 1 Vincent Danen 2013-07-17 20:13:39 EDT
Created rubygem-passenger tracking bugs for this issue:

Affects: fedora-all [bug 985634]
Comment 2 Troy Dawson 2013-07-18 10:50:50 EDT
Created attachment 775343 [details]
4.0.8 commits backported to 3.0.21

Both commits to the 4.0.x branch backported fairly well into 3.0.21.
This is a combination of both commits into one patch.
Comment 4 Fedora Update System 2013-07-30 13:29:08 EDT
rubygem-passenger-3.0.21-4.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 5 Fedora Update System 2013-07-30 13:32:05 EDT
rubygem-passenger-3.0.21-4.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 6 Fedora Update System 2013-07-30 13:50:23 EDT
rubygem-passenger-3.0.21-4.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 7 errata-xmlrpc 2013-08-05 11:54:08 EDT
This issue has been addressed in following products:

  RHEL 6 Version of OpenShift Enterprise 1.2

Via RHSA-2013:1136 https://rhn.redhat.com/errata/RHSA-2013-1136.html
Comment 8 Fedora Update System 2013-08-05 19:31:13 EDT
rubygem-passenger-3.0.21-4.el6 has been pushed to the Fedora EPEL 6 stable repository.  If problems still persist, please make note of it in this bug report.