{"id":"CVE-2017-1000257","aliases":["CVE-2017-1000257","CURL-CVE-2017-1000257"],"related":[],"kind":"vulnerability","state":"published","title":"IMAP FETCH response out of bounds read","summary":"An IMAP FETCH response line indicates the size of the returned data, in number of bytes. When that response says the data is zero bytes, libcurl would pass on that (non-existing) data with a pointer and the size (zero) to the deliver-data function. libcurl's deliver-data function treats zero as a magic number and invokes strlen() on the data to figure out the length. The strlen() is called on a heap based buffer that might not be zero terminated so libcurl might read beyond the end of it into whatever memory lies after (or just crash) and then deliver that to the application as if it was actually downloaded.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"An IMAP FETCH response line indicates the size of the returned data, in number of bytes. When that response says the data is zero bytes, libcurl would pass on that (non-existing) data with a pointer and the size (zero) to the deliver-data function. libcurl's deliver-data function treats zero as a magic number and invokes strlen() on the data to figure out the length. The strlen() is called on a heap based buffer that might not be zero terminated so libcurl might read beyond the end of it into whatever memory lies after (or just crash) and then deliver that to the application as if it was actually downloaded.","source":"cvelist"},{"lang":"en","text":"libcurl contains a buffer overrun flaw in the IMAP handler.\n\nAn IMAP FETCH response line indicates the size of the returned data, in number\nof bytes. When that response says the data is zero bytes, libcurl would pass\non that (non-existing) data with a pointer and the size (zero) to the\ndeliver-data function.\n\nlibcurl's deliver-data function treats zero as a magic number and invokes\nstrlen() on the data to figure out the length. The strlen() is called on a\nheap based buffer that might not be null-terminated so libcurl might read\nbeyond the end of it into whatever memory lies after (or crash) and then\ndeliver that to the application as if it was actually downloaded.","format":"markdown","source":"curl"},{"lang":"es","text":"Una línea de respuesta IMAP FETCH indica el tamaño de los datos devueltos en número de bytes. Cuando una respuesta indica que el tamaño de los datos es cero bytes, libcurl pasaría esos datos (inexistentes) con un puntero y el tamaño (cero) a la función deliver-data. La función deliver-data de libcurl trata el cero como un número mágico e invoca strlen() en los datos para adivinar la longitud. Se llama a strlen() en un búfer basado en memoria dinámica (heap) que podría no terminar en cero, por lo que libcurl podría leer más allá del final del búfer en cualquier memoria en la que se encuentre después (o simplemente provocar un cierre inesperado) y entregar los datos a la aplicación como si en realidad se hubieran descargado.","source":"nvd"}],"published":"2017-10-23T08:00:00.000Z","modified":"2026-10-25T01:05:07.031Z","severity":{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","score":9.1,"rating":"CRITICAL"},"severities":[{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","score":9.1,"rating":"CRITICAL"},{"scorer":"curl","scheme":"rating","rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H","score":9.1,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:N/C:P/I:N/A:P","score":6.4,"rating":"MEDIUM"}],"cwes":["CWE-119"],"affected":[{"ranges":[{"version":"n/a","status":"affected"}],"source":"cvelist"},{"ranges":[{"type":"semver","introduced":"7.20.0","status":"affected","fixed":"7.56.1"},{"type":"git","introduced":"ec3bb8f727405642a471b4b1b9eb0118fc003104","status":"affected","fixed":"13c9a9ded3ae744a1e11cbc14e9146d9fa427040"}],"repo":"https://github.com/curl/curl.git","source":"curl"},{"ranges":[{"status":"affected","introduced":"7.20.0","lastAffected":"7.56.0"}],"vendor":"haxx","product":"libcurl","cpe":"cpe:2.3:a:haxx:libcurl:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"8.0"},{"status":"affected","version":"9.0"}],"vendor":"debian","product":"debian_linux","cpe":"cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://curl.haxx.se/docs/adv_20171023.html","tags":["vendor-advisory","x-refsource-confirm","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://access.redhat.com/errata/RHSA-2017:3263","tags":["vendor-advisory","x-refsource-redhat","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://security.gentoo.org/glsa/201712-04","tags":["vendor-advisory","x-refsource-gentoo","x-transferred"],"sources":["cvelist","nvd"]},{"url":"http://www.securitytracker.com/id/1039644","tags":["third-party-advisory","vdb-entry","x-refsource-sectrack","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://access.redhat.com/errata/RHSA-2018:3558","tags":["vendor-advisory","x-refsource-redhat","x-transferred"],"sources":["cvelist","nvd"]},{"url":"http://www.securityfocus.com/bid/101519","tags":["third-party-advisory","vdb-entry","x-refsource-bid","x-transferred"],"sources":["cvelist","nvd"]},{"url":"http://www.debian.org/security/2017/dsa-4007","tags":["third-party-advisory","vendor-advisory","x-refsource-debian","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://access.redhat.com/errata/RHSA-2018:2486","tags":["vendor-advisory","x-refsource-redhat","x-transferred"],"sources":["cvelist","nvd"]}],"credits":["Brian Carpenter (Geeknik Labs)","0xd34db347","Daniel Stenberg"],"assigner":"mitre","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-04-15T21:02:33.578Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2017-1000257","url":"https://www.cve.org/CVERecord?id=CVE-2017-1000257","licence":"CVE Terms of Use","modified":"2026-04-15T21:02:38.720Z"},{"source":"curl","name":"curl","id":"CURL-CVE-2017-1000257","url":"https://osv.dev/vulnerability/CURL-CVE-2017-1000257","licence":"MIT","modified":"2026-10-25T01:05:07.031Z"},{"source":"nvd","name":"NVD","id":"CVE-2017-1000257","url":"https://nvd.nist.gov/vuln/detail/CVE-2017-1000257","licence":"Public domain","modified":"2026-06-17T00:59:00.403Z"}],"updatedAt":"2026-11-25T22:57:33.359Z","epss":{"score":0.06224,"percentile":0.93684,"date":"2026-12-01T12:00:22.000Z"}}