summaryrefslogtreecommitdiffstats
path: root/etc/inc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2006-12-21 00:28:13 +0000
committerScott Ullrich <sullrich@pfsense.org>2006-12-21 00:28:13 +0000
commite789a62534c7e51674d8747cc5b380441d66e8d2 (patch)
tree722c71f3c06ea5ea26d56bfb4533c11b34d8eef4 /etc/inc
parentbdc3c4891216785ffc80508060639ce48434b501 (diff)
downloadpfsense-e789a62534c7e51674d8747cc5b380441d66e8d2.zip
pfsense-e789a62534c7e51674d8747cc5b380441d66e8d2.tar.gz
Output dhclient.conf in the same format as current m0n0.ch beta (freebsd 6 + isc dhclient)
Diffstat (limited to 'etc/inc')
-rw-r--r--etc/inc/interfaces.inc30
1 files changed, 6 insertions, 24 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index a0e1abc..3b7e2f3 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -946,18 +946,12 @@ function interfaces_opt_dhcp_configure($interface) {
return 1;
}
- if ($optcfg['dhcphostname']) {
- $dhclientconf_hostname = "send dhcp-client-identifier \"{$optcfg['dhcphostname']}\";\n";
- $dhclientconf_hostname .= "\tsend host-name \"{$optcfg['dhcphostname']}\";\n";
- } else {
- $dhclientconf_hostname = "";
- }
-
$dhclientconf = "";
$dhclientconf .= <<<EOD
+send dhcp-client-identifier "{$optcfg['dhcphostname']}";
interface "{$optif}" {
- {$dhclientconf_hostname}
+ send host-name "{$optcfg['dhcphostname']}";
}
EOD;
@@ -989,18 +983,12 @@ function interfaces_dhcp_configure($interface) {
return 1;
}
- if ($optcfg['dhcphostname']) {
- $dhclientconf_hostname = "send dhcp-client-identifier \"{$optcfg['dhcphostname']}\";\n";
- $dhclientconf_hostname .= "\tsend host-name \"{$optcfg['dhcphostname']}\";\n";
- } else {
- $dhclientconf_hostname = "";
- }
-
$dhclientconf = "";
$dhclientconf .= <<<EOD
+send dhcp-client-identifier "{$optcfg['dhcphostname']}";
interface "{$realinterface}" {
- {$dhclientconf_hostname}
+ send host-name "{$optcfg['dhcphostname']}";
}
EOD;
@@ -1035,18 +1023,12 @@ function interfaces_wan_dhcp_configure() {
return 1;
}
- if ($wancfg['dhcphostname']) {
- $dhclientconf_hostname = "send dhcp-client-identifier \"{$wancfg['dhcphostname']}\";\n";
- $dhclientconf_hostname .= "\tsend host-name \"{$wancfg['dhcphostname']}\";\n";
- } else {
- $dhclientconf_hostname = "";
- }
-
$dhclientconf = "";
$dhclientconf .= <<<EOD
+send dhcp-client-identifier "{$wancfg['dhcphostname']}";
interface "{$wancfg['if']}" {
- {$dhclientconf_hostname}
+ send host-name "{$wancfg['dhcphostname']}";
}
EOD;
OpenPOWER on IntegriCloud