Don't reject ACL patterns without %u or %c, just warn.

Using `pattern blah/#` is a legitimate method of getting a global ACL.
We shouldn't be changing behaviour in a fixes release.
pull/1600/head
Roger A. Light 7 years ago
parent fb802d6b3d
commit ffbdad93b4

@ -16,8 +16,8 @@ Broker:
Closes #851.
- Fix problem opening listeners on Pi caused by unsigned char being default.
Found via #849.
- ACL patterns that do not contain either %c or %u are now rejected. Closes
#209.
- ACL patterns that do not contain either %c or %u now produce a warning in
the log. Closes #209.
- Fix bridge publishing failing when per_listener_settings was true. Closes
#860.
- Fix `use_identity_as_username true` not working. Closes #833.

@ -280,11 +280,9 @@ int add__acl_pattern(struct mosquitto__security_options *security_opts, const ch
}
if(acl->ccount == 0 && acl->ucount == 0){
log__printf(NULL, MOSQ_LOG_ERR,
"Error: ACL pattern '%s' does not contain '%%c' or '%%u'.",
log__printf(NULL, MOSQ_LOG_WARNING,
"Warning: ACL pattern '%s' does not contain '%%c' or '%%u'.",
topic);
return MOSQ_ERR_INVAL;
}
if(security_opts->acl_patterns){

Loading…
Cancel
Save