mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-04 01:05:06 -05:00
conf: don't allow slash with hostname in allow/deny directive
This commit is contained in:
2
conf.c
2
conf.c
@@ -1071,7 +1071,7 @@ parse_allow_deny(char *line, ARR_Instance restrictions, int allow)
|
|||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (DNS_Name2IPAddress(p, &ip_addr, 1) == DNS_Success) {
|
if (!slashpos && DNS_Name2IPAddress(p, &ip_addr, 1) == DNS_Success) {
|
||||||
new_node = (AllowDeny *)ARR_GetNewElement(restrictions);
|
new_node = (AllowDeny *)ARR_GetNewElement(restrictions);
|
||||||
new_node->allow = allow;
|
new_node->allow = allow;
|
||||||
new_node->all = all;
|
new_node->all = all;
|
||||||
|
|||||||
Reference in New Issue
Block a user