From patchwork Mon Apr 8 11:00:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Brodkin X-Patchwork-Id: 1080883 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=synopsys.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=synopsys.com header.i=@synopsys.com header.b="lJQ2Knyu"; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 44d6s75XNQz9sQq for ; Mon, 8 Apr 2019 21:00:25 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id B5ABB87B4D; Mon, 8 Apr 2019 11:00:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JmQaGNhxKDst; Mon, 8 Apr 2019 11:00:18 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 8D73C87B21; Mon, 8 Apr 2019 11:00:18 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 14C561BF2B0 for ; Mon, 8 Apr 2019 11:00:17 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 11D4E86DD6 for ; Mon, 8 Apr 2019 11:00:17 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ypncJw0+WFqy for ; Mon, 8 Apr 2019 11:00:16 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from smtprelay.synopsys.com (us01smtprelay-2.synopsys.com [198.182.60.111]) by whitealder.osuosl.org (Postfix) with ESMTPS id 2947884AB2 for ; Mon, 8 Apr 2019 11:00:15 +0000 (UTC) Received: from mailhost.synopsys.com (dc8-mailhost2.synopsys.com [10.13.135.210]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtprelay.synopsys.com (Postfix) with ESMTPS id 730B110C1FA7; Mon, 8 Apr 2019 04:00:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1554721215; bh=NBB5jUc9ftS/YUy9ZC6niSu/i3GXBljIZBXRsCoh4O0=; h=From:To:Cc:Subject:Date:From; b=lJQ2KnyuTWIVmYVrcXJJoUYx71Pt5qPBP2JXSROhPIb1jJn0tk8+lIzqneXQ3glGc 9tBVS3PCPCFkz/mcHCf5R/owfQ/2jsUvDgT6xPlcDqLdHLp93oYDJyIYrueLS6mRLM aBcZlSFHxWfZ3bmkWjz0lZI4dLyKGYaqRWy5zeVqcBrZLB5Tp2uuSMgULSyqsVR3u/ Zv0kTpIuXFd9S3BsiKehiGWPidRYXyQ6dG/ckUCg2dyUakTvBba4z4KlGIjywlX2Mt GMVaiqLpHJMLJA0F28FRUo0CJcALJBL2jP931bQpC9ZuT6l/d+cslCV7fSVYcKg+TM UOSjgnXP4IMeg== Received: from ru20arcgnu1.internal.synopsys.com (ru20arcgnu1.internal.synopsys.com [10.121.9.48]) by mailhost.synopsys.com (Postfix) with ESMTP id 79635A023C; Mon, 8 Apr 2019 11:00:13 +0000 (UTC) From: Alexey Brodkin To: buildroot@busybox.net Date: Mon, 8 Apr 2019 14:00:10 +0300 Message-Id: <20190408110010.2596-1-abrodkin@synopsys.com> X-Mailer: git-send-email 2.16.2 Subject: [Buildroot] [PATCH] busybox: Enable domain search list support in udhcpc X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ignacy Gawedzki , Alexey Brodkin , ARC Buildroot mailing list , Peter Korsgaard MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" This is useful in networks with internal resources as it allows to use much shorter names. E.g. instead of "server.internal.company.com" it's possible to use just "server" if DHCP server is configured with: ---------------------------->8----------------------- option domain-search "internal.company.com"; ---------------------------->8----------------------- This improvement consists of 2 parts: 1. Enable handling of RFC3397 so DHCP client is ready for processing corresponding data from DHCP server. 2. Some DHCP servers always send out search list if it is set in server's configuration and some servers only provide search list if client asks for that (sending list of options it expectes to get). And exactly for those stubborn DHCP servers we need to add "-O search" to udhcp's command line via CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS. Signed-off-by: Alexey Brodkin Cc: Ignacy Gawedzki Cc: Peter Korsgaard Acked-by: Yann E. MORIN --- package/busybox/busybox.config | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package/busybox/busybox.config b/package/busybox/busybox.config index 1d9560d655..ab04854c83 100644 --- a/package/busybox/busybox.config +++ b/package/busybox/busybox.config @@ -967,9 +967,9 @@ CONFIG_UDHCPC_DEFAULT_SCRIPT="/usr/share/udhcpc/default.script" # CONFIG_FEATURE_UDHCP_PORT is not set CONFIG_UDHCP_DEBUG=0 CONFIG_UDHCPC_SLACK_FOR_BUGGY_SERVERS=80 -# CONFIG_FEATURE_UDHCP_RFC3397 is not set +CONFIG_FEATURE_UDHCP_RFC3397=y CONFIG_FEATURE_UDHCP_8021Q=y -CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -n" +CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -n -O search" # # Print Utilities