note the new method of changing link layer addresses using a PF_LINK

socket ioctl.
This commit is contained in:
plunky 2009-03-12 11:34:54 +00:00
parent 983cc8fecf
commit ca6f23c3d4
1 changed files with 9 additions and 20 deletions

View File

@ -1,4 +1,4 @@
.\" $NetBSD: tap.4,v 1.9 2009/03/09 18:09:39 plunky Exp $
.\" $NetBSD: tap.4,v 1.10 2009/03/12 11:34:54 plunky Exp $
.\"
.\" Copyright (c) 2004, 2005 The NetBSD Foundation.
.\" All rights reserved.
@ -24,7 +24,7 @@
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd March 9, 2009
.Dd March 10, 2009
.Dt TAP 4
.Os
.Sh NAME
@ -151,23 +151,13 @@ When a
.Nm
device is created, it is assigned an Ethernet address
of the form f2:0b:a4:xx:xx:xx.
This address can later be changed in two ways:
through a sysctl node, or an ioctl call.
.Pp
The sysctl node is net.link.tap.\*[Lt]iface\*[Gt].
Any string of six colon-separated hexadecimal numbers will be accepted.
Reading that node will provide a string representation of the current
Ethernet address.
.Pp
The address can also be changed with the
.Dv SIOCSIFPHYADDR
ioctl, which is used the same way as with
.Xr gif 4 .
The difference is in the family of the address which is passed inside the
.Ft struct ifaliasreq
argument, which should be set to
.Dv AF_LINK .
This ioctl call should be made on a socket, as it is not available on
This address can later be changed using
.Xr ifconfig 8
to add an active link layer address, or directly via the
.Dv SIOCALIFADDR
ioctl on a
.Dv PF_LINK
socket, as it is not available on
the ioctl handler of the character device interface.
.Sh FILES
.Bl -tag -compact -width /dev/tap[0-9]*
@ -179,7 +169,6 @@ individual character device nodes
.Sh SEE ALSO
.Xr bridge 4 ,
.Xr etherip 4 ,
.Xr gif 4 ,
.Xr tun 4 ,
.Xr ifconfig 8
.Sh HISTORY