to_str: scope tvb_ip6_to_str

This commit is contained in:
Evan Huus 2021-10-07 13:31:23 -04:00
parent 086feb2f09
commit 0eda51a646
53 changed files with 151 additions and 151 deletions

View File

@ -401,7 +401,7 @@ wrong answer on the PC on which you're doing development, and try
answer on big-endian machines.
gchar *tvb_ip_to_str(wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset)
gchar *tvb_ip6_to_str(tvbuff_t *tvb, const gint offset)
gchar *tvb_ip6_to_str(wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset)
Returns a null-terminated buffer containing a string with IPv4 or IPv6 Address
from the specified tvbuff, starting at the specified offset.

View File

@ -299,7 +299,7 @@ KrbFastArmorTypes PROT_PREFIX UPPER_CASE
break;
case KERBEROS_ADDR_TYPE_IPV6:
it=proto_tree_add_item(tree, hf_krb_address_ipv6, tvb, offset, INET6_ADDRLEN, ENC_NA);
address_str = tvb_ip6_to_str(tvb, offset);
address_str = tvb_ip6_to_str(actx->pinfo->pool, tvb, offset);
break;
default:
proto_tree_add_expert(tree, actx->pinfo, &ei_kerberos_address, tvb, offset, len);

View File

@ -5039,13 +5039,13 @@ dissect_afp_server_status(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tre
}
break;
case 6: /* IP6 */
sub_tree = proto_tree_add_subtree_format(adr_tree, tvb, offset, len, ett_afp_server_addr_line, NULL, "IPv6: %s", tvb_ip6_to_str(tvb, offset+2));
sub_tree = proto_tree_add_subtree_format(adr_tree, tvb, offset, len, ett_afp_server_addr_line, NULL, "IPv6: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset+2));
break;
case 7: /* IP6 + 2bytes port */
port = tvb_get_ntohs(tvb, offset+ 2+INET6_ADDRLEN);
sub_tree = proto_tree_add_subtree_format(adr_tree, tvb, offset, len,
ett_afp_server_addr_line, NULL,
"IPv6: %s:%d", tvb_ip6_to_str(tvb, offset+2), port);
"IPv6: %s:%d", tvb_ip6_to_str(pinfo->pool, tvb, offset+2), port);
break;
default:
sub_tree = proto_tree_add_subtree_format(adr_tree, tvb, offset, len, ett_afp_server_addr_line, NULL, "Unknown type: %u", type);

View File

@ -212,7 +212,7 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree,
offset += 4;
if (is_ipv6) {
dest_addr_v6 = tvb_ip6_to_str(tvb, offset);
dest_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_dest_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -237,7 +237,7 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree,
offset += 4;
if (is_ipv6) {
orig_addr_v6 = tvb_ip6_to_str(tvb, offset);
orig_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_orig_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -310,7 +310,7 @@ dissect_aodv_rrep(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree,
offset += 1;
if (is_ipv6) {
dest_addr_v6 = tvb_ip6_to_str(tvb, offset);
dest_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_dest_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -337,7 +337,7 @@ dissect_aodv_rrep(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree,
offset += 4;
if (is_ipv6) {
orig_addr_v6 = tvb_ip6_to_str(tvb, offset);
orig_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_orig_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -471,7 +471,7 @@ dissect_aodv_draft_01_v6_rreq(tvbuff_t *tvb, packet_info *pinfo,
orig_seqno);
offset += 4;
dest_addr_v6 = tvb_ip6_to_str(tvb, offset);
dest_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_dest_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -481,7 +481,7 @@ dissect_aodv_draft_01_v6_rreq(tvbuff_t *tvb, packet_info *pinfo,
col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", dest_addr_v6);
offset += INET6_ADDRLEN;
orig_addr_v6 = tvb_ip6_to_str(tvb, offset);
orig_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_orig_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -541,7 +541,7 @@ dissect_aodv_draft_01_v6_rrep(tvbuff_t *tvb, packet_info *pinfo,
dest_seqno);
offset += 4;
dest_addr_v6 = tvb_ip6_to_str(tvb, offset);
dest_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_dest_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);
@ -551,7 +551,7 @@ dissect_aodv_draft_01_v6_rrep(tvbuff_t *tvb, packet_info *pinfo,
col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", dest_addr_v6);
offset += INET6_ADDRLEN;
orig_addr_v6 = tvb_ip6_to_str(tvb, offset);
orig_addr_v6 = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if (aodv_tree) {
proto_tree_add_item(aodv_tree, hf_aodv_orig_ipv6, tvb, offset,
INET6_ADDRLEN, ENC_NA);

View File

@ -208,7 +208,7 @@ static void
dissect_ipv6_parameter(tvbuff_t *parameter_tvb, proto_tree *parameter_tree, proto_item *parameter_item)
{
proto_tree_add_item(parameter_tree, hf_parameter_ipv6_address, parameter_tvb, IPV6_ADDRESS_OFFSET, IPV6_ADDRESS_LENGTH, ENC_NA);
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(parameter_tvb, IPV6_ADDRESS_OFFSET));
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(wmem_packet_scope(), parameter_tvb, IPV6_ADDRESS_OFFSET));
}
static void

View File

@ -144,7 +144,7 @@ dissect_ath(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
info_srcaddr = tvb_ip_to_str(pinfo->pool, tvb, offset);
} else if (hlen == 6) {
proto_tree_add_item(ath_tree, hf_ath_ipv6, tvb, offset, 6, ENC_NA);
info_srcaddr = tvb_ip6_to_str(tvb, offset);
info_srcaddr = tvb_ip6_to_str(pinfo->pool, tvb, offset);
} else {
expert_add_info(pinfo, hlen_item, &ei_ath_hlen_invalid);
}
@ -244,7 +244,7 @@ dissect_ath(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
info_srcaddr = tvb_ip_to_str(pinfo->pool, tvb, offset);
} else if (hlen == 6) {
proto_tree_add_item(ath_tree, hf_ath_ipv6, tvb, offset, 6, ENC_NA);
info_srcaddr = tvb_ip6_to_str(tvb, offset);
info_srcaddr = tvb_ip6_to_str(pinfo->pool, tvb, offset);
} else {
expert_add_info(pinfo, hlen_item, &ei_ath_hlen_invalid);
}

View File

@ -4179,12 +4179,12 @@ decode_mp_next_hop_ipv6(tvbuff_t *tvb, proto_tree *tree, gint offset, packet_inf
switch (nhlen) {
case (FT_IPv6_LEN):
proto_tree_add_item(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_ipv6, tvb, offset, FT_IPv6_LEN, ENC_NA);
wmem_strbuf_append(strbuf, tvb_ip6_to_str(tvb, offset));
wmem_strbuf_append(strbuf, tvb_ip6_to_str(pinfo->pool, tvb, offset));
break;
case (2*FT_IPv6_LEN):
/* global address followed by link-local */
proto_tree_add_item(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_ipv6, tvb, offset, FT_IPv6_LEN, ENC_NA);
wmem_strbuf_append_printf(strbuf, "IPv6=%s", tvb_ip6_to_str(tvb, offset));
wmem_strbuf_append_printf(strbuf, "IPv6=%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += FT_IPv6_LEN;
ti = proto_tree_add_item(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_ipv6_link_local, tvb, offset, FT_IPv6_LEN, ENC_NA);
tvb_get_ipv6(tvb, offset, &ipv6_addr);
@ -4225,7 +4225,7 @@ decode_mp_next_hop_vpn_ipv6(tvbuff_t *tvb, proto_tree *tree, gint offset, packet
wmem_strbuf_append_printf(strbuf, " RD=%s", rd_string);
offset += BGP_ROUTE_DISTINGUISHER_SIZE;
proto_tree_add_item(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_ipv6, tvb, offset, FT_IPv6_LEN, ENC_NA);
wmem_strbuf_append_printf(strbuf, " IPv6=%s", tvb_ip6_to_str(tvb, offset));
wmem_strbuf_append_printf(strbuf, " IPv6=%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
break;
case (2*(BGP_ROUTE_DISTINGUISHER_SIZE + FT_IPv6_LEN)):
rd_string = decode_bgp_rd(pinfo->pool, tvb, offset);
@ -4236,7 +4236,7 @@ decode_mp_next_hop_vpn_ipv6(tvbuff_t *tvb, proto_tree *tree, gint offset, packet
wmem_strbuf_append_printf(strbuf, " RD=%s", rd_string);
offset += BGP_ROUTE_DISTINGUISHER_SIZE;
proto_tree_add_item(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_ipv6, tvb, offset, FT_IPv6_LEN, ENC_NA);
wmem_strbuf_append_printf(strbuf, " IPv6=%s", tvb_ip6_to_str(tvb, offset));
wmem_strbuf_append_printf(strbuf, " IPv6=%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += FT_IPv6_LEN;
rd_string = decode_bgp_rd(pinfo->pool, tvb, offset);
ti = proto_tree_add_string(tree, hf_bgp_update_path_attribute_mp_reach_nlri_next_hop_rd, tvb, offset, BGP_ROUTE_DISTINGUISHER_SIZE, rd_string);

View File

@ -288,7 +288,7 @@ dissect_bt_dht_values(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, guint
value_tree = proto_item_add_subtree( value_ti, ett_bt_dht_peers);
proto_tree_add_item( value_tree, hf_ip6, tvb, offset, 16, ENC_NA);
proto_item_append_text(value_ti, " (IPv6/Port: [%s]", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(value_ti, " (IPv6/Port: [%s]", tvb_ip6_to_str(pinfo->pool, tvb, offset));
proto_tree_add_item( value_tree, hf_port, tvb, offset+16, 2, ENC_BIG_ENDIAN);
proto_item_append_text(value_ti, ":%u)", tvb_get_ntohs( tvb, offset+16 ));
}
@ -354,7 +354,7 @@ dissect_bt_dht_nodes(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, guint
if ( is_ipv6 )
{
proto_tree_add_item( node_tree, hf_ip6, tvb, offset+20, 16, ENC_NA);
proto_item_append_text(node_ti, ", IPv6/Port: [%s]", tvb_ip6_to_str(tvb, offset+20));
proto_item_append_text(node_ti, ", IPv6/Port: [%s]", tvb_ip6_to_str(pinfo->pool, tvb, offset+20));
proto_tree_add_item( node_tree, hf_port, tvb, offset+36, 2, ENC_BIG_ENDIAN);
proto_item_append_text(node_ti, ":%u)", tvb_get_ntohs( tvb, offset+36 ));

View File

@ -1138,7 +1138,7 @@ dissect_address_tlv(tvbuff_t *tvb, packet_info* pinfo, int offset, int length, p
case ETHERTYPE_IPv6:
if (address_length == 16) {
/* The address is an IPv6 address. */
proto_item_set_text(ti, "IPv6 address: %s", tvb_ip6_to_str(tvb, offset));
proto_item_set_text(ti, "IPv6 address: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
hf_addr = hf_cdp_nrgyz_ip6_address;
proto_tree_add_item(address_tree, hf_cdp_nrgyz_ip6_address, tvb, offset, address_length, ENC_NA);
}

View File

@ -1913,7 +1913,7 @@ guint c_dissect_sockaddr(proto_tree *root, c_sockaddr *out,
break;
case C_IPv6:
d.port = tvb_get_ntohs (tvb, off+2);
d.addr_str = tvb_ip6_to_str(tvb, off+8);
d.addr_str = tvb_ip6_to_str(wmem_packet_scope(), tvb, off+8);
proto_tree_add_item(tree, hf_port, tvb, off+2, 2, ENC_BIG_ENDIAN);
proto_tree_add_item(tree, hf_addr_ipv6, tvb, off+8, 16, ENC_NA);

View File

@ -1358,7 +1358,7 @@ static void dissect_cops_object_data(tvbuff_t *tvb, packet_info *pinfo, guint32
ifindex = tvb_get_ntohl(tvb, offset + (int)sizeof ipv6addr);
itf_tree = proto_tree_add_subtree_format(tree, tvb, offset, 20, ett_cops_itf, NULL,
"Contents: IPv6 address %s, ifIndex: %u",
tvb_ip6_to_str(tvb, offset), ifindex);
tvb_ip6_to_str(pinfo->pool, tvb, offset), ifindex);
proto_tree_add_item(itf_tree,
(c_num == COPS_OBJ_IN_INT) ? hf_cops_in_int_ipv6 : hf_cops_out_int_ipv6,
tvb, offset, 16, ENC_NA);
@ -1493,7 +1493,7 @@ static void dissect_cops_object_data(tvbuff_t *tvb, packet_info *pinfo, guint32
tcp_port = tvb_get_ntohs(tvb, offset + (int)sizeof ipv6addr + 2);
pdp_tree = proto_tree_add_subtree_format(tree, tvb, offset, 20, ett_cops_pdp, NULL,
"Contents: IPv6 address %s, TCP Port Number: %u",
tvb_ip6_to_str(tvb, offset), tcp_port);
tvb_ip6_to_str(pinfo->pool, tvb, offset), tcp_port);
proto_tree_add_item(pdp_tree,
(c_num == COPS_OBJ_PDPREDIRADDR) ? hf_cops_pdprediraddr_ipv6 : hf_cops_lastpdpaddr_ipv6,
tvb, offset, 16, ENC_NA);

View File

@ -381,7 +381,7 @@ PIDL_dissect_ipv6address(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tr
}
proto_tree_add_item(tree, hfindex, tvb, offset, 16, ENC_BIG_ENDIAN);
if (param & PIDL_SET_COL_INFO) {
const char *ip = tvb_ip6_to_str(tvb, offset);
const char *ip = tvb_ip6_to_str(pinfo->pool, tvb, offset);
header_field_info *hf_info = proto_registrar_get_nth(hfindex);
proto_item_append_text(proto_tree_get_parent(tree), " %s:%s", hf_info->name, ip);
col_append_fstr(pinfo->cinfo, COL_INFO," %s:%s", hf_info->name, ip);

View File

@ -2180,7 +2180,7 @@ dhcpv6_option(tvbuff_t *tvb, packet_info *pinfo, proto_tree *bp_tree,
}
proto_tree_add_item(subtree, hf_iaaddr_ip, tvb, off, 16, ENC_NA);
col_append_fstr(pinfo->cinfo, COL_INFO, "IAA: %s ", tvb_ip6_to_str(tvb, off));
col_append_fstr(pinfo->cinfo, COL_INFO, "IAA: %s ", tvb_ip6_to_str(pinfo->pool, tvb, off));
preferred_lifetime = tvb_get_ntohl(tvb, off + 16);
valid_lifetime = tvb_get_ntohl(tvb, off + 20);
@ -2927,7 +2927,7 @@ dissect_dhcpv6(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
expert_add_info_format(pinfo, previous_pi, &ei_dhcpv6_error_hopcount, "hopcount is not correctly incremented by 1 (expected : %d, actual : %d)", hpi.hopcount + 1, previous_hopcount);
}
hpi.relay_message_previously_detected = TRUE;
col_append_fstr(pinfo->cinfo, COL_INFO, "L: %s ", tvb_ip6_to_str(tvb, off + 2));
col_append_fstr(pinfo->cinfo, COL_INFO, "L: %s ", tvb_ip6_to_str(pinfo->pool, tvb, off + 2));
off += 34;
} else {
/* Check the inner hopcount equals 0 */

View File

@ -449,7 +449,7 @@ decode_dataitem_v6conn(tvbuff_t *tvb, int offset, proto_item *pi, proto_tree *pt
offset+=DLEP_DIT_V6CONN_FLAGS_LEN;
proto_tree_add_item(pt, hf_dlep_dataitem_v6conn_addr, tvb, offset, FT_IPv6_LEN, ENC_NA);
proto_item_append_text(pi, ", Addr: %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(pi, ", Addr: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset+=FT_IPv6_LEN;
if (len == DLEP_DIT_V6CONN_WPORT_LEN) {
@ -593,7 +593,7 @@ decode_dataitem_v6addr(tvbuff_t *tvb, int offset, proto_item *pi, proto_tree *pt
offset+=DLEP_DIT_V6ADDR_FLAGS_LEN;
proto_tree_add_item(pt, hf_dlep_dataitem_v6addr_addr, tvb, offset, FT_IPv6_LEN, ENC_NA);
proto_item_append_text(pi, " %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(pi, " %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset+=FT_IPv6_LEN;
if (len != DLEP_DIT_V6ADDR_LEN)
@ -651,7 +651,7 @@ decode_dataitem_v6subnet(tvbuff_t *tvb, int offset, proto_item *pi, proto_tree *
offset+=DLEP_DIT_V6SUBNET_FLAGS_LEN;
proto_tree_add_item(pt, hf_dlep_dataitem_v6subnet_subnet, tvb, offset, FT_IPv6_LEN, ENC_NA);
proto_item_append_text(pi, " %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(pi, " %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset+=FT_IPv6_LEN;
proto_tree_add_item_ret_uint(pt, hf_dlep_dataitem_v6subnet_prefixlen, tvb, offset, 1, ENC_BIG_ENDIAN, &prefixlen);

View File

@ -2624,7 +2624,7 @@ dissect_dns_answer(tvbuff_t *tvb, int offsetx, int dns_data_offset,
{
const char *addr6;
addr6 = tvb_ip6_to_str(tvb, cur_offset);
addr6 = tvb_ip6_to_str(pinfo->pool, tvb, cur_offset);
col_append_fstr(pinfo->cinfo, COL_INFO, " %s", addr6);
proto_item_append_text(trr, ", addr %s", addr6);
@ -3576,7 +3576,7 @@ dissect_dns_answer(tvbuff_t *tvb, int offsetx, int dns_data_offset,
case DNS_SVCB_KEY_IPV6HINT:
for (svc_param_offset = 0; svc_param_offset < svc_param_length; svc_param_offset += 16) {
proto_tree_add_item(svcb_param_tree, hf_dns_svcb_param_ipv6hint_ip, tvb, cur_offset, 16, ENC_NA);
proto_item_append_text(svcb_param_ti, "%c%s", (svc_param_offset == 0 ? '=' : ','), tvb_ip6_to_str(tvb, cur_offset));
proto_item_append_text(svcb_param_ti, "%c%s", (svc_param_offset == 0 ? '=' : ','), tvb_ip6_to_str(pinfo->pool, tvb, cur_offset));
cur_offset += 16;
}
break;

View File

@ -214,7 +214,7 @@ static void
dissect_ipv6_parameter(tvbuff_t *parameter_tvb, proto_tree *parameter_tree, proto_item *parameter_item)
{
proto_tree_add_item(parameter_tree, hf_parameter_ipv6_address, parameter_tvb, IPV6_ADDRESS_OFFSET, IPV6_ADDRESS_LENGTH, ENC_NA);
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(parameter_tvb, IPV6_ADDRESS_OFFSET));
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(wmem_packet_scope(), parameter_tvb, IPV6_ADDRESS_OFFSET));
}
static void

View File

@ -4901,7 +4901,7 @@ decode_gtp_user_addr(tvbuff_t * tvb, int offset, packet_info * pinfo _U_, proto_
break;
case 0x57:
proto_tree_add_item(ext_tree_user, hf_gtp_user_ipv6, tvb, offset + 5, 16, ENC_NA);
proto_item_append_text(te, " : %s", tvb_ip6_to_str(tvb, offset + 5));
proto_item_append_text(te, " : %s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 5));
break;
case 0x8d:
if (length == 6) {
@ -4913,12 +4913,12 @@ decode_gtp_user_addr(tvbuff_t * tvb, int offset, packet_info * pinfo _U_, proto_
} else if (length == 18) {
proto_tree_add_ipv4_format_value(ext_tree_user, hf_gtp_user_ipv6, tvb, offset + 5, 0, 0, "dynamic");
proto_tree_add_item(ext_tree_user, hf_gtp_user_ipv6, tvb, offset + 5, 16, ENC_NA);
proto_item_append_text(te, " : dynamic / %s", tvb_ip6_to_str(tvb, offset + 5));
proto_item_append_text(te, " : dynamic / %s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 5));
} else if (length == 22) {
proto_tree_add_item(ext_tree_user, hf_gtp_user_ipv4, tvb, offset + 5, 4, ENC_BIG_ENDIAN);
proto_tree_add_item(ext_tree_user, hf_gtp_user_ipv6, tvb, offset + 9, 16, ENC_NA);
proto_item_append_text(te, " : %s / %s", tvb_ip_to_str(pinfo->pool, tvb, offset + 5),
tvb_ip6_to_str(tvb, offset + 9));
tvb_ip6_to_str(pinfo->pool, tvb, offset + 9));
} else {
proto_tree_add_expert_format(ext_tree_user, pinfo, &ei_gtp_ext_length_mal, tvb, offset + 3, length, "Wrong length indicated. Expected 6, 18 or 22, got %u", length);
}
@ -6046,7 +6046,7 @@ decode_gtp_gsn_addr_common(tvbuff_t * tvb, int offset, packet_info * pinfo _U_,
proto_tree_add_item(ext_tree_gsn_addr, hf_ipv6, tvb, offset + 3, 16, ENC_NA);
if (hf_ipv6 != hf_gtp_gsn_ipv6)
proto_item_set_hidden(proto_tree_add_item(ext_tree_gsn_addr, hf_gtp_gsn_ipv6, tvb, offset + 3, 16, ENC_NA));
proto_item_append_text(te, "%s", tvb_ip6_to_str(tvb, offset + 3));
proto_item_append_text(te, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 3));
set_address_tvb(gsn_address, AT_IPv4, 4, tvb, offset + 3);
break;
case 17:
@ -6055,7 +6055,7 @@ decode_gtp_gsn_addr_common(tvbuff_t * tvb, int offset, packet_info * pinfo _U_,
proto_tree_add_uint(ext_tree_gsn_addr, hf_gtp_gsn_addr_type, tvb, offset + 3, 1, addr_type);
addr_len = tvb_get_guint8(tvb, offset + 3) & 0x3F;
proto_tree_add_uint(ext_tree_gsn_addr, hf_gtp_gsn_addr_len, tvb, offset + 3, 1, addr_len);
proto_item_append_text(te, "%s", tvb_ip6_to_str(tvb, offset + 4));
proto_item_append_text(te, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 4));
proto_tree_add_item(ext_tree_gsn_addr, hf_ipv6, tvb, offset + 4, 16, ENC_NA);
if (hf_ipv6 != hf_gtp_gsn_ipv6)
proto_item_set_hidden(proto_tree_add_item(ext_tree_gsn_addr, hf_gtp_gsn_ipv6, tvb, offset + 4, 16, ENC_NA));
@ -6451,7 +6451,7 @@ decode_gtp_chrg_addr(tvbuff_t * tvb, int offset, packet_info * pinfo _U_, proto_
break;
case 16:
proto_tree_add_item(ext_tree_chrg_addr, hf_gtp_chrg_ipv6, tvb, offset + 3, 16, ENC_NA);
proto_item_append_text(te, "%s", tvb_ip6_to_str(tvb, offset + 3));
proto_item_append_text(te, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 3));
break;
default:
proto_item_append_text(te, "unknown type or wrong length");
@ -8949,7 +8949,7 @@ decode_gtp_node_addr(tvbuff_t * tvb, int offset, packet_info * pinfo _U_, proto_
break;
case 16:
proto_tree_add_item(ext_tree_node_addr, hf_gtp_node_ipv6, tvb, offset + 3, 16, ENC_NA);
proto_item_append_text(te, "%s", tvb_ip6_to_str(tvb, offset + 3));
proto_item_append_text(te, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset + 3));
break;
default:
proto_item_append_text(te, "unknown type or wrong length");

View File

@ -2281,7 +2281,7 @@ dissect_gtpv2_ip_address(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree
else if (length == 16)
{
proto_tree_add_item(tree, hf_gtpv2_ip_address_ipv6, tvb, offset, length, ENC_NA);
proto_item_append_text(item, "IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, "IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
}
}
/*
@ -2613,7 +2613,7 @@ dissect_gtpv2_paa(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto
proto_tree_add_item(tree, hf_gtpv2_pdn_ipv6_len, tvb, offset, 1, ENC_BIG_ENDIAN);
offset += 1;
proto_tree_add_item(tree, hf_gtpv2_pdn_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, "IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, "IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
break;
case 3:
/* IPv4/IPv6 */
@ -2633,7 +2633,7 @@ dissect_gtpv2_paa(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto
proto_tree_add_item(tree, hf_gtpv2_pdn_ipv6_len, tvb, offset, 1, ENC_BIG_ENDIAN);
offset += 1;
proto_tree_add_item(tree, hf_gtpv2_pdn_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, "IPv6 %s, ", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, "IPv6 %s, ", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
proto_tree_add_item(tree, hf_gtpv2_pdn_ipv4, tvb, offset, 4, ENC_BIG_ENDIAN);
proto_item_append_text(item, "IPv4 %s", tvb_ip_to_str(pinfo->pool, tvb, offset));
@ -3356,7 +3356,7 @@ dissect_gtpv2_f_teid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_
{
ipv6 = wmem_new0(pinfo->pool, address);
proto_tree_add_item(tree, hf_gtpv2_f_teid_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
set_address_tvb(ipv6, AT_IPv6, 16, tvb, offset);
}
@ -6238,7 +6238,7 @@ dissect_gtpv2_mbms_ip_mc_dist(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree
} else if ((tvb_get_guint8(tvb, offset) & 0x3f) == 16) {
offset += 1;
proto_tree_add_item(tree, hf_gtpv2_mbms_ip_mc_dist_addrv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, " IPv6 Dist %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, " IPv6 Dist %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
@ -6253,7 +6253,7 @@ dissect_gtpv2_mbms_ip_mc_dist(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree
} else if ((tvb_get_guint8(tvb, offset) & 0x3f) == 16) {
offset += 1;
proto_tree_add_item(tree, hf_gtpv2_mbms_ip_mc_src_addrv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, " IPv6 Src %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, " IPv6 Src %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}

View File

@ -1785,7 +1785,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
/* Prefix */
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " : %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " : %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
@ -1853,7 +1853,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
while(opt_offset < (offset + opt_len) ) {
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_ipv6_address, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s", tvb_ip6_to_str(tvb, opt_offset));
proto_item_append_text(ti, " %s", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset));
opt_offset += 16;
}
break;
@ -2057,7 +2057,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
/* IPv6 Address */
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_ipa_ipv6_address, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
@ -2081,7 +2081,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
/* Prefix */
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_nrpi_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
@ -2193,7 +2193,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
break;
case 24:
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
default:
@ -2216,7 +2216,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
while(opt_offset < (offset + opt_len) ) {
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_rdnss, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s", tvb_ip6_to_str(tvb, opt_offset));
proto_item_append_text(ti, " %s", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset));
opt_offset += 16;
}
@ -2474,7 +2474,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
case 24:
tvb_memcpy(tvb, (guint8 *)&context_prefix.bytes, opt_offset, 16);
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_6co_context_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), context_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), context_len);
opt_offset += 16;
break;
default:
@ -2507,7 +2507,7 @@ dissect_icmpv6_nd_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
/* 6LBR Address */
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_opt_abro_6lbr_address, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " : Version %d.%d, Valid Lifetime : %d, 6LBR : %s", version_high, version_low, valid_lifetime, tvb_ip6_to_str(tvb, opt_offset));
proto_item_append_text(ti, " : Version %d.%d, Valid Lifetime : %d, 6LBR : %s", version_high, version_low, valid_lifetime, tvb_ip6_to_str(pinfo->pool, tvb, opt_offset));
opt_offset += 16;
}
@ -2869,7 +2869,7 @@ dissect_icmpv6_rpl_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
break;
case 22:
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_rpl_opt_route_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
default:
@ -2958,7 +2958,7 @@ dissect_icmpv6_rpl_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
break;
case 18:
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_rpl_opt_target_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
default:
@ -2995,7 +2995,7 @@ dissect_icmpv6_rpl_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
if(opt_len > 4)
{
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_rpl_opt_transit_parent, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s", tvb_ip6_to_str(tvb, opt_offset));
proto_item_append_text(ti, " %s", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset));
opt_offset += 16;
}
@ -3063,7 +3063,7 @@ dissect_icmpv6_rpl_opt(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
/* Prefix */
proto_tree_add_item(icmp6opt_tree, hf_icmpv6_rpl_opt_prefix, tvb, opt_offset, 16, ENC_NA);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(tvb, opt_offset), prefix_len);
proto_item_append_text(ti, " %s/%d", tvb_ip6_to_str(pinfo->pool, tvb, opt_offset), prefix_len);
opt_offset += 16;
break;
@ -3724,7 +3724,7 @@ dissect_rrenum(tvbuff_t *tvb, int rr_offset, packet_info *pinfo _U_, proto_tree
proto_tree_add_item(mp_tree, hf_icmpv6_rr_pco_mp_matchprefix, tvb, rr_offset, 16, ENC_NA);
/* Add Info (Prefix, Length...) to Match Prefix Part label */
proto_item_append_text(ti_mp, ": %s %s/%u (%u-%u)", val_to_str(opcode, rr_pco_mp_opcode_val, "Unknown %d"), tvb_ip6_to_str(tvb, rr_offset), matchlen, minlen, maxlen);
proto_item_append_text(ti_mp, ": %s %s/%u (%u-%u)", val_to_str(opcode, rr_pco_mp_opcode_val, "Unknown %d"), tvb_ip6_to_str(pinfo->pool, tvb, rr_offset), matchlen, minlen, maxlen);
rr_offset += 16;
while ((int)tvb_reported_length(tvb) > rr_offset) {
@ -3786,7 +3786,7 @@ dissect_rrenum(tvbuff_t *tvb, int rr_offset, packet_info *pinfo _U_, proto_tree
proto_tree_add_item(up_tree, hf_icmpv6_rr_pco_up_useprefix, tvb, rr_offset, 16, ENC_NA);
/* Add Info (Prefix, Length...) to Use Prefix Part label */
proto_item_append_text(ti_up, ": %s/%u (keep %u)", tvb_ip6_to_str(tvb, rr_offset), uselen, keeplen);
proto_item_append_text(ti_up, ": %s/%u (keep %u)", tvb_ip6_to_str(pinfo->pool, tvb, rr_offset), uselen, keeplen);
rr_offset += 16;
}
@ -3830,7 +3830,7 @@ dissect_rrenum(tvbuff_t *tvb, int rr_offset, packet_info *pinfo _U_, proto_tree
proto_tree_add_item(rm_tree, hf_icmpv6_rr_rm_matchedprefix, tvb, rr_offset, 16, ENC_NA);
/* Add Info (Prefix, Length...) to Use Resultant Message label */
proto_item_append_text(ti_rm, ": %s/%u (interface %u)", tvb_ip6_to_str(tvb, rr_offset), matchlen, interfaceindex);
proto_item_append_text(ti_rm, ": %s/%u (interface %u)", tvb_ip6_to_str(pinfo->pool, tvb, rr_offset), matchlen, interfaceindex);
rr_offset +=16;
}
}
@ -3878,7 +3878,7 @@ dissect_mldrv2( tvbuff_t *tvb, guint32 offset, packet_info *pinfo _U_, proto_tre
/* Multicast Address */
proto_tree_add_item(mar_tree, hf_icmpv6_mldr_mar_multicast_address, tvb, mldr_offset, 16, ENC_NA);
proto_item_append_text(ti_mar, " %s: %s", val_to_str(record_type, mldr_record_type_val,"Unknown Record Type (%d)"), tvb_ip6_to_str(tvb, mldr_offset));
proto_item_append_text(ti_mar, " %s: %s", val_to_str(record_type, mldr_record_type_val,"Unknown Record Type (%d)"), tvb_ip6_to_str(pinfo->pool, tvb, mldr_offset));
mldr_offset += 16;
/* Source Address */
@ -3960,7 +3960,7 @@ dissect_mpl_control(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *t
seed_id = tvb_eui64_to_str(pinfo->pool, tvb, body_offset);
break;
case 3:
seed_id = tvb_ip6_to_str(tvb, body_offset);
seed_id = tvb_ip6_to_str(pinfo->pool, tvb, body_offset);
break;
default:
/* not reached */
@ -4370,7 +4370,7 @@ dissect_icmpv6(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
/* Target Address */
proto_tree_add_item(icmp6_tree, hf_icmpv6_nd_ns_target_address, tvb, offset, 16, ENC_NA);
col_append_fstr(pinfo->cinfo, COL_INFO, " for %s", tvb_ip6_to_str(tvb, offset));
col_append_fstr(pinfo->cinfo, COL_INFO, " for %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
@ -4415,7 +4415,7 @@ dissect_icmpv6(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
wmem_strbuf_append(flags_strbuf, "none");
}
col_append_fstr(pinfo->cinfo, COL_INFO, " %s (%s)", tvb_ip6_to_str(tvb, offset), wmem_strbuf_get_str(flags_strbuf));
col_append_fstr(pinfo->cinfo, COL_INFO, " %s (%s)", tvb_ip6_to_str(pinfo->pool, tvb, offset), wmem_strbuf_get_str(flags_strbuf));
offset += 16;
/* Show options */

View File

@ -4278,17 +4278,17 @@ dissect_id_type(tvbuff_t *tvb, int offset, int length, guint8 id_type, proto_tre
break;
case IKE_ID_IPV6_ADDR:
proto_tree_add_item(idtree, hf_isakmp_id_data_ipv6_addr, tvb, offset, 16, ENC_NA);
proto_item_append_text(idit, "%s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(idit, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
break;
case IKE_ID_IPV6_ADDR_SUBNET:
proto_tree_add_item(idtree, hf_isakmp_id_data_ipv6_addr, tvb, offset, 16, ENC_NA);
proto_tree_add_item(idtree, hf_isakmp_id_data_ipv6_subnet, tvb, offset+16, 16, ENC_NA);
proto_item_append_text(idit, "%s/%s", tvb_ip6_to_str(tvb, offset), tvb_ip6_to_str(tvb, offset+16));
proto_item_append_text(idit, "%s/%s", tvb_ip6_to_str(pinfo->pool, tvb, offset), tvb_ip6_to_str(pinfo->pool, tvb, offset+16));
break;
case IKE_ID_IPV6_ADDR_RANGE:
proto_tree_add_item(idtree, hf_isakmp_id_data_ipv6_range_start, tvb, offset, 16, ENC_NA);
proto_tree_add_item(idtree, hf_isakmp_id_data_ipv6_range_end, tvb, offset+16, 16, ENC_NA);
proto_item_append_text(idit, "%s/%s", tvb_ip6_to_str(tvb, offset), tvb_ip6_to_str(tvb, offset+16));
proto_item_append_text(idit, "%s/%s", tvb_ip6_to_str(pinfo->pool, tvb, offset), tvb_ip6_to_str(pinfo->pool, tvb, offset+16));
break;
case IKE_ID_KEY_ID:
proto_tree_add_item(idtree, hf_isakmp_id_data_key_id, tvb, offset, length, ENC_NA);

View File

@ -5357,7 +5357,7 @@ dissect_kerberos_T_address(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int off
break;
case KERBEROS_ADDR_TYPE_IPV6:
it=proto_tree_add_item(tree, hf_krb_address_ipv6, tvb, offset, INET6_ADDRLEN, ENC_NA);
address_str = tvb_ip6_to_str(tvb, offset);
address_str = tvb_ip6_to_str(actx->pinfo->pool, tvb, offset);
break;
default:
proto_tree_add_expert(tree, actx->pinfo, &ei_kerberos_address, tvb, offset, len);

View File

@ -419,8 +419,8 @@ dissect_lisp_tcp_membership_message(tvbuff_t *tvb, packet_info *pinfo, proto_tre
break;
case AFNUM_INET6:
proto_tree_add_item(message_tree, hf_lisp_tcp_message_rloc_ipv6, tvb, offset, INET6_ADDRLEN, ENC_NA);
proto_item_append_text(tim, ", RLOC: %s", tvb_ip6_to_str(tvb, offset));
col_append_fstr(pinfo->cinfo, COL_INFO, " [%u] %s", iid, tvb_ip6_to_str(tvb, offset));
proto_item_append_text(tim, ", RLOC: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
col_append_fstr(pinfo->cinfo, COL_INFO, " [%u] %s", iid, tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += INET6_ADDRLEN;
data_len -= INET6_ADDRLEN;
break;

View File

@ -533,7 +533,7 @@ get_addr_str(tvbuff_t *tvb, gint offset, guint16 afi, guint16 *addr_len)
return addr_str;
case AFNUM_INET6:
*addr_len = INET6_ADDRLEN;
addr_str = tvb_ip6_to_str(tvb, offset);
addr_str = tvb_ip6_to_str(wmem_packet_scope(), tvb, offset);
return addr_str;
case AFNUM_LCAF:
get_lcaf_data(tvb, offset, &lcaf_type, addr_len);
@ -788,7 +788,7 @@ dissect_lcaf_afi_list(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
break;
case AFNUM_INET6:
proto_tree_add_item(lisp_afi_list_tree, hf_lisp_lcaf_afi_list_ipv6, tvb, offset, INET6_ADDRLEN, ENC_NA);
proto_item_append_text(tir, " %d. IPv6 Address: %s", i, tvb_ip6_to_str(tvb, offset));
proto_item_append_text(tir, " %d. IPv6 Address: %s", i, tvb_ip6_to_str(pinfo->pool, tvb, offset));
proto_item_set_len(tir, 2 + INET6_ADDRLEN);
offset += INET6_ADDRLEN;
remaining -= INET6_ADDRLEN;
@ -2326,7 +2326,7 @@ dissect_lisp_map_request(tvbuff_t *tvb, packet_info *pinfo, proto_tree *lisp_tre
break;
case AFNUM_INET6:
proto_tree_add_item(lisp_itr_tree, hf_lisp_mreq_itr_rloc_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(tir, " %d: %s", i + 1, tvb_ip6_to_str(tvb, offset));
proto_item_append_text(tir, " %d: %s", i + 1, tvb_ip6_to_str(pinfo->pool, tvb, offset));
proto_item_set_len(tir, 2 + INET6_ADDRLEN);
offset += INET6_ADDRLEN;
break;

View File

@ -1485,7 +1485,7 @@ dissect_lldp_chassis_id(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gui
break;
case AFNUM_INET6:
if (dataLen == 18){
strPtr = tvb_ip6_to_str(tvb, offset);
strPtr = tvb_ip6_to_str(pinfo->pool, tvb, offset);
}else{
expert_add_info_format(pinfo, lf, &ei_lldp_bad_length,
"Invalid Chassis ID Length (%u) for Type (%s, %s), expected (18)", dataLen, val_to_str_const(tlvsubType, chassis_id_subtypes, ""), val_to_str_const(addr_family, afn_vals, ""));
@ -1658,7 +1658,7 @@ dissect_lldp_port_id(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, guint3
break;
case AFNUM_INET6:
if (dataLen == 18){
strPtr = tvb_ip6_to_str(tvb, offset);
strPtr = tvb_ip6_to_str(pinfo->pool, tvb, offset);
}else{
expert_add_info_format(pinfo, lf, &ei_lldp_bad_length,
"Invalid Port ID Length (%u) for Type (%s, %s), expected (18)", dataLen, val_to_str_const(tlvsubType, port_id_subtypes, ""), val_to_str_const(addr_family, afn_vals, ""));

View File

@ -870,7 +870,7 @@ dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
case 4:
l = (type == 3)? LMPF_VAL_LOCAL_LINK_ID_IPV6:
LMPF_VAL_REMOTE_LINK_ID_IPV6;
proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(tvb, offset2));
proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2));
proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
offset2, 16, ENC_NA);
break;
@ -907,7 +907,7 @@ dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
case 4:
l = (type == 3)? LMPF_VAL_LOCAL_INTERFACE_ID_IPV6:
LMPF_VAL_REMOTE_INTERFACE_ID_IPV6;
proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(tvb, offset2));
proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2));
proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
offset2, 16, ENC_NA);
break;
@ -1097,8 +1097,8 @@ dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
case 2:
proto_item_append_text(ti, ": IPv6: Local %s, Remote %s",
tvb_ip6_to_str(tvb, offset2+4),
tvb_ip6_to_str(tvb, offset2+20));
tvb_ip6_to_str(pinfo->pool, tvb, offset2+4),
tvb_ip6_to_str(pinfo->pool, tvb, offset2+20));
proto_tree_add_item(lmp_object_tree,
hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_IPV6],
tvb, offset2+4, 16, ENC_NA);
@ -1159,8 +1159,8 @@ dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
case 2:
proto_item_append_text(ti, ": IPv6: Local %s, Remote %s",
tvb_ip6_to_str(tvb, offset2+4),
tvb_ip6_to_str(tvb, offset2+8));
tvb_ip6_to_str(pinfo->pool, tvb, offset2+4),
tvb_ip6_to_str(pinfo->pool, tvb, offset2+8));
proto_tree_add_item(lmp_object_tree, hf_lmp_data_link_local_id_ipv6, tvb, offset2+4, 16, ENC_NA);
proto_tree_add_item(lmp_object_tree, hf_lmp_data_link_remote_id_ipv6, tvb, offset2+20, 16, ENC_NA);
l = 36;
@ -1276,8 +1276,8 @@ dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
case 2:
if (j < 4)
proto_item_append_text(ti, ": [IPv6-%s", tvb_ip6_to_str(tvb, offset2+l));
proto_item_append_text(ti2, ": IPv6 %s", tvb_ip6_to_str(tvb, offset2+l));
proto_item_append_text(ti, ": [IPv6-%s", tvb_ip6_to_str(pinfo->pool, tvb, offset2+l));
proto_item_append_text(ti2, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2+l));
proto_tree_add_item(lmp_subobj_tree, hf_lmp_interface_id_ipv6, tvb, offset2, 16, ENC_NA);
l += 16;
break;

View File

@ -2200,7 +2200,7 @@ dissect_mip6_network_prefix_option(tvbuff_t *tvb, packet_info *pinfo, proto_tree
offset++;
proto_tree_add_item(field_tree, hf_mip6_nemo_mnp_mnp, tvb, offset, MIP6_NEMO_MNP_MNP_LEN, ENC_NA);
proto_item_append_text(ti, ": %s/%u", tvb_ip6_to_str(tvb, offset), prefix_len);
proto_item_append_text(ti, ": %s/%u", tvb_ip6_to_str(pinfo->pool, tvb, offset), prefix_len);
return tvb_captured_length(tvb);
}
@ -2954,7 +2954,7 @@ dissect_pmip6_opt_mhipv6ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
offset++;
proto_tree_add_item(opt_tree, hf_mip6_opt_mhipv6ap_ipv6_address, tvb, offset, 16, ENC_NA);
ti = proto_tree_add_string(opt_tree, hf_mip6_opt_mhipv6ap_ipv6_address_prefix, tvb, offset -1, 16+1, tvb_ip6_to_str(tvb, offset));
ti = proto_tree_add_string(opt_tree, hf_mip6_opt_mhipv6ap_ipv6_address_prefix, tvb, offset -1, 16+1, tvb_ip6_to_str(pinfo->pool, tvb, offset));
proto_item_append_text(ti, "/%u", prefix_l);
proto_item_set_generated(ti);
@ -3239,7 +3239,7 @@ dissect_pmip6_opt_lmaa(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void
if (opt_code == 1) {
/* Ipv6 Addr */
proto_tree_add_item(opt_tree, hf_mip6_lmaa_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(ti, ": %s", tvb_ip6_to_str(tvb,offset));
proto_item_append_text(ti, ": %s", tvb_ip6_to_str(pinfo->pool, tvb,offset));
}else if (opt_code == 2) {
/* IPv4 addr */
proto_tree_add_item(opt_tree, hf_mip6_lmaa_ipv4, tvb, offset, 4, ENC_BIG_ENDIAN);
@ -3673,7 +3673,7 @@ dissect_mip6_opt_dmnp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void*
proto_tree_add_item(opt_tree, hf_mip6_opt_dmnp_dmnp_ipv6, tvb,
offset, 16, ENC_NA);
proto_item_append_text(ti, ": %s/%u",
tvb_ip6_to_str(tvb, offset), prefix_len);
tvb_ip6_to_str(pinfo->pool, tvb, offset), prefix_len);
break;
default:

View File

@ -294,7 +294,7 @@ dissect_msnlb(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U
break;
case 0x17: /* IPv6 */
proto_tree_add_item(hb_tree, hf_msnlb_host_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(ti, ": %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(ti, ": %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
break;
default: /* Unknown */

View File

@ -1082,7 +1082,7 @@ dissect_netlink_route_ifa_attrs(tvbuff_t *tvb, void *data _U_, struct packet_net
proto_item_append_text(tree, ": %s", tvb_ip_to_str(wmem_packet_scope(), tvb, offset));
proto_tree_add_item(tree, &hfi_netlink_route_ifa_addr4, tvb, offset, len, ENC_BIG_ENDIAN);
} else {
proto_item_append_text(tree, ": %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(tree, ": %s", tvb_ip6_to_str(wmem_packet_scope(), tvb, offset));
proto_tree_add_item(tree, &hfi_netlink_route_ifa_addr6, tvb, offset, len, ENC_NA);
}
return 1;

View File

@ -395,7 +395,7 @@ decode_ip_element(nsip_ip_element_info_t *element, build_info_t *bi, proto_tree
bi->offset, element->address_length,
ENC_NA);
proto_item_append_text(tf, ": IP address: %s",
tvb_ip6_to_str(bi->tvb, bi->offset));
tvb_ip6_to_str(wmem_packet_scope(), bi->tvb, bi->offset));
break;
default:
;

View File

@ -220,7 +220,7 @@ static int dissect_olsrorg_lq_tc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *
nlq = tvb_get_guint8(tvb, offset + 17);
address_group = proto_tree_add_bytes_format_value(olsr_tree, hf_olsr_neighbor, tvb, offset, 20,
NULL, "%s (%d/%d)", tvb_ip6_to_str(tvb, offset), lq, nlq);
NULL, "%s (%d/%d)", tvb_ip6_to_str(pinfo->pool, tvb, offset), lq, nlq);
address_tree = proto_item_add_subtree(address_group, ett_olsr_message_neigh);
@ -376,7 +376,7 @@ static int handle_olsr_hello_olsrorg(tvbuff_t *tvb, packet_info *pinfo, proto_tr
nlq = tvb_get_guint8(tvb, offset + 17);
address_group = proto_tree_add_bytes_format_value(olsr_tree, hf_olsr_neighbor, tvb, offset, 20,
NULL, "%s (%d/%d)", tvb_ip6_to_str(tvb, offset), lq, nlq);
NULL, "%s (%d/%d)", tvb_ip6_to_str(pinfo->pool, tvb, offset), lq, nlq);
address_tree = proto_item_add_subtree(address_group, ett_olsr_message_neigh);

View File

@ -2783,7 +2783,7 @@ dissect_ospf_lsa_mpls(tvbuff_t *tvb, packet_info *pinfo, int offset, proto_tree
case OIF_TNA_IPv6_ADDRESS:
stlv_tree = proto_tree_add_subtree_format(tlv_tree, tvb, stlv_offset, stlv_len+4,
ett_ospf_lsa_oif_tna_stlv, NULL, "%s (IPv6): %s", stlv_name,
tvb_ip6_to_str(tvb, stlv_offset + 8));
tvb_ip6_to_str(pinfo->pool, tvb, stlv_offset + 8));
proto_tree_add_uint_format_value(stlv_tree, hf_ospf_tlv_type, tvb, stlv_offset, 2,
stlv_type, "%u: %s (IPv6)", stlv_type, stlv_name);
proto_tree_add_item(stlv_tree, hf_ospf_tlv_length, tvb, stlv_offset+2, 2, ENC_BIG_ENDIAN);

View File

@ -1871,7 +1871,7 @@ dissect_subobj_ipv6(proto_tree *pcep_subobj_tree, packet_info *pinfo, tvbuff_t *
}
prefix_length = tvb_get_guint8(tvb, offset+18);
proto_item_append_text(ti, ": %s/%u", tvb_ip6_to_str(tvb, offset+2),
proto_item_append_text(ti, ": %s/%u", tvb_ip6_to_str(pinfo->pool, tvb, offset+2),
prefix_length);
switch (obj_class) {
@ -2333,7 +2333,7 @@ dissect_subobj_pksv6(proto_tree *pcep_subobj_tree, packet_info *pinfo, tvbuff_t
}
path_key = tvb_get_ntohs(tvb, offset+2);
proto_item_append_text(ti, ": %s, Path Key %u", tvb_ip6_to_str(tvb, offset+4), path_key);
proto_item_append_text(ti, ": %s, Path Key %u", tvb_ip6_to_str(pinfo->pool, tvb, offset+4), path_key);
proto_tree_add_item(pcep_subobj_pksv6, hf_pcep_subobj_pksv6_l, tvb, offset, 1, ENC_NA);
proto_tree_add_item(pcep_subobj_pksv6, hf_PCEPF_SUBOBJ_7F, tvb, offset, 1, ENC_NA);

View File

@ -2168,7 +2168,7 @@ dissect_pfcp_f_teid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_i
if ((fteid_flags_val & 0x2) == 2) {
/* p to (p+15) IPv6 address */
proto_tree_add_item(tree, hf_pfcp_f_teid_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
/* If the value of CH bit is set to "0", but the value of CHID bit is "1" */
@ -3433,7 +3433,7 @@ dissect_pfcp_f_seid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_i
if ((f_seid_flags & 0x1) == 1) {
ipv6 = wmem_new0(pinfo->pool, address);
proto_tree_add_item(tree, hf_pfcp_f_seid_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
set_address_tvb(ipv6, AT_IPv6, 16, tvb, offset);
offset += 16;
}
@ -3532,7 +3532,7 @@ decode_pfcp_address(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_i
case 1:
/* IPv6 address */
proto_tree_add_item(tree, hf_pfcp_node_id_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, "%s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
break;
case 2:
@ -4939,7 +4939,7 @@ dissect_pfcp_remote_gtp_u_peer(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
/* IPv6 address (if present)*/
if (flags & 0x1) {
proto_tree_add_item(tree, hf_pfcp_remote_gtp_u_peer_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, "IPv6 %s ", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, "IPv6 %s ", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
/* DI (if present)*/
@ -6667,7 +6667,7 @@ dissect_pfcp_alternative_smf_ip_address(tvbuff_t *tvb, packet_info *pinfo, proto
/* IPv6 address (if present) */
if (alternative_smf_ip_address_flags & 0x1) {
proto_tree_add_item(tree, hf_pfcp_alternative_smf_ip_address_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
@ -6808,7 +6808,7 @@ dissect_pfcp_cp_pfcp_entity_ip_address(tvbuff_t *tvb, packet_info *pinfo, proto_
/* IPv6 address (if present) */
if ((cp_pfcp_entity_ip_address_flags & 0x1)) {
proto_tree_add_item(tree, hf_pfcp_cp_pfcp_entity_ip_address_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
@ -6925,13 +6925,13 @@ dissect_pfcp_source_ip_address(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
/* IPv6 address (if present) */
if ((source_ip_address_flags & 0x1)) {
proto_tree_add_item(tree, hf_pfcp_source_ip_address_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
/* Mask/Prefix Length (if present) */
if ((source_ip_address_flags & 0x4)) {
proto_tree_add_item(tree, hf_pfcp_source_ip_address_mask_prefix_lengt, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
@ -7392,7 +7392,7 @@ dissect_pfcp_mptcp_address_information(tvbuff_t *tvb, packet_info *pinfo, proto_
/* MPTCP Proxy IPv6 address (if present) */
if ((mptcp_address_flags & 0x2)) {
proto_tree_add_item(tree, hf_pfcp_mptcp_proxy_ip_address_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}
@ -8419,7 +8419,7 @@ dissect_pfcp_cp_ip_address(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
/* IPv6 address (if present) */
if (cp_ip_address_flags & 0x1) {
proto_tree_add_item(tree, hf_pfcp_cp_ip_address_ipv6, tvb, offset, 16, ENC_NA);
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(item, ", IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
}

View File

@ -798,7 +798,7 @@ dissect_pim_addr(proto_tree* tree, tvbuff_t *tvb, int offset, enum pimv2_addrtyp
if (label)
{
ti = proto_tree_add_ipv6_format(tree, hf_ip6, tvb, offset, 2 + len,
&ipv6, "%s: %s", label, tvb_ip6_to_str(tvb, offset + 2));
&ipv6, "%s: %s", label, tvb_ip6_to_str(wmem_packet_scope(), tvb, offset + 2));
}
else
{
@ -890,7 +890,7 @@ dissect_pim_addr(proto_tree* tree, tvbuff_t *tvb, int offset, enum pimv2_addrtyp
if (label)
{
ti = proto_tree_add_ipv6_format(tree, hf_ip6, tvb, offset, 4 + len,
&ipv6, "%s: %s", label, tvb_ip6_to_str(tvb, offset + 4));
&ipv6, "%s: %s", label, tvb_ip6_to_str(wmem_packet_scope(), tvb, offset + 4));
}
else
{
@ -942,12 +942,12 @@ dissect_pim_addr(proto_tree* tree, tvbuff_t *tvb, int offset, enum pimv2_addrtyp
if (label)
{
ti = proto_tree_add_ipv6_format(tree, hf_ip6, tvb, offset, 4 + len,
&ipv6, "%s: %s", label, tvb_ip6_to_str(tvb, offset + 4));
&ipv6, "%s: %s", label, tvb_ip6_to_str(wmem_packet_scope(), tvb, offset + 4));
}
else
{
ti = proto_tree_add_ipv6_format_value(tree, hf_ip6, tvb, offset, 4 + len, &ipv6,
"%s", tvb_ip6_to_str(tvb, offset + 4));
"%s", tvb_ip6_to_str(wmem_packet_scope(), tvb, offset + 4));
}
proto_item_append_text(ti, "/%u", mask_len);
break;

View File

@ -1121,7 +1121,7 @@ radius_ipv6addr(radius_attr_info_t *a, proto_tree *tree, packet_info *pinfo _U_,
proto_tree_add_item(tree, a->hf, tvb, offset, len, ENC_NA);
proto_item_append_text(avp_item, "%s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(avp_item, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
}
void
@ -1168,7 +1168,7 @@ radius_combo_ip(radius_attr_info_t *a, proto_tree *tree, packet_info *pinfo _U_,
proto_item_append_text(avp_item, "%s", tvb_ip_to_str(pinfo->pool, tvb, offset));
} else if (len == 16) {
proto_tree_add_item(tree, a->hf_alt, tvb, offset, len, ENC_NA);
proto_item_append_text(avp_item, "%s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(avp_item, "%s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
} else {
proto_item_append_text(avp_item, "[wrong length for both of IPv4 and IPv6 address]");
return;

View File

@ -292,7 +292,7 @@ raknet_dissect_system_address(proto_tree *tree, int hf,
proto_item_append_text(ti, "%s:%" G_GUINT16_FORMAT, addr_str, port);
break;
case 6:
addr_str = tvb_ip6_to_str(tvb, *offset);
addr_str = tvb_ip6_to_str(pinfo->pool, tvb, *offset);
proto_tree_add_item(sub_tree, hf_raknet_ipv6_address, tvb, *offset, 16, ENC_NA);
*offset += 16;
port = tvb_get_ntohs(tvb, *offset);

View File

@ -1364,7 +1364,7 @@ dissect_ipaddressport(int anchor, tvbuff_t *tvb, proto_tree *tree, guint16 offse
proto_item_append_text(ti_ipaddressport, " (%s:%d)", tvb_ip_to_str(wmem_packet_scope(), tvb, offset+2),tvb_get_ntohs(tvb,offset+2+4));
}
else if (ipaddressport_type == IPADDRESSPORTTYPE_IPV6) {
proto_item_append_text(ti_ipaddressport, " (%s:%d)", tvb_ip6_to_str(tvb, offset+2),tvb_get_ntohs(tvb,offset+2+16));
proto_item_append_text(ti_ipaddressport, " (%s:%d)", tvb_ip6_to_str(wmem_packet_scope(), tvb, offset+2),tvb_get_ntohs(tvb,offset+2+16));
}
ipaddressport_tree = proto_item_add_subtree(ti_ipaddressport, ett_reload_ipaddressport);
proto_tree_add_item(ipaddressport_tree, hf_reload_ipaddressport_type, tvb, offset, 1, ENC_BIG_ENDIAN);
@ -1389,7 +1389,7 @@ dissect_ipaddressport(int anchor, tvbuff_t *tvb, proto_tree *tree, guint16 offse
proto_item *ti_ipv6;
proto_tree *ipv6_tree;
ti_ipv6 = proto_tree_add_item(ipaddressport_tree, hf_reload_ipv6addrport, tvb, offset, 6, ENC_NA);
proto_item_append_text(ti_ipv6, ": %s:%d", tvb_ip6_to_str(tvb, offset),tvb_get_ntohs(tvb,offset+16));
proto_item_append_text(ti_ipv6, ": %s:%d", tvb_ip6_to_str(wmem_packet_scope(), tvb, offset),tvb_get_ntohs(tvb,offset+16));
ipv6_tree = proto_item_add_subtree(ti_ipv6, ett_reload_ipv6addrport);
proto_tree_add_item(ipv6_tree, hf_reload_ipv6addr, tvb, offset, 16, ENC_NA);
proto_tree_add_item(ipv6_tree, hf_reload_port, tvb, offset + 16, 2, ENC_BIG_ENDIAN);

View File

@ -83,7 +83,7 @@ dissect_ripng(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U
/* IPv6 Prefix */
proto_tree_add_item(rte_tree, hf_ripng_rte_ipv6_prefix, tvb, offset, 16, ENC_NA);
proto_item_append_text(rte_ti, ": IPv6 Prefix: %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(rte_ti, ": IPv6 Prefix: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
/* Route Tag */

View File

@ -307,7 +307,7 @@ rsip_parameter(tvbuff_t *tvb, proto_tree *rsip_tree, int off, int eoff)
hf_rsip_parameter_address_ipv6, tvb,
off + 4, paramlen - 1, ENC_NA);
proto_item_append_text(pti, ": %s",
tvb_ip6_to_str(tvb, off + 4));
tvb_ip6_to_str(wmem_packet_scope(), tvb, off + 4));
} else
proto_item_append_text(pti,
": Any IPv6 Address");

View File

@ -2548,7 +2548,7 @@ summary_session(wmem_allocator_t *pool, tvbuff_t *tvb, int offset)
case RSVP_SESSION_TYPE_IPV6_LSP:
return wmem_strdup_printf(pool,
"SESSION: IPv6-LSP, Destination %s, Short Call ID %d, Tunnel ID %d, Ext ID %0x%0x%0x%0x. ",
tvb_ip6_to_str(tvb, offset+4),
tvb_ip6_to_str(pool, tvb, offset+4),
tvb_get_ntohs(tvb, offset+20),
tvb_get_ntohs(tvb, offset+22),
tvb_get_ntohl(tvb, offset+24),
@ -2580,7 +2580,7 @@ summary_session(wmem_allocator_t *pool, tvbuff_t *tvb, int offset)
"SESSION: IPv6-P2MP LSP TUNNEL, PSMP ID %d, Tunnel ID %d, Ext Tunnel %s. ",
tvb_get_ntohl(tvb, offset+4),
tvb_get_ntohs(tvb, offset+10),
tvb_ip6_to_str(tvb, offset+12));
tvb_ip6_to_str(pool, tvb, offset+12));
break;
case RSVP_SESSION_TYPE_IPV4_E_NNI:
return wmem_strdup_printf(pool,
@ -2624,7 +2624,7 @@ summary_template(wmem_allocator_t *pool, tvbuff_t *tvb, int offset)
case 8:
return wmem_strdup_printf(pool,
"%s: IPv6-LSP, Tunnel Source: %s, Short Call ID: %d, LSP ID: %d. ", objtype,
tvb_ip6_to_str(tvb, offset+4),
tvb_ip6_to_str(pool, tvb, offset+4),
tvb_get_ntohs(tvb, offset+20),
tvb_get_ntohs(tvb, offset+22));
break;
@ -2764,7 +2764,7 @@ dissect_rsvp_session(packet_info *pinfo, proto_item *ti, proto_tree *rsvp_object
tvb, offset2+18, 2, ENC_BIG_ENDIAN);
proto_tree_add_item(rsvp_object_tree, hf_rsvp_extended_tunnel_ipv6, tvb, offset2+20, 16, ENC_NA);
proto_item_set_text(ti, "Extended Tunnel ID: (%s)", tvb_ip6_to_str(tvb, offset2+20));
proto_item_set_text(ti, "Extended Tunnel ID: (%s)", tvb_ip6_to_str(pinfo->pool, tvb, offset2+20));
hidden_item = proto_tree_add_item(rsvp_object_tree,
@ -2972,7 +2972,7 @@ dissect_rsvp_ifid_tlv(proto_tree *ti, packet_info* pinfo, proto_tree *rsvp_objec
case 17: /* INCOMING_IPV6 */
tlv_name = "Incoming ";
ifid_ipv6:
ip_str = tvb_ip6_to_str(tvb, offset+tlv_off+4);
ip_str = tvb_ip6_to_str(pinfo->pool, tvb, offset+tlv_off+4);
rsvp_ifid_subtree = proto_tree_add_subtree_format(rsvp_object_tree, tvb,
offset+tlv_off, tlv_len,
subtree_type, NULL, "%sIPv6 TLV - %s", tlv_name, ip_str);
@ -3214,7 +3214,7 @@ dissect_rsvp_hop(proto_item *ti, packet_info* pinfo, proto_tree *rsvp_object_tre
proto_tree_add_item(rsvp_object_tree, hf_rsvp_hop_logical_interface, tvb, offset2+16, 4, ENC_BIG_ENDIAN);
proto_item_set_text(ti, "HOP: IPv6 IF-ID. Control IPv6: %s. ",
tvb_ip6_to_str(tvb, offset2));
tvb_ip6_to_str(pinfo->pool, tvb, offset2));
dissect_rsvp_ifid_tlv(ti, pinfo, rsvp_object_tree, tvb, offset+24, obj_length-24,
TREE(TT_HOP_SUBOBJ));
@ -5248,7 +5248,7 @@ dissect_rsvp_ro_subobjects(proto_tree *ti, packet_info* pinfo, proto_tree *rsvp_
rsvp_ro_subtree = proto_tree_add_subtree_format(rsvp_object_tree, tvb,
offset+l, 8, tree_type, &ti2,
"Path Key subobject - %s, %u",
tvb_ip6_to_str(tvb, offset+l+4),
tvb_ip6_to_str(pinfo->pool, tvb, offset+l+4),
path_key);
proto_tree_add_uint_format_value(rsvp_ro_subtree, hf_rsvp_type, tvb, offset+l, 1,
type, "65 (Path Key with IPv6 PCE-ID)");
@ -5805,7 +5805,7 @@ dissect_rsvp_association(proto_tree *ti, proto_tree *rsvp_object_tree,
proto_tree_add_item(rsvp_object_tree, hf_rsvp_association_id, tvb, offset+6, 2, ENC_BIG_ENDIAN);
proto_item_append_text(ti, "ID: %u. ", association_id);
proto_tree_add_item(rsvp_object_tree, hf_rsvp_association_source_ipv6, tvb, offset+8, 16, ENC_NA);
proto_item_append_text(ti, "Src: %s", tvb_ip6_to_str(tvb, offset+8));
proto_item_append_text(ti, "Src: %s", tvb_ip6_to_str(wmem_packet_scope(), tvb, offset+8));
break;
case 4: /* oif2008.389 */
@ -5957,7 +5957,7 @@ dissect_rsvp_lsp_tunnel_if_id(proto_tree *ti, packet_info* pinfo, proto_tree *rs
proto_tree_add_item(rsvp_object_tree, hf_rsvp_lsp_tunnel_if_id_target_igp_instance, tvb, offset+20, 4, ENC_BIG_ENDIAN);
proto_item_set_text(ti, "LSP INTERFACE-ID: IPv6, interface address %s,"
"IGP instance %s",
tvb_ip6_to_str(tvb, offset+4),
tvb_ip6_to_str(pinfo->pool, tvb, offset+4),
tvb_ip_to_str(pinfo->pool, tvb, offset+20));
proto_tree_add_item(rsvp_object_tree, hf_rsvp_lsp_tunnel_if_id_action, tvb, offset+24, 1, ENC_BIG_ENDIAN);
dissect_rsvp_lsp_tunnel_if_id_tlv(rsvp_object_tree, pinfo, tvb, offset+28, obj_length-28,
@ -6014,7 +6014,7 @@ dissect_rsvp_notify_request(proto_item *ti, proto_tree *rsvp_object_tree,
proto_tree_add_item(rsvp_object_tree, hf_rsvp_ctype_notify_request, tvb, offset+3, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(rsvp_object_tree, hf_rsvp_notify_request_notify_node_address_ipv6, tvb, offset2, 16, ENC_NA);
proto_item_append_text(ti, ": Notify node: %s",
tvb_ip6_to_str(tvb, offset2));
tvb_ip6_to_str(wmem_packet_scope(), tvb, offset2));
break;
}
@ -6101,7 +6101,7 @@ dissect_rsvp_gen_uni(proto_tree *ti, packet_info* pinfo, proto_tree *rsvp_object
tvb, offset2+l+4, 16, ENC_NA);
if (i < 4) {
proto_item_append_text(ti, "%s IPv6 TNA: %s", c,
tvb_ip6_to_str(tvb, offset2+l+4));
tvb_ip6_to_str(pinfo->pool, tvb, offset2+l+4));
}
break;
@ -6359,7 +6359,7 @@ dissect_rsvp_call_id(proto_tree *ti, packet_info* pinfo, proto_tree *rsvp_object
case 2:
offset4 = offset3 + 16;
str = tvb_ip6_to_str(tvb, offset3);
str = tvb_ip6_to_str(pinfo->pool, tvb, offset3);
proto_tree_add_item(rsvp_object_tree, hf_rsvp_filter[RSVPF_CALL_ID_SRC_ADDR_IPV6],
tvb, offset3, 16, ENC_NA);
break;

View File

@ -299,9 +299,9 @@ static void rtitcp_util_add_locator_t(proto_tree *tree, packet_info *pinfo _U_,
col_append_str(pinfo->cinfo, COL_INFO, " (");
}
proto_item_append_text(rtitcp_message, "%s%s",
*first_attribute ? "" : ", ", tvb_ip6_to_str(tvb, offset));
*first_attribute ? "" : ", ", tvb_ip6_to_str(pinfo->pool, tvb, offset));
col_append_fstr(pinfo->cinfo, COL_INFO, "%s%s",
*first_attribute ? "" : ", ", tvb_ip6_to_str(tvb, offset));
*first_attribute ? "" : ", ", tvb_ip6_to_str(pinfo->pool, tvb, offset));
}
}

View File

@ -627,7 +627,7 @@ static gint dissect_parameter_transport_rtps_type(
addr,
sizeof(addr),
"%s",
tvb_ip6_to_str(tvb, OFFSET_TO_VAL));
tvb_ip6_to_str(pinfo->pool, tvb, OFFSET_TO_VAL));
}
/* Add source to destination column field */
@ -780,7 +780,7 @@ static gint dissect_parameter_transport_rtps_type(
addr,
sizeof(addr),
"%s",
tvb_ip6_to_str(tvb, OFFSET_TO_VAL));
tvb_ip6_to_str(pinfo->pool, tvb, OFFSET_TO_VAL));
}
/* Add address to destination column field */

View File

@ -3414,7 +3414,7 @@ static gint rtps_util_add_locator_t(proto_tree *tree, packet_info *pinfo, tvbuff
16, ENC_NA);
proto_item_append_text(tree, " (%s, %s, Logical Port = %u)",
val_to_str(kind, rtps_locator_kind_vals, "%02x"),
tvb_ip6_to_str(tvb, offset + 8), port);
tvb_ip6_to_str(pinfo->pool, tvb, offset + 8), port);
}
break;
}
@ -3450,7 +3450,7 @@ static gint rtps_util_add_locator_t(proto_tree *tree, packet_info *pinfo, tvbuff
proto_tree_add_item(locator_tree, hf_rtps_locator_ipv6, tvb, offset+8, 16, ENC_NA);
proto_item_append_text(tree, " (%s, %s:%u)",
val_to_str(kind, rtps_locator_kind_vals, "%02x"),
tvb_ip6_to_str(tvb, offset + 8), port);
tvb_ip6_to_str(pinfo->pool, tvb, offset + 8), port);
break;
}
case LOCATOR_KIND_DTLS: {
@ -3465,7 +3465,7 @@ static gint rtps_util_add_locator_t(proto_tree *tree, packet_info *pinfo, tvbuff
proto_tree_add_item(locator_tree, hf_rtps_locator_ipv6, tvb, offset+8, 16, ENC_NA);
proto_item_append_text(tree, " (%s, %s:%u)",
val_to_str(kind, rtps_locator_kind_vals, "%02x"),
tvb_ip6_to_str(tvb, offset + 8), port);
tvb_ip6_to_str(pinfo->pool, tvb, offset + 8), port);
break;
}
/*
@ -3686,10 +3686,10 @@ static int rtps_util_add_multichannel_locator_list(proto_tree *tree, packet_info
}
case LOCATOR_KIND_UDPV6: {
proto_tree_add_item(locator_tree, hf_rtps_locator_ipv6, tvb, offset + 4, 16, ENC_NA);
channel_address = tvb_ip6_to_str(tvb, offset + 4);
channel_address = tvb_ip6_to_str(pinfo->pool, tvb, offset + 4);
proto_item_append_text(tree, " (%s, %s)",
val_to_str(kind, rtps_locator_kind_vals, "%02x"),
tvb_ip6_to_str(tvb, offset + 4));
tvb_ip6_to_str(pinfo->pool, tvb, offset + 4));
break;
}
/* Default case, Multichannel locators only should be present in UDPv4 and UDPv6 transports

View File

@ -641,7 +641,7 @@ static guint32 dissect_memdatacomp(tvbuff_t *tvb, proto_tree *pay_load, guint32
ws_in6_addr ipv6_address;
tvb_get_ipv6(tvb, offset+7, &ipv6_address);
ip_str = tvb_ip6_to_str(tvb, offset+7);
ip_str = tvb_ip6_to_str(wmem_packet_scope(), tvb, offset+7);
lab_len = tvb_get_guint8(tvb, offset+23);

View File

@ -1372,9 +1372,9 @@ dissect_ipv6_parameter(tvbuff_t *parameter_tvb, proto_tree *parameter_tree, prot
{
if (parameter_tree) {
proto_tree_add_item(parameter_tree, hf_ipv6_address, parameter_tvb, IPV6_ADDRESS_OFFSET, IPV6_ADDRESS_LENGTH, ENC_NA);
proto_item_append_text(parameter_item, " (Address: %s)", tvb_ip6_to_str(parameter_tvb, IPV6_ADDRESS_OFFSET));
proto_item_append_text(parameter_item, " (Address: %s)", tvb_ip6_to_str(wmem_packet_scope(), parameter_tvb, IPV6_ADDRESS_OFFSET));
if (additional_item)
proto_item_append_text(additional_item, "%s", tvb_ip6_to_str(parameter_tvb, IPV6_ADDRESS_OFFSET));
proto_item_append_text(additional_item, "%s", tvb_ip6_to_str(wmem_packet_scope(), parameter_tvb, IPV6_ADDRESS_OFFSET));
}
if (dissecting_init_init_ack_chunk) {
if (sctp_info.number_of_tvbs < MAXIMUM_NUMBER_OF_TVBS)

View File

@ -7102,8 +7102,8 @@ dissect_windows_sockaddr_in6(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *
/* IPv6 address */
proto_tree_add_item(sub_tree, hf_windows_sockaddr_in6_addr, tvb, offset, 16, ENC_NA);
proto_item_append_text(sub_item, ", IPv6: %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(parent_item, ", IPv6: %s", tvb_ip6_to_str(tvb, offset));
proto_item_append_text(sub_item, ", IPv6: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
proto_item_append_text(parent_item, ", IPv6: %s", tvb_ip6_to_str(pinfo->pool, tvb, offset));
offset += 16;
/* sin6_scope_id */

View File

@ -1184,7 +1184,7 @@ dissect_stun_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gboole
case 2:
if (att_length < 20)
break;
addr_str = tvb_ip6_to_str(tvb, offset + 4);
addr_str = tvb_ip6_to_str(pinfo->pool, tvb, offset + 4);
proto_tree_add_item(att_tree, hf_stun_att_ipv6, tvb, offset+4, 16, ENC_NA);
break;
}

View File

@ -1506,7 +1506,7 @@ static void
dissect_ipv6_parameter(tvbuff_t *parameter_tvb, proto_tree *parameter_tree, proto_item *parameter_item, gboolean source)
{
proto_tree_add_item(parameter_tree, source ? hf_sua_source_ipv6 : hf_sua_dest_ipv6, parameter_tvb, IPV6_ADDRESS_OFFSET, IPV6_ADDRESS_LENGTH, ENC_NA);
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(parameter_tvb, IPV6_ADDRESS_OFFSET));
proto_item_append_text(parameter_item, " (%s)", tvb_ip6_to_str(wmem_packet_scope(), parameter_tvb, IPV6_ADDRESS_OFFSET));
}
static void

View File

@ -1515,7 +1515,7 @@ dissect_wccp2r1_address_table_info(tvbuff_t *tvb, int offset, int length,
break;
case 2:
/* IPv6 */
addr = tvb_ip6_to_str(tvb, offset);
addr = tvb_ip6_to_str(pinfo->pool, tvb, offset);
if ((wccp_wccp_address_table->in_use == FALSE) &&
(wccp_wccp_address_table->table_ipv6 != NULL) &&
(i < wccp_wccp_address_table->table_length))

View File

@ -323,7 +323,7 @@ static int dissect_xdmcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, vo
proto_item_append_text(connection_ti, ": %s", tvb_ip_to_str(pinfo->pool, tvb, caddrs_offset));
} else if ((ctype == 6) && (alen == 16)) {
proto_tree_add_item(connection_tree, hf_xdmcp_connection_address_ipv6, tvb, caddrs_offset, alen, ENC_NA);
proto_item_append_text(connection_ti, ": %s", tvb_ip6_to_str(tvb, caddrs_offset));
proto_item_append_text(connection_ti, ": %s", tvb_ip6_to_str(pinfo->pool, tvb, caddrs_offset));
} else {
proto_tree_add_item(connection_tree, hf_xdmcp_connection_address_bytes, tvb, caddrs_offset, alen, ENC_NA);
}

View File

@ -632,7 +632,7 @@ decode_xmcp_attr_value (proto_tree *attr_tree, guint16 attr_type,
} else {
proto_tree_add_item(attr_tree, xmcp_attr_servtrans_ipv6, tvb,
(offset+4), 16, ENC_NA);
proto_item_append_text(attr_tree, ": [%s]:%u", tvb_ip6_to_str(tvb, (offset+4)),
proto_item_append_text(attr_tree, ": [%s]:%u", tvb_ip6_to_str(pinfo->pool, tvb, (offset+4)),
tvb_get_ntohs(tvb, (offset+2)));
}
break;

View File

@ -226,7 +226,7 @@ PIDL_dissect_ipv6address(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tr
proto_tree_add_item(tree, hfindex, tvb, offset, 16, ENC_BIG_ENDIAN);
if (param & PIDL_SET_COL_INFO) {
const char *ip = tvb_ip6_to_str(tvb, offset);
const char *ip = tvb_ip6_to_str(pinfo->pool, tvb, offset);
header_field_info *hf_info = proto_registrar_get_nth(hfindex);
proto_item_append_text(proto_tree_get_parent(tree), " %s:%s", hf_info->name, ip);

View File

@ -86,7 +86,7 @@ WS_DLL_PUBLIC gchar* tvb_address_with_resolution_to_str(wmem_allocator_t *scope,
#define tvb_ip_to_str(scope, tvb, offset) tvb_address_to_str(scope, tvb, AT_IPv4, offset)
#define tvb_ip6_to_str(tvb, offset) tvb_address_to_str(wmem_packet_scope(), tvb, AT_IPv6, offset)
#define tvb_ip6_to_str(scope, tvb, offset) tvb_address_to_str(scope, tvb, AT_IPv6, offset)
#define tvb_fcwwn_to_str(scope, tvb, offset) tvb_address_to_str(scope, tvb, AT_FCWWN, offset)