← Back to the chapter · Next detail →
Technical detail · CoAP Security: Protection and Application Fit
Credential retirement, tampering and replay tests
Testing a protected CoAP resource requires separate evidence for accepted credentials, allowed operations and duplicate delivery.
A credential is evidence used to authenticate a peer; authorization determines which operations that identity may perform. The useful access cases are a valid credential, a wrong credential, and an authenticated identity without permission. Only the permitted reader should receive private data. Retiring a credential also requires removing it from the accepted configuration and ending sessions that used it before testing a fresh exchange.
Modified protected bytes should fail integrity checks, which detect unauthorized changes. A protected record is a unit of transport data checked by the security protocol. Replaying a captured protected record should produce no new application delivery. This differs from legitimate CoAP retransmission after an acknowledgement (ACK) is lost: a repeated request can travel in a fresh protected record. CoAP duplicate handling should prevent a second application operation while allowing the exchange to complete. Security diagnostics and application delivery counts distinguish these cases better than silence alone.