NetBSD/share/man/man4/iso.4

187 lines
5.6 KiB
Groff
Raw Normal View History

.\" $NetBSD: iso.4,v 1.8 2002/02/13 08:17:40 ross Exp $
.\"
.\" Copyright (c) 1990, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
1993-03-21 12:45:37 +03:00
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\" 3. All advertising materials mentioning features or use of this software
.\" must display the following acknowledgement:
.\" This product includes software developed by the University of
.\" California, Berkeley and its contributors.
.\" 4. Neither the name of the University nor the names of its contributors
.\" may be used to endorse or promote products derived from this software
.\" without specific prior written permission.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
.\" @(#)iso.4 8.2 (Berkeley) 11/30/93
1993-03-21 12:45:37 +03:00
.\"
.Dd November 30, 1993
1993-03-21 12:45:37 +03:00
.Dt ISO 4
.Os
.Sh NAME
.Nm iso
.Nd
.Tn ISO
protocol family
.Sh SYNOPSIS
.Fd #include \*[Lt]sys/types.h\*[Gt]
.Fd #include \*[Lt]netiso/iso.h\*[Gt]
1993-03-21 12:45:37 +03:00
.Sh DESCRIPTION
The
.Tn ISO
protocol family is a collection of protocols
that uses the
.Tn ISO
address format.
The
.Tn ISO
family provides protocol support for the
.Dv SOCK_SEQPACKET
abstraction through the
.Tn TP
protocol
.Pf ( Tn ISO
2001-06-12 16:00:19 +04:00
8073),
1993-03-21 12:45:37 +03:00
for the
.Dv SOCK_DGRAM
abstraction through the connectionless transport
protocol
.Pf ( Tn ISO
8602),
and for the
.Dv SOCK_RAW
abstraction
by providing direct access (for debugging) to the
2001-06-12 16:00:19 +04:00
.Tn CLNP
1993-03-21 12:45:37 +03:00
.Pf ( Tn ISO
8473) network layer protocol.
.Sh ADDRESSING
.Tn ISO
addresses are based upon
.Tn ISO
2001-06-12 16:00:19 +04:00
8348/AD2,
1993-03-21 12:45:37 +03:00
.%T "Addendum to the Network Service Definition Covering Network Layer Addressing."
.Pp
Sockets bound to the OSI protocol family use
the following address structure:
.Bd -literal
struct iso_addr {
u_char isoa_len; /* length, not including this byte */
char isoa_genaddr[20]; /* general opaque address */
};
struct sockaddr_iso {
2000-06-26 20:21:22 +04:00
u_char siso_len; /* size of this sockaddr */
sa_family_t siso_family; /* addressing domain, AF_ISO */
u_char siso_plen; /* presentation selector length */
u_char siso_slen; /* session selector length */
u_char siso_tlen; /* transport selector length */
struct iso_addr siso_addr; /* network address */
u_char siso_pad[6]; /* space for gosip v2 SELs */
1993-03-21 12:45:37 +03:00
};
#define siso_nlen siso_addr.isoa_len
#define siso_data siso_addr.isoa_genaddr
.Ed
.Pp
The fields of this structure are:
.Bl -tag -width Ds
2001-06-12 16:00:19 +04:00
.It Ar siso_len :
1993-03-21 12:45:37 +03:00
Length of the entire address structure, in bytes, which may grow to
be longer than the 32 bytes shown above.
2001-06-12 16:00:19 +04:00
.It Ar siso_family :
1993-03-21 12:45:37 +03:00
Identifies the domain:
.Dv AF_ISO .
2001-06-12 16:00:19 +04:00
.It Ar siso_tlen :
1993-03-21 12:45:37 +03:00
Length of the transport selector.
2001-06-12 16:00:19 +04:00
.It Ar siso_slen :
1993-03-21 12:45:37 +03:00
Length of the session selector.
This is not currently supported by the kernel and is provided as
a convenience for user level programs.
2001-06-12 16:00:19 +04:00
.It Ar siso_plen :
1993-03-21 12:45:37 +03:00
Length of the presentation selector.
This is not currently supported by the kernel and is provided as
a convenience for user level programs.
2001-06-12 16:00:19 +04:00
.It Ar siso_addr :
1993-03-21 12:45:37 +03:00
The network part of the address, described below.
.El
.Sh TRANSPORT ADDRESSING
An
.Tn ISO
transport address is similar to an Internet address in that
it contains a network-address portion and a portion that the
transport layer uses to multiplex its services among clients.
In the Internet domain, this portion of the address is called a
.Em port .
In the
.Tn ISO
domain, this is called a
.Em transport selector
(also known at one time as a
.Em transport suffix ) .
2001-06-12 16:00:19 +04:00
While ports are always 16 bits,
1993-03-21 12:45:37 +03:00
transport selectors may be
of (almost) arbitrary size.
.Pp
Since the C language does not provide convenient variable
1993-03-21 12:45:37 +03:00
length structures, we have separated the selector lengths
from the data themselves.
The network address and various selectors are stored contiguously,
with the network address first, then the transport selector, and so
2001-11-21 22:14:19 +03:00
on. Thus, if you had a network address of less than 20 bytes,
1993-03-21 12:45:37 +03:00
the transport selector would encroach on space normally reserved
for the network address.
2001-06-12 16:00:19 +04:00
.Sh NETWORK ADDRESSING
1993-03-21 12:45:37 +03:00
.Tn ISO
network addresses are limited to 20 bytes in length.
.Tn ISO
network addresses can take any format.
.Sh PROTOCOLS
The
.Tn ARGO
2001-06-12 16:00:19 +04:00
1.0 implementation of the
1993-03-21 12:45:37 +03:00
.Tn ISO
protocol family comprises
the Connectionless-Mode Network Protocol
2001-06-12 16:00:19 +04:00
.Pq Tn CLNP ,
1993-03-21 12:45:37 +03:00
and the Transport Protocol
.Pq Tn TP ,
classes 4 and 0,
and
.Tn X.25 .
.Tn TP
is used to support the
.Dv SOCK_SEQPACKET
abstraction.
A raw interface to
.Tn CLNP
is available
by creating an
.Tn ISO
socket of type
.Dv SOCK_RAW .
This is used for
.Tn CLNP
debugging only.
.Sh SEE ALSO
.Xr clnp 4 ,
.Xr cltp 4 ,
.Xr tp 4