Changeset View
Changeset View
Standalone View
Standalone View
sbin/pfctl/pfctl_parser.c
Show First 20 Lines • Show All 1,684 Lines • ▼ Show 20 Lines | if (cont && (h = host_v4(s, mask)) != NULL) | ||||
cont = 0; | cont = 0; | ||||
/* IPv6 address? */ | /* IPv6 address? */ | ||||
if (cont && (h = host_v6(ps, v6mask)) != NULL) | if (cont && (h = host_v6(ps, v6mask)) != NULL) | ||||
cont = 0; | cont = 0; | ||||
/* interface with this name exists? */ | /* interface with this name exists? */ | ||||
/* expensive with thousands of interfaces - prioritze IPv4/6 check */ | /* expensive with thousands of interfaces - prioritze IPv4/6 check */ | ||||
if (cont && (h = host_if(ps, mask)) != NULL) | if (cont && ((h = host_if(ps, mask)) != NULL || | ||||
strchr(ps, ':') != NULL)) | |||||
cont = 0; | cont = 0; | ||||
/* dns lookup */ | /* dns lookup */ | ||||
if (cont && (h = host_dns(ps, v4mask, v6mask)) != NULL) | if (cont && (h = host_dns(ps, v4mask, v6mask)) != NULL) | ||||
cont = 0; | cont = 0; | ||||
free(ps); | free(ps); | ||||
if (h == NULL || cont == 1) { | if (h == NULL || cont == 1) { | ||||
▲ Show 20 Lines • Show All 292 Lines • Show Last 20 Lines |