summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorge <george-gwu@users.noreply.github.com>2016-05-03 16:25:13 -0400
committerStephen Beaver <sbeaver@netgate.com>2016-05-04 08:16:49 -0400
commit23cc8797358343f69efb9e53047cf91f425955b9 (patch)
tree86c9203fd717ed3473ebd6de2187fbeccb25ac7a
parent6102c368c2c11f75b667165e86c85996ae2b0008 (diff)
downloadpfsense-23cc8797358343f69efb9e53047cf91f425955b9.zip
pfsense-23cc8797358343f69efb9e53047cf91f425955b9.tar.gz
Bug fixes to Route53 DynDNS
Fixed a bug regarding a leading space in $ZoneID that causes an AWS 505 error. Also adds support for updating DNS if TTL changes. (cherry picked from commit a4bda7563136a7b47a1d090cededdb1b1a076019)
-rw-r--r--src/etc/inc/dyndns.class4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/etc/inc/dyndns.class b/src/etc/inc/dyndns.class
index bcc53b6..419c980 100644
--- a/src/etc/inc/dyndns.class
+++ b/src/etc/inc/dyndns.class
@@ -594,7 +594,7 @@
/* Setting Variables */
$hostname = "{$this->_dnsHost}.";
- $ZoneID = $this->_dnsZoneID;
+ $ZoneID = trim($this->_dnsZoneID);
$AccessKeyId = $this->_dnsUser;
$SecretAccessKey = $this->_dnsPass;
$NewIP = $this->_dnsIP;
@@ -630,7 +630,7 @@
}
/* Check if we need to update DNS Record */
- if ($OldIP !== $NewIP) {
+ if ($OldIP !== $NewIP || $OldTTL !== $NewTTL) {
if (!empty($OldIP)) {
/* Your Hostname already exists, deleting and creating it again */
$changes = array();
OpenPOWER on IntegriCloud