From owner-freebsd-bugs Mon Jun 25 20:50: 8 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 4B99C37B409 for ; Mon, 25 Jun 2001 20:50:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.3/8.11.3) id f5Q3o2602341; Mon, 25 Jun 2001 20:50:02 -0700 (PDT) (envelope-from gnats) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id EC47B37B401 for ; Mon, 25 Jun 2001 20:42:56 -0700 (PDT) (envelope-from nobody@FreeBSD.org) Received: (from nobody@localhost) by freefall.freebsd.org (8.11.3/8.11.3) id f5Q3guO01335; Mon, 25 Jun 2001 20:42:56 -0700 (PDT) (envelope-from nobody) Message-Id: <200106260342.f5Q3guO01335@freefall.freebsd.org> Date: Mon, 25 Jun 2001 20:42:56 -0700 (PDT) From: Ernest Hua To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-1.0 Subject: kern/28417: arplookup uses potentially unprotected static variable ... Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 28417 >Category: kern >Synopsis: arplookup uses potentially unprotected static variable ... >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Jun 25 20:50:02 PDT 2001 >Closed-Date: >Last-Modified: >Originator: Ernest Hua >Release: 4.2-RELEASE >Organization: Luminous Networks >Environment: FreeBSD ernestbsd.luminousnetworks.com 4.2-RELEASE FreeBSD 4.2-RELEASE #0: Mon Nov 20 13:02:55 GMT 2000 jkh@bento.FreeBSD.org:/usr/src/sys/compile/GENERIC i386 >Description: I suspect that there is a hidden problem in using this static variable in arplookup. We actually found this while working in VxWorks 5.4, but it appears to be in FreeBSD and NetBSD as well. I'll check a few other OS's later. The problem is the static variable "sin" in arplookup(), which is used to hold the IP address to look up. I am not a network stack expert, but I suspect this path is not multi-thread friendly, and will have potentially corrupted results for simultaneous callers. >How-To-Repeat: >Fix: Remove the "static" keyword. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message