Log message for disconnecting a client with invalid UTF-8 topic.

Closes #1144. Thanks to Kris Mattheus.
pull/1151/head
Roger A. Light 7 years ago
parent f952ae3a67
commit 1c075988ca

@ -36,6 +36,8 @@ Broker:
- Windows: Fix possible crash when client disconnects. Closes #1137.
- Fixed durable clients being unable to receive messages when offline, when
per_listener_settings was set to true. Closes #1081.
- Add log message for the case where a client is disconnected for sending a
topic with invalid UTF-8. Closes #1144.
Library:
- Fix TLS connections not working over SOCKS.

@ -70,6 +70,7 @@ int handle__publish(struct mosquitto_db *db, struct mosquitto *context)
}
if(mosquitto_validate_utf8(topic, slen) != MOSQ_ERR_SUCCESS){
log__printf(NULL, MOSQ_LOG_INFO, "Client %s sent topic with invalid UTF-8, disconnecting.", context->id);
mosquitto__free(topic);
return 1;
}

Loading…
Cancel
Save