{"id":"CURL-CVE-2017-8818","summary":"SSL out of buffer access","details":"libcurl contains an out boundary access flaw in SSL related code.\n\nWhen allocating memory for a connection (the internal struct called\n`connectdata`), a certain amount of memory is allocated at the end of the\nstruct to be used for SSL related structs. Those structs are used by the\nparticular SSL library libcurl is built to use. The application can also tell\nlibcurl which specific SSL library to use if it was built to support more than\none.\n\nThe math used to calculate the extra memory amount necessary for the SSL\nlibrary was wrong on 32-bit systems, which made the allocated memory too small\nby 4 bytes. The last struct member of the last object within the memory area\ncould then be outside of what was allocated. Accessing that member could lead\nto a crash or other undefined behaviors depending on what memory that is\npresent there and how the particular SSL library decides to act on that memory\ncontent.\n\nSpecifically the vulnerability is present if libcurl was built so that\n`sizeof(long long *) \u003c sizeof(long long)` which as far as we are aware only\nhappens in 32-bit builds.","aliases":["CVE-2017-8818"],"modified":"2026-04-25T20:30:34.325410Z","published":"2017-11-29T08:00:00Z","database_specific":{"last_affected":"7.56.1","affects":"both","CWE":{"id":"CWE-125","desc":"Out-of-bounds Read"},"URL":"https://curl.se/docs/CVE-2017-8818.json","package":"curl","www":"https://curl.se/docs/CVE-2017-8818.html","severity":"High"},"affected":[{"ranges":[{"type":"SEMVER","events":[{"introduced":"7.56.0"},{"fixed":"7.57.0"}]},{"type":"GIT","repo":"https://github.com/curl/curl.git","events":[{"introduced":"70f1db321a2b39c75f679b5b052aa1ac0636bd50"},{"fixed":"9b5e12a5491d2e6b68e0c88ca56f3a9ef9fba400"}]}],"versions":["7.56.1","7.56.0"],"database_specific":{"source":"https://curl.se/docs/CURL-CVE-2017-8818.json","vanir_signatures":[{"id":"CURL-CVE-2017-8818-2e9fffff","source":"https://github.com/curl/curl.git/commit/9b5e12a5491d2e6b68e0c88ca56f3a9ef9fba400","digest":{"threshold":0.9,"line_hashes":["74519365798700727815501306324019181752","8227623838178206336447627114113526499","208968052275945858584323605974099818685","289985660858154134076170390871816744329","40596083909079714084395426035990256227","139237657046610833886990036128728878059"]},"deprecated":false,"target":{"file":"lib/urldata.h"},"signature_version":"v1","signature_type":"Line"},{"id":"CURL-CVE-2017-8818-6b852015","source":"https://github.com/curl/curl.git/commit/9b5e12a5491d2e6b68e0c88ca56f3a9ef9fba400","digest":{"function_hash":"6649342520484512342211797578294829512","length":4312},"deprecated":false,"target":{"function":"allocate_conn","file":"lib/url.c"},"signature_version":"v1","signature_type":"Function"},{"id":"CURL-CVE-2017-8818-d75987ef","source":"https://github.com/curl/curl.git/commit/9b5e12a5491d2e6b68e0c88ca56f3a9ef9fba400","digest":{"threshold":0.9,"line_hashes":["295612572197449119642062073279619435508","9643995011459194785553621756686177840","89375592586285747465246517511566977472","285724277223185123673438939810984061460","165772692332384755216552332741844327915","286917501116648199085544230494356482557","134268723277641467947241807518432051416","247888501838578019921090884192784397992","37164390252753081605346040942974362017","104499415839995184298186086287408674392","124604502765533275862367478837788863093","267120796023825293927121211307467915360","25556682137420556002444366678743634832","164620937650040169805139164021664836218","284189125221952731612535024615770549115","310578510010389364319082241074291031656","29733560279007910406193971606398242937","299725087779298214123803526348949144501","187683109645776335245643091552835955895","114683200105122791117131523505019954467","202066822490440179442270930777213625876","69113649687558460161471999498636613469","139405022227810439318728582510389572828","158586665494696168989387367307318495240","208704396188600719874877492196863109684"]},"deprecated":false,"target":{"file":"lib/url.c"},"signature_version":"v1","signature_type":"Line"}],"vanir_signatures_modified":"2026-04-25T20:30:34Z"}}],"schema_version":"1.7.5","credits":[{"name":"John Schoenick","type":"FINDER"},{"name":"Ray Satiro","type":"REMEDIATION_DEVELOPER"}]}