Project

General

Profile

Actions

Bug #400

closed

rfc2136 brokenness

Added by Aarno Aukia over 14 years ago. Updated over 14 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Dynamic DNS
Target version:
Start date:
03/04/2010
Due date:
% Done:

0%

Estimated time:
0.50 h
Plus Target Version:
Release Notes:
Affected Version:
2.0
Affected Architecture:

Description

rfc2136 does not work in 2.0 out of the box. please see the attached patches.

--- /etc/rc.dyndns.update.bak 2010-03-04 11:01:19.000000000 0100
++ /etc/rc.dyndns.update 2010-03-04 11:03:19.000000000 +0100
@ -38,9 +38,13 @

$argument = trim($argv[1], " \n");

+// update dyndns.org
if(empty($argument))
services_dyndns_configure();
else
services_dyndns_configure($argument);

// update rfc2136 dyndns
+services_dnsupdate_process();

?>

--- /etc/inc/services.inc.bak 2010-03-04 10:58:48.000000000 0100
++ /etc/inc/services.inc 2010-03-04 11:13:28.000000000 0100
@ -833,14 +833,14 @
/* Dynamic DNS updating active? */
if (is_array($config['dnsupdates']['dnsupdate'])) {
foreach ($config['dnsupdates']['dnsupdate'] as $i => $dnsupdate) {
- if (!isset($dyndns['enable']))
if (!isset($dnsupdate['enable']))
continue;
- if (!empty($int) && $int != $dyndns['interface'])
+ if (!empty($int) && $int != $dnsupdate['interface'])
continue;

/* determine interface name */
- $if = get_real_interface($dyndns['interface']);
- $wanip = get_interface_ip($dyndns['interface']);
+ $if = get_real_interface($dnsupdate['interface']);
+ $wanip = get_interface_ip($dnsupdate['interface']);
if ($wanip) {
$keyname = $dnsupdate['keyname'];
@ -878,7 +878,7 @
$proto = 2;
}

- $fd = fopen("{$g['varetc_path']}/K{$keyname}+157+00000.key", "w");
+ $fd = fopen("{$g['varetc_path']}/K{$i}{$keyname}+157+00000.key", "w");
fwrite($fd, "{$keyname} IN KEY {$flags} {$proto} 157 {$dnsupdate['keydata']}\n");
fclose($fd);

@ -895,7 +895,7 @
fclose($fd);

/* invoke nsupdate */
- $cmd = "/usr/sbin/nsupdate -k {$g['varetc_path']}/K{$i}{$keyname}+157+00000.key";
+ $cmd = "/usr/bin/nsupdate -k {$g['varetc_path']}/K{$i}{$keyname}+157+00000.key";
if (isset($dnsupdate['usetcp']))
$cmd .= " -v";
$cmd .= " {$g['varetc_path']}/nsupdatecmds{$i}";
@ -1273,4 +1273,4 @
}
}

-?>
\ No newline at end of file
+?>

--- /usr/local/www/services_rfc2136_edit.php.bak 2010-03-04 10:55:19.000000000 0100
++ /usr/local/www/services_rfc2136_edit.php 2010-03-04 10:55:43.000000000 +0100
@ -81,7 +81,7 @

if (!$input_errors) {
$rfc2136 = array();
- $rfc2136['enable'] = $_POST['enable'] ? false : true;
+ $rfc2136['enable'] = $_POST['enable'] ? true : false;
$rfc2136['host'] = $_POST['host'];
$rfc2136['ttl'] = $_POST['ttl'];
$rfc2136['keyname'] = $_POST['keyname'];

Files

pfsense2.rfc2136.patch (3.12 KB) pfsense2.rfc2136.patch Aarno Aukia, 03/04/2010 05:23 AM
Actions #1

Updated by Aarno Aukia over 14 years ago

attached patch.
This affected 1.2.3 in http://redmine.pfsense.org/issues/show/106, which probably can be closed now.

the sbin/nsupdate -> bin/nsupdate bug, which was fixed from 1.2.3-rc1 to 1.2.3-rc3 was missing from 2.0. Does this mean all our patches for 1.2.3 have not been incorporated to 2.0 ?

Actions #2

Updated by Ermal Luçi over 14 years ago

  • Status changed from New to Feedback

Partial patch committed.
RFC2136 updates will be called from rc.newwanip.

Actions #3

Updated by Chris Buechler over 14 years ago

  • Status changed from Feedback to Resolved
Actions

Also available in: Atom PDF