"An Empty message has the Code field set to 0.00. The Token Length field MUST be set to 0 and bytes of data MUST NOT be present after the Message ID field. If there are any bytes, they MUST be processed as a message format error."
Actual Behavior
An "empty" message with code 0.00 can contain a token, payload, and options.
Some questions:
Can you confirm this behavior?
Were you aware of it?
Is it intentional or an oversight?
Hi!
I have tested your library and found an issue which i would like to report.
cantcoap
Commit e7bb846
Problem Description
In a coap message, an "empty message" can contain a payload.
Expected behavior
According to RFC7252 (https://www.rfc-editor.org/rfc/rfc7252) :
"An Empty message has the Code field set to 0.00. The Token Length field MUST be set to 0 and bytes of data MUST NOT be present after the Message ID field. If there are any bytes, they MUST be processed as a message format error."
Actual Behavior
An "empty" message with code 0.00 can contain a token, payload, and options.
Some questions:
Can you confirm this behavior? Were you aware of it? Is it intentional or an oversight?
Sincerely Sabor