Bug 810807 (CVE-2012-2107)

Summary: CVE-2012-2107 Csound: Integer overflow leading to buffer overflow in lpc_import
Product: [Other] Security Response Reporter: Huzaifa S. Sidhpurwala <huzaifas>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: jrusnack, paul, pbrobinson, znmeb
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: 2016-01-20 14:18:33 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: 812721    
Bug Blocks: 810821    

Description Huzaifa S. Sidhpurwala 2012-04-09 08:56:47 UTC
An integer overflow, leading to a heap-based buffer overflow was found in lpc_import utility. If a specially crafted CSV file was opened by the lpc_import utility, it could cause the application to crash or, potentially, execute arbitrary code with the privileges of the user running lpc_import

Reference:
http://secunia.com/secunia_research/2012-6/

Possible patch:
http://csound.git.sourceforge.net/git/gitweb.cgi?p=csound/csound5.git;a=commitdiff;h=61d1df45ca9a52bab62892a3c3a13c41e6384505#patch2

Comment 1 Huzaifa S. Sidhpurwala 2012-04-16 05:27:22 UTC
The commit date does not match the secunia advisory, but this seems to be the only commit which matches the flaw description.

coef = (MYFLT *)malloc((hdr.npoles+hdr.nvals)*sizeof(MYFLT)); would cause an integer overflow and later when data was copied into coef at:
fread(&coef[0], sizeof(MYFLT), hdr.npoles, inf); it would cause an heap-based buffer overflow as well.

Comment 2 Huzaifa S. Sidhpurwala 2012-04-16 05:30:24 UTC
Created csound tracking bugs for this issue

Affects: fedora-all [bug 812721]

Comment 3 Kurt Seifried 2012-04-16 19:33:33 UTC
Assigned CVE as per http://www.openwall.com/lists/oss-security/2012/04/16/9

Comment 4 Peter Robinson 2016-01-20 14:18:33 UTC
csound 6 is in all current releases (from GA)