diff options
author | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2004-10-30 02:18:44 +0000 |
---|---|---|
committer | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2004-10-30 02:18:44 +0000 |
commit | 805f948c298ce5b3613328b5c20cd56b78e8fe95 (patch) | |
tree | 6677d3e5499cf6e7402ed1454a8dcb34165010ff /asn1/x509af/packet-x509af-template.c | |
parent | ee310edcda1ecbb581b87a41dc2819d505691bbd (diff) |
implement AlgorithmIdentifier using the conformance file and remove it from the template
svn path=/trunk/; revision=12437
Diffstat (limited to 'asn1/x509af/packet-x509af-template.c')
-rw-r--r-- | asn1/x509af/packet-x509af-template.c | 34 |
1 files changed, 2 insertions, 32 deletions
diff --git a/asn1/x509af/packet-x509af-template.c b/asn1/x509af/packet-x509af-template.c index 4a2a9f1552..b2d4eb9a77 100644 --- a/asn1/x509af/packet-x509af-template.c +++ b/asn1/x509af/packet-x509af-template.c @@ -53,6 +53,8 @@ static int hf_x509af_critical = -1; /* BOOLEAN */ /* Initialize the subtree pointers */ #include "packet-x509af-ett.c" +static char algorithm_id[64]; /*64 chars should be long enough? */ + static char extension_id[64]; /*64 chars should be long enough? */ static int @@ -96,38 +98,6 @@ dissect_x509af_Extension(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, p return offset; } -static char algorithm_id[64]; /*64 chars should be long enough? */ -static int -dissect_hf_x509af_algorithm_id(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) -{ - offset = dissect_ber_object_identifier(FALSE, pinfo, tree, tvb, offset, - hf_x509af_algorithm_id, algorithm_id); - return offset; -} - -static int -dissect_hf_x509af_algorithm_type(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) -{ - offset=call_ber_oid_callback(algorithm_id, tvb, offset, pinfo, tree); - - return offset; -} - -/* Algorithm Identifier can not yet be handled by the compiler */ -static const ber_sequence AlgorithmIdentifier_sequence[] = { - { BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_hf_x509af_algorithm_id }, - { BER_CLASS_ANY, 0, 0, dissect_hf_x509af_algorithm_type }, - { 0, 0, 0, NULL } -}; - -int -dissect_x509af_AlgorithmIdentifier(gboolean implicit_tag, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) { - offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset, - AlgorithmIdentifier_sequence, hf_index, ett_x509af_AlgorithmIdentifier); - - return offset; -} - #include "packet-x509af-fn.c" |