IPv4 to IPv6 translation.
More...
Go to the source code of this file.
|
| static u16 | ip4_get_port (ip4_header_t *ip, u8 sender) |
| | Get TCP/UDP port number or ICMP id from IPv4 packet. More...
|
| |
| static int | icmp_to_icmp6_header (icmp46_header_t *icmp, ip4_header_t **inner_ip4) |
| | Convert type and code value from ICMP4 to ICMP6. More...
|
| |
| static int | icmp_to_icmp6 (vlib_buffer_t *p, ip4_to_ip6_set_fn_t fn, void *ctx, ip4_to_ip6_set_fn_t inner_fn, void *inner_ctx) |
| | Translate ICMP4 packet to ICMP6. More...
|
| |
| static int | ip4_to_ip6_fragmented (vlib_buffer_t *p, ip4_to_ip6_set_fn_t fn, void *ctx) |
| | Translate IPv4 fragmented packet to IPv6. More...
|
| |
| static int | ip4_to_ip6_tcp_udp (vlib_buffer_t *p, ip4_to_ip6_set_fn_t fn, void *ctx) |
| | Translate IPv4 UDP/TCP packet to IPv6. More...
|
| |
IPv4 to IPv6 translation.
Definition in file ip4_to_ip6.h.
| #define frag_id_4to6 |
( |
|
id | ) |
(id) |
IPv4 to IPv6 set call back function type.
Definition at line 28 of file ip4_to_ip6.h.
Translate ICMP4 packet to ICMP6.
- Parameters
-
| p | Buffer to translate. |
| fn | The function to translate outer header. |
| ctx | A context passed in the outer header translate function. |
| inner_fn | The function to translate inner header. |
| inner_ctx | A context passed in the inner header translate function. |
- Returns
- 0 on success, non-zero value otherwise.
Definition at line 220 of file ip4_to_ip6.h.
| static int icmp_to_icmp6_header |
( |
icmp46_header_t * |
icmp, |
|
|
ip4_header_t ** |
inner_ip4 |
|
) |
| |
|
inlinestatic |
Convert type and code value from ICMP4 to ICMP6.
- Parameters
-
| icmp | ICMP header. |
| inner_ip4 | Inner IPv4 header if present, 0 otherwise. |
- Returns
- 0 on success, non-zero value otherwise.
Definition at line 102 of file ip4_to_ip6.h.
Get TCP/UDP port number or ICMP id from IPv4 packet.
- Parameters
-
| ip4 | IPv4 header. |
| sender | 1 get sender port, 0 get receiver port. |
- Returns
- Port number on success, 0 otherwise.
Definition at line 51 of file ip4_to_ip6.h.
Translate IPv4 fragmented packet to IPv6.
- Parameters
-
| p | Buffer to translate. |
| fn | The function to translate header. |
| ctx | A context passed in the header translate function. |
- Returns
- 0 on success, non-zero value otherwise.
Definition at line 450 of file ip4_to_ip6.h.
Translate IPv4 UDP/TCP packet to IPv6.
- Parameters
-
| p | Buffer to translate. |
| fn | The function to translate header. |
| ctx | A context passed in the header translate function. |
- Returns
- 0 on success, non-zero value otherwise.
Definition at line 501 of file ip4_to_ip6.h.
| u8 icmp_to_icmp6_updater_pointer_table[] |
|
static |
Initial value:=
{ 0, 1, 4, 4, ~0,
~0, ~0, ~0, 7, 6,
~0, ~0, 8, 8, 8,
8, 24, 24, 24, 24
}
Definition at line 32 of file ip4_to_ip6.h.