From bms@spc.org  Tue Jun 10 22:29:29 2003
Return-Path: <bms@spc.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id EC14637B401
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 10 Jun 2003 22:29:28 -0700 (PDT)
Received: from bigboy.spc.org (dolly.good1.com [195.206.69.225])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 4494943FBD
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 10 Jun 2003 22:29:28 -0700 (PDT)
	(envelope-from bms@spc.org)
Received: from saboteur.dek.spc.org (unknown [81.3.72.84])
	by bigboy.spc.org (Postfix) with ESMTP id 1BBA93260
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 11 Jun 2003 06:33:33 +0100 (BST)
Received: by saboteur.dek.spc.org (Postfix, from userid 1001)
	id 908A66C1; Wed, 11 Jun 2003 06:29:26 +0100 (BST)
Message-Id: <20030611052926.908A66C1@saboteur.dek.spc.org>
Date: Wed, 11 Jun 2003 06:29:26 +0100 (BST)
From: Bruce M Simpson <bms@spc.org>
Reply-To: Bruce M Simpson <bms@spc.org>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: wi(4) monitor mode on PRISM2 not functioning
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         53187
>Category:       kern
>Synopsis:       wi(4) monitor mode on PRISM2 not functioning
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jun 10 22:30:10 PDT 2003
>Closed-Date:    Wed Jul 09 09:06:39 PDT 2003
>Last-Modified:  Wed Jul 09 09:06:39 PDT 2003
>Originator:     Bruce M Simpson
>Release:        FreeBSD 5.1-RELEASE i386
>Organization:
>Environment:
System: FreeBSD saboteur.dek.spc.org 5.1-RELEASE FreeBSD 5.1-RELEASE #0: Mon Jun 9 16:25:10 BST 2003 root@saboteur.dek.spc.org:/usr/src/sys/i386/compile/SABOTEUR i386


	
>Description:
	Trying to use dstumbler from the net/bsd-airtools port for wireless
	network auditing under 5.1-RELEASE. This no longer works.

	I've confirmed that world/kernel/dstumbler out-of-sync snafus are
	not to blame - fresh installworld+installkernel, and rebuild of
	the port.

	Setting hw.wi.debug to 1 reveals the following:-
	<snip>
	wi_rx_intr: fid 4ca error status 701
	wi_rx_intr: fid 4de error status 701
	wi_rx_intr: fid 5f6 error status 701
	wi_rx_intr: fid 10c error status 701
	wi_rx_intr: fid 15c error status 701
	</snip>

	This repeats ad nauseam. No traffic is shown or displayed by either
	dstumbler or the prism2dump tools.

>How-To-Repeat:
	As description
>Fix:

	


>Release-Note:
>Audit-Trail:

From: Bruce M Simpson <bms@spc.org>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: kern/53187
Date: Wed, 11 Jun 2003 09:24:29 +0100

 Here are more of my notes from working through the problem:-
 
    - firmly established that old-style monitor-mode/procframe handling is
      gone from the driver. this is what breaks bsd-airtools.
    - tcpdump is able to sniff 802.11 headers though; but it does the
      following: pcap_set_datalink(p, DLT_IEEE802_11).
    - looks like enabling monitor mode does actually go through to hw still.
     - dstumbler is heavily dependent on the old monitor-mode behaviour 
       from 5.0-RELEASE. but it could be patched to do things in a way
       which is compatible with the new api changes.
     - looks like struct wi_rx_frame {} no longer used, but still defined.
     - the wi_frame is broadly equivalent to the wi_rx_frame struct
       abused by bsd-airtools.
     - one would need to define a different link layer, IEEE802_11_PRISM2,
       dummy mbuf with procfame, and bpf_mtap() that.
     - Conditionalise it for people who are worried about this support
       bloating up their packet input path.
     - Moving wi_rx_intr() processing into taskqs is probably a far distant
       future exercise right now anyway.
 
 I could potentially write the code to do the above. I would like review
 from sam@ and imp@ first before deciding how to proceed.
 
 BMS
State-Changed-From-To: open->closed 
State-Changed-By: sam 
State-Changed-When: Wed Jul 9 09:04:59 PDT 2003 
State-Changed-Why:  
monitor mode support returning in revision 1.143 of if_wi.c 

http://www.freebsd.org/cgi/query-pr.cgi?pr=53187 
>Unformatted:
