Skip to content

Test 'minimal publish' has non-conforming results #158

@neacsum

Description

@neacsum

According to this test, the generated packet is:

  48, 10, // Header
  0, 4, // Topic length
  116, 101, 115, 116, // Topic (test)
  116, 101, 115, 116 // Payload (test)

This is completely missing the PUBLISH packet properties. However, according to MQTT V5.0 2.2.2.1 If there are no properties, this MUST be indicated by including a Property Length of zero [MQTT-2.2.2-1]

EDIT: I see that at least one server (test.mosquitto.org) accepts the message in this form but I'd like to have at least a clarification how is this standard conforming.
-- END EDIT

Shouldn't this be:

  48, 11, // Header
  0, 4, // Topic length
  116, 101, 115, 116, // Topic (test)
  0,  //PUBLISH Properties
  116, 101, 115, 116 // Payload (test)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions