summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2017-09-11 17:40:09 -0300
committerRenato Botelho <renato@netgate.com>2017-09-11 17:40:09 -0300
commit46583aba3a382c28fb6bc4bbbcd7dbf28fe38782 (patch)
tree007dc8107ade0df711d744a566ec93270e57b739 /src
parent78670b63ce880dc930bd6f5e27bc520e899a9cb6 (diff)
downloadpfsense-46583aba3a382c28fb6bc4bbbcd7dbf28fe38782.zip
pfsense-46583aba3a382c28fb6bc4bbbcd7dbf28fe38782.tar.gz
Fix #7719
When Dynamic DNS entry uses a gateway group as interface, return_gateway_groups_array() will be called and it returns real interface instead of friendly name, as expected. Take both friendly and real interface name into consideration.
Diffstat (limited to 'src')
-rw-r--r--src/etc/inc/services.inc14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/etc/inc/services.inc b/src/etc/inc/services.inc
index 79a12db..132121b 100644
--- a/src/etc/inc/services.inc
+++ b/src/etc/inc/services.inc
@@ -1983,14 +1983,19 @@ function services_dyndns_configure($int = "") {
* the active gateway for that group
*/
$group_int = '';
+ $friendly_group_int = '';
if (is_array($gwgroups[$dyndns['interface']])) {
if (!empty($gwgroups[$dyndns['interface']][0]['vip'])) {
$group_int = $gwgroups[$dyndns['interface']][0]['vip'];
} else {
$group_int = $gwgroups[$dyndns['interface']][0]['int'];
+ $friendly_group_int =
+ convert_real_interface_to_friendly_name(
+ $group_int);
}
}
- if ((empty($int)) || ($int == $dyndns['interface']) || ($int == $group_int)) {
+ if ((empty($int)) || ($int == $dyndns['interface']) ||
+ ($int == $group_int) || ($int == $friendly_group_int)) {
$dyndns['verboselog'] = isset($dyndns['verboselog']);
$dyndns['curl_ipresolve_v4'] = isset($dyndns['curl_ipresolve_v4']);
$dyndns['curl_ssl_verifypeer'] = isset($dyndns['curl_ssl_verifypeer']);
@@ -2541,14 +2546,19 @@ function services_dnsupdate_process($int = "", $updatehost = "", $forced = false
* the active gateway for that group
*/
$group_int = '';
+ $friendly_group_int = '';
if (is_array($gwgroups[$dnsupdate['interface']])) {
if (!empty($gwgroups[$dnsupdate['interface']][0]['vip'])) {
$group_int = $gwgroups[$dnsupdate['interface']][0]['vip'];
} else {
$group_int = $gwgroups[$dnsupdate['interface']][0]['int'];
+ $friendly_group_int =
+ convert_real_interface_to_friendly_name(
+ $group_int);
}
}
- if (!empty($int) && ($int != $dnsupdate['interface']) && ($int != $group_int)) {
+ if (!empty($int) && ($int != $dnsupdate['interface']) &&
+ ($int != $group_int) && ($int != $friendly_group_int)) {
continue;
}
if (!empty($updatehost) && ($updatehost != $dnsupdate['host'])) {
OpenPOWER on IntegriCloud