aboutsummaryrefslogtreecommitdiffstats
path: root/asn1/x509af
diff options
context:
space:
mode:
authoretxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7>2005-11-16 07:13:12 +0000
committeretxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7>2005-11-16 07:13:12 +0000
commit3cf9e6ac03bb6b962f17a02ee566b81d0404e4f4 (patch)
tree0c7664cef1a075c4ecb3ad5ddc8d364055957829 /asn1/x509af
parent8a88ef70268ceb7c186b15406f4d786f866ed481 (diff)
From Graeme Lunt:
Here are a number of small patches for asn1 based dissectors: acse: release request/response column information (many X.400/X.500 unbinds are empty) "standardised" PNAME to "ISO 8650-1 OSI Association Control Service" fix for crash when using EXTERNAL dissector rtse: column information when attempting a resume x509if: generation of LDAP-style DNs from RDNSequences new function x509if_get_last_dn() to get the last DN generated. x509af: DSS parameters certificate extension naming subject naming of certificate x509sat: Guide syntax (as SET now supported) PDU exports. cms: verification of message digest attribute (SHA-1 and MD5) ess: enumerated/restrictive/permissive/informative security categories x411: generation of string encoding of X.400 addresses, trace information and message identifiers. s4406: separate types for primary and copy precedence to allow better filtering (e.g. primary precedence = flash) priority-level-qualifier git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@16508 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'asn1/x509af')
-rw-r--r--asn1/x509af/AuthenticationFramework.asn23
-rw-r--r--asn1/x509af/Makefile.nmake4
-rw-r--r--asn1/x509af/packet-x509af-template.c7
-rw-r--r--asn1/x509af/packet-x509af-template.h2
-rw-r--r--asn1/x509af/x509af.cnf29
5 files changed, 55 insertions, 10 deletions
diff --git a/asn1/x509af/AuthenticationFramework.asn b/asn1/x509af/AuthenticationFramework.asn
index c51f7f1223..050015e4c6 100644
--- a/asn1/x509af/AuthenticationFramework.asn
+++ b/asn1/x509af/AuthenticationFramework.asn
@@ -14,7 +14,7 @@ IMPORTS
basicAccessControl, certificateExtensions
FROM UsefulDefinitions {joint-iso-itu-t ds(5) module(1)
usefulDefinitions(0) 3}
- Name, ATTRIBUTE, AttributeType, MATCHING-RULE, Attribute
+ Name, ATTRIBUTE, AttributeType, MATCHING-RULE, Attribute, RDNSequence
FROM InformationFramework informationFramework
ub-user-password
FROM UpperBounds upperBounds
@@ -32,9 +32,9 @@ Certificate ::= SEQUENCE {
version [0] Version DEFAULT v1,
serialNumber CertificateSerialNumber,
signature AlgorithmIdentifier,
- issuer Name,
+ issuer Name,
validity Validity,
- subject Name,
+ subject SubjectName,
subjectPublicKeyInfo SubjectPublicKeyInfo,
issuerUniqueIdentifier [1] IMPLICIT UniqueIdentifier OPTIONAL,
-- if present, version must be v2 or v3
@@ -46,6 +46,11 @@ Certificate ::= SEQUENCE {
encrypted BIT STRING
}
+-- imported to allow labelling
+SubjectName ::= CHOICE {
+ rdnSequence RDNSequence
+}
+
Version ::= INTEGER {v1(0), v2(1), v3(2)}
CertificateSerialNumber ::= INTEGER
@@ -122,7 +127,7 @@ CertificateList ::= SEQUENCE {
version Version OPTIONAL,
-- if present, version must be v2
signature AlgorithmIdentifier,
- issuer Name,
+ issuer Name,
thisUpdate Time,
nextUpdate Time OPTIONAL,
revokedCertificates
@@ -192,7 +197,7 @@ AttCertValidityPeriod ::= SEQUENCE {
AttributeCertificateAssertion ::= SEQUENCE {
subject
[0] CHOICE {baseCertificateID [0] IssuerSerial,
- subjectName [1] Name} OPTIONAL,
+ subjectName [1] SubjectName} OPTIONAL,
issuer [1] Name OPTIONAL,
attCertValidity [2] GeneralizedTime OPTIONAL,
attType [3] SET OF AttributeType OPTIONAL
@@ -264,6 +269,14 @@ id-at-attributeCertificateRevocationList OBJECT IDENTIFIER ::= {id-at 59}
--id-mr-attributeCertificateMatch OBJECT IDENTIFIER ::= {id-mr 42}
+-- these are sneaked in from DSS - a separate dissector seems OTT
+
+DSS-Params ::= SEQUENCE {
+ p INTEGER,
+ q INTEGER,
+ g INTEGER
+}
+
END
-- Generated by Asnp, the ASN.1 pretty-printer of France Telecom R&D
diff --git a/asn1/x509af/Makefile.nmake b/asn1/x509af/Makefile.nmake
index b88a7c8596..1e14d4f63d 100644
--- a/asn1/x509af/Makefile.nmake
+++ b/asn1/x509af/Makefile.nmake
@@ -37,5 +37,5 @@ fix_eol: generate_dissector
del /f packet-$(PROTOCOL_NAME).c.tmp packet-$(PROTOCOL_NAME).h.tmp
copy_files: generate_dissector fix_eol
- xcopy packet-$(PROTOCOL_NAME).c ..\..\epan\dissectors /d
- xcopy packet-$(PROTOCOL_NAME).h ..\..\epan\dissectors /d
+ xcopy packet-$(PROTOCOL_NAME).c ..\..\epan\dissectors /d /y
+ xcopy packet-$(PROTOCOL_NAME).h ..\..\epan\dissectors /d /y
diff --git a/asn1/x509af/packet-x509af-template.c b/asn1/x509af/packet-x509af-template.c
index 393a052eea..c289bda7da 100644
--- a/asn1/x509af/packet-x509af-template.c
+++ b/asn1/x509af/packet-x509af-template.c
@@ -55,13 +55,14 @@ static gint ett_pkix_crl = -1;
#include "packet-x509af-ett.c"
static const char *algorithm_id;
-
-
static const char *extension_id;
-
#include "packet-x509af-fn.c"
+char *x509af_get_last_algorithm_id() {
+ return algorithm_id;
+}
+
static int
dissect_pkix_crl(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
diff --git a/asn1/x509af/packet-x509af-template.h b/asn1/x509af/packet-x509af-template.h
index aee498631c..bd1b0cf86c 100644
--- a/asn1/x509af/packet-x509af-template.h
+++ b/asn1/x509af/packet-x509af-template.h
@@ -28,5 +28,7 @@
#include "packet-x509af-exp.h"
+extern char* x509af_get_last_algorithm_id();
+
#endif /* PACKET_X509AF_H */
diff --git a/asn1/x509af/x509af.cnf b/asn1/x509af/x509af.cnf
index 4bde694356..182b1a6d48 100644
--- a/asn1/x509af/x509af.cnf
+++ b/asn1/x509af/x509af.cnf
@@ -47,6 +47,7 @@ CertificatePair B "2.5.4.40" "id-at-crossCertificatePair"
AttributeCertificate B "2.5.4.58" "id-at-attributeCertificate"
CertificateList B "2.5.4.59" "id-at-attributeCertificateRevocationList"
+DSS-Params B "1.2.840.10040.4.1" "id-dsa"
#.NO_EMIT
#.TYPE_RENAME
@@ -69,6 +70,16 @@ CertificateList/signedCertificateList/revokedCertificates/_item/userCertificate
#.FN_PARS AlgorithmIdentifier/algorithmId
FN_VARIANT = _str HF_INDEX = hf_x509af_algorithm_id VAL_PTR = &algorithm_id
+#.FN_BODY AlgorithmIdentifier/algorithmId
+ char *name;
+
+ %(DEFAULT_BODY)s
+
+ if(algorithm_id) {
+ name = get_ber_oid_name(algorithm_id);
+
+ proto_item_append_text(tree, " (%%s)", name ? name : algorithm_id);
+ }
#.FN_BODY AlgorithmIdentifier/parameters
offset=call_ber_oid_callback(algorithm_id, tvb, offset, pinfo, tree);
@@ -76,6 +87,17 @@ CertificateList/signedCertificateList/revokedCertificates/_item/userCertificate
#.FN_PARS Extension/extnId
FN_VARIANT = _str HF_INDEX = hf_x509af_extension_id VAL_PTR = &extension_id
+#.FN_BODY Extension/extnId
+ char *name;
+
+ %(DEFAULT_BODY)s
+
+ if(extension_id) {
+ name = get_ber_oid_name(extension_id);
+
+ proto_item_append_text(tree, " (%%s)", name ? name : extension_id);
+ }
+
#.FN_BODY Extension/extnValue
gint8 class;
gboolean pc, ind;
@@ -86,3 +108,10 @@ CertificateList/signedCertificateList/revokedCertificates/_item/userCertificate
offset = dissect_ber_length(pinfo, tree, tvb, offset, &len, &ind);
offset=call_ber_oid_callback(extension_id, tvb, offset, pinfo, tree);
+#.FN_BODY SubjectName
+
+ %(DEFAULT_BODY)s
+
+ proto_item_append_text(proto_item_get_parent(tree), " (%%s)", x509if_get_last_dn());
+
+#.END