icmp6(4p) 맨 페이지 - 윈디하나의 솔라나라


맨 페이지 이름


icmp6(4P)                      Network Protocols                     icmp6(4P)

       icmp6 - Internet Control Message Protocol for Internet Protocol Version

       #include <sys/socket.h>
       #include <netinet/in.h>
       #include <netinet/ip_icmp.h>
       #include <netinet/icmp6.h>

       s = socket(AF_INET6, SOCK_RAW, proto);

       t = t_open("/dev/icmp6", O_RDWR);

       The ICMP6 protocol is the error and control message protocol used  with
       Version  6 of the Internet Protocol. It is used by the kernel to handle
       and report errors in protocol processing. It  is  also  used  for  IPv6
       neighbor  and  router  discovery,  and  for  multicast group membership
       queries and reports. It may also be  accessed  by  programs  using  the
       socket  interface  or  the  Transport Level Interface (TLI) for network
       monitoring and diagnostic functions. When used with the  socket  inter‐
       face,  a "raw socket" type is used. The protocol number for ICMP6, used
       in the proto parameter to the socket call, can be obtained from getpro‐
       tobyname(3C). ICMP6 file descriptors and sockets are connectionless and
       are normally used with the t_sndudata / t_rcvudata and the  sendto()  /
       recvfrom()  calls.  They may also be used with the sendmsg()/recvgmsg()
       calls when sending or receiving ancillary data.

       Outgoing packets automatically have  an  Internet  Protocol  Version  6
       (IPv6)  header and zero or more IPv6 extension headers prepended. These
       headers are  prepended  by  the  kernel.  Unlike  ICMP  for  IPv4,  the
       IP_HDRINCL  option  is  not  supported for ICMP6, so ICMP6 applications
       neither build their own outbound IPv6 headers, nor do they receive  the
       inbound  IPv6  headers  with  received data. IPv6 extension headers and
       relevant fields of the IPv6 header may be set or received as  ancillary
       data  to a sendmsg(3C) or recvmsg(3C) system call. Each of these fields
       and extension headers may also be set on a per socket  basis  with  the
       setsockopt(3C)  system call. Such "sticky" options are used on all out‐
       going packets unless overridden by ancillary data. When  any  ancillary
       data  is present with a sendmsg(3C) system call, all sticky options are
       ignored for that system call, but subsequently remain configured.

       ICMP6 is a datagram protocol layered above IPv6.  Received  ICMP6  mes‐
       sages  may be reflected back to users of higher-level protocols such as
       TCP or UDP  as  error  returns  from  system  calls.  A  copy  of  each
       ICMP6error  message  received by the system is provided to every holder
       of an open ICMP6 socket or TLI descriptor.

       recvmsg(3C),  send(3C),  sendmsg(3C),  setsockopt(3C),  t_rcvudata(3C),
       t_sndudata(3C), getprotobyname(3C), recv(3C), inet6(4P), ip6(4P), rout‐

       Conta, A. and Deering, S., RFC 2463, Internet Control Message  Protocol
       (ICMPv6)  for the Internet Protocol Version 6 (IPv6) Specification, The
       Internet Society, December 1998.

       A socket operation may fail with one of the following errors returned:

       EISCONN          An attempt was made to establish  a  connection  on  a
                        socket which already has one, or when trying to send a
                        datagram with the destination  address  specified  and
                        the socket is already connected.

       ENOTCONN          An attempt was made to send a datagram, but no desti‐
                        nation address is specified, and the  socket  has  not
                        been connected.

       ENOBUFS           The  system  ran  out  of memory for an internal data

       EADDRNOTAVAIL    An attempt was made to create a socket with a  network
                        address for which no network interface exists.

       ENOMEM            The  system  was  unable  to  allocate  memory for an
                        internal data structure.

       ENOPROTOOPT      An attempt was made to set an IPv4 socket option on an
                        IPv6 socket.

       EINVAL            An  attempt  was  made to set an invalid or malformed
                        socket option.

       EAFNOSUPPORT     An attempt was made to bind or connect to an  IPv4  or
                        mapped  address,  or  to  specify  an  IPv4  or mapped
                        address as the next hop.

Oracle Solaris 11.4               10 Nov 1999                        icmp6(4P)
맨 페이지 내용의 저작권은 맨 페이지 작성자에게 있습니다.