While the case in bug #74429 is not documented and is only worky due to
an implementation bug, the strength seems to breach some real world
apps. Given this patch doesn't impact the initial security fix for
bug #74216, it is reasonable to let the apps keep working. As mentioned
in the ticket, this behavior is a subject to change in future versions
and should not be abused.
return NULL;
}
*portno = strtol(p + 2, &e, 10);
- if (e && *e) {
+ if (e && *e && *e != '/') {
if (get_err) {
*err = strpprintf(0, "Failed to parse address \"%s\"", str);
}
if (colon) {
char *e = NULL;
*portno = strtol(colon + 1, &e, 10);
- if (!e || !*e) {
+ if (!e || !*e || *e == '/') {
return estrndup(str, colon - str);
}
}