Bug 1135624 (CVE-2014-5509)

Summary: CVE-2014-5509 perl-Clipboard: insecure temporary file usage
Product: [Other] Security Response Reporter: Vincent Danen <vdanen>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED UPSTREAM QA Contact:
Severity: low Docs Contact:
Priority: low    
Version: unspecifiedCC: iarnell, jrusnack, mkreder, perl-devel
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 02:34:43 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:
Bug Depends On: 1135625, 1135626    
Bug Blocks:    

Description Vincent Danen 2014-08-29 19:53:05 UTC
It was reported [1],[2] that the clipedit program as shipped with perl-Clipboard uses temporary files insecurely (based on the PID of the running program).  Using symlink attacks, an attacker could cause the deletion of arbitrary files that the user running clipedit has write access to.

 [...]
  7 my $tmpfilename = "/tmp/clipedit$$";  
  8 open my $tmpfile, ">$tmpfilename" or die "Failure to open $tmpfilename: $!";  
  9 print $tmpfile $orig;  
 10 close $tmpfile;
 [...]
 13 system($ed, $tmpfilename);  
 14   
 15 open $tmpfile, $tmpfilename or die "Failure to open $tmpfilename: $!";
 16 my $edited = join '', <$tmpfile>;
 [...]
 49 unlink($tmpfilename) or die "Couldn't remove $tmpfilename: $!";



[1] http://seclists.org/oss-sec/2014/q3/467
[2] https://rt.cpan.org/Public/Bug/Display.html?id=98435

Comment 1 Vincent Danen 2014-08-29 19:53:33 UTC
Created perl-Clipboard tracking bugs for this issue:

Affects: fedora-all [bug 1135625]
Affects: epel-7 [bug 1135626]

Comment 2 Murray McAllister 2014-09-01 03:15:46 UTC
MITRE assigned CVE-2014-5509 to this issue:

http://seclists.org/oss-sec/2014/q3/470

Comment 3 Product Security DevOps Team 2019-06-08 02:34:43 UTC
This CVE Bugzilla entry is for community support informational purposes only as it does not affect a package in a commercially supported Red Hat product. Refer to the dependent bugs for status of those individual community products.