diff options
author | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2007-05-13 20:58:29 +0000 |
---|---|---|
committer | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2007-05-13 20:58:29 +0000 |
commit | 2904c6115933cfab7bc881b269680fb73ab59a54 (patch) | |
tree | eb3da0d69d5bc62ca587ebd999b6beacd693f168 /epan/dissectors/packet-cms.c | |
parent | 449bb111a734d5bef2f890102e2d0a6ff2f1b9da (diff) |
Second step in introducing asn context to BER dissectors just like in PER.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@21753 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/dissectors/packet-cms.c')
-rw-r--r-- | epan/dissectors/packet-cms.c | 753 |
1 files changed, 392 insertions, 361 deletions
diff --git a/epan/dissectors/packet-cms.c b/epan/dissectors/packet-cms.c index 16cff43132..5776b2c8dd 100644 --- a/epan/dissectors/packet-cms.c +++ b/epan/dissectors/packet-cms.c @@ -39,6 +39,7 @@ #include <epan/packet.h> #include <epan/conversation.h> #include <epan/oid_resolv.h> +#include <epan/asn1.h> #include <stdio.h> #include <string.h> @@ -162,7 +163,7 @@ static int hf_cms_rc2WrapParameter = -1; /* RC2WrapParameter */ static int hf_cms_rc2CBCParameter = -1; /* RC2CBCParameter */ /*--- End of included file: packet-cms-hf.c ---*/ -#line 54 "packet-cms-template.c" +#line 55 "packet-cms-template.c" /* Initialize the subtree pointers */ @@ -216,9 +217,9 @@ static gint ett_cms_SMIMEEncryptionKeyPreference = -1; static gint ett_cms_RC2CBCParameters = -1; /*--- End of included file: packet-cms-ett.c ---*/ -#line 57 "packet-cms-template.c" +#line 58 "packet-cms-template.c" -static int dissect_cms_OCTET_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) ; /* XXX kill a compiler warning until asn2wrs stops generating these silly wrappers */ +static int dissect_cms_OCTET_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn1_ctx_t *actx, proto_tree *tree, int hf_index _U_) ; /* XXX kill a compiler warning until asn2wrs stops generating these silly wrappers */ static const char *object_identifier_id; @@ -299,33 +300,33 @@ cms_verify_msg_digest(proto_item *pi, tvbuff_t *content, const char *alg, tvbuff #line 1 "packet-cms-fn.c" /*--- Fields for imported types ---*/ -static int dissect_algorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509af_AlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_algorithm); +static int dissect_algorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509af_AlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_algorithm); } -static int dissect_CertificateRevocationLists_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509af_CertificateList(FALSE, tvb, offset, pinfo, tree, hf_cms_CertificateRevocationLists_item); +static int dissect_CertificateRevocationLists_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509af_CertificateList(FALSE, tvb, offset, actx, tree, hf_cms_CertificateRevocationLists_item); } -static int dissect_certificate(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509af_Certificate(FALSE, tvb, offset, pinfo, tree, hf_cms_certificate); +static int dissect_certificate(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509af_Certificate(FALSE, tvb, offset, actx, tree, hf_cms_certificate); } -static int dissect_attrCert_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509af_AttributeCertificate(TRUE, tvb, offset, pinfo, tree, hf_cms_attrCert); +static int dissect_attrCert_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509af_AttributeCertificate(TRUE, tvb, offset, actx, tree, hf_cms_attrCert); } -static int dissect_issuer(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509if_Name(FALSE, tvb, offset, pinfo, tree, hf_cms_issuer); +static int dissect_issuer(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509if_Name(FALSE, tvb, offset, actx, tree, hf_cms_issuer); } -static int dissect_serialNumber(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_x509af_CertificateSerialNumber(FALSE, tvb, offset, pinfo, tree, hf_cms_serialNumber); +static int dissect_serialNumber(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_x509af_CertificateSerialNumber(FALSE, tvb, offset, actx, tree, hf_cms_serialNumber); } int -dissect_cms_ContentType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_ContentType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 73 "cms.cnf" const char *name = NULL; - offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_index, &object_identifier_id); + offset = dissect_ber_object_identifier_str(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, &object_identifier_id); if(object_identifier_id) { @@ -337,30 +338,30 @@ dissect_cms_ContentType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset return offset; } -static int dissect_contentType(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ContentType(FALSE, tvb, offset, pinfo, tree, hf_cms_contentType); +static int dissect_contentType(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ContentType(FALSE, tvb, offset, actx, tree, hf_cms_contentType); } -static int dissect_eContentType(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ContentType(FALSE, tvb, offset, pinfo, tree, hf_cms_eContentType); +static int dissect_eContentType(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ContentType(FALSE, tvb, offset, actx, tree, hf_cms_eContentType); } -static int dissect_encryptedContentType(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ContentType(FALSE, tvb, offset, pinfo, tree, hf_cms_encryptedContentType); +static int dissect_encryptedContentType(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ContentType(FALSE, tvb, offset, actx, tree, hf_cms_encryptedContentType); } static int -dissect_cms_T_content(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_content(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 83 "cms.cnf" - offset=call_ber_oid_callback(object_identifier_id, tvb, offset, pinfo, tree); + offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree); return offset; } -static int dissect_content(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_content(FALSE, tvb, offset, pinfo, tree, hf_cms_content); +static int dissect_content(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_content(FALSE, tvb, offset, actx, tree, hf_cms_content); } @@ -371,10 +372,10 @@ static const ber_sequence_t ContentInfo_sequence[] = { }; int -dissect_cms_ContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_ContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 64 "cms.cnf" top_tree = tree; - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, ContentInfo_sequence, hf_index, ett_cms_ContentInfo); content_tvb = NULL; @@ -397,32 +398,32 @@ static const value_string cms_CMSVersion_vals[] = { static int -dissect_cms_CMSVersion(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_CMSVersion(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_integer(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_version(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_CMSVersion(FALSE, tvb, offset, pinfo, tree, hf_cms_version); +static int dissect_version(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_CMSVersion(FALSE, tvb, offset, actx, tree, hf_cms_version); } int -dissect_cms_DigestAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_DigestAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_DigestAlgorithmIdentifiers_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_DigestAlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_DigestAlgorithmIdentifiers_item); +static int dissect_DigestAlgorithmIdentifiers_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_DigestAlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_DigestAlgorithmIdentifiers_item); } -static int dissect_digestAlgorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_DigestAlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_digestAlgorithm); +static int dissect_digestAlgorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_DigestAlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_digestAlgorithm); } -static int dissect_digestAlgorithm_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_DigestAlgorithmIdentifier(TRUE, tvb, offset, pinfo, tree, hf_cms_digestAlgorithm); +static int dissect_digestAlgorithm_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_DigestAlgorithmIdentifier(TRUE, tvb, offset, actx, tree, hf_cms_digestAlgorithm); } @@ -431,20 +432,20 @@ static const ber_sequence_t DigestAlgorithmIdentifiers_set_of[1] = { }; int -dissect_cms_DigestAlgorithmIdentifiers(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_DigestAlgorithmIdentifiers(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, DigestAlgorithmIdentifiers_set_of, hf_index, ett_cms_DigestAlgorithmIdentifiers); return offset; } -static int dissect_digestAlgorithms(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_DigestAlgorithmIdentifiers(FALSE, tvb, offset, pinfo, tree, hf_cms_digestAlgorithms); +static int dissect_digestAlgorithms(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_DigestAlgorithmIdentifiers(FALSE, tvb, offset, actx, tree, hf_cms_digestAlgorithms); } static int -dissect_cms_T_eContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_eContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 87 "cms.cnf" gint8 class; gboolean pc, ind; @@ -454,11 +455,11 @@ dissect_cms_T_eContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset int content_offset; /* XXX Do we care about printing out the octet string? */ - offset = dissect_cms_OCTET_STRING(FALSE, tvb, offset, pinfo, NULL, hf_cms_eContent); + offset = dissect_cms_OCTET_STRING(FALSE, tvb, offset, actx, NULL, hf_cms_eContent); pdu_offset = get_ber_identifier(tvb, pdu_offset, &class, &pc, &tag); content_offset = pdu_offset = get_ber_length(tree, tvb, pdu_offset, &len, &ind); - pdu_offset = call_ber_oid_callback(object_identifier_id, tvb, pdu_offset, pinfo, top_tree ? top_tree : tree); + pdu_offset = call_ber_oid_callback(object_identifier_id, tvb, pdu_offset, actx->pinfo, top_tree ? top_tree : tree); /* save the content for checking the message digest */ content_tvb = tvb_new_subset(tvb, content_offset, len, -1); @@ -467,8 +468,8 @@ dissect_cms_T_eContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset return offset; } -static int dissect_eContent(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_eContent(FALSE, tvb, offset, pinfo, tree, hf_cms_eContent); +static int dissect_eContent(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_eContent(FALSE, tvb, offset, actx, tree, hf_cms_eContent); } @@ -479,24 +480,24 @@ static const ber_sequence_t EncapsulatedContentInfo_sequence[] = { }; int -dissect_cms_EncapsulatedContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_EncapsulatedContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, EncapsulatedContentInfo_sequence, hf_index, ett_cms_EncapsulatedContentInfo); return offset; } -static int dissect_encapContentInfo(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_EncapsulatedContentInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_encapContentInfo); +static int dissect_encapContentInfo(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_EncapsulatedContentInfo(FALSE, tvb, offset, actx, tree, hf_cms_encapContentInfo); } static int -dissect_cms_T_attrType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_attrType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 115 "cms.cnf" const char *name = NULL; - offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_cms_attrType, &object_identifier_id); + offset = dissect_ber_object_identifier_str(implicit_tag, actx->pinfo, tree, tvb, offset, hf_cms_attrType, &object_identifier_id); if(object_identifier_id) { @@ -508,24 +509,24 @@ dissect_cms_T_attrType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset return offset; } -static int dissect_attrType(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_attrType(FALSE, tvb, offset, pinfo, tree, hf_cms_attrType); +static int dissect_attrType(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_attrType(FALSE, tvb, offset, actx, tree, hf_cms_attrType); } static int -dissect_cms_AttributeValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_AttributeValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 125 "cms.cnf" - offset=call_ber_oid_callback(object_identifier_id, tvb, offset, pinfo, tree); + offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree); return offset; } -static int dissect_attrValues_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_AttributeValue(FALSE, tvb, offset, pinfo, tree, hf_cms_attrValues_item); +static int dissect_attrValues_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_AttributeValue(FALSE, tvb, offset, actx, tree, hf_cms_attrValues_item); } @@ -534,14 +535,14 @@ static const ber_sequence_t SET_OF_AttributeValue_set_of[1] = { }; static int -dissect_cms_SET_OF_AttributeValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SET_OF_AttributeValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, SET_OF_AttributeValue_set_of, hf_index, ett_cms_SET_OF_AttributeValue); return offset; } -static int dissect_attrValues(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SET_OF_AttributeValue(FALSE, tvb, offset, pinfo, tree, hf_cms_attrValues); +static int dissect_attrValues(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SET_OF_AttributeValue(FALSE, tvb, offset, actx, tree, hf_cms_attrValues); } @@ -552,26 +553,26 @@ static const ber_sequence_t Attribute_sequence[] = { }; static int -dissect_cms_Attribute(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_Attribute(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, Attribute_sequence, hf_index, ett_cms_Attribute); return offset; } -static int dissect_SignedAttributes_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Attribute(FALSE, tvb, offset, pinfo, tree, hf_cms_SignedAttributes_item); +static int dissect_SignedAttributes_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Attribute(FALSE, tvb, offset, actx, tree, hf_cms_SignedAttributes_item); } -static int dissect_UnsignedAttributes_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Attribute(FALSE, tvb, offset, pinfo, tree, hf_cms_UnsignedAttributes_item); +static int dissect_UnsignedAttributes_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Attribute(FALSE, tvb, offset, actx, tree, hf_cms_UnsignedAttributes_item); } -static int dissect_UnprotectedAttributes_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Attribute(FALSE, tvb, offset, pinfo, tree, hf_cms_UnprotectedAttributes_item); +static int dissect_UnprotectedAttributes_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Attribute(FALSE, tvb, offset, actx, tree, hf_cms_UnprotectedAttributes_item); } -static int dissect_AuthAttributes_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Attribute(FALSE, tvb, offset, pinfo, tree, hf_cms_AuthAttributes_item); +static int dissect_AuthAttributes_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Attribute(FALSE, tvb, offset, actx, tree, hf_cms_AuthAttributes_item); } -static int dissect_UnauthAttributes_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Attribute(FALSE, tvb, offset, pinfo, tree, hf_cms_UnauthAttributes_item); +static int dissect_UnauthAttributes_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Attribute(FALSE, tvb, offset, actx, tree, hf_cms_UnauthAttributes_item); } @@ -580,17 +581,17 @@ static const ber_sequence_t UnauthAttributes_set_of[1] = { }; static int -dissect_cms_UnauthAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_UnauthAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, UnauthAttributes_set_of, hf_index, ett_cms_UnauthAttributes); return offset; } -static int dissect_unauthenticatedAttributes_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UnauthAttributes(TRUE, tvb, offset, pinfo, tree, hf_cms_unauthenticatedAttributes); +static int dissect_unauthenticatedAttributes_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UnauthAttributes(TRUE, tvb, offset, actx, tree, hf_cms_unauthenticatedAttributes); } -static int dissect_attributes(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UnauthAttributes(FALSE, tvb, offset, pinfo, tree, hf_cms_attributes); +static int dissect_attributes(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UnauthAttributes(FALSE, tvb, offset, actx, tree, hf_cms_attributes); } @@ -602,40 +603,40 @@ static const ber_sequence_t ExtendedCertificateInfo_sequence[] = { }; static int -dissect_cms_ExtendedCertificateInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_ExtendedCertificateInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, ExtendedCertificateInfo_sequence, hf_index, ett_cms_ExtendedCertificateInfo); return offset; } -static int dissect_extendedCertificateInfo(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ExtendedCertificateInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_extendedCertificateInfo); +static int dissect_extendedCertificateInfo(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ExtendedCertificateInfo(FALSE, tvb, offset, actx, tree, hf_cms_extendedCertificateInfo); } static int -dissect_cms_SignatureAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_SignatureAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_signatureAlgorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignatureAlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_signatureAlgorithm); +static int dissect_signatureAlgorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignatureAlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_signatureAlgorithm); } static int -dissect_cms_Signature(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_bitstring(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_Signature(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_bitstring(implicit_tag, actx->pinfo, tree, tvb, offset, NULL, hf_index, -1, NULL); return offset; } -static int dissect_signature(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Signature(FALSE, tvb, offset, pinfo, tree, hf_cms_signature); +static int dissect_signature(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Signature(FALSE, tvb, offset, actx, tree, hf_cms_signature); } @@ -647,14 +648,14 @@ static const ber_sequence_t ExtendedCertificate_sequence[] = { }; static int -dissect_cms_ExtendedCertificate(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_ExtendedCertificate(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, ExtendedCertificate_sequence, hf_index, ett_cms_ExtendedCertificate); return offset; } -static int dissect_extendedCertificate_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ExtendedCertificate(TRUE, tvb, offset, pinfo, tree, hf_cms_extendedCertificate); +static int dissect_extendedCertificate_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ExtendedCertificate(TRUE, tvb, offset, actx, tree, hf_cms_extendedCertificate); } @@ -673,15 +674,15 @@ static const ber_choice_t CertificateChoices_choice[] = { }; static int -dissect_cms_CertificateChoices(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_CertificateChoices(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, CertificateChoices_choice, hf_index, ett_cms_CertificateChoices, NULL); return offset; } -static int dissect_CertificateSet_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_CertificateChoices(FALSE, tvb, offset, pinfo, tree, hf_cms_CertificateSet_item); +static int dissect_CertificateSet_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_CertificateChoices(FALSE, tvb, offset, actx, tree, hf_cms_CertificateSet_item); } @@ -690,17 +691,17 @@ static const ber_sequence_t CertificateSet_set_of[1] = { }; static int -dissect_cms_CertificateSet(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_CertificateSet(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, CertificateSet_set_of, hf_index, ett_cms_CertificateSet); return offset; } -static int dissect_certificates_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_CertificateSet(TRUE, tvb, offset, pinfo, tree, hf_cms_certificates); +static int dissect_certificates_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_CertificateSet(TRUE, tvb, offset, actx, tree, hf_cms_certificates); } -static int dissect_certs_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_CertificateSet(TRUE, tvb, offset, pinfo, tree, hf_cms_certs); +static int dissect_certs_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_CertificateSet(TRUE, tvb, offset, actx, tree, hf_cms_certs); } @@ -709,14 +710,14 @@ static const ber_sequence_t CertificateRevocationLists_set_of[1] = { }; static int -dissect_cms_CertificateRevocationLists(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_CertificateRevocationLists(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, CertificateRevocationLists_set_of, hf_index, ett_cms_CertificateRevocationLists); return offset; } -static int dissect_crls_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_CertificateRevocationLists(TRUE, tvb, offset, pinfo, tree, hf_cms_crls); +static int dissect_crls_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_CertificateRevocationLists(TRUE, tvb, offset, actx, tree, hf_cms_crls); } @@ -727,36 +728,36 @@ static const ber_sequence_t IssuerAndSerialNumber_sequence[] = { }; int -dissect_cms_IssuerAndSerialNumber(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_IssuerAndSerialNumber(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, IssuerAndSerialNumber_sequence, hf_index, ett_cms_IssuerAndSerialNumber); return offset; } -static int dissect_issuerAndSerialNumber(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_IssuerAndSerialNumber(FALSE, tvb, offset, pinfo, tree, hf_cms_issuerAndSerialNumber); +static int dissect_issuerAndSerialNumber(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_IssuerAndSerialNumber(FALSE, tvb, offset, actx, tree, hf_cms_issuerAndSerialNumber); } -static int dissect_issuerAndSerialNumber_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_IssuerAndSerialNumber(TRUE, tvb, offset, pinfo, tree, hf_cms_issuerAndSerialNumber); +static int dissect_issuerAndSerialNumber_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_IssuerAndSerialNumber(TRUE, tvb, offset, actx, tree, hf_cms_issuerAndSerialNumber); } static int -dissect_cms_SubjectKeyIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_SubjectKeyIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_subjectKeyIdentifier(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SubjectKeyIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_subjectKeyIdentifier); +static int dissect_subjectKeyIdentifier(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SubjectKeyIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_subjectKeyIdentifier); } -static int dissect_subjectKeyIdentifier_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SubjectKeyIdentifier(TRUE, tvb, offset, pinfo, tree, hf_cms_subjectKeyIdentifier); +static int dissect_subjectKeyIdentifier_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SubjectKeyIdentifier(TRUE, tvb, offset, actx, tree, hf_cms_subjectKeyIdentifier); } -static int dissect_subjectAltKeyIdentifier_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SubjectKeyIdentifier(TRUE, tvb, offset, pinfo, tree, hf_cms_subjectAltKeyIdentifier); +static int dissect_subjectAltKeyIdentifier_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SubjectKeyIdentifier(TRUE, tvb, offset, actx, tree, hf_cms_subjectAltKeyIdentifier); } @@ -773,15 +774,15 @@ static const ber_choice_t SignerIdentifier_choice[] = { }; int -dissect_cms_SignerIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_SignerIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, SignerIdentifier_choice, hf_index, ett_cms_SignerIdentifier, NULL); return offset; } -static int dissect_sid(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignerIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_sid); +static int dissect_sid(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignerIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_sid); } @@ -790,27 +791,27 @@ static const ber_sequence_t SignedAttributes_set_of[1] = { }; int -dissect_cms_SignedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SignedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, SignedAttributes_set_of, hf_index, ett_cms_SignedAttributes); return offset; } -static int dissect_signedAttrs_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignedAttributes(TRUE, tvb, offset, pinfo, tree, hf_cms_signedAttrs); +static int dissect_signedAttrs_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignedAttributes(TRUE, tvb, offset, actx, tree, hf_cms_signedAttrs); } int -dissect_cms_SignatureValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_SignatureValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_signatureValue(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignatureValue(FALSE, tvb, offset, pinfo, tree, hf_cms_signatureValue); +static int dissect_signatureValue(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignatureValue(FALSE, tvb, offset, actx, tree, hf_cms_signatureValue); } @@ -819,14 +820,14 @@ static const ber_sequence_t UnsignedAttributes_set_of[1] = { }; int -dissect_cms_UnsignedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_UnsignedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, UnsignedAttributes_set_of, hf_index, ett_cms_UnsignedAttributes); return offset; } -static int dissect_unsignedAttrs_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UnsignedAttributes(TRUE, tvb, offset, pinfo, tree, hf_cms_unsignedAttrs); +static int dissect_unsignedAttrs_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UnsignedAttributes(TRUE, tvb, offset, actx, tree, hf_cms_unsignedAttrs); } @@ -842,14 +843,14 @@ static const ber_sequence_t SignerInfo_sequence[] = { }; int -dissect_cms_SignerInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SignerInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, SignerInfo_sequence, hf_index, ett_cms_SignerInfo); return offset; } -static int dissect_SignerInfos_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignerInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_SignerInfos_item); +static int dissect_SignerInfos_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignerInfo(FALSE, tvb, offset, actx, tree, hf_cms_SignerInfos_item); } @@ -858,14 +859,14 @@ static const ber_sequence_t SignerInfos_set_of[1] = { }; int -dissect_cms_SignerInfos(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SignerInfos(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, SignerInfos_set_of, hf_index, ett_cms_SignerInfos); return offset; } -static int dissect_signerInfos(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SignerInfos(FALSE, tvb, offset, pinfo, tree, hf_cms_signerInfos); +static int dissect_signerInfos(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SignerInfos(FALSE, tvb, offset, actx, tree, hf_cms_signerInfos); } @@ -880,8 +881,8 @@ static const ber_sequence_t SignedData_sequence[] = { }; int -dissect_cms_SignedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SignedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, SignedData_sequence, hf_index, ett_cms_SignedData); return offset; @@ -895,14 +896,14 @@ static const ber_sequence_t OriginatorInfo_sequence[] = { }; static int -dissect_cms_OriginatorInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_OriginatorInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, OriginatorInfo_sequence, hf_index, ett_cms_OriginatorInfo); return offset; } -static int dissect_originatorInfo_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OriginatorInfo(TRUE, tvb, offset, pinfo, tree, hf_cms_originatorInfo); +static int dissect_originatorInfo_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OriginatorInfo(TRUE, tvb, offset, actx, tree, hf_cms_originatorInfo); } @@ -919,40 +920,40 @@ static const ber_choice_t RecipientIdentifier_choice[] = { }; static int -dissect_cms_RecipientIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_RecipientIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, RecipientIdentifier_choice, hf_index, ett_cms_RecipientIdentifier, NULL); return offset; } -static int dissect_rid(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_rid); +static int dissect_rid(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_rid); } static int -dissect_cms_KeyEncryptionAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_KeyEncryptionAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_keyEncryptionAlgorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KeyEncryptionAlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_keyEncryptionAlgorithm); +static int dissect_keyEncryptionAlgorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KeyEncryptionAlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_keyEncryptionAlgorithm); } static int -dissect_cms_EncryptedKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_EncryptedKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_encryptedKey(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_EncryptedKey(FALSE, tvb, offset, pinfo, tree, hf_cms_encryptedKey); +static int dissect_encryptedKey(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_EncryptedKey(FALSE, tvb, offset, actx, tree, hf_cms_encryptedKey); } @@ -965,28 +966,28 @@ static const ber_sequence_t KeyTransRecipientInfo_sequence[] = { }; static int -dissect_cms_KeyTransRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_KeyTransRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, KeyTransRecipientInfo_sequence, hf_index, ett_cms_KeyTransRecipientInfo); return offset; } -static int dissect_ktri(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KeyTransRecipientInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_ktri); +static int dissect_ktri(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KeyTransRecipientInfo(FALSE, tvb, offset, actx, tree, hf_cms_ktri); } static int -dissect_cms_BIT_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_bitstring(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_BIT_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_bitstring(implicit_tag, actx->pinfo, tree, tvb, offset, NULL, hf_index, -1, NULL); return offset; } -static int dissect_publicKey(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_BIT_STRING(FALSE, tvb, offset, pinfo, tree, hf_cms_publicKey); +static int dissect_publicKey(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_BIT_STRING(FALSE, tvb, offset, actx, tree, hf_cms_publicKey); } @@ -997,14 +998,14 @@ static const ber_sequence_t OriginatorPublicKey_sequence[] = { }; static int -dissect_cms_OriginatorPublicKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_OriginatorPublicKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, OriginatorPublicKey_sequence, hf_index, ett_cms_OriginatorPublicKey); return offset; } -static int dissect_originatorKey_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OriginatorPublicKey(TRUE, tvb, offset, pinfo, tree, hf_cms_originatorKey); +static int dissect_originatorKey_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OriginatorPublicKey(TRUE, tvb, offset, actx, tree, hf_cms_originatorKey); } @@ -1023,71 +1024,71 @@ static const ber_choice_t OriginatorIdentifierOrKey_choice[] = { }; static int -dissect_cms_OriginatorIdentifierOrKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_OriginatorIdentifierOrKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, OriginatorIdentifierOrKey_choice, hf_index, ett_cms_OriginatorIdentifierOrKey, NULL); return offset; } -static int dissect_originator(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OriginatorIdentifierOrKey(FALSE, tvb, offset, pinfo, tree, hf_cms_originator); +static int dissect_originator(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OriginatorIdentifierOrKey(FALSE, tvb, offset, actx, tree, hf_cms_originator); } static int -dissect_cms_UserKeyingMaterial(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_UserKeyingMaterial(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_ukm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UserKeyingMaterial(FALSE, tvb, offset, pinfo, tree, hf_cms_ukm); +static int dissect_ukm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UserKeyingMaterial(FALSE, tvb, offset, actx, tree, hf_cms_ukm); } static int -dissect_cms_GeneralizedTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_GeneralizedTime(implicit_tag, pinfo, tree, tvb, offset, hf_index); +dissect_cms_GeneralizedTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_GeneralizedTime(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index); return offset; } -static int dissect_date(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_GeneralizedTime(FALSE, tvb, offset, pinfo, tree, hf_cms_date); +static int dissect_date(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_GeneralizedTime(FALSE, tvb, offset, actx, tree, hf_cms_date); } -static int dissect_generalTime(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_GeneralizedTime(FALSE, tvb, offset, pinfo, tree, hf_cms_generalTime); +static int dissect_generalTime(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_GeneralizedTime(FALSE, tvb, offset, actx, tree, hf_cms_generalTime); } static int -dissect_cms_T_keyAttrId(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_cms_ci_contentType, &object_identifier_id); +dissect_cms_T_keyAttrId(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_object_identifier_str(implicit_tag, actx->pinfo, tree, tvb, offset, hf_cms_ci_contentType, &object_identifier_id); return offset; } -static int dissect_keyAttrId(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_keyAttrId(FALSE, tvb, offset, pinfo, tree, hf_cms_keyAttrId); +static int dissect_keyAttrId(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_keyAttrId(FALSE, tvb, offset, actx, tree, hf_cms_keyAttrId); } static int -dissect_cms_T_keyAttr(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_keyAttr(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 108 "cms.cnf" - offset=call_ber_oid_callback(object_identifier_id, tvb, offset, pinfo, tree); + offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree); return offset; } -static int dissect_keyAttr(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_keyAttr(FALSE, tvb, offset, pinfo, tree, hf_cms_keyAttr); +static int dissect_keyAttr(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_keyAttr(FALSE, tvb, offset, actx, tree, hf_cms_keyAttr); } @@ -1098,14 +1099,14 @@ static const ber_sequence_t OtherKeyAttribute_sequence[] = { }; static int -dissect_cms_OtherKeyAttribute(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_OtherKeyAttribute(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, OtherKeyAttribute_sequence, hf_index, ett_cms_OtherKeyAttribute); return offset; } -static int dissect_other(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OtherKeyAttribute(FALSE, tvb, offset, pinfo, tree, hf_cms_other); +static int dissect_other(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OtherKeyAttribute(FALSE, tvb, offset, actx, tree, hf_cms_other); } @@ -1117,17 +1118,17 @@ static const ber_sequence_t RecipientKeyIdentifier_sequence[] = { }; static int -dissect_cms_RecipientKeyIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_RecipientKeyIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, RecipientKeyIdentifier_sequence, hf_index, ett_cms_RecipientKeyIdentifier); return offset; } -static int dissect_rKeyId_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientKeyIdentifier(TRUE, tvb, offset, pinfo, tree, hf_cms_rKeyId); +static int dissect_rKeyId_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientKeyIdentifier(TRUE, tvb, offset, actx, tree, hf_cms_rKeyId); } -static int dissect_recipientKeyId_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientKeyIdentifier(TRUE, tvb, offset, pinfo, tree, hf_cms_recipientKeyId); +static int dissect_recipientKeyId_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientKeyIdentifier(TRUE, tvb, offset, actx, tree, hf_cms_recipientKeyId); } @@ -1144,15 +1145,15 @@ static const ber_choice_t KeyAgreeRecipientIdentifier_choice[] = { }; static int -dissect_cms_KeyAgreeRecipientIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_KeyAgreeRecipientIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, KeyAgreeRecipientIdentifier_choice, hf_index, ett_cms_KeyAgreeRecipientIdentifier, NULL); return offset; } -static int dissect_rekRid(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KeyAgreeRecipientIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_rekRid); +static int dissect_rekRid(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KeyAgreeRecipientIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_rekRid); } @@ -1163,14 +1164,14 @@ static const ber_sequence_t RecipientEncryptedKey_sequence[] = { }; static int -dissect_cms_RecipientEncryptedKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_RecipientEncryptedKey(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, RecipientEncryptedKey_sequence, hf_index, ett_cms_RecipientEncryptedKey); return offset; } -static int dissect_RecipientEncryptedKeys_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientEncryptedKey(FALSE, tvb, offset, pinfo, tree, hf_cms_RecipientEncryptedKeys_item); +static int dissect_RecipientEncryptedKeys_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientEncryptedKey(FALSE, tvb, offset, actx, tree, hf_cms_RecipientEncryptedKeys_item); } @@ -1179,14 +1180,14 @@ static const ber_sequence_t RecipientEncryptedKeys_sequence_of[1] = { }; static int -dissect_cms_RecipientEncryptedKeys(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_RecipientEncryptedKeys(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset, RecipientEncryptedKeys_sequence_of, hf_index, ett_cms_RecipientEncryptedKeys); return offset; } -static int dissect_recipientEncryptedKeys(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientEncryptedKeys(FALSE, tvb, offset, pinfo, tree, hf_cms_recipientEncryptedKeys); +static int dissect_recipientEncryptedKeys(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientEncryptedKeys(FALSE, tvb, offset, actx, tree, hf_cms_recipientEncryptedKeys); } @@ -1200,30 +1201,30 @@ static const ber_sequence_t KeyAgreeRecipientInfo_sequence[] = { }; static int -dissect_cms_KeyAgreeRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_KeyAgreeRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, KeyAgreeRecipientInfo_sequence, hf_index, ett_cms_KeyAgreeRecipientInfo); return offset; } -static int dissect_kari_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KeyAgreeRecipientInfo(TRUE, tvb, offset, pinfo, tree, hf_cms_kari); +static int dissect_kari_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KeyAgreeRecipientInfo(TRUE, tvb, offset, actx, tree, hf_cms_kari); } static int -dissect_cms_OCTET_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_OCTET_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_keyIdentifier(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OCTET_STRING(FALSE, tvb, offset, pinfo, tree, hf_cms_keyIdentifier); +static int dissect_keyIdentifier(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OCTET_STRING(FALSE, tvb, offset, actx, tree, hf_cms_keyIdentifier); } -static int dissect_iv(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_OCTET_STRING(FALSE, tvb, offset, pinfo, tree, hf_cms_iv); +static int dissect_iv(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_OCTET_STRING(FALSE, tvb, offset, actx, tree, hf_cms_iv); } @@ -1235,14 +1236,14 @@ static const ber_sequence_t KEKIdentifier_sequence[] = { }; static int -dissect_cms_KEKIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_KEKIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, KEKIdentifier_sequence, hf_index, ett_cms_KEKIdentifier); return offset; } -static int dissect_kekid(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KEKIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_kekid); +static int dissect_kekid(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KEKIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_kekid); } @@ -1255,14 +1256,14 @@ static const ber_sequence_t KEKRecipientInfo_sequence[] = { }; static int -dissect_cms_KEKRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_KEKRecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, KEKRecipientInfo_sequence, hf_index, ett_cms_KEKRecipientInfo); return offset; } -static int dissect_kekri_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_KEKRecipientInfo(TRUE, tvb, offset, pinfo, tree, hf_cms_kekri); +static int dissect_kekri_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_KEKRecipientInfo(TRUE, tvb, offset, actx, tree, hf_cms_kekri); } @@ -1281,15 +1282,15 @@ static const ber_choice_t RecipientInfo_choice[] = { }; static int -dissect_cms_RecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_RecipientInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, RecipientInfo_choice, hf_index, ett_cms_RecipientInfo, NULL); return offset; } -static int dissect_RecipientInfos_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_RecipientInfos_item); +static int dissect_RecipientInfos_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientInfo(FALSE, tvb, offset, actx, tree, hf_cms_RecipientInfos_item); } @@ -1298,39 +1299,39 @@ static const ber_sequence_t RecipientInfos_set_of[1] = { }; static int -dissect_cms_RecipientInfos(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_RecipientInfos(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, RecipientInfos_set_of, hf_index, ett_cms_RecipientInfos); return offset; } -static int dissect_recipientInfos(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RecipientInfos(FALSE, tvb, offset, pinfo, tree, hf_cms_recipientInfos); +static int dissect_recipientInfos(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RecipientInfos(FALSE, tvb, offset, actx, tree, hf_cms_recipientInfos); } static int -dissect_cms_ContentEncryptionAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_ContentEncryptionAlgorithmIdentifier(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_contentEncryptionAlgorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_ContentEncryptionAlgorithmIdentifier(FALSE, tvb, offset, pinfo, tree, hf_cms_contentEncryptionAlgorithm); +static int dissect_contentEncryptionAlgorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_ContentEncryptionAlgorithmIdentifier(FALSE, tvb, offset, actx, tree, hf_cms_contentEncryptionAlgorithm); } static int -dissect_cms_EncryptedContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_EncryptedContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_encryptedContent_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_EncryptedContent(TRUE, tvb, offset, pinfo, tree, hf_cms_encryptedContent); +static int dissect_encryptedContent_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_EncryptedContent(TRUE, tvb, offset, actx, tree, hf_cms_encryptedContent); } @@ -1342,14 +1343,14 @@ static const ber_sequence_t EncryptedContentInfo_sequence[] = { }; static int -dissect_cms_EncryptedContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_EncryptedContentInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, EncryptedContentInfo_sequence, hf_index, ett_cms_EncryptedContentInfo); return offset; } -static int dissect_encryptedContentInfo(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_EncryptedContentInfo(FALSE, tvb, offset, pinfo, tree, hf_cms_encryptedContentInfo); +static int dissect_encryptedContentInfo(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_EncryptedContentInfo(FALSE, tvb, offset, actx, tree, hf_cms_encryptedContentInfo); } @@ -1358,14 +1359,14 @@ static const ber_sequence_t UnprotectedAttributes_set_of[1] = { }; static int -dissect_cms_UnprotectedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_UnprotectedAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, UnprotectedAttributes_set_of, hf_index, ett_cms_UnprotectedAttributes); return offset; } -static int dissect_unprotectedAttrs_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UnprotectedAttributes(TRUE, tvb, offset, pinfo, tree, hf_cms_unprotectedAttrs); +static int dissect_unprotectedAttrs_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UnprotectedAttributes(TRUE, tvb, offset, actx, tree, hf_cms_unprotectedAttrs); } @@ -1379,8 +1380,8 @@ static const ber_sequence_t EnvelopedData_sequence[] = { }; int -dissect_cms_EnvelopedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_EnvelopedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, EnvelopedData_sequence, hf_index, ett_cms_EnvelopedData); return offset; @@ -1389,14 +1390,14 @@ dissect_cms_EnvelopedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offs int -dissect_cms_Digest(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_Digest(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_digest(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_Digest(FALSE, tvb, offset, pinfo, tree, hf_cms_digest); +static int dissect_digest(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_Digest(FALSE, tvb, offset, actx, tree, hf_cms_digest); } @@ -1409,8 +1410,8 @@ static const ber_sequence_t DigestedData_sequence[] = { }; static int -dissect_cms_DigestedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_DigestedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, DigestedData_sequence, hf_index, ett_cms_DigestedData); return offset; @@ -1425,8 +1426,8 @@ static const ber_sequence_t EncryptedData_sequence[] = { }; static int -dissect_cms_EncryptedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_EncryptedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, EncryptedData_sequence, hf_index, ett_cms_EncryptedData); return offset; @@ -1435,13 +1436,13 @@ dissect_cms_EncryptedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offs static int -dissect_cms_MessageAuthenticationCodeAlgorithm(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_MessageAuthenticationCodeAlgorithm(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_macAlgorithm(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_MessageAuthenticationCodeAlgorithm(FALSE, tvb, offset, pinfo, tree, hf_cms_macAlgorithm); +static int dissect_macAlgorithm(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_MessageAuthenticationCodeAlgorithm(FALSE, tvb, offset, actx, tree, hf_cms_macAlgorithm); } @@ -1450,27 +1451,27 @@ static const ber_sequence_t AuthAttributes_set_of[1] = { }; static int -dissect_cms_AuthAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_set_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_AuthAttributes(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_set_of(implicit_tag, actx, tree, tvb, offset, AuthAttributes_set_of, hf_index, ett_cms_AuthAttributes); return offset; } -static int dissect_authenticatedAttributes_impl(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_AuthAttributes(TRUE, tvb, offset, pinfo, tree, hf_cms_authenticatedAttributes); +static int dissect_authenticatedAttributes_impl(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_AuthAttributes(TRUE, tvb, offset, actx, tree, hf_cms_authenticatedAttributes); } static int -dissect_cms_MessageAuthenticationCode(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_MessageAuthenticationCode(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_mac(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_MessageAuthenticationCode(FALSE, tvb, offset, pinfo, tree, hf_cms_mac); +static int dissect_mac(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_MessageAuthenticationCode(FALSE, tvb, offset, actx, tree, hf_cms_mac); } @@ -1488,8 +1489,8 @@ static const ber_sequence_t AuthenticatedData_sequence[] = { }; static int -dissect_cms_AuthenticatedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_AuthenticatedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, AuthenticatedData_sequence, hf_index, ett_cms_AuthenticatedData); return offset; @@ -1498,12 +1499,12 @@ dissect_cms_AuthenticatedData(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int static int -dissect_cms_MessageDigest(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_MessageDigest(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 129 "cms.cnf" proto_item *pi; int old_offset = offset; - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); @@ -1524,15 +1525,15 @@ dissect_cms_MessageDigest(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offs static int -dissect_cms_UTCTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_UTCTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { offset = dissect_ber_restricted_string(implicit_tag, BER_UNI_TAG_UTCTime, - pinfo, tree, tvb, offset, hf_index, + actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_utcTime(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_UTCTime(FALSE, tvb, offset, pinfo, tree, hf_cms_utcTime); +static int dissect_utcTime(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_UTCTime(FALSE, tvb, offset, actx, tree, hf_cms_utcTime); } @@ -1549,8 +1550,8 @@ static const ber_choice_t Time_choice[] = { }; static int -dissect_cms_Time(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_Time(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, Time_choice, hf_index, ett_cms_Time, NULL); @@ -1560,8 +1561,8 @@ dissect_cms_Time(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, p static int -dissect_cms_SigningTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_cms_Time(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_SigningTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_cms_Time(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } @@ -1569,8 +1570,8 @@ dissect_cms_SigningTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset int -dissect_cms_Countersignature(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_cms_SignerInfo(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_Countersignature(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_cms_SignerInfo(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } @@ -1578,8 +1579,8 @@ dissect_cms_Countersignature(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o static int -dissect_cms_KeyWrapAlgorithm(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_KeyWrapAlgorithm(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_x509af_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } @@ -1587,11 +1588,11 @@ dissect_cms_KeyWrapAlgorithm(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o static int -dissect_cms_RC2ParameterVersion(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_RC2ParameterVersion(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 166 "cms.cnf" guint32 length = 0; - offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index, + offset = dissect_ber_integer(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, &length); @@ -1606,20 +1607,20 @@ dissect_cms_RC2ParameterVersion(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, in static int -dissect_cms_RC2WrapParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_cms_RC2ParameterVersion(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_RC2WrapParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_cms_RC2ParameterVersion(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } -static int dissect_rc2WrapParameter(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RC2WrapParameter(FALSE, tvb, offset, pinfo, tree, hf_cms_rc2WrapParameter); +static int dissect_rc2WrapParameter(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RC2WrapParameter(FALSE, tvb, offset, actx, tree, hf_cms_rc2WrapParameter); } static int -dissect_cms_IV(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_IV(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_octet_string(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; @@ -1628,8 +1629,8 @@ dissect_cms_IV(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, pac static int -dissect_cms_CBCParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_cms_IV(implicit_tag, tvb, offset, pinfo, tree, hf_index); +dissect_cms_CBCParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_cms_IV(implicit_tag, tvb, offset, actx, tree, hf_index); return offset; } @@ -1637,14 +1638,14 @@ dissect_cms_CBCParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offse static int -dissect_cms_INTEGER(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index, +dissect_cms_INTEGER(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_integer(implicit_tag, actx->pinfo, tree, tvb, offset, hf_index, NULL); return offset; } -static int dissect_rc2ParameterVersion(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_INTEGER(FALSE, tvb, offset, pinfo, tree, hf_cms_rc2ParameterVersion); +static int dissect_rc2ParameterVersion(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_INTEGER(FALSE, tvb, offset, actx, tree, hf_cms_rc2ParameterVersion); } @@ -1655,24 +1656,24 @@ static const ber_sequence_t RC2CBCParameter_sequence[] = { }; static int -dissect_cms_RC2CBCParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_RC2CBCParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, RC2CBCParameter_sequence, hf_index, ett_cms_RC2CBCParameter); return offset; } -static int dissect_rc2CBCParameter(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_RC2CBCParameter(FALSE, tvb, offset, pinfo, tree, hf_cms_rc2CBCParameter); +static int dissect_rc2CBCParameter(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_RC2CBCParameter(FALSE, tvb, offset, actx, tree, hf_cms_rc2CBCParameter); } static int -dissect_cms_T_capability(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_capability(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 147 "cms.cnf" const char *name = NULL; - offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_cms_attrType, &object_identifier_id); + offset = dissect_ber_object_identifier_str(implicit_tag, actx->pinfo, tree, tvb, offset, hf_cms_attrType, &object_identifier_id); if(object_identifier_id) { @@ -1685,25 +1686,25 @@ dissect_cms_T_capability(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offse return offset; } -static int dissect_capability(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_capability(FALSE, tvb, offset, pinfo, tree, hf_cms_capability); +static int dissect_capability(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_capability(FALSE, tvb, offset, actx, tree, hf_cms_capability); } static int -dissect_cms_T_parameters(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { +dissect_cms_T_parameters(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { #line 158 "cms.cnf" - offset=call_ber_oid_callback(object_identifier_id, tvb, offset, pinfo, tree); + offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree); return offset; } -static int dissect_parameters(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_T_parameters(FALSE, tvb, offset, pinfo, tree, hf_cms_parameters); +static int dissect_parameters(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_T_parameters(FALSE, tvb, offset, actx, tree, hf_cms_parameters); } @@ -1714,14 +1715,14 @@ static const ber_sequence_t SMIMECapability_sequence[] = { }; static int -dissect_cms_SMIMECapability(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SMIMECapability(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset, SMIMECapability_sequence, hf_index, ett_cms_SMIMECapability); return offset; } -static int dissect_SMIMECapabilities_item(packet_info *pinfo _U_, proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { - return dissect_cms_SMIMECapability(FALSE, tvb, offset, pinfo, tree, hf_cms_SMIMECapabilities_item); +static int dissect_SMIMECapabilities_item(proto_tree *tree _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_) { + return dissect_cms_SMIMECapability(FALSE, tvb, offset, actx, tree, hf_cms_SMIMECapabilities_item); } @@ -1730,8 +1731,8 @@ static const ber_sequence_t SMIMECapabilities_sequence_of[1] = { }; static int -dissect_cms_SMIMECapabilities(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_sequence_of(implicit_tag, pinfo, tree, tvb, offset, +dissect_cms_SMIMECapabilities(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset, SMIMECapabilities_sequence_of, hf_index, ett_cms_SMIMECapabilities); return offset; @@ -1753,8 +1754,8 @@ static const ber_choice_t SMIMEEncryptionKeyPreference_choice[] = { }; static int -dissect_cms_SMIMEEncryptionKeyPreference(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_SMIMEEncryptionKeyPreference(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, SMIMEEncryptionKeyPreference_choice, hf_index, ett_cms_SMIMEEncryptionKeyPreference, NULL); @@ -1775,8 +1776,8 @@ static const ber_choice_t RC2CBCParameters_choice[] = { }; static int -dissect_cms_RC2CBCParameters(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int hf_index _U_) { - offset = dissect_ber_choice(pinfo, tree, tvb, offset, +dissect_cms_RC2CBCParameters(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { + offset = dissect_ber_choice(actx, tree, tvb, offset, RC2CBCParameters_choice, hf_index, ett_cms_RC2CBCParameters, NULL); @@ -1786,54 +1787,84 @@ dissect_cms_RC2CBCParameters(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o /*--- PDUs ---*/ static void dissect_ContentInfo_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_ContentInfo(FALSE, tvb, 0, pinfo, tree, hf_cms_ContentInfo_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_ContentInfo(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_ContentInfo_PDU); } static void dissect_ContentType_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_ContentType(FALSE, tvb, 0, pinfo, tree, hf_cms_ContentType_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_ContentType(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_ContentType_PDU); } static void dissect_SignedData_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_SignedData(FALSE, tvb, 0, pinfo, tree, hf_cms_SignedData_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_SignedData(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_SignedData_PDU); } static void dissect_EnvelopedData_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_EnvelopedData(FALSE, tvb, 0, pinfo, tree, hf_cms_EnvelopedData_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_EnvelopedData(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_EnvelopedData_PDU); } static void dissect_DigestedData_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_DigestedData(FALSE, tvb, 0, pinfo, tree, hf_cms_DigestedData_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_DigestedData(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_DigestedData_PDU); } static void dissect_EncryptedData_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_EncryptedData(FALSE, tvb, 0, pinfo, tree, hf_cms_EncryptedData_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_EncryptedData(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_EncryptedData_PDU); } static void dissect_AuthenticatedData_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_AuthenticatedData(FALSE, tvb, 0, pinfo, tree, hf_cms_AuthenticatedData_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_AuthenticatedData(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_AuthenticatedData_PDU); } static void dissect_IssuerAndSerialNumber_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_IssuerAndSerialNumber(FALSE, tvb, 0, pinfo, tree, hf_cms_IssuerAndSerialNumber_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_IssuerAndSerialNumber(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_IssuerAndSerialNumber_PDU); } static void dissect_MessageDigest_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_MessageDigest(FALSE, tvb, 0, pinfo, tree, hf_cms_MessageDigest_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_MessageDigest(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_MessageDigest_PDU); } static void dissect_SigningTime_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_SigningTime(FALSE, tvb, 0, pinfo, tree, hf_cms_SigningTime_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_SigningTime(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_SigningTime_PDU); } static void dissect_Countersignature_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_Countersignature(FALSE, tvb, 0, pinfo, tree, hf_cms_Countersignature_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_Countersignature(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_Countersignature_PDU); } static void dissect_RC2WrapParameter_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_RC2WrapParameter(FALSE, tvb, 0, pinfo, tree, hf_cms_RC2WrapParameter_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_RC2WrapParameter(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_RC2WrapParameter_PDU); } static void dissect_SMIMECapabilities_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_SMIMECapabilities(FALSE, tvb, 0, pinfo, tree, hf_cms_SMIMECapabilities_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_SMIMECapabilities(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_SMIMECapabilities_PDU); } static void dissect_SMIMEEncryptionKeyPreference_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_SMIMEEncryptionKeyPreference(FALSE, tvb, 0, pinfo, tree, hf_cms_SMIMEEncryptionKeyPreference_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_SMIMEEncryptionKeyPreference(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_SMIMEEncryptionKeyPreference_PDU); } static void dissect_RC2CBCParameters_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) { - dissect_cms_RC2CBCParameters(FALSE, tvb, 0, pinfo, tree, hf_cms_RC2CBCParameters_PDU); + asn1_ctx_t asn1_ctx; + asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); + dissect_cms_RC2CBCParameters(FALSE, tvb, 0, &asn1_ctx, tree, hf_cms_RC2CBCParameters_PDU); } /*--- End of included file: packet-cms-fn.c ---*/ -#line 135 "packet-cms-template.c" +#line 136 "packet-cms-template.c" /*--- proto_register_cms ----------------------------------------------*/ void proto_register_cms(void) { @@ -2245,7 +2276,7 @@ void proto_register_cms(void) { "cms.RC2CBCParameter", HFILL }}, /*--- End of included file: packet-cms-hfarr.c ---*/ -#line 146 "packet-cms-template.c" +#line 147 "packet-cms-template.c" }; /* List of subtrees */ @@ -2301,7 +2332,7 @@ void proto_register_cms(void) { &ett_cms_RC2CBCParameters, /*--- End of included file: packet-cms-ettarr.c ---*/ -#line 151 "packet-cms-template.c" +#line 152 "packet-cms-template.c" }; /* Register protocol */ @@ -2345,7 +2376,7 @@ void proto_reg_handoff_cms(void) { /*--- End of included file: packet-cms-dis-tab.c ---*/ -#line 172 "packet-cms-template.c" +#line 173 "packet-cms-template.c" add_oid_str_name("1.2.840.113549.1.7.1", "id-data"); add_oid_str_name("1.2.840.113549.3.7", "id-alg-des-ede3-cbc"); |