Project

General

Profile

Actions

Feature #1917

closed

DHCP server support for multiple domains in search list

Added by Chris Buechler almost 10 years ago. Updated about 9 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
DHCP (IPv4)
Target version:
Start date:
09/28/2011
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
Release Notes:

Description

The DHCP server's search list only supports a single domain, should be extended to support multiple domains such as:

option domain-search "example.com", "sales.example.com", "eng.example.com";
Actions #1

Updated by Fabien Grumelard almost 10 years ago

To solve this problem, I've written this patch:

--- /etc/inc/services.inc.org    2011-10-05 12:41:46.000000000 +0200
+++ /etc/inc/services.inc    2011-10-05 12:40:48.000000000 +0200
@@ -242,7 +242,7 @@
         }

             if($dhcpifconf['domainsearchlist'] <> "") {
-            $dnscfg .= "    option domain-search-list \"{$dhcpifconf['domainsearchlist']}\";\n";
+            $dnscfg .= "    option domain-search \"" . join("\",\"", preg_split("/[ ,]+/", $dhcpifconf['domainsearchlist'])) . "\";\n";
             }

         if (isset($dhcpifconf['ddnsupdate'])) {

Actions #2

Updated by Chris Buechler almost 10 years ago

Needs input validation in web interface as well, that doesn't suffice.

Actions #3

Updated by Wayne Scott over 9 years ago

Can we do something here? Right now it doesn't work at all.

Actions #4

Updated by Pierre POMES over 9 years ago

  • Status changed from New to Feedback
  • Assignee set to Pierre POMES
  • Target version set to 2.1
  • % Done changed from 0 to 100
  • Affected Version set to 2.0.1
Actions #5

Updated by Jim Pingle over 9 years ago

Looks like someone also checked in a fix in 107e8acc that broke this again. It appears the fix on this ticket is better, so I'll remove the other one.

Actions #6

Updated by Jim Pingle about 9 years ago

  • Status changed from Feedback to Resolved
Actions

Also available in: Atom PDF