# CVE-2021-40828: TLS hostname validation issues within AWS IoT Device SDKs on Windows

- Severity: Medium 6.3 (CVSS:3.1, scored by F-SecureUS) `CVSS:3.1/AV:A/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:H`
- 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.41%, higher than 37% of CVEs (2026-12-01)
- Published: 2021-11-22T23:41:16.000Z
- Modified: 2026-06-17T04:07:29.540Z
- Also known as: GHSA-94jq-q5v2-76wj, PYSEC-2021-861
- Weaknesses: CWE-295
- Assigned by: F-SecureUS

## Description

Connections initialized by the AWS IoT Device SDK v2 for Java (versions prior to 1.3.3), Python (versions prior to 1.5.18), C++ (versions prior to 1.12.7) and Node.js (versions prior to 1.5.1) did not verify server certificate hostname during TLS handshake when overriding Certificate Authorities (CA) in their trust stores on Windows. This issue has been addressed in aws-c-io submodule versions 0.9.13 onward. This issue affects: Amazon Web Services AWS IoT Device SDK v2 for Java versions prior to 1.3.3 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Python versions prior to 1.5.18 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for C++ versions prior to 1.12.7 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Node.js versions prior to 1.5.3 on Microsoft Windows.

(As written by CVE List.)

## Affected

- Amazon Web Services AWS IoT Device SDK v2 for Java: from unspecified before 1.3.3
- Amazon Web Services AWS IoT Device SDK v2 for Python: from unspecified before 1.5.18
- Amazon Web Services AWS IoT Device SDK v2 for C++: from unspecified before 1.12.7
- Amazon Web Services AWS IoT Device SDK v2 for Node.js: from unspecified before 1.5.3
- Amazon Web Services AWS-C-IO: 0.9.12
- software.amazon.awssdk.iotdevicesdk:aws-iot-device-sdk (Maven): before 1.3.3
- aws-iot-device-sdk-v2 (npm): before 1.5.1
- awsiotsdk (PyPI): before 1.5.18
- amazon amazon_web_services_aws-c-io: before 0.9.13
- amazon amazon_web_services_internet_of_things_device_software_development_kit_v2: before 1.3.3; before 1.5.1; before 1.5.18; before 1.12.7

## Every score

- F-SecureUS: CVSS:3.1 6.3 Medium `CVSS:3.1/AV:A/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:H`
- GitHub: CVSS:3.1 6.3 Medium `CVSS:3.1/AV:A/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:H`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:A/AC:L/AT:P/PR:H/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- NVD: CVSS:3.1 8.8 High `CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 5.8 Medium `AV:A/AC:L/Au:N/C:P/I:P/A:P`

## References

- <https://github.com/awslabs/aws-c-io/> (product, web)
- <https://github.com/aws/aws-iot-device-sdk-cpp-v2> (product, web)
- <https://github.com/aws/aws-iot-device-sdk-python-v2> (product, web)
- <https://github.com/aws/aws-iot-device-sdk-java-v2> (product, web)
- <https://github.com/aws/aws-iot-device-sdk-js-v2> (product, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-40828> (advisory)
- <https://github.com/aws/aws-iot-device-sdk-java-v2/commit/67950ad2a02f2f9355c310b69dc9226b017f32f2> (web)
- <https://github.com/aws/aws-iot-device-sdk-js-v2/commit/4be41394f1aee979e6f4b012fcb01eecabd0c08d> (web)
- <https://github.com/aws/aws-iot-device-sdk-python-v2/commit/fd4c0ba04b35eab9e20c635af5548fcc5a92d8be> (web)
- <https://github.com/advisories/GHSA-94jq-q5v2-76wj> (advisory)
- <https://github.com/awslabs/aws-c-io> (web)
- <https://github.com/pypa/advisory-database/tree/main/vulns/awsiotsdk/PYSEC-2021-861.yaml> (web)

## Sources

- CVE List: [CVE-2021-40828](https://www.cve.org/CVERecord?id=CVE-2021-40828), CVE Terms of Use, modified 2024-08-04
- GitHub Advisory Database: [GHSA-94jq-q5v2-76wj](https://github.com/advisories/GHSA-94jq-q5v2-76wj), CC-BY-4.0, modified 2024-09-12
- NVD: [CVE-2021-40828](https://nvd.nist.gov/vuln/detail/CVE-2021-40828), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2021-861](https://osv.dev/vulnerability/PYSEC-2021-861), CC-BY-4.0, modified 2023-11-08

---

Page: https://cve.day/CVE-2021-40828 · Whole record: https://cve.day/CVE-2021-40828.json · Rebuilt by cve.day 2026-11-25T22:58:05.712Z
