mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-20 05:11:03 +01:00
Convert DNS names into ip addresses in validate_net().
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
853b9ce916
commit
90bd19feb9
@ -202,7 +202,7 @@ sub validate_4net( $$ ) {
|
|||||||
fatal_error "Invalid IP address ($net)" unless valid_4address $net;
|
fatal_error "Invalid IP address ($net)" unless valid_4address $net;
|
||||||
} else {
|
} else {
|
||||||
fatal_error "Invalid Network address ($_[0])" if $_[0] =~ '/' || ! defined $net;
|
fatal_error "Invalid Network address ($_[0])" if $_[0] =~ '/' || ! defined $net;
|
||||||
validate_4address $net, $_[1];
|
$net = validate_4address $net, $_[1];
|
||||||
$vlsm = 32;
|
$vlsm = 32;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -635,7 +635,7 @@ sub validate_6net( $$ ) {
|
|||||||
fatal_error "Invalid IPv6 address ($net)" unless valid_6address $net;
|
fatal_error "Invalid IPv6 address ($net)" unless valid_6address $net;
|
||||||
} else {
|
} else {
|
||||||
fatal_error "Invalid Network address ($_[0])" if $_[0] =~ '/';
|
fatal_error "Invalid Network address ($_[0])" if $_[0] =~ '/';
|
||||||
validate_6address $net, $allow_name;
|
net = validate_6address $net, $allow_name;
|
||||||
$vlsm = 128;
|
$vlsm = 128;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user