Partager via


2.2.1.2.255 BGP_IP_PREFIX

The BGP_IP_PREFIX structure<184> is used to represent the prefix of an IPv4 or IPv6 network subnet.

 typedef struct _BGP_IP_PREFIX {
   union {
     DWORD v4;
     BYTE v6[16];
   } address;
   USHORT uPrefixLength;
   USHORT uAddressFamily;
 } BGP_IP_PREFIX,
  *PBGP_IP_PREFIX;

v4: A 32-bit, unsigned integer in network byte order that represents an IPv4 address prefix.

v6[16]: A 128-bit, unsigned integer in network byte order that represents an IPv6 address prefix.

uPrefixLength: Specifies prefix length of the IPv4 or IPv6 network subnet.

uAddressFamily: Specifies whether the subnet is an IPv4 or IPv6 network subnet.

Value

Meaning

AF_INET

0x02

The IP address is an IPv4 network subnet.

AF_INET6

0x17

The IP address is an IPv6 network subnet.