From owner-freebsd-bugs@FreeBSD.ORG Mon Oct 17 06:00:25 2011 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A5E7B1065676 for ; Mon, 17 Oct 2011 06:00:25 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 687C58FC14 for ; Mon, 17 Oct 2011 06:00:25 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p9H60PRX070178 for ; Mon, 17 Oct 2011 06:00:25 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p9H60P5H070174; Mon, 17 Oct 2011 06:00:25 GMT (envelope-from gnats) Resent-Date: Mon, 17 Oct 2011 06:00:25 GMT Resent-Message-Id: <201110170600.p9H60P5H070174@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Eygene Ryabinkin Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B036C1065676; Mon, 17 Oct 2011 05:54:20 +0000 (UTC) (envelope-from rea@codelabs.ru) Received: from 0.mx.codelabs.ru (0.mx.codelabs.ru [144.206.177.45]) by mx1.freebsd.org (Postfix) with ESMTP id 625FF8FC0C; Mon, 17 Oct 2011 05:54:20 +0000 (UTC) Received: from void.codelabs.ru (void.codelabs.ru [144.206.177.25]) by 0.mx.codelabs.ru with esmtps (TLSv1:CAMELLIA256-SHA:256) id 1RFfvB-0003xU-LI; Mon, 17 Oct 2011 09:39:33 +0400 Message-Id: <20111017053932.6B331DA820@void.codelabs.ru> Date: Mon, 17 Oct 2011 09:39:32 +0400 (MSD) From: Eygene Ryabinkin To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: des@FreeBSD.org Subject: bin/161733: [patch] fix rc_force check in /etc/rc.d/dhclient X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Eygene Ryabinkin List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Oct 2011 06:00:25 -0000 >Number: 161733 >Category: bin >Synopsis: [patch] fix rc_force check in /etc/rc.d/dhclient >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Oct 17 06:00:24 UTC 2011 >Closed-Date: >Last-Modified: >Originator: Eygene Ryabinkin >Release: FreeBSD 10.0-CURRENT amd64 >Organization: Code Labs >Environment: System: FreeBSD 10.0-CURRENT amd64 >Description: Revision 226345 of /etc/rc.d/dhclient introduced the number of sanity checks, but the condition '[ -n "${rc_force}" ]' must be inversed, because the script should exit if it was _not_ forced to run and this is not the DHCP interface. 'it was not forced' == '[ -z "${rc_force}" ]' and not the other way round. >How-To-Repeat: Build and boot FreeBSD 10-CURRENT after 226345 and watch how your non-DHCP-enabled interfaces are trying to acquire the address via DHCP (dhclient in my case was invoked from the devd hooks for the "interface up" event). >Fix: Apply patch at http://codelabs.ru/fbsd/patches/dhclient/dhclient-properly-check-rc_force.diff It works both for my DHCP-enabled laptop and non-DHCP-enabled workstation. >Release-Note: >Audit-Trail: >Unformatted: