aboutsummaryrefslogtreecommitdiffstats
path: root/asn1
diff options
context:
space:
mode:
authorHadriel Kaplan <hadrielk@yahoo.com>2015-01-25 14:30:13 -0500
committerHadriel Kaplan <hadrielk@yahoo.com>2015-01-27 15:14:12 +0000
commitceb8d954d25211d5cb4766ece277c15aa53578d5 (patch)
tree859ad1b08e44c140728311e9ed60fd3444cd2054 /asn1
parent9bbc33730622e117d9edfa3f393da883624510f1 (diff)
Lua: Expose tcp_dissect_pdus() to Lua
Provide a way for Lua-based dissectors to invoke tcp_dissect_pdus() to make TCP-based dissection easier. Bug: 9851 Change-Id: I91630ebf1f1fc1964118b6750cc34238e18a8ad3 Reviewed-on: https://code.wireshark.org/review/6778 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com> Tested-by: Hadriel Kaplan <hadrielk@yahoo.com>
Diffstat (limited to 'asn1')
-rw-r--r--asn1/c1222/packet-c1222-template.c2
-rw-r--r--asn1/cmp/packet-cmp-template.c3
-rw-r--r--asn1/idmp/packet-idmp-template.c3
-rw-r--r--asn1/ilp/packet-ilp-template.c2
-rw-r--r--asn1/kerberos/packet-kerberos-template.c2
-rw-r--r--asn1/ldap/packet-ldap-template.c6
-rw-r--r--asn1/sabp/packet-sabp-template.c2
-rw-r--r--asn1/ulp/packet-ulp-template.c2
8 files changed, 13 insertions, 9 deletions
diff --git a/asn1/c1222/packet-c1222-template.c b/asn1/c1222/packet-c1222-template.c
index 47c69aca6b..45f5d51c6b 100644
--- a/asn1/c1222/packet-c1222-template.c
+++ b/asn1/c1222/packet-c1222-template.c
@@ -1073,7 +1073,7 @@ dissect_c1222_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void*
* \returns length of entire C12.22 message
*/
static guint
-get_c1222_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset)
+get_c1222_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset, void *data _U_)
{
int orig_offset;
guint length;
diff --git a/asn1/cmp/packet-cmp-template.c b/asn1/cmp/packet-cmp-template.c
index b7d94a942e..c9506d21ad 100644
--- a/asn1/cmp/packet-cmp-template.c
+++ b/asn1/cmp/packet-cmp-template.c
@@ -190,7 +190,8 @@ static int dissect_cmp_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *pa
return offset;
}
-static guint get_cmp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+static guint get_cmp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb,
+ int offset, void *data _U_)
{
guint32 plen;
diff --git a/asn1/idmp/packet-idmp-template.c b/asn1/idmp/packet-idmp-template.c
index 425e400b91..f0cce14c56 100644
--- a/asn1/idmp/packet-idmp-template.c
+++ b/asn1/idmp/packet-idmp-template.c
@@ -229,7 +229,8 @@ static int dissect_idmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tr
return tvb_captured_length(tvb);
}
-static guint get_idmp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+static guint get_idmp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb,
+ int offset, void *data _U_)
{
guint32 len;
diff --git a/asn1/ilp/packet-ilp-template.c b/asn1/ilp/packet-ilp-template.c
index c0398a6996..6251662ce7 100644
--- a/asn1/ilp/packet-ilp-template.c
+++ b/asn1/ilp/packet-ilp-template.c
@@ -70,7 +70,7 @@ static gint ett_ilp = -1;
static guint
-get_ilp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_ilp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset, void *data _U_)
{
/* PDU length = Message length */
return tvb_get_ntohs(tvb,offset);
diff --git a/asn1/kerberos/packet-kerberos-template.c b/asn1/kerberos/packet-kerberos-template.c
index 8bbd90fbc9..ed3137dc40 100644
--- a/asn1/kerberos/packet-kerberos-template.c
+++ b/asn1/kerberos/packet-kerberos-template.c
@@ -2170,7 +2170,7 @@ kerberos_rm_to_reclen(guint krb_rm)
}
guint
-get_krb_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_krb_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset, void *data _U_)
{
guint krb_rm;
gint pdulen;
diff --git a/asn1/ldap/packet-ldap-template.c b/asn1/ldap/packet-ldap-template.c
index d5dccc94c7..87b427194f 100644
--- a/asn1/ldap/packet-ldap-template.c
+++ b/asn1/ldap/packet-ldap-template.c
@@ -1619,7 +1619,8 @@ static void dissect_NetLogon_PDU(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tr
static guint
-get_sasl_ldap_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_sasl_ldap_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb,
+ int offset, void *data _U_)
{
/* sasl encapsulated ldap is 4 bytes plus the length in size */
return tvb_get_ntohl(tvb, offset)+4;
@@ -1633,7 +1634,8 @@ dissect_sasl_ldap_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void*
}
static guint
-get_normal_ldap_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_normal_ldap_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb,
+ int offset, void *data _U_)
{
guint32 len;
gboolean ind;
diff --git a/asn1/sabp/packet-sabp-template.c b/asn1/sabp/packet-sabp-template.c
index 23d4fb79c7..6261b27a9c 100644
--- a/asn1/sabp/packet-sabp-template.c
+++ b/asn1/sabp/packet-sabp-template.c
@@ -167,7 +167,7 @@ dissect_sabp_cb_data(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
}
static guint
-get_sabp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_sabp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset, void *data _U_)
{
guint32 type_length;
int bit_offset;
diff --git a/asn1/ulp/packet-ulp-template.c b/asn1/ulp/packet-ulp-template.c
index 27a6b411bf..ab3db01eaf 100644
--- a/asn1/ulp/packet-ulp-template.c
+++ b/asn1/ulp/packet-ulp-template.c
@@ -72,7 +72,7 @@ static gint ett_ulp = -1;
static guint
-get_ulp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
+get_ulp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset, void *data _U_)
{
/* PDU length = Message length */
return tvb_get_ntohs(tvb,offset);