# Missing or partial TLS validation

TLS checks skipped, gated on negotiation, or reimplemented wildcard/hostname matching that fails open

_Area: Network devices and IoT. Seen in 5 disclosed reports; one confirmed bounty: $2,100; latest 2023-06-25. Updated 2026-10-23._

## How it works
TLS trust rests on a chain of checks: verify the certificate signature chain, then match the certificate identity (hostname) to the peer you intended to reach. This pattern is when one of those checks is absent, disabled, or bypassed. The broken assumption is that "TLS is on" means "the peer is authenticated." In practice the handshake can complete while signature verification is never performed [E3](https://bugbountylibrary.com/r/h1%3A894922.md), while hostname matching is skipped or cached past [E1](https://bugbountylibrary.com/r/h1%3A811502.md), or while a mandatory-TLS policy silently degrades to cleartext [E2](https://bugbountylibrary.com/r/h1%3A1334111.md). The connection looks encrypted but the identity guarantee is gone.

## Where it shows up
- Bundled crypto libraries configured via a feature/resource list; check that signature verification is actually enabled [E3](https://bugbountylibrary.com/r/h1%3A894922.md)
- Custom hostname/wildcard matchers instead of delegating to the TLS library [E5](https://bugbountylibrary.com/r/h1%3A1991427.md)
- Session caches populated by a callback separate from the verification result [E1](https://bugbountylibrary.com/r/h1%3A811502.md)
- Security controls gated on a negotiation step (CAPABILITY, greeting codes) that can fail open [E2](https://bugbountylibrary.com/r/h1%3A1334111.md)
- Mobile/embedded clients that accept any CA-signed cert, including a proxy CA [E4](https://bugbountylibrary.com/r/h1%3A168538.md)

## How to review
The invariant: no application data (especially credentials/tokens) is sent until the peer's chain signature is verified AND the certificate identity matches the intended host. Check each independently:
- Is signature verification enabled in the underlying library config, not just a "verify" flag set in code? [E3](https://bugbountylibrary.com/r/h1%3A894922.md)
- Does hostname matching use the library's matcher, or a hand-rolled one? Test wildcard and punycode (xn--) inputs [E5](https://bugbountylibrary.com/r/h1%3A1991427.md)
- Are sessions cached only after verification succeeds, and evicted on failure? [E1](https://bugbountylibrary.com/r/h1%3A811502.md)
- Does a failed negotiation step abort, or fall through to cleartext? [E2](https://bugbountylibrary.com/r/h1%3A1334111.md)
- On stock devices, does traffic decrypt through an untrusted CA? [E4](https://bugbountylibrary.com/r/h1%3A168538.md)

## Variants seen
- Signature check omitted from crypto library resource list [E3](https://bugbountylibrary.com/r/h1%3A894922.md)
- Session cached before hostname verification, reused to bypass it [E1](https://bugbountylibrary.com/r/h1%3A811502.md)
- Mandatory-TLS enforcement tied to negotiation success, fails open [E2](https://bugbountylibrary.com/r/h1%3A1334111.md)
- No certificate validation at all in a mobile client [E4](https://bugbountylibrary.com/r/h1%3A168538.md)
- Reimplemented wildcard matcher accepts partial patterns on IDN hosts [E5](https://bugbountylibrary.com/r/h1%3A1991427.md)

## Impact and severity
Leads to MitM: capture of OAuth tokens and auth headers [E4](https://bugbountylibrary.com/r/h1%3A168538.md), interception of any TLS connection [E3](https://bugbountylibrary.com/r/h1%3A894922.md), hostname bypass [E1](https://bugbountylibrary.com/r/h1%3A811502.md)[E5](https://bugbountylibrary.com/r/h1%3A1991427.md), and cleartext downgrade [E2](https://bugbountylibrary.com/r/h1%3A1334111.md). Worse when the client carries long-lived credentials or when the flaw is silent (no user-visible warning).

## Evidence
- E1: https://bugbountylibrary.com/r/h1%3A811502.md
- E2: https://bugbountylibrary.com/r/h1%3A1334111.md
- E3: https://bugbountylibrary.com/r/h1%3A894922.md
- E4: https://bugbountylibrary.com/r/h1%3A168538.md
- E5: https://bugbountylibrary.com/r/h1%3A1991427.md
