aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/x509if/packet-x509if-template.c
diff options
context:
space:
mode:
authorRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2004-07-22 10:29:17 +0000
committerRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2004-07-22 10:29:17 +0000
commitf42a958398daccf62c08ee0836b68fda1c33998b (patch)
tree000f82bdf7c2a8234e8cf6c9699131d8262948ea /asn1/x509if/packet-x509if-template.c
parent283807bf4b413de7a06ff4751d8e7880934a833a (diff)
start dissecting AttributeTypeAnddistinguishedValue
(which must be implemented by hand inside themplate) svn path=/trunk/; revision=11469
Diffstat (limited to 'asn1/x509if/packet-x509if-template.c')
-rw-r--r--asn1/x509if/packet-x509if-template.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/asn1/x509if/packet-x509if-template.c b/asn1/x509if/packet-x509if-template.c
index 03921bba51..524e78750d 100644
--- a/asn1/x509if/packet-x509if-template.c
+++ b/asn1/x509if/packet-x509if-template.c
@@ -42,12 +42,14 @@
/* Initialize the protocol and registered fields */
int proto_x509if = -1;
+int hf_x509if_ATADV_attribute_id = -1;
#include "packet-x509if-hf.c"
/* Initialize the subtree pointers */
static gint ett_x509if_Attribute = -1;
#include "packet-x509if-ett.c"
+
static ber_sequence Attribute_sequence[] = {
/* { BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_hf_x509if_type },*/
/*XXX missing stuff here */
@@ -63,6 +65,30 @@ dissect_x509if_Attribute(gboolean implicit_tag, tvbuff_t *tvb, int offset, packe
}
+
+static char ATADV_attribute_id[64]; /*64 chars should be long enough? */
+static int
+dissect_hf_x509if_ATADV_attribute_id(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset)
+{
+ offset = dissect_ber_object_identifier(FALSE, pinfo, tree, tvb, offset,
+ hf_x509if_ATADV_attribute_id, ATADV_attribute_id);
+ return offset;
+}
+
+static ber_sequence AttributeTypeAndDistinguishedValue_sequence[] = {
+ { BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_hf_x509if_ATADV_attribute_id },
+ /*XXX missing stuff here */
+ { 0, 0, 0, NULL }
+};
+
+static int
+dissect_x509if_AttributeTypeAndDistinguishedValue(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,
+ AttributeTypeAndDistinguishedValue_sequence, hf_index, ett_x509if_AttributeTypeAndDistinguishedValue);
+
+ return offset;
+}
+
#include "packet-x509if-fn.c"
@@ -71,6 +97,10 @@ void proto_register_x509if(void) {
/* List of fields */
static hf_register_info hf[] = {
+ { &hf_x509if_ATADV_attribute_id,
+ { "Attribute Id", "x509if.attribute.id",
+ FT_STRING, BASE_NONE, NULL, 0,
+ "Attribute Id", HFILL }},
#include "packet-x509if-hfarr.c"
};