Bug 871617 (CVE-2012-4561) - CVE-2012-4561 libssh: multiple invalid free() flaws
Summary: CVE-2012-4561 libssh: multiple invalid free() flaws
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2012-4561
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 861968 878521
Blocks: 815693
TreeView+ depends on / blocked
 
Reported: 2012-10-30 21:09 UTC by Vincent Danen
Modified: 2019-09-29 12:56 UTC (History)
4 users (show)

Fixed In Version: libssh 0.5.3
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-16 12:39:08 UTC
Embargoed:


Attachments (Terms of Use)
CVE-2012-4561-Fix-error-handling-of-try_publickey_fr.patch (1.85 KB, patch)
2012-11-14 08:49 UTC, Andreas Schneider
no flags Details | Diff
CVE-2012-4561-Fix-possible-free-s-on-invalid-pointer.patch (1.61 KB, patch)
2012-11-14 08:50 UTC, Andreas Schneider
no flags Details | Diff
CVE-2012-4561-Fix-error-handling-of-try_publickey_fr.patch (1.85 KB, patch)
2012-11-14 16:45 UTC, Andreas Schneider
no flags Details | Diff
CVE-2012-4561-Fix-possible-free-s-on-invalid-pointer.patch (1.61 KB, patch)
2012-11-14 16:45 UTC, Andreas Schneider
no flags Details | Diff

Description Vincent Danen 2012-10-30 21:09:58 UTC
Florian Weimer of the Red Hat Product Security Team reported the existence of several unitialized heap allocations in the following functions:

keys.c:publickey_make_dss() (key)
keys.c:publickey_make_rsa() (key)
keys.c:signature_from_string() (sign)
keys.c:ssh_do_sign() (sign)
keys.c:ssh_sign_session_id() (sign)

This could lead to freeing an invalid pointer on an error path, which could lead to a crash in the process using libssh.

Comment 1 Andreas Schneider 2012-11-14 08:49:57 UTC
Created attachment 644662 [details]
CVE-2012-4561-Fix-error-handling-of-try_publickey_fr.patch

Comment 2 Andreas Schneider 2012-11-14 08:50:19 UTC
Created attachment 644663 [details]
CVE-2012-4561-Fix-possible-free-s-on-invalid-pointer.patch

Comment 3 Andreas Schneider 2012-11-14 16:45:10 UTC
Created attachment 644998 [details]
CVE-2012-4561-Fix-error-handling-of-try_publickey_fr.patch

Comment 4 Andreas Schneider 2012-11-14 16:45:37 UTC
Created attachment 644999 [details]
CVE-2012-4561-Fix-possible-free-s-on-invalid-pointer.patch

Comment 5 Vincent Danen 2012-11-20 15:27:35 UTC
Fixed upstream:

http://www.libssh.org/2012/11/20/libssh-0-5-3-security-release/

Comment 6 Vincent Danen 2012-11-20 15:35:48 UTC
Created libssh tracking bugs for this issue

Affects: fedora-all [bug 878521]

Comment 7 Fedora Update System 2012-11-27 05:29:46 UTC
libssh-0.5.3-1.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2012-11-29 04:00:50 UTC
libssh-0.5.3-1.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2012-11-29 06:03:52 UTC
libssh-0.5.3-1.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2012-12-06 06:57:48 UTC
libssh-0.5.3-1.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.