diff --git a/asn1/x509af/x509af.cnf b/asn1/x509af/x509af.cnf index 7d1f44a244..8453660909 100644 --- a/asn1/x509af/x509af.cnf +++ b/asn1/x509af/x509af.cnf @@ -110,8 +110,10 @@ CertificateList/signedCertificateList/revokedCertificates/_item/userCertificate #.FN_BODY SubjectName + const char* str; %(DEFAULT_BODY)s - proto_item_append_text(proto_item_get_parent(tree), " (%%s)", x509if_get_last_dn()); + str = x509if_get_last_dn(); + proto_item_append_text(proto_item_get_parent(tree), " (%%s)", str?str:""); #.END diff --git a/epan/dissectors/packet-x509af.c b/epan/dissectors/packet-x509af.c index 022c8f97a9..56a6d55a19 100644 --- a/epan/dissectors/packet-x509af.c +++ b/epan/dissectors/packet-x509af.c @@ -427,12 +427,14 @@ static int dissect_x509af_SubjectName(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) { #line 112 "x509af.cnf" + const char* str; offset = dissect_ber_choice(pinfo, tree, tvb, offset, SubjectName_choice, hf_index, ett_x509af_SubjectName, NULL); - proto_item_append_text(proto_item_get_parent(tree), " (%s)", x509if_get_last_dn()); + str = x509if_get_last_dn(); + proto_item_append_text(proto_item_get_parent(tree), " (%s)", str?str:""); @@ -1419,7 +1421,7 @@ void proto_register_x509af(void) { "AttributeCertificateAssertion/attType", HFILL }}, { &hf_x509af_attType_item, { "Item", "x509af.attType_item", - FT_STRING, BASE_NONE, NULL, 0, + FT_OID, BASE_NONE, NULL, 0, "AttributeCertificateAssertion/attType/_item", HFILL }}, { &hf_x509af_p, { "p", "x509af.p",