aboutsummaryrefslogtreecommitdiffstats
path: root/packet-wsp.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2003-06-30 23:24:39 +0000
committerGuy Harris <guy@alum.mit.edu>2003-06-30 23:24:39 +0000
commit299f79c4f7573a1ee22e041418db863a9d00568f (patch)
tree62944baf5b6512b3c6681b95f2a4ee68fe7a3cfa /packet-wsp.c
parentdd544457db7e76d8abb3d6ff1ccd69da6ef99ee2 (diff)
From Olivier Biot:
UDH dissection in SMPP message WTP and WSP dissection over SMPP (no reassembly) WSP status code rendering in Info column svn path=/trunk/; revision=7954
Diffstat (limited to 'packet-wsp.c')
-rw-r--r--packet-wsp.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/packet-wsp.c b/packet-wsp.c
index e628db8b04..541f963e02 100644
--- a/packet-wsp.c
+++ b/packet-wsp.c
@@ -2,7 +2,7 @@
*
* Routines to dissect WSP component of WAP traffic.
*
- * $Id: packet-wsp.c,v 1.69 2003/05/25 19:36:51 guy Exp $
+ * $Id: packet-wsp.c,v 1.70 2003/06/30 23:24:39 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@@ -335,6 +335,7 @@ static const value_string vals_status[] = {
{ 0x63, "Service Unavailable" },
{ 0x64, "Gateway Timeout" },
{ 0x65, "HTTP Version Not Supported" },
+
{ 0x00, NULL }
};
@@ -1242,6 +1243,7 @@ dissect_wsp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
int offset = 0;
guint8 pdut;
+ guint8 reply_status;
guint count = 0;
guint value = 0;
guint uriLength = 0;
@@ -1451,7 +1453,13 @@ dissect_wsp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
headersLength = tvb_get_guintvar (tvb, offset+1, &count);
headerStart = offset + count + 1;
if (tree) {
+ reply_status = tvb_get_guint8(tvb, offset);
ti = proto_tree_add_item (wsp_tree, hf_wsp_header_status,tvb,offset,1,bo_little_endian);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ { /* Append status code to INFO column */
+ col_append_fstr(pinfo->cinfo, COL_INFO, ": \"0x%02x %s\"", reply_status,
+ val_to_str (reply_status, vals_status, "Unknown response status (0x%02x)"));
+ }
nextOffset = offset + 1 + count;
ti = proto_tree_add_uint (wsp_tree, hf_wsp_header_length,tvb,offset+1,count,headersLength);
@@ -5206,5 +5214,9 @@ proto_reg_handoff_wsp(void)
dissector_add("udp.port", UDP_PORT_WSP, wsp_fromudp_handle);
dissector_add("udp.port", UDP_PORT_WSP_PUSH, wsp_fromudp_handle);
+ /* SMPP dissector can also carry WSP */
+ dissector_add("smpp.udh.port", UDP_PORT_WSP, wsp_fromudp_handle);
+ dissector_add("smpp.udh.port", UDP_PORT_WSP_PUSH, wsp_fromudp_handle);
+
/* This dissector is also called from the WTP and WTLS dissectors */
}