Bug 1316481 (CVE-2016-2563)

Summary: CVE-2016-2563 putty: old-style scp downloads may allow remote code execution
Product: [Other] Security Response Reporter: Andrej Nemec <anemec>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED UPSTREAM QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: fedora, jskarvad, tremble
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: putty 0.67 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 02:49: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:
Bug Depends On: 1316482, 1316485, 1316486    
Bug Blocks:    

Description Andrej Nemec 2016-03-10 11:01:40 UTC
Prior to any download in the SCP sink protocol, the server sends a line of text consisting of an octal number encoding Unix file permissions, a decimal number encoding the file size, and the file name. Since the file size can exceed 232 bytes, and in some compilation configurations of PuTTY the host platform's largest integer type is only 32 bits wide, PuTTY extracts the decimal file size into a temporary string variable to send to its own 64-bit decimal decoding function. Unfortunately, that extraction was done carelessly, using a sscanf with no length limit, permitting a buffer overrun.

External references:

http://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/vuln-pscp-sink-sscanf.html
http://seclists.org/fulldisclosure/2016/Mar/22

Upstream fix:

http://tartarus.org/~simon-git/gitweb/?p=putty.git;a=commit;h=bc6c15ab5f636e05b7e91883f0031a7e06117947

Comment 1 Andrej Nemec 2016-03-10 11:02:22 UTC
Created putty tracking bugs for this issue:

Affects: fedora-all [bug 1316482]
Affects: epel-6 [bug 1316485]
Affects: epel-5 [bug 1316486]

Comment 2 Fedora Update System 2016-03-29 17:21:50 UTC
putty-0.63-6.el5 has been pushed to the Fedora EPEL 5 stable repository. If problems still persist, please make note of it in this bug report.

Comment 3 Fedora Update System 2016-03-29 18:23:15 UTC
putty-0.63-6.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.

Comment 4 Product Security DevOps Team 2019-06-08 02:49:35 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.