libcurl vulnerable to buffer overflow




Volema company have discovered a buffer overflow vulnerability in libcurl library for POP3 and SMTP protocol handler version 7.26.0, researcher published the exploit for the remote code execution.

the bug exist when negotiating SASL DIGEST-MD5 authentication, the function Curl_sasl_create_digest_md5_message() uses the data provided from the server without doing the proper length checks and that data is then appended to a local fixed-size buffer on the stack.

This vulnerability can be exploited by someone who is in control of a server that a libcurl based program is accessing with POP3, SMTP or IMAP. For applications that accept user provided URLs, it is also thinkable that a malicious user would feed an application with a URL to a server hosting code targeting this flaw.   This vulnerability can be used for remote code execution (RCE) on vulnerable systems.   Both curl the command line tool and applications using the libcurl library are vulnerable.

To fix this vulnerability you need to upgrade to curl and libcurl 7.29.0, rebuild curl with support for vulnerable protocols IMAP, POP3 and SMTP disabled and/or disable the vulnerable protocols IMAP, POP3 and SMTP at run-time to forbid libcurl from using them. there is already exploit published for this security bug.

Notify of
Inline Feedbacks
View all comments