Update to latest changes.
[dragonfly.git] / sbin / ifconfig / ifconfig.8
... / ...
CommitLineData
1.\" Copyright (c) 1983, 1991, 1993
2.\" The Regents of the University of California. All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\" notice, this list of conditions and the following disclaimer in the
11.\" documentation and/or other materials provided with the distribution.
12.\" 4. Neither the name of the University nor the names of its contributors
13.\" may be used to endorse or promote products derived from this software
14.\" without specific prior written permission.
15.\"
16.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
17.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
20.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26.\" SUCH DAMAGE.
27.\"
28.\" From: @(#)ifconfig.8 8.3 (Berkeley) 1/5/94
29.\" $FreeBSD: src/sbin/ifconfig/ifconfig.8,v 1.124 2006/10/10 09:44:08 ru Exp $
30.\" $DragonFly: src/sbin/ifconfig/ifconfig.8,v 1.25 2008/11/14 12:52:04 sephe Exp $
31.\"
32.Dd March 2, 2010
33.Dt IFCONFIG 8
34.Os
35.Sh NAME
36.Nm ifconfig
37.Nd configure network interface parameters
38.Sh SYNOPSIS
39.Nm
40.Op Fl L
41.Op Fl k
42.Op Fl m
43.Ar interface
44.Op Cm create
45.Op Ar address_family
46.Oo
47.Ar address
48.Op Ar dest_address
49.Oc
50.Op Ar parameters
51.Nm
52.Ar interface
53.Cm destroy
54.Nm
55.Fl a
56.Op Fl L
57.Op Fl d
58.Op Fl m
59.Op Fl u
60.Op Fl v
61.Op Ar address_family
62.Nm
63.Fl l
64.Op Fl d
65.Op Fl u
66.Op Ar address_family
67.Nm
68.Op Fl L
69.Op Fl d
70.Op Fl k
71.Op Fl m
72.Op Fl u
73.Op Fl v
74.Op Fl C
75.Sh DESCRIPTION
76The
77.Nm
78utility is used to assign an address
79to a network interface and/or configure
80network interface parameters.
81The
82.Nm
83utility must be used at boot time to define the network address
84of each interface present on a machine; it may also be used at
85a later time to redefine an interface's address
86or other operating parameters.
87.Pp
88The following options are available:
89.Bl -tag -width indent
90.It Ar address
91For the
92.Tn DARPA Ns -Internet
93family,
94the address is either a host name present in the host name data
95base,
96.Xr hosts 5 ,
97or a
98.Tn DARPA
99Internet address expressed in the Internet standard
100.Dq dot notation .
101.Pp
102It is also possible to use the CIDR notation (also known as the
103slash notation) to include the netmask.
104That is, one can specify an address like
105.Li 192.168.0.1/16 .
106.Pp
107For
108.Dq inet6
109family, it is also possible to specify the prefix length using the slash
110notation, like
111.Li ::1/128 .
112See the
113.Cm prefixlen
114parameter below for more information.
115.\" For the Xerox Network Systems(tm) family,
116.\" addresses are
117.\" .Ar net:a.b.c.d.e.f ,
118.\" where
119.\" .Ar net
120.\" is the assigned network number (in decimal),
121.\" and each of the six bytes of the host number,
122.\" .Ar a
123.\" through
124.\" .Ar f ,
125.\" are specified in hexadecimal.
126.\" The host number may be omitted on IEEE 802 protocol
127.\" (Ethernet, FDDI, and Token Ring) interfaces,
128.\" which use the hardware physical address,
129.\" and on interfaces other than the first.
130.\" For the
131.\" .Tn ISO
132.\" family, addresses are specified as a long hexadecimal string,
133.\" as in the Xerox family.
134.\" However, two consecutive dots imply a zero
135.\" byte, and the dots are optional, if the user wishes to (carefully)
136.\" count out long strings of digits in network byte order.
137.Pp
138The link-level
139.Pq Dq link
140address
141is specified as a series of colon-separated hex digits.
142This can be used to
143e.g.\& set a new MAC address on an ethernet interface, though the
144mechanism used is not ethernet-specific.
145If the interface is already
146up when this option is used, it will be briefly brought down and
147then brought back up again in order to ensure that the receive
148filter in the underlying ethernet hardware is properly reprogrammed.
149.It Ar address_family
150Specify the
151address family
152which affects interpretation of the remaining parameters.
153Since an interface can receive transmissions in differing protocols
154with different naming schemes, specifying the address family is recommended.
155The address or protocol families currently
156supported are
157.Dq inet ,
158.Dq inet6 ,
159.Dq atalk ,
160.Dq ipx ,
161.\" .Dq iso ,
162and
163.Dq link .
164.\" and
165.\" .Dq ns .
166The default is
167.Dq inet .
168.Dq ether
169and
170.Dq lladdr
171are synonyms for
172.Dq link .
173.It Ar dest_address
174Specify the address of the correspondent on the other end
175of a point to point link.
176.It Ar interface
177This
178parameter is a string of the form
179.Dq name unit ,
180for example,
181.Dq Li ed0 .
182.El
183.Pp
184The following parameters may be set with
185.Nm :
186.Bl -tag -width indent
187.It Cm add
188Another name for the
189.Cm alias
190parameter.
191Introduced for compatibility
192with
193.Bsx .
194.It Cm alias
195Establish an additional network address for this interface.
196This is sometimes useful when changing network numbers, and
197one wishes to accept packets addressed to the old interface.
198If the address is on the same subnet as the first network address
199for this interface, a non-conflicting netmask must be given.
200Usually
201.Li 0xffffffff
202is most appropriate.
203.It Fl alias
204Remove the network address specified.
205This would be used if you incorrectly specified an alias, or it
206was no longer needed.
207If you have incorrectly set an NS address having the side effect
208of specifying the host portion, removing all NS addresses will
209allow you to respecify the host portion.
210.It Cm anycast
211(Inet6 only.)
212Specify that the address configured is an anycast address.
213Based on the current specification,
214only routers may configure anycast addresses.
215Anycast address will not be used as source address of any of outgoing
216IPv6 packets.
217.It Cm arp
218Enable the use of the Address Resolution Protocol
219.Pq Xr arp 4
220in mapping
221between network level addresses and link level addresses (default).
222This is currently implemented for mapping between
223.Tn DARPA
224Internet
225addresses and
226.Tn IEEE
227802 48-bit MAC addresses (Ethernet, FDDI, and Token Ring addresses).
228.It Fl arp
229Disable the use of the Address Resolution Protocol
230.Pq Xr arp 4 .
231.It Cm staticarp
232If the Address Resolution Protocol is enabled,
233the host will only reply to requests for its addresses,
234and will never send any requests.
235.It Fl staticarp
236If the Address Resolution Protocol is enabled,
237the host will perform normally,
238sending out requests and listening for replies.
239.It Cm broadcast
240(Inet only.)
241Specify the address to use to represent broadcasts to the
242network.
243The default broadcast address is the address with a host part of all 1's.
244.It Cm debug
245Enable driver dependent debugging code; usually, this turns on
246extra console error logging.
247.It Fl debug
248Disable driver dependent debugging code.
249.It Cm promisc
250Put interface into permanently promiscuous mode.
251.It Fl promisc
252Disable permanently promiscuous mode.
253.It Cm delete
254Another name for the
255.Fl alias
256parameter.
257.It Cm down
258Mark an interface
259.Dq down .
260When an interface is marked
261.Dq down ,
262the system will not attempt to
263transmit messages through that interface.
264If possible, the interface will be reset to disable reception as well.
265This action does not automatically disable routes using the interface.
266.It Cm eui64
267(Inet6 only.)
268Fill interface index
269(lowermost 64bit of an IPv6 address)
270automatically.
271.It Cm ipdst
272This is used to specify an Internet host who is willing to receive
273IP packets encapsulating IPX packets bound for a remote network.
274An apparent point to point link is constructed, and
275the address specified will be taken as the IPX address and network
276of the destination.
277.It Cm media Ar type
278If the driver supports the media selection system, set the media type
279of the interface to
280.Ar type .
281Some interfaces support the mutually exclusive use of one of several
282different physical media connectors.
283For example, a 10Mbit/s Ethernet
284interface might support the use of either
285.Tn AUI
286or twisted pair connectors.
287Setting the media type to
288.Cm 10base5/AUI
289would change the currently active connector to the AUI port.
290Setting it to
291.Cm 10baseT/UTP
292would activate twisted pair.
293Refer to the interfaces' driver
294specific documentation or man page for a complete list of the
295available types.
296.It Cm mediaopt Ar opts
297If the driver supports the media selection system, set the specified
298media options on the interface.
299The
300.Ar opts
301argument
302is a comma delimited list of options to apply to the interface.
303Refer to the interfaces' driver specific man page for a complete
304list of available options.
305.It Fl mediaopt Ar opts
306If the driver supports the media selection system, disable the
307specified media options on the interface.
308.It Cm mode Ar mode
309If the driver supports the media selection system, set the specified
310operating mode on the interface to
311.Ar mode .
312For IEEE 802.11 wireless interfaces that support multiple operating modes
313this directive is used to select between 802.11a
314.Pq Cm 11a ,
315802.11b
316.Pq Cm 11b ,
317and 802.11g
318.Pq Cm 11g
319operating modes.
320.It Cm name Ar name
321Set the interface name to
322.Ar name .
323.It Cm rss
324If the driver supports receive side scaling,
325enable receive side scaling on the interface.
326.It Fl rss
327If the driver supports receive side scaling,
328disable receive side scaling on the interface.
329.It Cm rxcsum , txcsum
330If the driver supports user-configurable checksum offloading,
331enable receive (or transmit) checksum offloading on the interface.
332Some drivers may not be able to enable these flags independently
333of each other, so setting one may also set the other.
334The driver will offload as much checksum work as it can reliably
335support, the exact level of offloading varies between drivers.
336.It Fl rxcsum , txcsum
337If the driver supports user-configurable checksum offloading,
338disable receive (or transmit) checksum offloading on the interface.
339These settings may not always be independent of each other.
340.It Cm vlanmtu , vlanhwtag
341If the driver offers user-configurable VLAN support, enable
342reception of extended frames or tag processing in hardware,
343respectively.
344Note that this must be issued on a physical interface associated with
345.Xr vlan 4 ,
346not on a
347.Xr vlan 4
348interface itself.
349.It Fl vlanmtu , vlanhwtag
350If the driver offers user-configurable VLAN support, disable
351reception of extended frames or tag processing in hardware,
352respectively.
353.It Cm pollcpu Ar cpu
354Turn on
355.Xr polling 4
356feature and disable interrupts on the interface,
357if the driver supports this mode and
358.Ar cpu
359supports
360.Xr polling 4 .
361Driver will be polled by
362.Ar cpu .
363.It Cm polling
364Turn on
365.Xr polling 4
366feature and disable interrupts on the interface, if the driver supports
367this mode.
368.It Fl polling
369Turn off
370.Xr polling 4
371feature and enable interrupt mode on the interface.
372.It Cm create
373Create the specified network pseudo-device.
374If the interface is given without a unit number, try to create a new
375device with an arbitrary unit number.
376If creation of an arbitrary device is successful, the new device name is
377printed to standard output unless the interface is renamed or destroyed
378in the same
379.Nm
380invocation.
381.It Cm destroy
382Destroy the specified network pseudo-device.
383.It Cm plumb
384Another name for the
385.Cm create
386parameter.
387Included for
388.Tn Solaris
389compatibility.
390.It Cm unplumb
391Another name for the
392.Cm destroy
393parameter.
394Included for
395.Tn Solaris
396compatibility.
397.It Cm metric Ar n
398Set the routing metric of the interface to
399.Ar n ,
400default 0.
401The routing metric is used by the routing protocol
402.Pq Xr routed 8 .
403Higher metrics have the effect of making a route
404less favorable; metrics are counted as additional hops
405to the destination network or host.
406.It Cm mtu Ar n
407Set the maximum transmission unit of the interface to
408.Ar n ,
409default is interface specific.
410The MTU is used to limit the size of packets that are transmitted on an
411interface.
412Not all interfaces support setting the MTU, and some interfaces have
413range restrictions.
414.It Cm netmask Ar mask
415.\" (Inet and ISO.)
416(Inet only.)
417Specify how much of the address to reserve for subdividing
418networks into sub-networks.
419The mask includes the network part of the local address
420and the subnet part, which is taken from the host field of the address.
421The mask can be specified as a single hexadecimal number
422with a leading
423.Ql 0x ,
424with a dot-notation Internet address,
425or with a pseudo-network name listed in the network table
426.Xr networks 5 .
427The mask contains 1's for the bit positions in the 32-bit address
428which are to be used for the network and subnet parts,
429and 0's for the host part.
430The mask should contain at least the standard network portion,
431and the subnet field should be contiguous with the network
432portion.
433.Pp
434The netmask can also be specified in CIDR notation after the address.
435See the
436.Ar address
437option above for more information.
438.It Cm autoconf
439(Inet6 only.)
440Enable autoconfiguration.
441.It Fl autoconf
442Disable autoconfiguration.
443.It Cm pltime Ar n
444(Inet6 only.)
445Set preferred lifetime for the address.
446.It Cm vltime Ar n
447(Inet6 only.)
448Set valid lifetime for the address.
449.It Cm prefixlen Ar len
450(Inet6 only.)
451Specify that
452.Ar len
453bits are reserved for subdividing networks into sub-networks.
454The
455.Ar len
456must be integer, and for syntactical reason it must be between 0 to 128.
457It is almost always 64 under the current IPv6 assignment rule.
458If the parameter is omitted, 64 is used.
459.Pp
460The prefix can also be specified using the slash notation after the address.
461See the
462.Ar address
463option above for more information.
464.It Cm deprecated
465(Inet6 only.)
466Set the IPv6 deprecated address bit.
467.It Fl deprecated
468(Inet6 only.)
469Clear the IPv6 deprecated address bit.
470.It Cm tentative
471(Inet6 only.)
472Set the IPv6 tentative address bit.
473.It Fl tentative
474(Inet6 only.)
475Clear the IPv6 tentative address bit.
476.\" see
477.\" Xr eon 5 .
478.\" .It Cm nsellength Ar n
479.\" .Pf ( Tn ISO
480.\" only)
481.\" This specifies a trailing number of bytes for a received
482.\" .Tn NSAP
483.\" used for local identification, the remaining leading part of which is
484.\" taken to be the
485.\" .Tn NET
486.\" (Network Entity Title).
487.\" The default value is 1, which is conformant to US
488.\" .Tn GOSIP .
489.\" When an ISO address is set in an ifconfig command,
490.\" it is really the
491.\" .Tn NSAP
492.\" which is being specified.
493.\" For example, in
494.\" .Tn US GOSIP ,
495.\" 20 hex digits should be
496.\" specified in the
497.\" .Tn ISO NSAP
498.\" to be assigned to the interface.
499.\" There is some evidence that a number different from 1 may be useful
500.\" for
501.\" .Tn AFI
502.\" 37 type addresses.
503.It Cm range Ar netrange
504Under appletalk, set the interface to respond to a
505.Ar netrange
506of the form
507.Ar startnet Ns - Ns Ar endnet .
508Appletalk uses this scheme instead of
509netmasks though
510.Dx
511implements it internally as a set of netmasks.
512.It Cm remove
513Another name for the
514.Fl alias
515parameter.
516Introduced for compatibility
517with
518.Bsx .
519.It Cm phase
520The argument following this specifies the version (phase) of the
521Appletalk network attached to the interface.
522Values of 1 or 2 are permitted.
523.Sm off
524.It Cm link Op Cm 0 No - Cm 2
525.Sm on
526Enable special processing of the link level of the interface.
527These three options are interface specific in actual effect, however,
528they are in general used to select special modes of operation.
529An example
530of this is to enable SLIP compression, or to select the connector type
531for some Ethernet cards.
532Refer to the man page for the specific driver
533for more information.
534.Sm off
535.It Fl link Op Cm 0 No - Cm 2
536.Sm on
537Disable special processing at the link level with the specified interface.
538.It Cm compress
539Another name for the
540.Cm link0
541parameter.
542.It Cm normal
543Another name for the
544.Fl link0
545parameter.
546.It Cm noicmp
547Another name for the
548.Cm link1
549parameter.
550.It Cm monitor
551Put the interface in monitor mode.
552No packets are transmitted, and received packets are discarded after
553.Xr bpf 4
554processing.
555.It Fl monitor
556Take the interface out of monitor mode.
557.It Cm up
558Mark an interface
559.Dq up .
560This may be used to enable an interface after an
561.Dq Nm Cm down .
562It happens automatically when setting the first address on an interface.
563If the interface was reset when previously marked down,
564the hardware will be re-initialized.
565.El
566.Pp
567The following parameters are specific to cloning
568IEEE 802.11 wireless interfaces with the
569.Cm create
570request:
571.Bl -tag -width indent
572.It Cm wlandev Ar device
573Use
574.Ar device
575as the parent for the cloned device.
576.It Cm wlanmode Ar mode
577Specify the operating mode for this cloned device.
578.Ar mode
579is one of
580.Cm sta ,
581.Cm ahdemo
582(or
583.Cm adhoc-demo ),
584.Cm ibss ,
585(or
586.Cm adhoc ),
587.Cm ap ,
588(or
589.Cm hostap ),
590.Cm wds ,
591.Cm tdma ,
592.Cm mesh ,
593and
594.Cm monitor .
595The operating mode of a cloned interface cannot be changed.
596The
597.Cm tdma
598mode is actually implemented as an
599.Cm adhoc-demo
600interface with special properties.
601.It Cm wlanbssid Ar bssid
602The 802.11 mac address to use for the bssid.
603This must be specified at create time for a legacy
604.Cm wds
605device.
606.It Cm wlanaddr Ar address
607The local mac address.
608If this is not specified then a mac address will automatically be assigned
609to the cloned device.
610Typically this address is the same as the address of the parent device
611but if the
612.Cm bssid
613parameter is specified then the driver will craft a unique address for
614the device (if supported).
615.It Cm wdslegacy
616Mark a
617.Cm wds
618device as operating in ``legacy mode''.
619Legacy
620.Cm wds
621devices have a fixed peer relationship and do not, for example, roam
622if their peer stops communicating.
623For completeness a Dynamic WDS (DWDS) interface may marked as
624.Fl wdslegacy .
625.It Cm bssid
626Request a unique local mac address for the cloned device.
627This is only possible if the device supports multiple mac addresses.
628To force use of the parent's mac address use
629.Fl bssid .
630.It Cm beacons
631Mark the cloned interface as depending on hardware support to
632track received beacons.
633To have beacons tracked in software use
634.Fl beacons .
635For
636.Cm hostap
637mode
638.Fl beacons
639can also be used to indicate no beacons should
640be transmitted; this can be useful when creating a WDS configuration but
641.Cm wds
642interfaces can only be created as companions to an access point.
643.El
644.Pp
645The following parameters are specific to IEEE 802.11 wireless interfaces
646cloned with a
647.Cm create
648operation:
649.Bl -tag -width indent
650.It Cm ampdu
651Enable sending and receiving AMPDU frames when using 802.11n (default).
652The 802.11n specification states a compliant station must be capable
653of receiving AMPDU frames but transmision is optional.
654Use
655.Fl ampdu
656to disable all use of AMPDU with 802.11n.
657For testing and/or to work around interoperability problems one can use
658.Cm ampdutx
659and
660.Cm ampdurx
661to control use of AMPDU in one direction.
662.It Cm ampdudensity Ar density
663Set the AMPDU density parameter used when operating with 802.11n.
664This parameter controls the inter-packet gap for AMPDU frames.
665The sending device normally controls this setting but a receiving station
666may request wider gaps.
667Legal values for
668.Ar density
669are 0, .25, .5, 1, 2, 4, 8, and 16 (microseconds).
670A value of
671.Cm -
672is treated the same as 0.
673.It Cm ampdulimit Ar limit
674Set the limit on packet size for receiving AMPDU frames when operating
675with 802.11n.
676Legal values for
677.Ar limit
678are 8192, 16384, 32768, and 65536 but one can also specify
679just the unique prefix: 8, 16, 32, 64.
680Note the sender may limit the size of AMPDU frames to be less
681than the maximum specified by the receiving station.
682.It Cm amsdu
683Enable sending and receiving AMSDU frames when using 802.11n.
684By default AMSDU is received but not transmitted.
685Use
686.Fl amsdu
687to disable all use of AMSDU with 802.11n.
688For testing and/or to work around interoperability problems one can use
689.Cm amsdutx
690and
691.Cm amsdurx
692to control use of AMSDU in one direction.
693.It Cm amsdulimit Ar limit
694Set the limit on packet size for sending and receiving AMSDU frames
695when operating with 802.11n.
696Legal values for
697.Ar limit
698are 7935 and 3839 (bytes).
699Note the sender may limit the size of AMSDU frames to be less
700than the maximum specified by the receiving station.
701Note also that devices are not required to support the 7935 limit,
702only 3839 is required by the specification and the larger value
703may require more memory to be dedicated to support functionality
704that is rarely used.
705.It Cm apbridge
706When operating as an access point, pass packets between
707wireless clients directly (default).
708To instead let them pass up through the
709system and be forwarded using some other mechanism, use
710.Fl apbridge .
711Disabling the internal bridging
712is useful when traffic is to be processed with
713packet filtering.
714.It Cm authmode Ar mode
715Set the desired authentication mode in infrastructure mode.
716Not all adapters support all modes.
717The set of
718valid modes is
719.Cm none , open , shared
720(shared key),
721.Cm 8021x
722(IEEE 802.1x),
723and
724.Cm wpa
725(IEEE WPA/WPA2/802.11i).
726The
727.Cm 8021x
728and
729.Cm wpa
730modes are only useful when using an authentication service
731(a supplicant for client operation or an authenticator when
732operating as an access point).
733Modes are case insensitive.
734.It Cm bgscan
735Enable background scanning when operating as a station.
736Background scanning is a technique whereby a station associated to
737an access point will temporarily leave the channel to scan for
738neighboring stations.
739This allows a station to maintain a cache of nearby access points
740so that roaming between access points can be done without
741a lengthy scan operation.
742Background scanning is done only when a station is not busy and
743any outbound traffic will cancel a scan operation.
744Background scanning should never cause packets to be lost though
745there may be some small latency if outbound traffic interrupts a
746scan operation.
747By default background scanning is enabled if the device is capable.
748To disable background scanning, use
749.Fl bgscan .
750Background scanning is controlled by the
751.Cm bgscanidle
752and
753.Cm bgscanintvl
754parameters.
755Background scanning must be enabled for roaming; this is an artifact
756of the current implementation and may not be required in the future.
757.It Cm bgscanidle Ar idletime
758Set the minimum time a station must be idle (not transmitting or
759receiving frames) before a background scan is initiated.
760The
761.Ar idletime
762parameter is specified in milliseconds.
763By default a station must be idle at least 250 milliseconds before
764a background scan is initiated.
765The idle time may not be set to less than 100 milliseconds.
766.It Cm bgscanintvl Ar interval
767Set the interval at which background scanning is attempted.
768The
769.Ar interval
770parameter is specified in seconds.
771By default a background scan is considered every 300 seconds (5 minutes).
772The
773.Ar interval
774may not be set to less than 15 seconds.
775.It Cm bintval Ar interval
776Set the interval at which beacon frames are sent when operating in
777ad-hoc or ap mode.
778The
779.Ar interval
780parameter is specified in TU's (1024 usecs).
781By default beacon frames are transmitted every 100 TU's.
782.It Cm bmissthreshold Ar count
783Set the number of consecutive missed beacons at which the station
784will attempt to roam (i.e., search for a new access point).
785The
786.Ar count
787parameter must be in the range 1 to 255; though the
788upper bound may be reduced according to device capabilities.
789The default threshold is 7 consecutive missed beacons; but
790this may be overridden by the device driver.
791Another name for the
792.Cm bmissthreshold
793parameter is
794.Cm bmiss .
795.It Cm bssid Ar address
796Specify the MAC address of the access point to use when operating
797as a station in a BSS network.
798This overrides any automatic selection done by the system.
799To disable a previously selected access point, supply
800.Cm any , none ,
801or
802.Cm -
803for the address.
804This option is useful when more than one access point uses the same SSID.
805Another name for the
806.Cm bssid
807parameter is
808.Cm ap .
809.It Cm burst
810Enable packet bursting.
811Packet bursting is a transmission technique whereby the wireless
812medium is acquired once to send multiple frames and the interframe
813spacing is reduced.
814This technique can significantly increase throughput by reducing
815transmission overhead.
816Packet bursting is supported by the 802.11e QoS specification
817and some devices that do not support QoS may still be capable.
818By default packet bursting is enabled if a device is capable
819of doing it.
820To disable packet bursting, use
821.Fl burst .
822.It Cm chanlist Ar channels
823Set the desired channels to use when scanning for access
824points, neighbors in an IBSS network, or looking for unoccupied
825channels when operating as an access point.
826The set of channels is specified as a comma-separated list with
827each element in the list representing either a single channel number or a range
828of the form
829.Dq Li a-b .
830Channel numbers must be in the range 1 to 255 and be permissible
831according to the operating characteristics of the device.
832.It Cm channel Ar number
833Set a single desired channel.
834Channels range from 1 to 255, but the exact selection available
835depends on the region your adaptor was manufactured for.
836Setting
837the channel to
838.Li any ,
839or
840.Cm -
841will clear any desired channel and, if the device is marked up,
842force a scan for a channel to operate on.
843Alternatively the frequency, in megahertz, may be specified
844instead of the channel number.
845.Pp
846When there are several ways to use a channel the channel
847number/frequency may be appended with attributes to clarify.
848For example, if a device is capable of operating on channel 6
849with 802.11n and 802.11g then one can specify that g-only use
850should be used by specifying ``6:g''.
851Similarly the channel width can be specified by appending it
852with ``/''; e.g. ``6/40'' specifies a 40MHz wide channel,
853These attributes can be combined as in: ``6:ht/40''.
854The full set of flags specified following a `:'' are:
855.Cm a
856(802.11a),
857.Cm b
858(802.11b),
859.Cm d
860(Atheros Dynamic Turbo mode),
861.Cm g
862(802.11g),
863.Cm h
864or
865.Cm n
866(802.11n aka HT),
867.Cm s
868(Atheros Static Turbo mode),
869and
870.Cm t
871(Atheros Dynamic Turbo mode, or appended to ``st'' and ``dt'').
872The full set of channel widths following a '/' are:
873.Cm 5
874(5MHz aka quarter-rate channel),
875.Cm 10
876(10MHz aka half-rate channel),
877.Cm 20
878(20MHz mostly for use in specifying ht20),
879and
880.Cm 40
881(40MHz mostly for use in specifying ht40),
882In addition,
883a 40MHz HT channel specification may include the location
884of the extension channel by appending ``+'' or ``-'' for above and below,
885respectively; e.g. ``2437:ht/40+'' specifies 40MHz wide HT operation
886with the center channel at frequency 2437 and the extension channel above.
887.It Cm country Ar name
888Set the country code to use in calculating the regulatory constraints
889for operation.
890In particular the set of available channels, how the wireless device
891will operation on the channels, and the maximum transmit power that
892can be used on a channel are defined by this setting.
893Country/Region codes are specified as a 2-character abbreviation
894defined by ISO 3166 or using a longer, but possibly ambiguous, spelling;
895e.g. "ES" and "Spain".
896The set of country codes are taken from /etc/regdomain.xml and can also
897be viewed with the ``list countries'' request.
898Note that not all devices support changing the country code from a default
899setting; typically stored in EEPROM.
900See also
901.Cm regdomain ,
902.Cm indoor ,
903.Cm outdoor ,
904and
905.Cm anywhere .
906.It Cm dfs
907Enable Dynamic Frequency Selection (DFS) as specified in 802.11h.
908DFS embodies several facilities including detection of overlapping
909radar signals, dynamic transmit power control, and channel selection
910according to a least-congested criteria.
911DFS support is mandatory for some 5Ghz frequencies in certain
912locales (e.g. ETSI).
913By default DFS is enabled according to the regulatory definitions
914specified in /etc/regdomain.xml and the curent country code, regdomain,
915and channel.
916Note the underlying device (and driver) must support radar detection
917for full DFS support to work.
918To be fully compliant with the local regulatory agency frequencies that
919require DFS should not be used unless it is fully supported.
920Use
921.Fl dfs
922to disable this functionality for testing.
923.It Cm dotd
924Enable support for the 802.11d specification (default).
925When this support is enabled in station mode, beacon frames that advertise
926a country code different than the currently configured country code will
927cause an event to be dispatched to user applications.
928This event can be used by the station to adopt that country code and
929operate according to the associated regulatory constraints.
930When operating as an access point with 802.11d enabled the beacon and
931probe response frames transmitted will advertise the current regulatory
932domain settings.
933To disable 802.11d use
934.Fl dotd .
935.It Cm doth
936Enable 802.11h support including spectrum management.
937When 802.11h is enabled beacon and probe response frames will have
938the SpectrumMgt bit set in the capabilities field and
939country and power constraint information elements will be present.
940802.11h support also includes handling Channel Switch Announcements (CSA)
941which are a mechanism to coordinate channel changes by an access point.
942By default 802.11h is enabled if the device is capable.
943To disable 802.11h use
944.Fl doth .
945.It Cm deftxkey Ar index
946Set the default key to use for transmission.
947Typically this is only set when using WEP encryption.
948Note that you must set a default transmit key
949for the system to know which key to use in encrypting outbound traffic.
950The
951.Cm weptxkey
952is an alias for this request; it is provided for backwards compatibility.
953.It Cm dtimperiod Ar period
954Set the
955DTIM
956period for transmitting buffered multicast data frames when
957operating in ap mode.
958The
959.Ar period
960specifies the number of beacon intervals between DTIM
961and must be in the range 1 to 15.
962By default DTIM is 1 (i.e., DTIM occurs at each beacon).
963.It Cm dturbo
964Enable the use of Atheros Dynamic Turbo mode when communicating with
965another Dynamic Turbo-capable station.
966Dynamic Turbo mode is an Atheros-specific mechanism by which
967stations switch between normal 802.11 operation and a ``boosted''
968mode in which a 40MHz wide channel is used for communication.
969Stations using Dynamic Turbo mode operate boosted only when the
970channel is free of non-dturbo stations; when a non-dturbo station
971is identified on the channel all stations will automatically drop
972back to normal operation.
973By default, Dynamic Turbo mode is not enabled, even if the device is capable.
974Note that turbo mode (dynamic or static) is only allowed on some
975channels depending on the regulatory constraints; use the
976.Cm list chan
977command to identify the channels where turbo mode may be used.
978To disable Dynamic Turbo mode use
979.Fl dturbo .
980.It Cm dwds
981Enable Dynamic WDS (DWDS) support.
982DWDS is a facility by which 4-address traffic can be carried between
983stations operating in infrastructure mode.
984A station first associates to an access point and authenticates using
985normal procedures (e.g. WPA).
986Then 4-address frames are passed to carry traffic for stations
987operating on either side of the wireless link.
988DWDS extends the normal WDS mechanism by leveraging existing security
989protocols and eliminating static binding.
990.Pp
991When DWDS is enabled on an access point 4-address frames received from
992an authorized station will generate a ``DWDS discovery'' event to user
993applications.
994This event should be used to create a WDS interface that is bound
995to the remote station (and usually plumbed into a bridge).
996Once the WDS interface is up and running 4-address traffic then logically
997flows through that interface.
998.Pp
999When DWDS is enabled on a station, traffic with a destination address
1000different from the peer station are encapsulated in a 4-address frame
1001and transmitted to the peer.
1002All 4-address traffic uses the security information of the stations
1003(e.g. cryptographic keys).
1004A station is associated using 802.11n facilities may transport
10054-address traffic using these same mechanisms; this depends on available
1006resources and capabilities of the device.
1007The DWDS implementation guards against layer 2 routing loops of
1008multicast traffic.
1009.It Cm ff
1010Enable the use of Atheros Fast Frames when communicating with
1011another Fast Frames-capable station.
1012Fast Frames are an encapsulation technique by which two 802.3
1013frames are transmitted in a single 802.11 frame.
1014This can noticeably improve throughput but requires that the
1015receiving station understand how to decapsulate the frame.
1016Fast frame use is negotiated using the Atheros 802.11 vendor-specific
1017protocol extension so enabling use is safe when communicating with
1018non-Atheros devices.
1019By default, use of fast frames is enabled if the device is capable.
1020To explicitly disable fast frames, use
1021.Fl ff .
1022.It Cm fragthreshold Ar length
1023Set the threshold for which transmitted frames are broken into fragments.
1024The
1025.Ar length
1026argument is the frame size in bytes and must be in the range 256 to 2346.
1027Setting
1028.Ar length
1029to
1030.Li 2346 ,
1031.Cm any ,
1032or
1033.Cm -
1034disables transmit fragmentation.
1035Not all adapters honor the fragmentation threshold.
1036.It Cm hidessid
1037When operating as an access point, do not broadcast the SSID
1038in beacon frames or respond to probe request frames unless
1039they are directed to the ap (i.e., they include the ap's SSID).
1040By default, the SSID is included in beacon frames and
1041undirected probe request frames are answered.
1042To re-enable the broadcast of the SSID etc., use
1043.Fl hidessid .
1044.It Cm ht
1045Enable use of High Throughput (HT) when using 802.11n (default).
1046The 802.11n specification includes mechanisms for operation
1047on 20MHz and 40MHz wide channels using different signalling mechanisms
1048than specified in 802.11b, 802.11g, and 802.11a.
1049Stations negotiate use of these facilities, termed HT20 and HT40,
1050when they associate.
1051To disable all use of 802.11n use
1052.Fl ht .
1053To disable use of HT20 (e.g. to force only HT40 use) use
1054.Fl ht20 .
1055To disable use of HT40 use
1056.Fl ht40 .
1057.Pp
1058HT configuration is used to ``auto promote'' operation
1059when several choices are available.
1060For example, if a station associates to an 11n-capable access point
1061it controls whether the station uses legacy operation, HT20, or HT40.
1062When an 11n-capable device is setup as an access point and
1063Auto Channel Selection is used to locate a channel to operate on,
1064HT configuration controls whether legacy, HT20, or HT40 operation is setup
1065on the selected channel.
1066If a fixed channel is specified for a station then HT configuration can
1067be given as part of the channel specification; e.g. 6:ht/20 to setup
1068HT20 operation on channel 6.
1069.It Cm htcompat
1070Enable use of compatibility support for pre-802.11n devices (default).
1071The 802.11n protocol specification went through several incompatible iterations.
1072Some vendors implemented 11n support to older specifications that
1073will not interoperate with a purely 11n-compliant station.
1074In particular the information elements included in management frames
1075for old devices are different.
1076When compatibility support is enabled both standard and compatible data
1077will be provided.
1078Stations that associate using the compatiblity mechanisms are flagged
1079in ``list sta''.
1080To disable compatiblity support use
1081.Fl htcompat .
1082.It Cm htprotmode Ar technique
1083For interfaces operating in 802.11n, use the specified
1084.Ar technique
1085for protecting HT frames in a mixed legacy/HT network.
1086The set of valid techniques is
1087.Cm off ,
1088and
1089.Cm rts
1090(RTS/CTS, default).
1091Technique names are case insensitive.
1092.It Cm inact
1093Enable inactivity processing for stations associated to an
1094access point (default).
1095When operating as an access point the 802.11 layer monitors
1096the activity of each associated station.
1097When a station is inactive for 5 minutes it will send several
1098``probe frames'' to see if the station is still present.
1099If no response is received then the station is deauthenticated.
1100Applications that prefer to handle this work can disable this
1101facility by using
1102.Fl inact .
1103.It Cm indoor
1104Set the location to use in calculating regulatory constraints.
1105The location is also advertised in beacon and probe response frames
1106when 802.11d is enabled with
1107.Cm dotd .
1108See also
1109.Cm outdoor ,
1110.Cm anywhere ,
1111.Cm country ,
1112and
1113.Cm regdomain .
1114.It Cm list active
1115Display the list of channels available for use taking into account
1116any restrictions set with the
1117.Cm chanlist
1118directive.
1119See the description of
1120.Cm list chan
1121for more information.
1122.It Cm list caps
1123Display the adaptor's capabilities, including the operating
1124modes supported.
1125.It Cm list chan
1126Display the list of channels available for use.
1127Channels are shown with their IEEE channel number, equivalent
1128frequency, and usage modes.
1129Channels identified as
1130.Ql 11g
1131are also usable in
1132.Ql 11b
1133mode.
1134Channels identified as
1135.Ql 11a Turbo
1136may be used only for Atheros' Static Turbo mode
1137(specified with
1138. Cm mediaopt turbo ) .
1139Channels marked with a
1140.Ql *
1141have a regulatory constraint that they be passively scanned.
1142This means a station is not permitted to transmit on the channel until
1143it identifies the channel is being used for 802.11 communication;
1144typically by hearing a beacon frame from an access point operating
1145on the channel.
1146.Cm list freq
1147is another way of requesting this information.
1148By default a compacted list of channels is displayed; if the
1149.Fl v
1150option is specified then all channels are shown.
1151.It Cm list countries
1152Display the set of country codes and regulatory domains that can be
1153used in regulatory configuration.
1154.It Cm list mac
1155Display the current MAC Access Control List state.
1156Each address is prefixed with a character that indicates the
1157current policy applied to it:
1158.Ql +
1159indicates the address is allowed access,
1160.Ql -
1161indicates the address is denied access,
1162.Ql *
1163indicates the address is present but the current policy open
1164(so the ACL is not consulted).
1165.It Cm list mesh
1166Displays the mesh routing table, used for forwarding packets on a mesh
1167network.
1168.It Cm list regdomain
1169Display the current regulatory settings including the available channels
1170and transmit power caps.
1171.It Cm list roam
1172Display the parameters that govern roaming operation.
1173.It Cm list txparam
1174Display the parameters that govern transmit operation.
1175.It Cm list txpower
1176Display the transmit power caps for each channel.
1177.It Cm list scan
1178Display the access points and/or ad-hoc neighbors
1179located in the vicinity.
1180This information may be updated automatically by the adapter
1181with a
1182.Cm scan
1183request or through background scanning.
1184Depending on the capabilities of the stations the following
1185flags can be included in the output:
1186.Bl -tag -width 3n
1187.It Li A
1188Authorized.
1189Indicates that the station is permitted to send/receive data frames.
1190.It Li E
1191Extended Rate Phy (ERP).
1192Indicates that the station is operating in an 802.11g network
1193using extended transmit rates.
1194.It Li H
1195High Throughput (HT).
1196Indicates that the station is using HT transmit rates.
1197If a `+' follows immediately after then the station associated
1198using deprecated mechanisms supported only when
1199.Cm htcompat
1200is enabled.
1201.It Li P
1202Power Save.
1203Indicates that the station is operating in power save mode.
1204.It Li Q
1205Quality of Service (QoS).
1206Indicates that the station is using QoS encapsulation for
1207data frame.
1208QoS encapsulation is enabled only when WME mode is enabled.
1209.It Li T
1210Transitional Security Network (TSN).
1211Indicates that the station associated using TSN; see also
1212.Cm tsn
1213below.
1214.It Li W
1215Wi-Fi Protected Setup (WPS).
1216Indicates that the station associated using WPS.
1217.El
1218.Pp
1219By default interesting information elements captured from the neighboring
1220stations are displayed at the end of each row.
1221Possible elements include:
1222.Cm WME
1223(station supports WME),
1224.Cm WPA
1225(station supports WPA),
1226.Cm WPS
1227(station supports WPS),
1228.Cm RSN
1229(station supports 802.11i/RSN),
1230.Cm HTCAP
1231(station supports 802.11n/HT communication),
1232.Cm ATH
1233(station supports Atheros protocol extensions),
1234.Cm VEN
1235(station supports unknown vendor-specific extensions).
1236If the
1237.Fl v
1238flag is used all the information elements and their
1239contents will be shown.
1240Specifying the
1241.Fl v
1242flag also enables display of long SSIDs.
1243The
1244.Cm list ap
1245command is another way of requesting this information.
1246.It Cm list sta
1247When operating as an access point display the stations that are
1248currently associated.
1249When operating in ad-hoc mode display stations identified as
1250neighbors in the IBSS.
1251When operating in mesh mode display stations identified as
1252neighbors in the MBSS.
1253When operating in station mode display the access point.
1254Capabilities advertised by the stations are described under
1255the
1256.Cm scan
1257request.
1258Depending on the capabilities of the stations the following
1259flags can be included in the output:
1260.Bl -tag -width 3n
1261.It Li A
1262Authorized.
1263Indicates that the station is permitted to send/receive data frames.
1264.It Li E
1265Extended Rate Phy (ERP).
1266Indicates that the station is operating in an 802.11g network
1267using extended transmit rates.
1268.It Li H
1269High Throughput (HT).
1270Indicates that the station is using HT transmit rates.
1271If a `+' follows immediately after then the station associated
1272using deprecated mechanisms supported only when
1273.Cm htcompat
1274is enabled.
1275.It Li P
1276Power Save.
1277Indicates that the station is operating in power save mode.
1278.It Li Q
1279Quality of Service (QoS).
1280Indicates that the station is using QoS encapsulation for
1281data frame.
1282QoS encapsulation is enabled only when WME mode is enabled.
1283.It Li T
1284Transitional Security Network (TSN).
1285Indicates that the station associated using TSN; see also
1286.Cm tsn
1287below.
1288.It Li W
1289Wi-Fi Protected Setup (WPS).
1290Indicates that the station associated using WPS.
1291.El
1292.Pp
1293By default information elements received from associated stations
1294are displayed in a short form; the
1295.Fl v
1296flag causes this information to be displayed symbolically.
1297.It Cm list wme
1298Display the current channel parameters to use when operating in WME mode.
1299If the
1300.Fl v
1301option is specified then both channel and BSS parameters are displayed
1302for each AC (first channel, then BSS).
1303When WME mode is enabled for an adaptor this information will be
1304displayed with the regular status; this command is mostly useful
1305for examining parameters when WME mode is disabled.
1306See the description of the
1307.Cm wme
1308directive for information on the various parameters.
1309.It Cm maxretry Ar count
1310Set the maximum number of tries to use in sending unicast frames.
1311The default setting is 6 but drivers may override this with a value
1312they choose.
1313.It Cm mcastrate Ar rate
1314Set the rate for transmitting multicast/broadcast frames.
1315Rates are specified as megabits/second in decimal; e.g.\& 5.5 for 5.5 Mb/s.
1316This rate should be valid for the current operating conditions;
1317if an invalid rate is specified drivers are free to chose an
1318appropriate rate.
1319.It Cm mgtrate Ar rate
1320Set the rate for transmitting management and/or control frames.
1321Rates are specified as megabits/second in decimal; e.g.\& 5.5 for 5.5 Mb/s.
1322.It Cm outdoor
1323Set the location to use in calculating regulatory constraints.
1324The location is also advertised in beacon and probe response frames
1325when 802.11d is enabled with
1326.Cm dotd .
1327See also
1328.Cm anywhere ,
1329.Cm country ,
1330.Cm indoor ,
1331and
1332.Cm regdomain .
1333.It Cm powersave
1334Enable powersave operation.
1335When operating as a client, the station will conserve power by
1336periodically turning off the radio and listening for
1337messages from the access point telling it there are packets waiting.
1338The station must then retrieve the packets.
1339Not all devices support power save operation as a client.
1340The 802.11 specification requires that all access points support
1341power save but some drivers do not.
1342Use
1343.Fl powersave
1344to disable powersave operation when operating as a client.
1345.It Cm powersavesleep Ar sleep
1346Set the desired max powersave sleep time in TU's (1024 usecs).
1347By default the max powersave sleep time is 100 TU's.
1348.It Cm protmode Ar technique
1349For interfaces operating in 802.11g, use the specified
1350.Ar technique
1351for protecting OFDM frames in a mixed 11b/11g network.
1352The set of valid techniques is
1353.Cm off , cts
1354(CTS to self),
1355and
1356.Cm rtscts
1357(RTS/CTS).
1358Technique names are case insensitive.
1359Not all devices support
1360.Cm cts
1361as a protection technique.
1362.It Cm pureg
1363When operating as an access point in 802.11g mode allow only
136411g-capable stations to associate (11b-only stations are not
1365permitted to associate).
1366To allow both 11g and 11b-only stations to associate, use
1367.Fl pureg .
1368.It Cm puren
1369When operating as an access point in 802.11n mode allow only
1370HT-capable stations to associate (legacy stations are not
1371permitted to associate).
1372To allow both HT and legacy stations to associate, use
1373.Fl puren .
1374.It Cm regdomain Ar sku
1375Set the regulatory domain to use in calculating the regulatory constraints
1376for operation.
1377In particular the set of available channels, how the wireless device
1378will operation on the channels, and the maximum transmit power that
1379can be used on a channel are defined by this setting.
1380Regdomain codes (SKU's) are taken from /etc/regdomain.xml and can also
1381be viewed with the ``list countries'' request.
1382Note that not all devices support changing the regdomain from a default
1383setting; typically stored in EEPROM.
1384See also
1385.Cm country ,
1386.Cm indoor ,
1387.Cm outdoor ,
1388and
1389.Cm anywhere .
1390.It Cm rifs
1391Enable use of Reduced InterFrame Spacing (RIFS) when operating in 802.11n
1392on an HT channel.
1393Note that RIFS must be supported by both the station and access point
1394for it to be used.
1395To disable RIFS use
1396.Fl rifs .
1397.It Cm roam:rate Ar rate
1398Set the threshold for controlling roaming when operating in a BSS.
1399The
1400.Ar rate
1401parameter specifies the transmit rate in megabits
1402at which roaming should be considered.
1403If the current transmit rate drops below this setting and background scanning
1404is enabled, then the system will check if a more desirable access point is
1405available and switch over to it.
1406The current scan cache contents are used if they are considered
1407valid according to the
1408.Cm scanvalid
1409parameter; otherwise a background scan operation is triggered before
1410any selection occurs.
1411Each channel type has a separate rate threshold; the default values are:
141212 Mb/s (11a), 2 Mb/s (11b), 2 Mb/s (11g), MCS 1 (11na, 11ng).
1413.It Cm roam:rssi Ar rssi
1414Set the threshold for controlling roaming when operating in a BSS.
1415The
1416.Ar rssi
1417parameter specifies the receive signal strength in dBm units
1418at which roaming should be considered.
1419If the current rssi drops below this setting and background scanning
1420is enabled, then the system will check if a more desirable access point is
1421available and switch over to it.
1422The current scan cache contents are used if they are considered
1423valid according to the
1424.Cm scanvalid
1425parameter; otherwise a background scan operation is triggered before
1426any selection occurs.
1427Each channel type has a separate rssi threshold; the default values are
1428all 7 dBm.
1429.It Cm roaming Ar mode
1430When operating as a station, control how the system will
1431behave when communication with the current access point
1432is broken.
1433The
1434.Ar mode
1435argument may be one of
1436.Cm device
1437(leave it to the hardware device to decide),
1438.Cm auto
1439(handle either in the device or the operating system\[em]as appropriate),
1440.Cm manual
1441(do nothing until explicitly instructed).
1442By default, the device is left to handle this if it is
1443capable; otherwise, the operating system will automatically
1444attempt to reestablish communication.
1445Manual mode is used by applications such as
1446.Xr wpa_supplicant 8
1447that want to control the selection of an access point.
1448.It Cm rtsthreshold Ar length
1449Set the threshold for which
1450transmitted frames are preceded by transmission of an
1451RTS
1452control frame.
1453The
1454.Ar length
1455argument
1456is the frame size in bytes and must be in the range 1 to 2346.
1457Setting
1458.Ar length
1459to
1460.Li 2346 ,
1461.Cm any ,
1462or
1463.Cm -
1464disables transmission of RTS frames.
1465Not all adapters support setting the RTS threshold.
1466.It Cm scan
1467Initiate a scan of neighboring stations, wait for it to complete, and
1468display all stations found.
1469Only the super-user can initiate a scan.
1470See
1471.Cm list scan
1472for information on the display.
1473By default a background scan is done; otherwise a foreground
1474scan is done and the station may roam to a different access point.
1475The
1476.Cm list scan
1477request can be used to show recent scan results without
1478initiating a new scan.
1479.It Cm scanvalid Ar threshold
1480Set the maximum time the scan cache contents are considered valid;
1481i.e. will be used without first triggering a scan operation to
1482refresh the data.
1483The
1484.Ar threshold
1485parameter is specified in seconds and defaults to 60 seconds.
1486The minimum setting for
1487.Ar threshold
1488is 10 seconds.
1489One should take care setting this threshold; if it is set too low
1490then attempts to roam to another access point may trigger unnecessary
1491background scan operations.
1492.It Cm shortgi
1493Enable use of Short Guard Interval when operating in 802.11n
1494on an HT channel.
1495NB: this currently enables Short GI on both HT40 and HT20 channels.
1496To disable Short GI use
1497.Fl shortgi .
1498.It Cm smps
1499Enable use of Static Spatial Multiplexing Power Save (SMPS)
1500when operating in 802.11n.
1501A station operating with Static SMPS maintains only a single
1502receive chain active (this can significantly reduce power consumption).
1503To disable SMPS use
1504.Fl smps .
1505.It Cm smpsdyn
1506Enable use of Dynamic Spatial Multiplexing Power Save (SMPS)
1507when operating in 802.11n.
1508A station operating with Dynamic SMPS maintains only a single
1509receive chain active but switches to multiple receive chains when it
1510receives an RTS frame (this can significantly reduce power consumption).
1511Note that stations cannot distinguish between RTS/CTS intended to
1512enable multiple receive chains and those used for other purposes.
1513To disable SMPS use
1514.Fl smps .
1515.It Cm ssid Ar ssid
1516Set the desired Service Set Identifier (aka network name).
1517The SSID is a string up to 32 characters
1518in length and may be specified as either a normal string or in
1519hexadecimal when preceded by
1520.Ql 0x .
1521Additionally, the SSID may be cleared by setting it to
1522.Ql - .
1523.It Cm tdmaslot Ar slot
1524When operating with TDMA, use the specified
1525.Ar slot
1526configuration.
1527The
1528.Ar slot
1529is a number between 0 and the maximum number of slots in the BSS.
1530Note that a station configured as slot 0 is a master and
1531will broadcast beacon frames advertising the BSS;
1532stations configured to use other slots will always
1533scan to locate a master before they ever transmit.
1534By default
1535.Cm tdmaslot
1536is set to 1.
1537.It Cm tdmaslotcnt Ar cnt
1538When operating with TDMA, setup a BSS with
1539.Ar cnt
1540slots.
1541The slot count may be at most 8.
1542The current implementation is only tested with two stations
1543(i.e. point to point applications).
1544This setting is only meaningful when a station is configured as slot 0;
1545other stations adopt this setting from the BSS they join.
1546By default
1547.Cm tdmaslotcnt
1548is set to 2.
1549.It Cm tdmaslotlen Ar len
1550When operating with TDMA, setup a BSS such that each station has a slot
1551.Ar len
1552microseconds long.
1553The slot length must be at least 150 microseconds (1/8 TU)
1554and no more than 65 milliseconds.
1555Note that setting too small a slot length may result in poor channel
1556bandwidth utilization due to factors such as timer granularity and
1557guard time.
1558This setting is only meaningful when a station is configured as slot 0;
1559other stations adopt this setting from the BSS they join.
1560By default
1561.Cm tdmaslotlen
1562is set to 10 milliseconds.
1563.It Cm tdmabintval Ar intval
1564When operating with TDMA, setup a BSS such that beacons are transmitted every
1565.Ar intval
1566superframes to synchronize the TDMA slot timing.
1567A superframe is defined as the number of slots times the slot length; e.g.
1568a BSS with two slots of 10 milliseconds has a 20 millisecond superframe.
1569The beacon interval may not be zero.
1570A lower setting of
1571.Cm tdmabintval
1572causes the timers to be resynchronized more often; this can be help if
1573significant timer drift is observed.
1574By default
1575.Cm tdmabintval
1576is set to 5.
1577.It Cm tsn
1578When operating as an access point with WPA/802.11i allow legacy
1579stations to associate using static key WEP and open authentication.
1580To disallow legacy station use of WEP, use
1581.Fl tsn .
1582.It Cm txpower Ar power
1583Set the power used to transmit frames.
1584The
1585.Ar power
1586argument is specified in .5 dBm units.
1587Out of range values are truncated.
1588Typically only a few discreet power settings are available and
1589the driver will use the setting closest to the specified value.
1590Not all adapters support changing the transmit power.
1591.It Cm ucastrate Ar rate
1592Set a fixed rate for transmitting unicast frames.
1593Rates are specified as megabits/second in decimal; e.g.\& 5.5 for 5.5 Mb/s.
1594This rate should be valid for the current operating conditions;
1595if an invalid rate is specified drivers are free to chose an
1596appropriate rate.
1597.It Cm wepmode Ar mode
1598Set the desired WEP mode.
1599Not all adapters support all modes.
1600The set of valid modes is
1601.Cm off , on ,
1602and
1603.Cm mixed .
1604The
1605.Cm mixed
1606mode explicitly tells the adaptor to allow association with access
1607points which allow both encrypted and unencrypted traffic.
1608On these adapters,
1609.Cm on
1610means that the access point must only allow encrypted connections.
1611On other adapters,
1612.Cm on
1613is generally another name for
1614.Cm mixed .
1615Modes are case insensitive.
1616.It Cm weptxkey Ar index
1617Set the WEP key to be used for transmission.
1618This is the same as setting the default transmission key with
1619.Cm deftxkey .
1620.It Cm wepkey Ar key Ns | Ns Ar index : Ns Ar key
1621Set the selected WEP key.
1622If an
1623.Ar index
1624is not given, key 1 is set.
1625A WEP key will be either 5 or 13
1626characters (40 or 104 bits) depending of the local network and the
1627capabilities of the adaptor.
1628It may be specified either as a plain
1629string or as a string of hexadecimal digits preceded by
1630.Ql 0x .
1631For maximum portability, hex keys are recommended;
1632the mapping of text keys to WEP encryption is usually driver-specific.
1633In particular, the
1634.Tn Windows
1635drivers do this mapping differently to
1636.Fx .
1637A key may be cleared by setting it to
1638.Ql - .
1639If WEP is supported then there are at least four keys.
1640Some adapters support more than four keys.
1641If that is the case, then the first four keys
1642(1-4) will be the standard temporary keys and any others will be adaptor
1643specific keys such as permanent keys stored in NVRAM.
1644.Pp
1645Note that you must set a default transmit key with
1646.Cm deftxkey
1647for the system to know which key to use in encrypting outbound traffic.
1648.It Cm wme
1649Enable Wireless Multimedia Extensions (WME) support, if available,
1650for the specified interface.
1651WME is a subset of the IEEE 802.11e standard to support the
1652efficient communication of realtime and multimedia data.
1653To disable WME support, use
1654.Fl wme .
1655Another name for this parameter is
1656.Cm wmm .
1657.Pp
1658The following parameters are meaningful only when WME support is in use.
1659Parameters are specified per-AC (Access Category) and
1660split into those that are used by a station when acting
1661as an access point and those for client stations in the BSS.
1662The latter are received from the access point and may not be changed
1663(at the station).
1664The following Access Categories are recognized:
1665.Pp
1666.Bl -tag -width ".Cm AC_BK" -compact
1667.It Cm AC_BE
1668(or
1669.Cm BE )
1670best effort delivery,
1671.It Cm AC_BK
1672(or
1673.Cm BK )
1674background traffic,
1675.It Cm AC_VI
1676(or
1677.Cm VI )
1678video traffic,
1679.It Cm AC_VO
1680(or
1681.Cm VO )
1682voice traffic.
1683.El
1684.Pp
1685AC parameters are case-insensitive.
1686Traffic classification is done in the operating system using the
1687vlan priority associated with data frames or the
1688ToS (Type of Service) indication in IP-encapsulated frames.
1689If neither information is present, traffic is assigned to the
1690Best Effort (BE) category.
1691.Bl -tag -width indent
1692.It Cm ack Ar ac
1693Set the ACK policy for QoS transmissions by the local station;
1694this controls whether or not data frames transmitted by a station
1695require an ACK response from the receiving station.
1696To disable waiting for an ACK use
1697.Fl ack .
1698This parameter is applied only to the local station.
1699.It Cm acm Ar ac
1700Enable the Admission Control Mandatory (ACM) mechanism
1701for transmissions by the local station.
1702To disable the ACM use
1703.Fl acm .
1704On stations in a BSS this parameter is read-only and indicates
1705the setting received from the access point.
1706NB: ACM is not supported right now.
1707.It Cm aifs Ar ac Ar count
1708Set the Arbitration Inter Frame Spacing (AIFS)
1709channel access parameter to use for transmissions
1710by the local station.
1711On stations in a BSS this parameter is read-only and indicates
1712the setting received from the access point.
1713.It Cm cwmin Ar ac Ar count
1714Set the CWmin channel access parameter to use for transmissions
1715by the local station.
1716On stations in a BSS this parameter is read-only and indicates
1717the setting received from the access point.
1718.It Cm cwmax Ar ac Ar count
1719Set the CWmax channel access parameter to use for transmissions
1720by the local station.
1721On stations in a BSS this parameter is read-only and indicates
1722the setting received from the access point.
1723.It Cm txoplimit Ar ac Ar limit
1724Set the Transmission Opportunity Limit channel access parameter
1725to use for transmissions by the local station.
1726This parameter defines an interval of time when a WME station
1727has the right to initiate transmissions onto the wireless medium.
1728On stations in a BSS this parameter is read-only and indicates
1729the setting received from the access point.
1730.It Cm bss:aifs Ar ac Ar count
1731Set the AIFS channel access parameter to send to stations in a BSS.
1732This parameter is meaningful only when operating in ap mode.
1733.It Cm bss:cwmin Ar ac Ar count
1734Set the CWmin channel access parameter to send to stations in a BSS.
1735This parameter is meaningful only when operating in ap mode.
1736.It Cm bss:cwmax Ar ac Ar count
1737Set the CWmax channel access parameter to send to stations in a BSS.
1738This parameter is meaningful only when operating in ap mode.
1739.It Cm bss:txoplimit Ar ac Ar limit
1740Set the TxOpLimit channel access parameter to send to stations in a BSS.
1741This parameter is meaningful only when operating in ap mode.
1742.El
1743.It Cm wps
1744Enable Wireless Privacy Subscriber support.
1745Note that WPS support requires a WPS-capable supplicant.
1746To disable this function use
1747.Fl wps .
1748.El
1749.Pp
1750The following parameters support an optional access control list
1751feature available with some adapters when operating in ap mode; see
1752.Xr wlan_acl 4 .
1753This facility allows an access point to accept/deny association
1754requests based on the MAC address of the station.
1755Note that this feature does not significantly enhance security
1756as MAC address spoofing is easy to do.
1757.Bl -tag -width indent
1758.It Cm mac:add Ar address
1759Add the specified MAC address to the database.
1760Depending on the policy setting association requests from the
1761specified station will be allowed or denied.
1762.It Cm mac:allow
1763Set the ACL policy to permit association only by
1764stations registered in the database.
1765.It Cm mac:del Ar address
1766Delete the specified MAC address from the database.
1767.It Cm mac:deny
1768Set the ACL policy to deny association only by
1769stations registered in the database.
1770.It Cm mac:kick Ar address
1771Force the specified station to be deauthenticated.
1772This typically is done to block a station after updating the
1773address database.
1774.It Cm mac:open
1775Set the ACL policy to allow all stations to associate.
1776.It Cm mac:flush
1777Delete all entries in the database.
1778.It Cm mac:radius
1779Set the ACL policy to permit association only by
1780stations approved by a RADIUS server.
1781Note that this feature requires the
1782.Xr hostapd 8
1783program be configured to do the right thing
1784as it handles the RADIUS processing
1785(and marks stations as authorized).
1786.El
1787.Pp
1788The following parameters are related to a wireless interface operating in mesh
1789mode:
1790.Bl -tag -width indent
1791.It Cm meshid Ar meshid
1792Set the desired Mesh Identifier.
1793The Mesh ID is a string up to 32 characters in length.
1794A mesh interface must have a Mesh Identifier specified
1795to reach an operational state.
1796.It Cm meshttl Ar ttl
1797Set the desired ``time to live'' for mesh forwarded packets;
1798this is the number of hops a packet may be forwarded before
1799it is discarded.
1800The default setting for
1801.Cm meshttl
1802is 31.
1803.It Cm meshpeering
1804Enable or disable peering with neighbor mesh stations.
1805Stations must peer before any data packets can be exchanged.
1806By default
1807.Cm meshpeering
1808is enabled.
1809.It Cm meshforward
1810Enable or disable forwarding packets by a mesh interface.
1811By default
1812.Cm meshforward
1813is enabled.
1814.It Cm meshmetric Ar protocol
1815Set the specified
1816.Ar protocol
1817as the link metric protocol used on a mesh network.
1818The default protocol is called
1819.Ar AIRTIME .
1820The mesh interface will restart after changing this setting.
1821.It Cm meshpath Ar protocol
1822Set the specified
1823.Ar protocol
1824as the path selection protocol used on a mesh network.
1825The only available protocol at the moment is called
1826.Ar HWMP
1827(Hybrid Wireless Mesh Protocol).
1828The mesh interface will restart after changing this setting.
1829.It Cm hwmprootmode Ar mode
1830Stations on a mesh network can operate as ``root nodes.''
1831Root nodes try to find paths to all mesh nodes and advertise themselves
1832regularly.
1833When there is a root mesh node on a network, other mesh nodes can setup
1834paths between themselves faster because they can use the root node
1835to find the destination.
1836This path may not be the best, but on-demand
1837routing will eventually find the best path.
1838The following modes are recognized:
1839.Pp
1840.Bl -tag -width ".Cm PROACTIVE" -compact
1841.It Cm DISABLED
1842Disable root mode.
1843.It Cm NORMAL
1844Send broadcast path requests every two seconds.
1845Nodes on the mesh without a path to this root mesh station with try to
1846discover a path to us.
1847.It Cm PROACTIVE
1848Send broadcast path requests every two seconds and every node must reply with
1849with a path reply even if it already has a path to this root mesh station,
1850.It Cm RANN
1851Send broadcast root annoucement (RANN) frames.
1852Nodes on the mesh without a path to this root mesh station with try to
1853discover a path to us.
1854.El
1855By default
1856.Cm hwmprootmode
1857is set to
1858.Ar DISABLED .
1859.It Cm hwmpmaxhops Ar cnt
1860Set the maximum number of hops allowed in an HMWP path to
1861.Ar cnt .
1862The default setting for
1863.Cm hwmpmaxhops
1864is 31.
1865.El
1866.Pp
1867The following parameters are for compatibility with other systems:
1868.Bl -tag -width indent
1869.It Cm nwid Ar ssid
1870Another name for the
1871.Cm ssid
1872parameter.
1873Included for
1874.Nx
1875compatibility.
1876.It Cm stationname Ar name
1877Set the name of this station.
1878The station name is not part of the IEEE 802.11
1879protocol though some interfaces support it.
1880As such it only
1881seems to be meaningful to identical or virtually identical equipment.
1882Setting the station name is identical in syntax to setting the SSID.
1883One can also use
1884.Cm station
1885for
1886.Bsx
1887compatibility.
1888.It Cm wep
1889Another way of saying
1890.Cm wepmode on .
1891Included for
1892.Bsx
1893compatibility.
1894.It Fl wep
1895Another way of saying
1896.Cm wepmode off .
1897Included for
1898.Bsx
1899compatibility.
1900.It Cm nwkey key
1901Another way of saying:
1902.Dq Li "wepmode on weptxkey 1 wepkey 1:key wepkey 2:- wepkey 3:- wepkey 4:-" .
1903Included for
1904.Nx
1905compatibility.
1906.It Cm nwkey Xo
1907.Sm off
1908.Ar n : k1 , k2 , k3 , k4
1909.Sm on
1910.Xc
1911Another way of saying
1912.Dq Li "wepmode on weptxkey n wepkey 1:k1 wepkey 2:k2 wepkey 3:k3 wepkey 4:k4" .
1913Included for
1914.Nx
1915compatibility.
1916.It Fl nwkey
1917Another way of saying
1918.Cm wepmode off .
1919Included for
1920.Nx
1921compatibility.
1922.El
1923.Pp
1924The following parameters are specific to bridge interfaces:
1925.Bl -tag -width indent
1926.It Cm addm Ar interface
1927Add the interface named by
1928.Ar interface
1929as a member of the bridge.
1930The interface is put into promiscuous mode
1931so that it can receive every packet sent on the network.
1932.It Cm deletem Ar interface
1933Remove the interface named by
1934.Ar interface
1935from the bridge.
1936Promiscuous mode is disabled on the interface when
1937it is removed from the bridge.
1938.It Cm maxaddr Ar size
1939Set the size of the bridge address cache to
1940.Ar size .
1941The default is 100 entries.
1942.It Cm timeout Ar seconds
1943Set the timeout of address cache entries to
1944.Ar seconds
1945seconds.
1946If
1947.Ar seconds
1948is zero, then address cache entries will not be expired.
1949The default is 1200 seconds.
1950.It Cm addr
1951Display the addresses that have been learned by the bridge.
1952.It Cm static Ar interface-name Ar address
1953Add a static entry into the address cache pointing to
1954.Ar interface-name .
1955Static entries are never aged out of the cache or re-placed, even if the
1956address is seen on a different interface.
1957.It Cm deladdr Ar address
1958Delete
1959.Ar address
1960from the address cache.
1961.It Cm flush
1962Delete all dynamically-learned addresses from the address cache.
1963.It Cm flushall
1964Delete all addresses, including static addresses, from the address cache.
1965.It Cm discover Ar interface
1966Mark an interface as a
1967.Dq discovering
1968interface.
1969When the bridge has no address cache entry
1970(either dynamic or static)
1971for the destination address of a packet,
1972the bridge will forward the packet to all
1973member interfaces marked as
1974.Dq discovering .
1975This is the default for all interfaces added to a bridge.
1976.It Fl discover Ar interface
1977Clear the
1978.Dq discovering
1979attribute on a member interface.
1980For packets without the
1981.Dq discovering
1982attribute, the only packets forwarded on the interface are broadcast
1983or multicast packets and packets for which the destination address
1984is known to be on the interface's segment.
1985.It Cm learn Ar interface
1986Mark an interface as a
1987.Dq learning
1988interface.
1989When a packet arrives on such an interface, the source
1990address of the packet is entered into the address cache as being a
1991destination address on the interface's segment.
1992This is the default for all interfaces added to a bridge.
1993.It Fl learn Ar interface
1994Clear the
1995.Dq learning
1996attribute on a member interface.
1997.It Cm span Ar interface
1998Add the interface named by
1999.Ar interface
2000as a span port on the bridge.
2001Span ports transmit a copy of every frame received by the bridge.
2002This is most useful for snooping a bridged network passively on
2003another host connected to one of the span ports of the bridge.
2004.It Fl span Ar interface
2005Delete the interface named by
2006.Ar interface
2007from the list of span ports of the bridge.
2008.It Cm stp Ar interface
2009Enable Spanning Tree protocol on
2010.Ar interface .
2011The
2012.Xr bridge 4
2013driver has support for the IEEE 802.1D Spanning Tree protocol (STP).
2014Spanning Tree is used to detect and remove loops in a network topology.
2015.It Fl stp Ar interface
2016Disable Spanning Tree protocol on
2017.Ar interface .
2018This is the default for all interfaces added to a bridge.
2019.It Cm maxage Ar seconds
2020Set the time that a Spanning Tree protocol configuration is valid.
2021The default is 20 seconds.
2022The minimum is 1 second and the maximum is 255 seconds.
2023.It Cm fwddelay Ar seconds
2024Set the time that must pass before an interface begins forwarding
2025packets when Spanning Tree is enabled.
2026The default is 15 seconds.
2027The minimum is 1 second and the maximum is 255 seconds.
2028.It Cm hellotime Ar seconds
2029Set the time between broadcasting of Spanning Tree protocol
2030configuration messages.
2031The default is 2 seconds.
2032The minimum is 1 second and the maximum is 255 seconds.
2033.It Cm priority Ar value
2034Set the bridge priority for Spanning Tree.
2035The default is 32768.
2036The minimum is 0 and the maximum is 65536.
2037.It Cm ifpriority Ar interface Ar value
2038Set the Spanning Tree priority of
2039.Ar interface
2040to
2041.Ar value .
2042The default is 128.
2043The minimum is 0 and the maximum is 255.
2044.It Cm ifpathcost Ar interface Ar value
2045Set the Spanning Tree path cost of
2046.Ar interface
2047to
2048.Ar value .
2049The default is 55.
2050The minimum is 0 and the maximum is 65535.
2051.El
2052.Pp
2053The following parameters are specific to IP tunnel interfaces,
2054.Xr gif 4 :
2055.Bl -tag -width indent
2056.It Cm tunnel Ar src_addr dest_addr
2057Configure the physical source and destination address for IP tunnel
2058interfaces.
2059The arguments
2060.Ar src_addr
2061and
2062.Ar dest_addr
2063are interpreted as the outer source/destination for the encapsulating
2064IPv4/IPv6 header.
2065.It Fl tunnel
2066Unconfigure the physical source and destination address for IP tunnel
2067interfaces previously configured with
2068.Cm tunnel .
2069.It Cm deletetunnel
2070Another name for the
2071.Fl tunnel
2072parameter.
2073.El
2074.Pp
2075The following parameters are specific to
2076.Xr vlan 4
2077interfaces:
2078.Bl -tag -width indent
2079.It Cm vlan Ar vlan_tag
2080Set the VLAN tag value to
2081.Ar vlan_tag .
2082This value is a 16-bit number which is used to create an 802.1Q
2083VLAN header for packets sent from the
2084.Xr vlan 4
2085interface.
2086Note that
2087.Cm vlan
2088and
2089.Cm vlandev
2090must both be set at the same time.
2091.It Cm vlandev Ar iface
2092Associate the physical interface
2093.Ar iface
2094with a
2095.Xr vlan 4
2096interface.
2097Packets transmitted through the
2098.Xr vlan 4
2099interface will be
2100diverted to the specified physical interface
2101.Ar iface
2102with 802.1Q VLAN encapsulation.
2103Packets with 802.1Q encapsulation received
2104by the parent interface with the correct VLAN tag will be diverted to
2105the associated
2106.Xr vlan 4
2107pseudo-interface.
2108The
2109.Xr vlan 4
2110interface is assigned a
2111copy of the parent interface's flags and the parent's ethernet address.
2112The
2113.Cm vlandev
2114and
2115.Cm vlan
2116must both be set at the same time.
2117If the
2118.Xr vlan 4
2119interface already has
2120a physical interface associated with it, this command will fail.
2121To
2122change the association to another physical interface, the existing
2123association must be cleared first.
2124.Pp
2125Note: if the hardware tagging capability
2126is set on the parent interface, the
2127.Xr vlan 4
2128pseudo
2129interface's behavior changes:
2130the
2131.Xr vlan 4
2132interface recognizes that the
2133parent interface supports insertion and extraction of VLAN tags on its
2134own (usually in firmware) and that it should pass packets to and from
2135the parent unaltered.
2136.It Fl vlandev Op Ar iface
2137If the driver is a
2138.Xr vlan 4
2139pseudo device, disassociate the parent interface from it.
2140This breaks the link between the
2141.Xr vlan 4
2142interface and its parent,
2143clears its VLAN tag, flags and its link address and shuts the interface down.
2144The
2145.Ar iface
2146argument is useless and hence deprecated.
2147.El
2148.Pp
2149The following parameters are specific to
2150.Xr carp 4
2151interfaces:
2152.Bl -tag -width indent
2153.It Cm advbase Ar seconds
2154Specifies the base of the advertisement interval in seconds.
2155The acceptable values are 1 to 255.
2156The default value is 1.
2157.\" The default value is
2158.\" .Dv CARP_DFLTINTV .
2159.It Cm advskew Ar interval
2160Specifies the skew to add to the base advertisement interval to
2161make one host advertise slower than another host.
2162It is specified in 1/256 of seconds.
2163The acceptable values are 1 to 254.
2164The default value is 0.
2165.It Cm pass Ar phrase
2166Set the authentication key to
2167.Ar phrase .
2168.It Cm vhid Ar n
2169Set the virtual host ID.
2170This is a required setting.
2171Acceptable values are 1 to 255.
2172.El
2173.Pp
2174The
2175.Nm
2176utility displays the current configuration for a network interface
2177when no optional parameters are supplied.
2178If a protocol family is specified,
2179.Nm
2180will report only the details specific to that protocol family.
2181.Pp
2182If the
2183.Fl m
2184flag is passed before an interface name,
2185.Nm
2186will display the capability list and all
2187of the supported media for the specified interface.
2188If
2189.Fl L
2190flag is supplied, address lifetime is displayed for IPv6 addresses,
2191as time offset string.
2192.Pp
2193Optionally, the
2194.Fl a
2195flag may be used instead of an interface name.
2196This flag instructs
2197.Nm
2198to display information about all interfaces in the system.
2199The
2200.Fl d
2201flag limits this to interfaces that are down, and
2202.Fl u
2203limits this to interfaces that are up.
2204When no arguments are given,
2205.Fl a
2206is implied.
2207.Pp
2208The
2209.Fl l
2210flag may be used to list all available interfaces on the system, with
2211no other additional information.
2212Use of this flag is mutually exclusive
2213with all other flags and commands, except for
2214.Fl d
2215(only list interfaces that are down)
2216and
2217.Fl u
2218(only list interfaces that are up).
2219.Pp
2220The
2221.Fl v
2222flag may be used to get more verbose status for an interface.
2223.Pp
2224The
2225.Fl C
2226flag may be used to list all of the interface cloners available on
2227the system, with no additional information.
2228Use of this flag is mutually exclusive with all other flags and commands.
2229.Pp
2230The
2231.Fl k
2232flag causes keying information for the interface, if available, to be
2233printed.
2234For example, the values of 802.11 WEP keys will be printed, if accessible to
2235the current user.
2236This information is not printed by default, as it may be considered
2237sensitive.
2238.Pp
2239Only the super-user may modify the configuration of a network interface.
2240.Sh DIAGNOSTICS
2241Messages indicating the specified interface does not exist, the
2242requested address is unknown, or the user is not privileged and
2243tried to alter an interface's configuration.
2244.Sh SEE ALSO
2245.Xr netstat 1 ,
2246.Xr carp 4 ,
2247.Xr ifmedia 4 ,
2248.Xr netintro 4 ,
2249.Xr polling 4 ,
2250.Xr vlan 4 ,
2251.\" .Xr eon 5 ,
2252.Xr rc 8 ,
2253.Xr routed 8 ,
2254.Xr sysctl 8
2255.Sh HISTORY
2256The
2257.Nm
2258utility appeared in
2259.Bx 4.2 .
2260.Sh BUGS
2261Basic IPv6 node operation requires a link-local address on each
2262interface configured for IPv6.
2263Normally, such an address is automatically configured by the
2264kernel on each interface added to the system; this behaviour may
2265be disabled by setting the sysctl MIB variable
2266.Va net.inet6.ip6.auto_linklocal
2267to 0.
2268.Pp
2269If you delete such an address using
2270.Nm ,
2271the kernel may act very odd.
2272Do this at your own risk.