Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1731324 (CVE-2019-13115)
Summary: | CVE-2019-13115 libssh2: integer overflow in kex_method_diffie_hellman_group_exchange_sha256_key_exchange in kex.c leads to out-of-bounds write | ||
---|---|---|---|
Product: | [Other] Security Response | Reporter: | Dhananjay Arunesh <darunesh> |
Component: | vulnerability | Assignee: | Red Hat Product Security <security-response-team> |
Status: | CLOSED ERRATA | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | unspecified | CC: | djuran, kdudka, paul |
Target Milestone: | --- | Keywords: | Security |
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | libssh2 1.9.0 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2021-10-27 10:46:54 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: | 1731325, 1732662, 1732663, 1732664, 1732666 | ||
Bug Blocks: |
Description
Dhananjay Arunesh
2019-07-19 06:12:16 UTC
Created libssh2 tracking bugs for this issue: Affects: fedora-all [bug 1731325] Upstream patch at: https://github.com/doorsdown/libssh2/commit/7e7189e013db15c6306fab0ddb38c020c0de81ed Public reproducer: https://github.com/Semmle/SecurityExploits/tree/446048470633bf0f8da9570d008d056dbaa28ea9/libssh2/out_of_bounds_read_kex_CVE-2019-13115 External References: https://blog.semmle.com/libssh2-integer-overflow/ This is an out-of-bounds read flaw in libssh2, which can be triggered by a malicious MITM SSH server. The flaw can be triggered during the initial Diffie-Hellman key change, therefore no authentication is required by the attacker. This flaw can cause applications compiled with libssh2 to crash. However, I believe that a more carefully chosen offset could lead to an information disclosure as it appears that the memory which is read is subsequently returned to the server. The exploitability will depend on the heap layout. In libssh2 versions after 1.8.2 the flaw exists in the function _libssh2_check_length(). Older versions however have no bounds checking at all, and the flaw manifests itself at: https://github.com/libssh2/libssh2/blob/02ecf17a6d5f9837699e8fb3aad0c804caa67eeb/src/kex.c#L1675 The problem is that p_len contains an untrusted value, so the subsequent reads from s could be out-of-bounds. (In reply to Huzaifa S. Sidhpurwala from comment #2) > Upstream patch at: > https://github.com/doorsdown/libssh2/commit/ > 7e7189e013db15c6306fab0ddb38c020c0de81ed The above URL refers to some non-authoritative fork of the project. This seems to be the actual upstream commit: https://github.com/libssh2/libssh2/commit/ff1b1557 |