firewall: Add WireGuard RW to the UI

commit 5a1c02df8973b3acc5c3101a94e86fe6df4b43b6
    Author: Michael Tremer <michael.tremer@ipfire.org>
    Date:   Thu Sep 12 19:39:26 2024 +0200

        firewall: Add WireGuard RW to the UI

        Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>

Signed-off-by: Vincent Li <vincent.mc.li@gmail.com>
This commit is contained in:
Vincent Li
2025-07-03 22:55:18 +00:00
parent 6ed934dbfc
commit aff726b928
5 changed files with 44 additions and 5 deletions

View File

@@ -26,6 +26,7 @@ $General::swroot = 'CONFIG_ROOT';
$General::noipprefix = 'noipg-';
require "${General::swroot}/network-functions.pl";
require "${General::swroot}/wireguard-functions.pl";
# This function executes a shell command without forking a shell or do any other
# Perl-voodoo before it. It deprecates the "system" command and is the only way
@@ -180,6 +181,13 @@ sub setup_default_networks
$defaultNetworks->{'IPsec RW (' .$ip."/".$sub.")"}{'NET'} = &getnextip($ip);
}
}
# WireGuard
if ($Wireguard::settings{'CLIENT_POOL'}) {
my $name = $Lang::tr{'wg rw peers'};
$defaultNetworks->{$name}{'NAME'} = "WGRW";
}
}
sub get_aliases
{