CoAP
— Constrained Application ProtocolCoAP is designed as a lightweight, binary version of HTTP designed specifically for IoT microcontrollers (like 8-bit MCUs with minimal RAM). It runs over UDP rather than TCP to eliminate handshaking overhead and support multicast.
Interactive Session: How CoAP Works
Step through the packet exchange sequence between nodes.
Interactive Execution Sandbox
Interact with a live or clearly-labelled simulated instance of CoAP.
Threat Model & Attack Simulation
How this protocol is attacked in practice, what defenders can see, and which control stops it.
Threat model & attack simulation
SimulatedDefensive education. Every step runs in this page; no traffic is generated or sent.
CoAP amplification
Denial of serviceSpoofed CoAP requests to discovery or large-resource endpoints generate responses aimed at a victim.
Find a responder
The attacker probes for discovery or large resource endpoints.
Repeated /.well-known/core queries.
Reflected traffic and device overload.
Defences that matter
- BCP 38 filtering
- Rate limits on constrained devices
- Disable multicast discovery from untrusted networks
This is a conceptual model for defenders, not an exploit toolkit. It contains no payloads, tooling or instructions for attacking systems you do not own.
Protocol Specification & Architecture
Key characteristics, real-world deployment patterns, and trade-offs.
Core Technical Features
- RESTful model with GET, POST, PUT, DELETE methods over UDP
- Tiny 4-byte fixed binary header
- Built-in resource discovery via `/.well-known/core`
- Asynchronous subscribe/observe mechanism (RFC 7641)
- Security via DTLS (Datagram Transport Layer Security)
Real-World Use Cases
- Smart utility energy and water meters
- Agricultural soil moisture sensors
- Smart city street light control networks
Advantages & Strengths
- Extremely small footprint; runs on MCUs with only 10 KB RAM
- Native multicast support for group device control
Limitations & Vulnerabilities
- UDP requires application-level handling of duplicate packets