Threat model
Initial checklist; this is not a completed security analysis.
Assets
- User traffic confidentiality and integrity.
- Client and server identities and credentials.
- Session keys, session identifiers, and replay state.
- Server availability and resource limits.
Threats to consider
- Active network attackers and certificate-validation failures.
- Replay, downgrade, impersonation, and malformed frames.
- Oversized lengths, memory exhaustion, queue exhaustion, and connection floods.
- Session hijacking or incorrect resumption after reconnect.
- Secrets exposed in logs, crash reports, configuration, or command-line arguments.
- Compromise of software dependencies.
Minimum controls before production
- TLS certificate and hostname verification.
- Explicit client-authentication design and credential rotation.
- Strict parsing, bounded allocations, and timeouts.
- Fuzzing and adversarial interoperability tests.
- No secrets in logs; dependency security checks.
- Independent review before handling real user traffic.