IP_OPTION_INFORMATION structure (ipexport.h)

The IP_OPTION_INFORMATION structure describes the options to be included in the header of an IP packet.

Syntax

typedef struct ip_option_information {
  UCHAR  Ttl;
  UCHAR  Tos;
  UCHAR  Flags;
  UCHAR  OptionsSize;
  PUCHAR OptionsData;
} IP_OPTION_INFORMATION, *PIP_OPTION_INFORMATION;

Members

Ttl

Type: UCHAR

The Time to Live field in an IPv4 packet header. This is the Hop Limit field in an IPv6 header.

Tos

Type: UCHAR

The type of service field in an IPv4 header. This member is currently silently ignored.

Flags

Type: UCHAR

The Flags field. In IPv4, this is the Flags field in the IPv4 header. In IPv6, this field is represented by options headers.

For IPv4, the possible values for the Flags member are a combination of the following values defined in the Ipexport.h header file:

Value Meaning
IP_FLAG_REVERSE
0x01
This value causes the IP packet to add in an IP routing header with the source. This value is only applicable on Windows Vista and later.
IP_FLAG_DF
0x02
This value indicates that the packet should not be fragmented.

OptionsSize

Type: UCHAR

The size, in bytes, of IP options data.

OptionsData

Type: PUCHAR

A pointer to options data.

Remarks

The IP_OPTION_INFORMATION structure is used to describe the options to be included in the header of an IP packet. On a 64-bit platform, the IP_OPTION_INFORMATION32 structure should be used.

The values in the TTL, TOS and Flags members are carried in specific fields in the IP header.

The bytes in the OptionsData member are carried in the options area that follows the standard IP header.

With the exception of source route options for IPv4, the options data must be in the format to be transmitted on the wire as specified in RFC 791. An IPv4 source route option should contain the full route, first hop through final destination, in the route data. The first hop is pulled out of the data and the option is reformatted accordingly. Otherwise, the route option should be formatted as specified in RFC 791.

For use with IPv6, the options data must be in the format to be transmitted on the wire as specified in RFC 2460.

The IP_OPTION_INFORMATION structure is a member of the ICMP_ECHO_REPLY structure used by the IcmpSendEcho, IcmpSendEcho2, and Icmp6SendEcho2 functions.

This structure is defined in the Ipexport.h header file which is automatically included in the Iphlpapi.h header file. The Ipexport.h header file should never be used directly.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Header ipexport.h (include Iphlpapi.h)

See also

ICMP_ECHO_REPLY

IP_OPTION_INFORMATION32

Icmp6SendEcho2

IcmpSendEcho

IcmpSendEcho2