1$FreeBSD: src/tools/tools/net80211/wlaninject/README,v 1.1 2006/08/05 05:13:31 sam Exp $
2
3This tool generates raw 802.11 frames.  The resulting frame will
4depend on the capabilities of the hardware.  Some hardware mangles
5the 802.11 header [e.g. wi] other hardware does not [e.g. ath].
6This tool does not deal with layers above 802.11.  A payload from
7a file must be supplied if, for example, IP data needs to be sent.
8
9Refer to the usage for a complete list of options.  Here, the most
10relevant will be described.  There are three types of switches:
11
12physical layer	Physical parameters for transmission
13		[such as iface and chan].
14802.11 header	Fields in the 802.11 header.
15802.11 body	The payload of the 802.11 frame.  This includes
16		management information elements.
17
18Interesting physical layer options.
19-----------------------------------
20-i The network interface to use to TX; defaults to ath0.
21-c The channel to TX on; defaults to 1.
22-N Mark transmitted frames such that no ACK is expected. In practice,
23   this will disable any retransmission done by the card.  This
24   way, you are sure that a single copy of your packet will be TXed.
25-V Verify that the packet you TXed did indeed fly in the air as
26   expected.  This is done by sniffing on a second network interface
27   and comparing the received frame to what was sent.  This option
28   is especially useful because some cards mangle 802.11 header
29   fields such as duration and fragment numbers.
30-W The WME AC to use for transmission.  Symbolic names are used:
31	ac_be, be	best effort
32	ac_bk, bk	background
33	ac_vi, vi	video
34	ac_vo, vo	voice
35-X The rate to use for transmission; defaults to 1Mbps.
36-P The txpower to use; defaults to the maximum permitted by the driver.
37
38Interesting 802.11 header options.
39----------------------------------
40-t The 802.11 frame type.  Symbolic names are:
41	mgt	Management frame
42	ctl	Control frame
43	data	Data frame
44   Otherwise the numerical type must be supplied.
45-s The 802.11 frame subtype.  At this point, the length of the 802.11 header
46   will be calculated.  Symbolic names are:
47	preq, probereq	Probe Request
48	auth		Authenticate
49	areq, assocreq	Assocation Request
50	data		Data
51   Otherwise the numerical subtype must be supplied.
52-4 The 4th MAC addr used for WDS.  Make sure you specify this before
53   -s so the header length is calculated correctly.
54-l Override the length of the packet.  This is useful for sending
55   truncated packets.
56-b Specify a file which will be used as a payload inside the 802.11
57   frame.  The length should be calculated automatically correctly.
58
59Interesting 802.11 payload options.
60-----------------------------------
61This is mainly used for management frames.  For data frames, -b
62would typically be used.
63
64-e Add an information element.  You can supply multiple -e options,
65   but make sure you add them in the expected order.  The format
66   of the information element is a list of 2 digit hex numbers.
67   That is, 010203...  The first hexdigit is the type of the IE.
68   Therefore, 00616161 should correspond to the SSID IE of 'aaa'.
69   The length is calculated automatically---you do not need to
70   supply it.
71-S Add an SSID IE with the data specified in ascii; e.g. -S 'aaa'
72   is the equivalent of -e 0061616161.
73-R Add an IE of 11b supported rates.
74
75Examples:
76---------
77
78wlaninject -t data -s data -i ral0 -V ath0 -m -n 1 -f 1
79
80Transmit a data frame on ral0 and verify the transmission on ath0.
81The frame is sent with sequence number 1, fragment number 1, and
82the MoreFrag bit marked in the 802.11 header.
83