Every CVE Search/ Get API key

CVE-2016-2402

Improper Certificate Validation in OkHttp

5.9 MediumPublic exploitFix available

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
High
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
High
Availability
None

Exploit likelihood

1.94%Down 5.2 points since Feb 4, 2022
90%50%10%1%

What each source reports

NVD Score used 5.9

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
CVE-2016-2402
CVSS 3.1
5.9 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
CVSS 2.0
4.3 MediumAV:N/AC:M/Au:N/C:N/I:P/A:N
Weakness
CWE-295
Updated
2026-11-02
CVE List No score

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
CVE-2016-2402
Updated
2026-11-02
EUVDEUVD-2022-2383 No score

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
EUVD-2022-2383
Updated
2026-11-03
GitHub AdvisoriesGHSA-4hc2-jh7r-wrc3 5.9

Improper Certificate Validation in OkHttp

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
GHSA-4hc2-jh7r-wrc3
CVSS 3.1
5.9 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02
OSV 5.9

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
CVE-2016-2402
CVSS 3.1
5.9 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
Updated
2026-11-02
OSVGHSA-4hc2-jh7r-wrc3 5.9

Improper Certificate Validation in OkHttp

OkHttp before 2.7.4 and 3.x before 3.1.2 allows man-in-the-middle attackers to bypass certificate pinning by sending a certificate chain with a certificate from a non-pinned trusted CA and the pinned certificate.

Record
GHSA-4hc2-jh7r-wrc3
CVSS 3.1
5.9 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
com.squareup.okhttp3:okhttp
Maven
through 2.7.3
2.7.4
com.squareup.okhttp3:okhttp
Maven
3.0.0 to 3.1.1
3.1.2
com.squareup.okhttp3:okhttp
Maven
before 2.7.4
2.7.4
com.squareup.okhttp3:okhttp
Maven
3.0.0 up to 3.1.2, plus listed versions
3.0.13.1.03.1.1
3.1.2

Public exploits

Links only. Every CVE stores no exploit code.

Public exploits
SourceLinkDate
PoC in GitHubikoz/cert-pinning-flaw-poc2016-03-20
PoC in GitHubikoz/certPinningVulnerableOkHttp2016-03-30

History

History
RecordedChangedSources
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV, PoC in GitHub

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2016-2402 is a medium vulnerability (CVSS 5.9) in Squareup Okhttp, published January 30, 2017. Public exploit code exists. EPSS puts the chance of exploitation in the next 30 days at 1.94%, the 80th percentile. Fixed in com.squareup.okhttp3:okhttp 2.7.4.

References

MoveEnter Open