Vulnerabilities / CVE-2019-3822

critical

CVE-2019-3822

curl: NTLMv2 type-3 header stack buffer overflow

Published Modified CWE 121, 787
In the Trivy database since at least 24 Oct 2026, 07:11 UTCWhen it arrived before that build is not recorded.

Severity by source

NVD9.8CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Red Hat5.3CVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:N/A:H

Trivy's own label is CRITICAL. Rated critical by NVD, Photon OS. Rated lower by Red Hat (medium), Amazon (medium), Oracle (medium), Ubuntu (medium).

Description

libcurl versions from 7.36.0 to before 7.64.0 are vulnerable to a stack-based buffer overflow. The function creating an outgoing NTLM type-3 header (`lib/vauth/ntlm.c:Curl_auth_create_ntlm_type3_message()`), generates the request HTTP header contents based on previously received data. The check that exists to prevent the local buffer from getting overflowed is implemented wrongly (using unsigned math) and as such it does not prevent the overflow from happening. This output data can grow larger than the local buffer if very large 'nt response' data is extracted from a previous NTLMv2 header provided by the malicious or broken HTTP server. Such a 'large value' needs to be around 1000 bytes or more. The actual payload data copied to the target buffer comes from the NTLMv2 type-2 response header.

Affected packages and fixed versions

SourcePackageFixed in
Photon OS 1.0curl7.59.0-6.ph1
Photon OS 2.0curl7.59.0-6.ph2
Photon OS 3.0cmake, curl3.13.5-2.ph3 and 1 more
alpine 3.10curl7.64.0-r0
alpine 3.11curl7.64.0-r0
alpine 3.12curl7.64.0-r0
alpine 3.13curl7.64.0-r0
alpine 3.14curl7.64.0-r0
alpine 3.15curl7.64.0-r0
alpine 3.16curl7.64.0-r0
alpine 3.17curl7.64.0-r0
alpine 3.18curl7.64.0-r0
Show all 66 entries from 42 sources
SourcePackageFixed in
Photon OS 1.0curl7.59.0-6.ph1
Photon OS 2.0curl7.59.0-6.ph2
Photon OS 3.0cmake3.13.5-2.ph3
Photon OS 3.0curl7.61.1-3.ph3
alpine 3.10curl7.64.0-r0
alpine 3.11curl7.64.0-r0
alpine 3.12curl7.64.0-r0
alpine 3.13curl7.64.0-r0
alpine 3.14curl7.64.0-r0
alpine 3.15curl7.64.0-r0
alpine 3.16curl7.64.0-r0
alpine 3.17curl7.64.0-r0
alpine 3.18curl7.64.0-r0
alpine 3.19curl7.64.0-r0
alpine 3.20curl7.64.0-r0
alpine 3.21curl7.64.0-r0
alpine 3.22curl7.64.0-r0
alpine 3.23curl7.64.0-r0
alpine 3.24curl7.64.0-r0
alpine 3.6curl7.61.1-r2
alpine 3.7curl7.61.1-r2
alpine 3.8curl7.61.1-r2
alpine 3.9curl7.64.0-r0
alpine edgecurl7.64.0-r0
amazon linux 1mysql575.7.27-1.13.amzn1
amazon linux 1mysql57-common5.7.27-1.13.amzn1
amazon linux 1mysql57-debuginfo5.7.27-1.13.amzn1
amazon linux 1mysql57-devel5.7.27-1.13.amzn1
amazon linux 1mysql57-embedded5.7.27-1.13.amzn1
amazon linux 1mysql57-embedded-devel5.7.27-1.13.amzn1
amazon linux 1mysql57-errmsg5.7.27-1.13.amzn1
amazon linux 1mysql57-libs5.7.27-1.13.amzn1
amazon linux 1mysql57-server5.7.27-1.13.amzn1
amazon linux 1mysql57-test5.7.27-1.13.amzn1
amazon linux 2curl7.61.1-9.amzn2.0.1
amazon linux 2curl-debuginfo7.61.1-9.amzn2.0.1
amazon linux 2libcurl7.61.1-9.amzn2.0.1
amazon linux 2libcurl-devel7.61.1-9.amzn2.0.1
debian 11curl7.64.0-1
debian 12curl7.64.0-1
debian 13curl7.64.0-1
debian 14curl7.64.0-1
debian 8curl7.38.0-4+deb8u14
debian 9curl7.52.1-5+deb9u9
echocurl7.64.0-1
Oracle Linux 8curl7.61.1-11.el8
Oracle Linux 8libcurl7.61.1-11.el8
Oracle Linux 8libcurl-devel7.61.1-11.el8
Oracle Linux 8libcurl-minimal7.61.1-11.el8
Red Hathttpd24-curlno fix listed
Red Hathttpd24-libcurlno fix listed
Red Hathttpd24-libcurl-develno fix listed
Red Hatrh-dotnet21-curlno fix listed
Red Hatrh-dotnet21-libcurlno fix listed
Red Hatrh-dotnet21-libcurl-develno fix listed
Red Hatrh-dotnet22-curlno fix listed
Red Hatrh-dotnet22-libcurlno fix listed
Red Hatrh-dotnet22-libcurl-develno fix listed
root.io debian 11rootio-curl7.64.0-1
root.io debian 12rootio-curl7.64.0-1
root.io debian 13rootio-curl7.64.0-1
ubuntu 16.04curl7.47.0-1ubuntu2.12
ubuntu 16.04-ESMcurl7.47.0-1ubuntu2.12
ubuntu 18.04curl7.58.0-2ubuntu3.6
ubuntu 18.04-ESMcurl7.58.0-2ubuntu3.6
ubuntu 18.10curl7.61.0-1ubuntu2.3

References

All 21 references

Vulnerability data compiled from the Trivy vulnerability database (trivy-db, Aqua Security, Apache License 2.0), which aggregates third-party advisories. CVE records are published by The MITRE Corporation under the CVE Terms of Use; CVE is a trademark of MITRE. This product uses data from the NVD API but is not endorsed or certified by the NVD. Severity, titles and advisory data from the GitHub Advisory Database (CC BY 4.0), Red Hat security data (CC BY 4.0) and the other sources linked on each entry. Entries may be summarised or re-formatted; the linked original is the authoritative record.