From owner-freebsd-bugs@FreeBSD.ORG Thu Jul 2 22:30:04 2009 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 E267F1065676 for ; Thu, 2 Jul 2009 22:30:04 +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 B94978FC1E for ; Thu, 2 Jul 2009 22:30:04 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n62MU4bT028520 for ; Thu, 2 Jul 2009 22:30:04 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n62MU46p028518; Thu, 2 Jul 2009 22:30:04 GMT (envelope-from gnats) Resent-Date: Thu, 2 Jul 2009 22:30:04 GMT Resent-Message-Id: <200907022230.n62MU46p028518@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, Andrew Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5B19A106564A for ; Thu, 2 Jul 2009 22:21:17 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 491378FC0A for ; Thu, 2 Jul 2009 22:21:17 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n62MLHNO068446 for ; Thu, 2 Jul 2009 22:21:17 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id n62MLG9i068445; Thu, 2 Jul 2009 22:21:16 GMT (envelope-from nobody) Message-Id: <200907022221.n62MLG9i068445@www.freebsd.org> Date: Thu, 2 Jul 2009 22:21:16 GMT From: Andrew To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/136257: Able to set an invalid netmask X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Jul 2009 22:30:05 -0000 >Number: 136257 >Category: kern >Synopsis: Able to set an invalid netmask >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Jul 02 22:30:04 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Andrew >Release: 7.2-RELEASE-p2 >Organization: Falcon Tech Systems >Environment: >Description: I'm able to set an invalid netmask: ifconfig bridge0 inet 192.168.8.1 netmask 0xd0452484; bridge0: flags=8843 metric 0 mtu 1500 ether 6a:7d:09:1a:3e:34 inet 192.168.8.1 netmask 0xd0452484 broadcast 192.168.8.255 id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15 maxage 20 holdcnt 6 proto rstp maxaddr 100 timeout 1200 root id 00:00:00:00:00:00 priority 32768 ifcost 0 port 0 member: em0 flags=143 ifmaxaddr 0 port 1 priority 128 path cost 20000 Netstat output is then confusing: 192.0.0.0&0xd0452484 link#5 UC 0 0 bridge I've also tested this on a non-bridge interface, gif0, em0. As inet corresponds to an IPv4 address, this seems invalid. >How-To-Repeat: >Fix: >Release-Note: >Audit-Trail: >Unformatted: