ipsec: fix auth server parsing regression

PR: https://forum.opnsense.org/index.php?topic=46774.0
This commit is contained in:
Franco Fichtner 2025-04-10 20:51:37 +02:00
parent 25b2716325
commit fb87f688f6

View File

@ -203,8 +203,8 @@ class IPsec extends BaseModel
foreach (explode(',', (string)$item) as $item) {
$idx = 'server' . (string)(count($servers) + 1);
$mapping = [];
if (isset($cnf->authserver)) {
foreach ($cnf->authserver as $authserver) {
if (isset($cnf->system->authserver)) {
foreach ($cnf->system->authserver as $authserver) {
if ($authserver->name == $item) {
$servers[$idx] = [
'address' => (string)$authserver->host,