randpkt: Add support to generate IPv6

Change-Id: I23e68ef204486f6e3e388172cfa8701a595fcedc
Reviewed-on: https://code.wireshark.org/review/16707
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
This commit is contained in:
João Valverde 2016-07-26 22:15:25 +01:00 committed by João Valverde
parent 9a73978ba5
commit fed443e799
1 changed files with 17 additions and 0 deletions

View File

@ -47,6 +47,7 @@ enum {
PKT_GIOP,
PKT_ICMP,
PKT_IP,
PKT_IPv6,
PKT_LLC,
PKT_M2M,
PKT_MEGACO,
@ -110,6 +111,14 @@ guint8 pkt_ip[] = {
0x08, 0x00
};
/* Ethernet, indicating IPv6 */
guint8 pkt_ipv6[] = {
0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0x01, 0x01,
0x01, 0x01, 0x01, 0x01,
0x86, 0xdd
};
/* TR, indicating LLC */
guint8 pkt_llc[] = {
0x10, 0x40, 0x68, 0x00,
@ -416,6 +425,14 @@ static randpkt_example examples[] = {
1000,
},
{ "ipv6", "Internet Protocol Version 6",
PKT_IPv6, WTAP_ENCAP_ETHERNET,
pkt_ipv6, array_length(pkt_ipv6),
NULL, 0,
NULL, NULL,
1000,
},
{ "llc", "Logical Link Control",
PKT_LLC, WTAP_ENCAP_TOKEN_RING,
pkt_llc, array_length(pkt_llc),