libcurl's implementation of the printf() functions triggers a buffer overflow
when doing a large floating point output. The bug occurs when the conversion
outputs more than 255 bytes.
The flaw happens because the floating point conversion is using system
functions without the correct boundary checks.
The functions have been documented as deprecated for a long time and users are
discouraged from using them in "new programs" as they are planned to get
removed at a future point. But as the functions are present and there's
nothing preventing users from using them, we expect there to be a certain
amount of existing users in the wild.
If there are any application that accepts a format string from the outside
without necessary input filtering, it could allow remote attacks.
This flaw does not exist in the command line tool.
We are not aware of any exploit of this flaw.
Name: the Curl project
Created curl tracking bugs for this issue:
Affects: fedora-all [bug 1406716]
Created mingw-curl tracking bugs for this issue:
Affects: fedora-all [bug 1406717]
Affects: epel-7 [bug 1406718]
This flaw is present in the curl_*printf (curlx_*printf) family of functions, which are not used by curl but are exposed from libcurl. I can't find any of these functions being used across Enterprise Linux.
To be exposed, third-party code would need to be using these long-deprecated functions, with a floating-point specifier and user-controlled (floating-point) input. The overflow itself is of a 256-byte stack-allocated buffer, when the decimal expansion of the float exceeds that by up to 70 bytes. Beyond about 16 digits for a double, the decimal expansion is effectively random so the attacker has very little control over precisely what bytes are written. I think the chance of ACE can be discounted here.
This issue has been addressed in the following products:
Red Hat Software Collections for Red Hat Enterprise Linux 6
Red Hat Software Collections for Red Hat Enterprise Linux 7
Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
Via RHSA-2018:3558 https://access.redhat.com/errata/RHSA-2018:3558