aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-x509if.c
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2012-11-08 08:42:45 +0000
committerStig Bjørlykke <stig@bjorlykke.org>2012-11-08 08:42:45 +0000
commitf4ade83844b7cd29a8f0d3cc0208b2b2c7005209 (patch)
treefec7053a43d863a2ef337edadfd54a81afd85396 /epan/dissectors/packet-x509if.c
parent77db504364e9e2a467e23237a99f997ec8cdbd7d (diff)
Only append oid name to parent item once when having RDN as a attribute.
svn path=/trunk/; revision=45965
Diffstat (limited to 'epan/dissectors/packet-x509if.c')
-rw-r--r--epan/dissectors/packet-x509if.c40
1 files changed, 19 insertions, 21 deletions
diff --git a/epan/dissectors/packet-x509if.c b/epan/dissectors/packet-x509if.c
index 5cfebe1721..27ec08d3f4 100644
--- a/epan/dissectors/packet-x509if.c
+++ b/epan/dissectors/packet-x509if.c
@@ -363,7 +363,7 @@ dissect_x509if_T_type(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _
static int
dissect_x509if_T_values_item(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 315 "../../asn1/x509if/x509if.cnf"
+#line 313 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -388,7 +388,7 @@ dissect_x509if_T_values(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset
static int
dissect_x509if_T_value(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 285 "../../asn1/x509if/x509if.cnf"
+#line 283 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback("unknown", tvb, offset, actx->pinfo, tree);
@@ -409,7 +409,7 @@ dissect_x509if_T_contextType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o
static int
dissect_x509if_T_contextValues_item(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 297 "../../asn1/x509if/x509if.cnf"
+#line 295 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -506,7 +506,7 @@ static const ber_sequence_t Attribute_sequence[] = {
int
dissect_x509if_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_) {
-#line 418 "../../asn1/x509if/x509if.cnf"
+#line 416 "../../asn1/x509if/x509if.cnf"
doing_attr = TRUE;
register_frame_end_routine (actx->pinfo, x509if_frame_end);
@@ -531,7 +531,7 @@ dissect_x509if_AttributeType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o
int
dissect_x509if_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 303 "../../asn1/x509if/x509if.cnf"
+#line 301 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -552,7 +552,7 @@ dissect_x509if_T_type_01(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offse
static int
dissect_x509if_T_assertion(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 309 "../../asn1/x509if/x509if.cnf"
+#line 307 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -663,7 +663,7 @@ static const ber_sequence_t AttributeValueAssertion_sequence[] = {
int
dissect_x509if_AttributeValueAssertion(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 408 "../../asn1/x509if/x509if.cnf"
+#line 406 "../../asn1/x509if/x509if.cnf"
ava_hf_index = hf_index;
last_ava = ep_alloc(MAX_AVA_STR_LEN); *last_ava = '\0';
@@ -739,9 +739,7 @@ dissect_x509if_T_type_02(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offse
/* append it to the tree */
proto_item_append_text(tree, " (%s=", name);
- }
-
- if(doing_attr) {
+ } else if(doing_attr) {
/* append it to the parent item */
proto_item_append_text(tree, " (%s)", name);
}
@@ -767,7 +765,7 @@ dissect_x509if_T_type_02(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offse
static int
dissect_x509if_T_atadv_value(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 226 "../../asn1/x509if/x509if.cnf"
+#line 224 "../../asn1/x509if/x509if.cnf"
int old_offset = offset;
tvbuff_t *out_tvb;
char *value = NULL;
@@ -823,7 +821,7 @@ dissect_x509if_T_atadv_value(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int o
static int
dissect_x509if_T_distingAttrValue(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 330 "../../asn1/x509if/x509if.cnf"
+#line 328 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -880,7 +878,7 @@ dissect_x509if_AttributeTypeAndDistinguishedValue(gboolean implicit_tag _U_, tvb
static int
dissect_x509if_RelativeDistinguishedName_item(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 360 "../../asn1/x509if/x509if.cnf"
+#line 358 "../../asn1/x509if/x509if.cnf"
if(!rdn_one_value) {
top_of_rdn = tree;
@@ -908,7 +906,7 @@ static const ber_sequence_t RelativeDistinguishedName_set_of[1] = {
int
dissect_x509if_RelativeDistinguishedName(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 333 "../../asn1/x509if/x509if.cnf"
+#line 331 "../../asn1/x509if/x509if.cnf"
char *temp_dn;
rdn_one_value = FALSE;
@@ -946,7 +944,7 @@ dissect_x509if_RelativeDistinguishedName(gboolean implicit_tag _U_, tvbuff_t *tv
static int
dissect_x509if_RDNSequence_item(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 397 "../../asn1/x509if/x509if.cnf"
+#line 395 "../../asn1/x509if/x509if.cnf"
if(!dn_one_rdn) {
/* this is the first element - record the top */
@@ -970,7 +968,7 @@ static const ber_sequence_t RDNSequence_sequence_of[1] = {
int
dissect_x509if_RDNSequence(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 375 "../../asn1/x509if/x509if.cnf"
+#line 373 "../../asn1/x509if/x509if.cnf"
const char *fmt;
dn_one_rdn = FALSE; /* reset */
@@ -1382,7 +1380,7 @@ dissect_x509if_T_attributeType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int
static int
dissect_x509if_T_ra_selectedValues_item(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 276 "../../asn1/x509if/x509if.cnf"
+#line 274 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -1416,7 +1414,7 @@ dissect_x509if_T_entryType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int off
static int
dissect_x509if_T_ra_values_item(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 282 "../../asn1/x509if/x509if.cnf"
+#line 280 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -1478,7 +1476,7 @@ dissect_x509if_T_contextType_01(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, in
static int
dissect_x509if_T_contextValue_item(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 321 "../../asn1/x509if/x509if.cnf"
+#line 319 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -1579,7 +1577,7 @@ dissect_x509if_T_restrictionType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, i
static int
dissect_x509if_T_restrictionValue(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 327 "../../asn1/x509if/x509if.cnf"
+#line 325 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
@@ -1700,7 +1698,7 @@ dissect_x509if_T_attributeType_01(gboolean implicit_tag _U_, tvbuff_t *tvb _U_,
static int
dissect_x509if_T_selectedValues_item(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 291 "../../asn1/x509if/x509if.cnf"
+#line 289 "../../asn1/x509if/x509if.cnf"
offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);