curl contains a heap out of buffer read vulnerability.
The command line tool has a generic function for displaying warning and informational messages to stderr for various situations. For example if an unknown command line argument is used, or passed to it in a "config" file.
This display function formats the output to wrap at 80 columns. The wrap logic is however flawed, so if a single word in the message is itself longer than 80 bytes the buffer arithmetic calculates the remainder wrong and ends up reading behind the end of the buffer. This could lead to information disclosure or crash.
This vulnerability could lead to a security issue if used in this or similar situations:
{ "CWE": { "id": "CWE-125", "desc": "Out-of-bounds Read" }, "award": { "amount": "100", "currency": "USD" }, "URL": "https://curl.se/docs/CVE-2018-16842.json", "package": "curl", "severity": "Low", "www": "https://curl.se/docs/CVE-2018-16842.html", "last_affected": "7.61.1" }