icmp_header Struct Reference
[Internet Control Message Protocol (ICMP) Service]

Internet control message header. More...

#include <icmp_header.h>

Collaboration diagram for icmp_header:
Collaboration graph
[legend]

Data Fields

uint8_t type
 The type of the message.
uint8_t code
 The error code for the datagram reported by the ICMP message.
uint16_t checksum
 The checksum is the 16-bit ones's complement of the one's complement sum of the ICMP message starting with the ICMP Type.
union {
   icmp_echo_t   echo
 Echo specific data.
   in_addr_t   gateway
 Proposed gateway value.
   struct {
      icmp_param_t   reserved
 Reserved field.
      icmp_param_t   mtu
 Proposed MTU.
   }   frag
 Fragmentation needed specific data.
   struct {
      icmp_param_t   pointer
 Problem pointer.
      icmp_param_t   reserved
 Reserved field.
   }   param
 Parameter problem specific data.
un
 Message specific data.

Detailed Description

Internet control message header.


Field Documentation

The checksum is the 16-bit ones's complement of the one's complement sum of the ICMP message starting with the ICMP Type.

For computing the checksum, the checksum field should be zero. If the checksum does not match the contents, the datagram is discarded.

Referenced by icmp_process_packet(), and icmp_send_packet().

The error code for the datagram reported by the ICMP message.

The interpretation is dependent on the message type.

Referenced by icmp_client_process_packet(), and icmp_send_packet().

Echo specific data.

Referenced by icmp_echo(), and icmp_process_echo_reply().

struct { ... } icmp_header::frag

Fragmentation needed specific data.

Referenced by icmp_client_process_packet().

Proposed gateway value.

Proposed MTU.

struct { ... } icmp_header::param

Parameter problem specific data.

Referenced by icmp_client_process_packet().

Problem pointer.

Reserved field.

Must be zero.

The type of the message.

Referenced by icmp_client_process_packet(), icmp_process_packet(), and icmp_send_packet().

union { ... } icmp_header::un

Message specific data.

Referenced by icmp_client_process_packet(), icmp_echo(), and icmp_process_echo_reply().


The documentation for this struct was generated from the following file:

Generated on Thu Mar 11 20:48:28 2010 for Networking and TCP/IP stack for HelenOS system by  doxygen 1.6.1