mirror of
https://github.com/webmin/webmin.git
synced 2026-05-04 22:30:33 +01:00
Allow hostnames to be entered as well as IPs
This commit is contained in:
@@ -18,7 +18,7 @@ print &ui_hidden("new", $in{'new'}),"\n";
|
||||
print &ui_hidden("idx", $in{'idx'}),"\n";
|
||||
print &ui_table_start($text{'ipkey_header'}, undef, 2);
|
||||
|
||||
print &ui_table_row($text{'ipkey_ips'},
|
||||
print &ui_table_row($text{'ipkey_ips2'},
|
||||
&ui_textarea("ips", join("\n", @{$ipkey->{'ips'}}),
|
||||
3, 60));
|
||||
|
||||
|
||||
@@ -129,13 +129,14 @@ print ui_table_row($text{'ssl_download'}, &ui_links_row(\@clinks));
|
||||
print ui_table_end();
|
||||
print ui_tabs_end_tab();
|
||||
|
||||
# Table listing per-IP SSL certs
|
||||
# Table listing per-IP / domain SSL certs
|
||||
print ui_tabs_start_tab("mode", "ips");
|
||||
print "$text{'ssl_ipkeys'}<p>\n";
|
||||
my @ipkeys = get_ipkeys(\%miniserv);
|
||||
if (@ipkeys) {
|
||||
print ui_columns_start([ $text{'ssl_ips'}, $text{'ssl_key'},
|
||||
$text{'ssl_cert'} ]);
|
||||
print ui_columns_start([ $text{'ssl_ips'},
|
||||
$text{'ssl_key'},
|
||||
$text{'ssl_cert'} ]);
|
||||
foreach my $k (@ipkeys) {
|
||||
print ui_columns_row([
|
||||
ui_link("edit_ipkey.cgi?idx=".$k->{'index'},
|
||||
|
||||
@@ -356,7 +356,7 @@ ssl_bits=bits
|
||||
ssl_eextraca=Additional certificate file '$1' does not exist
|
||||
ssl_days=Days before expiry
|
||||
ssl_ipkeys=This section lists additional SSL certificates that will be used for connections to particular IP addresses.
|
||||
ssl_ips=IP addresses
|
||||
ssl_ips=IP addresses and domain names
|
||||
ssl_ipkeynone=No IP-specific SSL keys have been defined yet.
|
||||
ssl_addipkey=Add a new IP-specific SSL key.
|
||||
ssl_return=SSL keys
|
||||
@@ -819,9 +819,9 @@ lock_edirs=No files or directories entered
|
||||
ipkey_title1=Create SSL Key
|
||||
ipkey_title2=Edit SSL Key
|
||||
ipkey_header=IP-specific SSL key details
|
||||
ipkey_ips=For connections to IP addresses
|
||||
ipkey_ips2=For IP addresses and hostnames
|
||||
ipkey_err=Failed to save SSL key
|
||||
ipkey_eip='$1' is not a valid IP address
|
||||
ipkey_eip2='$1' is not a valid IP address or hostname
|
||||
ipkey_eips=No IP addresses entered
|
||||
ipkey_eextracas=No additional certificate files entered
|
||||
ipkey_eextraca=Additional certificate file $1 does not exist
|
||||
|
||||
@@ -22,7 +22,7 @@ else {
|
||||
@ips = split(/\s+/, $in{'ips'});
|
||||
foreach $i (@ips) {
|
||||
&check_ipaddress($i) || &check_ip6address($i) ||
|
||||
&error(&text('ipkey_eip', $i));
|
||||
&to_ipaddress($i) || &error(&text('ipkey_eip2', $i));
|
||||
}
|
||||
@ips || &error(&text('ipkey_eips'));
|
||||
$ipkey->{'ips'} = \@ips;
|
||||
|
||||
Reference in New Issue
Block a user