Content deleted Content added
→Security issues: space units |
→Message formats: Reorganize the messages format introduction (high-level view in the first paragraph, structure in the second paragraph) and fix naming: "header" denotes only the first 4 bytes, "payload" is the correct name of what was called "message body" before according to the spec |
||
Line 16:
==Message formats==
The smallest CoAP message is 4 bytes in length, if the token, options and payload fields are omitted, i.e. if it only consists of the CoAP header. The header is followed by the token value (0 to 8 bytes) which may be followed by a list of options in an optimized type–length–value format. Any bytes after the header, token and options (if any) are considered the message payload, which is prefixed by the one-byte "payload marker" (0xFF). The length of the payload is implied by the datagram length.
{| class="wikitable" style="margin: 0 auto; text-align:center"
|+ CoAP
! [[Octet (computing)|Octet]] offset !! !! colspan="8" | 0 !! colspan="8" | 1 !! colspan="8" | 2 !! colspan="8" | 3
|-
|