# CVE-2021-0341: Square OkHttp can accept the wrong certificate

- Severity: High 7.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.92%, higher than 61% of CVEs (2026-12-02)
- Published: 2021-02-10T16:50:15.000Z
- Modified: 2026-09-10T03:49:29.393Z
- Also known as: GHSA-3cqm-mf7h-prrj, A-171980069, ASB-A-171980069
- Weaknesses: CWE-295
- Assigned by: google_android

## Description

In verifyHostName of OkHostnameVerifier.java, there is a possible way to accept a certificate for the wrong domain due to improperly used crypto. This could lead to remote information disclosure with no additional execution privileges needed. User interaction is not needed for exploitation.Product: AndroidVersions: Android-8.1 Android-9 Android-10 Android-11Android ID: A-171980069

(As written by CVE List.)

## Affected

- Android: Android-8.1 Android-9 Android-10 Android-11
- com.squareup.okhttp3:okhttp (Maven): before 4.9.2
- google android: 8.1; 9.0; 10.0; 11.0

## Every score

- GitHub: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:2.0 5.0 Medium `AV:N/AC:L/Au:N/C:P/I:N/A:N`

## References

- <https://source.android.com/security/bulletin/2021-02-01> (patch, vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-0341> (advisory)
- <https://github.com/square/okhttp/issues/6724> (web)
- <https://github.com/square/okhttp/pull/6741> (web)
- <https://github.com/square/okhttp/commit/f574ea2f5259d9040f264ddeb582fb1ce563f10c> (web)
- <https://github.com/square/okhttp> (package)

## Sources

- CVE List: [CVE-2021-0341](https://www.cve.org/CVERecord?id=CVE-2021-0341), CVE Terms of Use, modified 2024-08-03
- GitHub Advisory Database: [GHSA-3cqm-mf7h-prrj](https://github.com/advisories/GHSA-3cqm-mf7h-prrj), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2021-0341](https://nvd.nist.gov/vuln/detail/CVE-2021-0341), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-0341 · Whole record: https://cve.day/CVE-2021-0341.json · Rebuilt by cve.day 2026-11-25T22:57:59.888Z
