summaryrefslogtreecommitdiff
path: root/epan/addr_resolv.c
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2007-01-29 20:25:26 +0000
committerGerald Combs <gerald@wireshark.org>2007-01-29 20:25:26 +0000
commit063621f11ba5c3c05514be94bd03865096b911b5 (patch)
tree97af587679fd749ac55b6ce95491d0c2260b5f7d /epan/addr_resolv.c
parent54f4d487f4e9425492298cf08099cf8fa4adcf9a (diff)
downloadwireshark-063621f11ba5c3c05514be94bd03865096b911b5.tar.gz
Fix potential buffer overruns in address_to_str_buf() found by Andrej
Mikus. Add a buf_len parameter to ip_to_str_buf(), and make sure it's enforced. Copy the release notes over from the 0.99.5 trunk and add a note about the ISUP dissector (which is affected by the overrun). svn path=/trunk/; revision=20607
Diffstat (limited to 'epan/addr_resolv.c')
-rw-r--r--epan/addr_resolv.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/epan/addr_resolv.c b/epan/addr_resolv.c
index bde00bde74..f12eda1080 100644
--- a/epan/addr_resolv.c
+++ b/epan/addr_resolv.c
@@ -407,7 +407,7 @@ static gchar *host_name_lookup(guint addr, gboolean *found)
adns_queue_head = g_list_append(adns_queue_head, (gpointer) qmsg);
tp->is_dummy_entry = TRUE;
- ip_to_str_buf((guint8 *)&addr, tp->name);
+ ip_to_str_buf((guint8 *)&addr, tp->name, MAXNAMELEN);
return tp->name;
}
#endif /* HAVE_GNU_ADNS */
@@ -453,7 +453,7 @@ static gchar *host_name_lookup(guint addr, gboolean *found)
/* unknown host or DNS timeout */
- ip_to_str_buf((guint8 *)&addr, tp->name);
+ ip_to_str_buf((guint8 *)&addr, tp->name, MAXNAMELEN);
tp->is_dummy_entry = TRUE;
*found = FALSE;