Skip to content

Commit

Permalink
Add support for complex device IDs.
Browse files Browse the repository at this point in the history
  • Loading branch information
chkr1011 committed Apr 30, 2017
1 parent 9816f12 commit b3a6919
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions MQTTnet.Core/Serializer/DefaultMqttV311PacketSerializer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -354,11 +354,6 @@ private void ValidateConnectPacket(MqttConnectPacket packet)
{
throw new MqttProtocolViolationException("CleanSession must be set if ClientId is empty [MQTT-3.1.3-7].");
}

if (!string.IsNullOrEmpty(packet.ClientId) && !Regex.IsMatch(packet.ClientId, "^[a-zA-Z0-9]*$"))
{
throw new MqttProtocolViolationException("ClientId contains invalid characters [MQTT-3.1.3-5].");
}
}

private void ValidatePublishPacket(MqttPublishPacket packet)
Expand Down

0 comments on commit b3a6919

Please sign in to comment.