In 1.5-dev23, support for specifying an ACL unique ID was added via
commit
3534d881bc ("MINOR: pattern/acl: Each pattern of each acl can
be load with specified id"). It turns out that if the argument is
missing, we read past the end and can segfault.
This can be backported to all versions. Thanks to Zlatko Bratkovic
for reporting this bug.
patflags |= PAT_MF_NO_DNS;
else if (strcmp(*args, "-u") == 0) {
unique_id = strtol(args[1], &error, 10);
- if (*error != '\0') {
+ if (!*args[1] || *error != '\0') {
memprintf(err, "the argument of -u must be an integer");
goto out_free_expr;
}