1 /* Do not modify this file. */
2 /* It is created automatically by the ASN.1 to Wireshark dissector compiler */
4 /* ../../tools/asn2wrs.py -b -p cmp -c ./cmp.cnf -s ./packet-cmp-template -D . CMP.asn */
6 /* Input file: packet-cmp-template.c */
8 #line 1 "packet-cmp-template.c"
11 * Routines for RFC2510 Certificate Management Protocol packet dissection
12 * Ronnie Sahlberg 2004
13 * Updated to RFC4210 CMPv2 and associated "Transport Protocols for CMP" draft
18 * Wireshark - Network traffic analyzer
19 * By Gerald Combs <gerald@wireshark.org>
20 * Copyright 1998 Gerald Combs
22 * This program is free software; you can redistribute it and/or
23 * modify it under the terms of the GNU General Public License
24 * as published by the Free Software Foundation; either version 2
25 * of the License, or (at your option) any later version.
27 * This program is distributed in the hope that it will be useful,
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 * GNU General Public License for more details.
32 * You should have received a copy of the GNU General Public License
33 * along with this program; if not, write to the Free Software
34 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
42 #include <epan/packet.h>
47 #include <epan/oids.h>
48 #include <epan/asn1.h>
49 #include "packet-ber.h"
50 #include "packet-cmp.h"
51 #include "packet-crmf.h"
52 #include "packet-pkix1explicit.h"
53 #include "packet-pkix1implicit.h"
54 #include "packet-tcp.h"
55 #include "packet-http.h"
56 #include <epan/prefs.h>
57 #include <epan/nstime.h>
59 #define PNAME "Certificate Management Protocol"
63 #define TCP_PORT_CMP 829
65 /* desegmentation of CMP over TCP */
66 static gboolean cmp_desegment = TRUE;
68 static guint cmp_alternate_tcp_port = 0;
69 static guint cmp_alternate_http_port = 0;
70 static guint cmp_alternate_tcp_style_http_port = 0;
72 /* Initialize the protocol and registered fields */
74 static int hf_cmp_type_oid = -1;
75 static int hf_cmp_tcptrans_len = -1;
76 static int hf_cmp_tcptrans_type = -1;
77 static int hf_cmp_tcptrans_poll_ref = -1;
78 static int hf_cmp_tcptrans_next_poll_ref = -1;
79 static int hf_cmp_tcptrans_ttcb = -1;
80 static int hf_cmp_tcptrans10_version = -1;
81 static int hf_cmp_tcptrans10_flags = -1;
83 /*--- Included file: packet-cmp-hf.c ---*/
84 #line 1 "packet-cmp-hf.c"
85 static int hf_cmp_PBMParameter_PDU = -1; /* PBMParameter */
86 static int hf_cmp_DHBMParameter_PDU = -1; /* DHBMParameter */
87 static int hf_cmp_CAProtEncCertValue_PDU = -1; /* CAProtEncCertValue */
88 static int hf_cmp_SignKeyPairTypesValue_PDU = -1; /* SignKeyPairTypesValue */
89 static int hf_cmp_EncKeyPairTypesValue_PDU = -1; /* EncKeyPairTypesValue */
90 static int hf_cmp_PreferredSymmAlgValue_PDU = -1; /* PreferredSymmAlgValue */
91 static int hf_cmp_CAKeyUpdateInfoValue_PDU = -1; /* CAKeyUpdateInfoValue */
92 static int hf_cmp_CurrentCRLValue_PDU = -1; /* CurrentCRLValue */
93 static int hf_cmp_UnsupportedOIDsValue_PDU = -1; /* UnsupportedOIDsValue */
94 static int hf_cmp_KeyPairParamReqValue_PDU = -1; /* KeyPairParamReqValue */
95 static int hf_cmp_KeyPairParamRepValue_PDU = -1; /* KeyPairParamRepValue */
96 static int hf_cmp_RevPassphraseValue_PDU = -1; /* RevPassphraseValue */
97 static int hf_cmp_ImplicitConfirmValue_PDU = -1; /* ImplicitConfirmValue */
98 static int hf_cmp_ConfirmWaitTimeValue_PDU = -1; /* ConfirmWaitTimeValue */
99 static int hf_cmp_OrigPKIMessageValue_PDU = -1; /* OrigPKIMessageValue */
100 static int hf_cmp_SuppLangTagsValue_PDU = -1; /* SuppLangTagsValue */
101 static int hf_cmp_x509v3PKCert = -1; /* Certificate */
102 static int hf_cmp_header = -1; /* PKIHeader */
103 static int hf_cmp_body = -1; /* PKIBody */
104 static int hf_cmp_protection = -1; /* PKIProtection */
105 static int hf_cmp_extraCerts = -1; /* SEQUENCE_SIZE_1_MAX_OF_CMPCertificate */
106 static int hf_cmp_extraCerts_item = -1; /* CMPCertificate */
107 static int hf_cmp_PKIMessages_item = -1; /* PKIMessage */
108 static int hf_cmp_pvno = -1; /* T_pvno */
109 static int hf_cmp_sender = -1; /* GeneralName */
110 static int hf_cmp_recipient = -1; /* GeneralName */
111 static int hf_cmp_messageTime = -1; /* GeneralizedTime */
112 static int hf_cmp_protectionAlg = -1; /* AlgorithmIdentifier */
113 static int hf_cmp_senderKID = -1; /* KeyIdentifier */
114 static int hf_cmp_recipKID = -1; /* KeyIdentifier */
115 static int hf_cmp_transactionID = -1; /* OCTET_STRING */
116 static int hf_cmp_senderNonce = -1; /* OCTET_STRING */
117 static int hf_cmp_recipNonce = -1; /* OCTET_STRING */
118 static int hf_cmp_freeText = -1; /* PKIFreeText */
119 static int hf_cmp_generalInfo = -1; /* SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue */
120 static int hf_cmp_generalInfo_item = -1; /* InfoTypeAndValue */
121 static int hf_cmp_PKIFreeText_item = -1; /* UTF8String */
122 static int hf_cmp_ir = -1; /* CertReqMessages */
123 static int hf_cmp_ip = -1; /* CertRepMessage */
124 static int hf_cmp_cr = -1; /* CertReqMessages */
125 static int hf_cmp_cp = -1; /* CertRepMessage */
126 static int hf_cmp_p10cr = -1; /* NULL */
127 static int hf_cmp_popdecc = -1; /* POPODecKeyChallContent */
128 static int hf_cmp_popdecr = -1; /* POPODecKeyRespContent */
129 static int hf_cmp_kur = -1; /* CertReqMessages */
130 static int hf_cmp_kup = -1; /* CertRepMessage */
131 static int hf_cmp_krr = -1; /* CertReqMessages */
132 static int hf_cmp_krp = -1; /* KeyRecRepContent */
133 static int hf_cmp_rr = -1; /* RevReqContent */
134 static int hf_cmp_rp = -1; /* RevRepContent */
135 static int hf_cmp_ccr = -1; /* CertReqMessages */
136 static int hf_cmp_ccp = -1; /* CertRepMessage */
137 static int hf_cmp_ckuann = -1; /* CAKeyUpdAnnContent */
138 static int hf_cmp_cann = -1; /* CertAnnContent */
139 static int hf_cmp_rann = -1; /* RevAnnContent */
140 static int hf_cmp_crlann = -1; /* CRLAnnContent */
141 static int hf_cmp_pkiconf = -1; /* PKIConfirmContent */
142 static int hf_cmp_nested = -1; /* NestedMessageContent */
143 static int hf_cmp_genm = -1; /* GenMsgContent */
144 static int hf_cmp_genp = -1; /* GenRepContent */
145 static int hf_cmp_error = -1; /* ErrorMsgContent */
146 static int hf_cmp_certConf = -1; /* CertConfirmContent */
147 static int hf_cmp_pollReq = -1; /* PollReqContent */
148 static int hf_cmp_pollRep = -1; /* PollRepContent */
149 static int hf_cmp_salt = -1; /* OCTET_STRING */
150 static int hf_cmp_owf = -1; /* AlgorithmIdentifier */
151 static int hf_cmp_iterationCount = -1; /* INTEGER */
152 static int hf_cmp_mac = -1; /* AlgorithmIdentifier */
153 static int hf_cmp_pkistatus = -1; /* PKIStatus */
154 static int hf_cmp_statusString = -1; /* PKIFreeText */
155 static int hf_cmp_failInfo = -1; /* PKIFailureInfo */
156 static int hf_cmp_hashAlg = -1; /* AlgorithmIdentifier */
157 static int hf_cmp_certId = -1; /* CertId */
158 static int hf_cmp_hashVal = -1; /* BIT_STRING */
159 static int hf_cmp_POPODecKeyChallContent_item = -1; /* Challenge */
160 static int hf_cmp_witness = -1; /* OCTET_STRING */
161 static int hf_cmp_challenge = -1; /* OCTET_STRING */
162 static int hf_cmp_POPODecKeyRespContent_item = -1; /* INTEGER */
163 static int hf_cmp_caPubs = -1; /* SEQUENCE_SIZE_1_MAX_OF_CMPCertificate */
164 static int hf_cmp_caPubs_item = -1; /* CMPCertificate */
165 static int hf_cmp_response = -1; /* SEQUENCE_OF_CertResponse */
166 static int hf_cmp_response_item = -1; /* CertResponse */
167 static int hf_cmp_certReqId = -1; /* INTEGER */
168 static int hf_cmp_pkistatusinf = -1; /* PKIStatusInfo */
169 static int hf_cmp_certifiedKeyPair = -1; /* CertifiedKeyPair */
170 static int hf_cmp_rspInfo = -1; /* OCTET_STRING */
171 static int hf_cmp_certOrEncCert = -1; /* CertOrEncCert */
172 static int hf_cmp_privateKey = -1; /* EncryptedValue */
173 static int hf_cmp_publicationInfo = -1; /* PKIPublicationInfo */
174 static int hf_cmp_certificate = -1; /* CMPCertificate */
175 static int hf_cmp_encryptedCert = -1; /* EncryptedValue */
176 static int hf_cmp_newSigCert = -1; /* CMPCertificate */
177 static int hf_cmp_caCerts = -1; /* SEQUENCE_SIZE_1_MAX_OF_CMPCertificate */
178 static int hf_cmp_caCerts_item = -1; /* CMPCertificate */
179 static int hf_cmp_keyPairHist = -1; /* SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair */
180 static int hf_cmp_keyPairHist_item = -1; /* CertifiedKeyPair */
181 static int hf_cmp_RevReqContent_item = -1; /* RevDetails */
182 static int hf_cmp_certDetails = -1; /* CertTemplate */
183 static int hf_cmp_crlEntryDetails = -1; /* Extensions */
184 static int hf_cmp_rvrpcnt_status = -1; /* SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo */
185 static int hf_cmp_rvrpcnt_status_item = -1; /* PKIStatusInfo */
186 static int hf_cmp_revCerts = -1; /* SEQUENCE_SIZE_1_MAX_OF_CertId */
187 static int hf_cmp_revCerts_item = -1; /* CertId */
188 static int hf_cmp_crls = -1; /* SEQUENCE_SIZE_1_MAX_OF_CertificateList */
189 static int hf_cmp_crls_item = -1; /* CertificateList */
190 static int hf_cmp_oldWithNew = -1; /* CMPCertificate */
191 static int hf_cmp_newWithOld = -1; /* CMPCertificate */
192 static int hf_cmp_newWithNew = -1; /* CMPCertificate */
193 static int hf_cmp_willBeRevokedAt = -1; /* GeneralizedTime */
194 static int hf_cmp_badSinceDate = -1; /* GeneralizedTime */
195 static int hf_cmp_crlDetails = -1; /* Extensions */
196 static int hf_cmp_CRLAnnContent_item = -1; /* CertificateList */
197 static int hf_cmp_CertConfirmContent_item = -1; /* CertStatus */
198 static int hf_cmp_certHash = -1; /* OCTET_STRING */
199 static int hf_cmp_statusInfo = -1; /* PKIStatusInfo */
200 static int hf_cmp_infoType = -1; /* T_infoType */
201 static int hf_cmp_infoValue = -1; /* T_infoValue */
202 static int hf_cmp_SignKeyPairTypesValue_item = -1; /* AlgorithmIdentifier */
203 static int hf_cmp_EncKeyPairTypesValue_item = -1; /* AlgorithmIdentifier */
204 static int hf_cmp_UnsupportedOIDsValue_item = -1; /* OBJECT_IDENTIFIER */
205 static int hf_cmp_SuppLangTagsValue_item = -1; /* UTF8String */
206 static int hf_cmp_GenMsgContent_item = -1; /* InfoTypeAndValue */
207 static int hf_cmp_GenRepContent_item = -1; /* InfoTypeAndValue */
208 static int hf_cmp_pKIStatusInfo = -1; /* PKIStatusInfo */
209 static int hf_cmp_errorCode = -1; /* INTEGER */
210 static int hf_cmp_errorDetails = -1; /* PKIFreeText */
211 static int hf_cmp_PollReqContent_item = -1; /* PollReqContent_item */
212 static int hf_cmp_PollRepContent_item = -1; /* PollRepContent_item */
213 static int hf_cmp_checkAfter = -1; /* INTEGER */
214 static int hf_cmp_reason = -1; /* PKIFreeText */
216 static int hf_cmp_PKIFailureInfo_badAlg = -1;
217 static int hf_cmp_PKIFailureInfo_badMessageCheck = -1;
218 static int hf_cmp_PKIFailureInfo_badRequest = -1;
219 static int hf_cmp_PKIFailureInfo_badTime = -1;
220 static int hf_cmp_PKIFailureInfo_badCertId = -1;
221 static int hf_cmp_PKIFailureInfo_badDataFormat = -1;
222 static int hf_cmp_PKIFailureInfo_wrongAuthority = -1;
223 static int hf_cmp_PKIFailureInfo_incorrectData = -1;
224 static int hf_cmp_PKIFailureInfo_missingTimeStamp = -1;
225 static int hf_cmp_PKIFailureInfo_badPOP = -1;
226 static int hf_cmp_PKIFailureInfo_certRevoked = -1;
227 static int hf_cmp_PKIFailureInfo_certConfirmed = -1;
228 static int hf_cmp_PKIFailureInfo_wrongIntegrity = -1;
229 static int hf_cmp_PKIFailureInfo_badRecipientNonce = -1;
230 static int hf_cmp_PKIFailureInfo_timeNotAvailable = -1;
231 static int hf_cmp_PKIFailureInfo_unacceptedPolicy = -1;
232 static int hf_cmp_PKIFailureInfo_unacceptedExtension = -1;
233 static int hf_cmp_PKIFailureInfo_addInfoNotAvailable = -1;
234 static int hf_cmp_PKIFailureInfo_badSenderNonce = -1;
235 static int hf_cmp_PKIFailureInfo_badCertTemplate = -1;
236 static int hf_cmp_PKIFailureInfo_signerNotTrusted = -1;
237 static int hf_cmp_PKIFailureInfo_transactionIdInUse = -1;
238 static int hf_cmp_PKIFailureInfo_unsupportedVersion = -1;
239 static int hf_cmp_PKIFailureInfo_notAuthorized = -1;
240 static int hf_cmp_PKIFailureInfo_systemUnavail = -1;
241 static int hf_cmp_PKIFailureInfo_systemFailure = -1;
242 static int hf_cmp_PKIFailureInfo_duplicateCertReq = -1;
244 /*--- End of included file: packet-cmp-hf.c ---*/
245 #line 75 "packet-cmp-template.c"
247 /* Initialize the subtree pointers */
248 static gint ett_cmp = -1;
250 /*--- Included file: packet-cmp-ett.c ---*/
251 #line 1 "packet-cmp-ett.c"
252 static gint ett_cmp_CMPCertificate = -1;
253 static gint ett_cmp_PKIMessage = -1;
254 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate = -1;
255 static gint ett_cmp_PKIMessages = -1;
256 static gint ett_cmp_PKIHeader = -1;
257 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue = -1;
258 static gint ett_cmp_PKIFreeText = -1;
259 static gint ett_cmp_PKIBody = -1;
260 static gint ett_cmp_ProtectedPart = -1;
261 static gint ett_cmp_PBMParameter = -1;
262 static gint ett_cmp_DHBMParameter = -1;
263 static gint ett_cmp_PKIFailureInfo = -1;
264 static gint ett_cmp_PKIStatusInfo = -1;
265 static gint ett_cmp_OOBCertHash = -1;
266 static gint ett_cmp_POPODecKeyChallContent = -1;
267 static gint ett_cmp_Challenge = -1;
268 static gint ett_cmp_POPODecKeyRespContent = -1;
269 static gint ett_cmp_CertRepMessage = -1;
270 static gint ett_cmp_SEQUENCE_OF_CertResponse = -1;
271 static gint ett_cmp_CertResponse = -1;
272 static gint ett_cmp_CertifiedKeyPair = -1;
273 static gint ett_cmp_CertOrEncCert = -1;
274 static gint ett_cmp_KeyRecRepContent = -1;
275 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair = -1;
276 static gint ett_cmp_RevReqContent = -1;
277 static gint ett_cmp_RevDetails = -1;
278 static gint ett_cmp_RevRepContent = -1;
279 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo = -1;
280 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertId = -1;
281 static gint ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertificateList = -1;
282 static gint ett_cmp_CAKeyUpdAnnContent = -1;
283 static gint ett_cmp_RevAnnContent = -1;
284 static gint ett_cmp_CRLAnnContent = -1;
285 static gint ett_cmp_CertConfirmContent = -1;
286 static gint ett_cmp_CertStatus = -1;
287 static gint ett_cmp_InfoTypeAndValue = -1;
288 static gint ett_cmp_SignKeyPairTypesValue = -1;
289 static gint ett_cmp_EncKeyPairTypesValue = -1;
290 static gint ett_cmp_UnsupportedOIDsValue = -1;
291 static gint ett_cmp_SuppLangTagsValue = -1;
292 static gint ett_cmp_GenMsgContent = -1;
293 static gint ett_cmp_GenRepContent = -1;
294 static gint ett_cmp_ErrorMsgContent = -1;
295 static gint ett_cmp_PollReqContent = -1;
296 static gint ett_cmp_PollReqContent_item = -1;
297 static gint ett_cmp_PollRepContent = -1;
298 static gint ett_cmp_PollRepContent_item = -1;
300 /*--- End of included file: packet-cmp-ett.c ---*/
301 #line 79 "packet-cmp-template.c"
303 static const char *object_identifier_id;
307 /*--- Included file: packet-cmp-fn.c ---*/
308 #line 1 "packet-cmp-fn.c"
309 /*--- Cyclic dependencies ---*/
311 /* PKIMessage -> PKIBody -> NestedMessageContent -> PKIMessages -> PKIMessage */
312 int dissect_cmp_PKIMessage(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_);
316 const value_string cmp_CMPCertificate_vals[] = {
317 { 0, "x509v3PKCert" },
321 static const ber_choice_t CMPCertificate_choice[] = {
322 { 0, &hf_cmp_x509v3PKCert , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_Certificate },
323 { 0, NULL, 0, 0, 0, NULL }
327 dissect_cmp_CMPCertificate(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
328 offset = dissect_ber_choice(actx, tree, tvb, offset,
329 CMPCertificate_choice, hf_index, ett_cmp_CMPCertificate,
336 static const value_string cmp_T_pvno_vals[] = {
344 dissect_cmp_T_pvno(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
345 offset = dissect_ber_integer(implicit_tag, actx, tree, tvb, offset, hf_index,
354 dissect_cmp_GeneralizedTime(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
355 offset = dissect_ber_GeneralizedTime(implicit_tag, actx, tree, tvb, offset, hf_index);
363 dissect_cmp_OCTET_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
364 offset = dissect_ber_octet_string(implicit_tag, actx, tree, tvb, offset, hf_index,
373 dissect_cmp_UTF8String(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
374 offset = dissect_ber_restricted_string(implicit_tag, BER_UNI_TAG_UTF8String,
375 actx, tree, tvb, offset, hf_index,
382 static const ber_sequence_t PKIFreeText_sequence_of[1] = {
383 { &hf_cmp_PKIFreeText_item, BER_CLASS_UNI, BER_UNI_TAG_UTF8String, BER_FLAGS_NOOWNTAG, dissect_cmp_UTF8String },
387 dissect_cmp_PKIFreeText(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
388 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
389 PKIFreeText_sequence_of, hf_index, ett_cmp_PKIFreeText);
397 dissect_cmp_T_infoType(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
398 offset = dissect_ber_object_identifier_str(implicit_tag, actx, tree, tvb, offset, hf_cmp_type_oid, &object_identifier_id);
406 dissect_cmp_T_infoValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
408 offset=call_ber_oid_callback(object_identifier_id, tvb, offset, actx->pinfo, tree);
416 static const ber_sequence_t InfoTypeAndValue_sequence[] = {
417 { &hf_cmp_infoType , BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_cmp_T_infoType },
418 { &hf_cmp_infoValue , BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_T_infoValue },
419 { NULL, 0, 0, 0, NULL }
423 dissect_cmp_InfoTypeAndValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
424 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
425 InfoTypeAndValue_sequence, hf_index, ett_cmp_InfoTypeAndValue);
431 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue_sequence_of[1] = {
432 { &hf_cmp_generalInfo_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_InfoTypeAndValue },
436 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
437 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
438 SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue);
444 static const ber_sequence_t PKIHeader_sequence[] = {
445 { &hf_cmp_pvno , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_T_pvno },
446 { &hf_cmp_sender , BER_CLASS_CON, -1/*choice*/, BER_FLAGS_NOOWNTAG, dissect_pkix1implicit_GeneralName },
447 { &hf_cmp_recipient , BER_CLASS_CON, -1/*choice*/, BER_FLAGS_NOOWNTAG, dissect_pkix1implicit_GeneralName },
448 { &hf_cmp_messageTime , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_cmp_GeneralizedTime },
449 { &hf_cmp_protectionAlg , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_pkix1explicit_AlgorithmIdentifier },
450 { &hf_cmp_senderKID , BER_CLASS_CON, 2, BER_FLAGS_OPTIONAL, dissect_pkix1implicit_KeyIdentifier },
451 { &hf_cmp_recipKID , BER_CLASS_CON, 3, BER_FLAGS_OPTIONAL, dissect_pkix1implicit_KeyIdentifier },
452 { &hf_cmp_transactionID , BER_CLASS_CON, 4, BER_FLAGS_OPTIONAL, dissect_cmp_OCTET_STRING },
453 { &hf_cmp_senderNonce , BER_CLASS_CON, 5, BER_FLAGS_OPTIONAL, dissect_cmp_OCTET_STRING },
454 { &hf_cmp_recipNonce , BER_CLASS_CON, 6, BER_FLAGS_OPTIONAL, dissect_cmp_OCTET_STRING },
455 { &hf_cmp_freeText , BER_CLASS_CON, 7, BER_FLAGS_OPTIONAL, dissect_cmp_PKIFreeText },
456 { &hf_cmp_generalInfo , BER_CLASS_CON, 8, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue },
457 { NULL, 0, 0, 0, NULL }
461 dissect_cmp_PKIHeader(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
462 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
463 PKIHeader_sequence, hf_index, ett_cmp_PKIHeader);
469 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_CMPCertificate_sequence_of[1] = {
470 { &hf_cmp_extraCerts_item , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_CMPCertificate },
474 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
475 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
476 SEQUENCE_SIZE_1_MAX_OF_CMPCertificate_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate);
484 dissect_cmp_INTEGER(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
485 offset = dissect_ber_integer(implicit_tag, actx, tree, tvb, offset, hf_index,
492 const value_string cmp_PKIStatus_vals[] = {
494 { 1, "grantedWithMods" },
497 { 4, "revocationWarning" },
498 { 5, "revocationNotification" },
499 { 6, "keyUpdateWarning" },
505 dissect_cmp_PKIStatus(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
509 offset = dissect_ber_integer(implicit_tag, actx, tree, tvb, offset, hf_index,
513 if (check_col(actx->pinfo->cinfo, COL_INFO)) {
514 col_append_fstr(actx->pinfo->cinfo, COL_INFO, " Status=%s", val_to_str(value, cmp_PKIStatus_vals, "unknown"));
523 static const asn_namedbit PKIFailureInfo_bits[] = {
524 { 0, &hf_cmp_PKIFailureInfo_badAlg, -1, -1, "badAlg", NULL },
525 { 1, &hf_cmp_PKIFailureInfo_badMessageCheck, -1, -1, "badMessageCheck", NULL },
526 { 2, &hf_cmp_PKIFailureInfo_badRequest, -1, -1, "badRequest", NULL },
527 { 3, &hf_cmp_PKIFailureInfo_badTime, -1, -1, "badTime", NULL },
528 { 4, &hf_cmp_PKIFailureInfo_badCertId, -1, -1, "badCertId", NULL },
529 { 5, &hf_cmp_PKIFailureInfo_badDataFormat, -1, -1, "badDataFormat", NULL },
530 { 6, &hf_cmp_PKIFailureInfo_wrongAuthority, -1, -1, "wrongAuthority", NULL },
531 { 7, &hf_cmp_PKIFailureInfo_incorrectData, -1, -1, "incorrectData", NULL },
532 { 8, &hf_cmp_PKIFailureInfo_missingTimeStamp, -1, -1, "missingTimeStamp", NULL },
533 { 9, &hf_cmp_PKIFailureInfo_badPOP, -1, -1, "badPOP", NULL },
534 { 10, &hf_cmp_PKIFailureInfo_certRevoked, -1, -1, "certRevoked", NULL },
535 { 11, &hf_cmp_PKIFailureInfo_certConfirmed, -1, -1, "certConfirmed", NULL },
536 { 12, &hf_cmp_PKIFailureInfo_wrongIntegrity, -1, -1, "wrongIntegrity", NULL },
537 { 13, &hf_cmp_PKIFailureInfo_badRecipientNonce, -1, -1, "badRecipientNonce", NULL },
538 { 14, &hf_cmp_PKIFailureInfo_timeNotAvailable, -1, -1, "timeNotAvailable", NULL },
539 { 15, &hf_cmp_PKIFailureInfo_unacceptedPolicy, -1, -1, "unacceptedPolicy", NULL },
540 { 16, &hf_cmp_PKIFailureInfo_unacceptedExtension, -1, -1, "unacceptedExtension", NULL },
541 { 17, &hf_cmp_PKIFailureInfo_addInfoNotAvailable, -1, -1, "addInfoNotAvailable", NULL },
542 { 18, &hf_cmp_PKIFailureInfo_badSenderNonce, -1, -1, "badSenderNonce", NULL },
543 { 19, &hf_cmp_PKIFailureInfo_badCertTemplate, -1, -1, "badCertTemplate", NULL },
544 { 20, &hf_cmp_PKIFailureInfo_signerNotTrusted, -1, -1, "signerNotTrusted", NULL },
545 { 21, &hf_cmp_PKIFailureInfo_transactionIdInUse, -1, -1, "transactionIdInUse", NULL },
546 { 22, &hf_cmp_PKIFailureInfo_unsupportedVersion, -1, -1, "unsupportedVersion", NULL },
547 { 23, &hf_cmp_PKIFailureInfo_notAuthorized, -1, -1, "notAuthorized", NULL },
548 { 24, &hf_cmp_PKIFailureInfo_systemUnavail, -1, -1, "systemUnavail", NULL },
549 { 25, &hf_cmp_PKIFailureInfo_systemFailure, -1, -1, "systemFailure", NULL },
550 { 26, &hf_cmp_PKIFailureInfo_duplicateCertReq, -1, -1, "duplicateCertReq", NULL },
551 { 0, NULL, 0, 0, NULL, NULL }
555 dissect_cmp_PKIFailureInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
556 offset = dissect_ber_bitstring(implicit_tag, actx, tree, tvb, offset,
557 PKIFailureInfo_bits, hf_index, ett_cmp_PKIFailureInfo,
564 static const ber_sequence_t PKIStatusInfo_sequence[] = {
565 { &hf_cmp_pkistatus , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatus },
566 { &hf_cmp_statusString , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_PKIFreeText },
567 { &hf_cmp_failInfo , BER_CLASS_UNI, BER_UNI_TAG_BITSTRING, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_PKIFailureInfo },
568 { NULL, 0, 0, 0, NULL }
572 dissect_cmp_PKIStatusInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
573 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
574 PKIStatusInfo_sequence, hf_index, ett_cmp_PKIStatusInfo);
580 const value_string cmp_CertOrEncCert_vals[] = {
581 { 0, "certificate" },
582 { 1, "encryptedCert" },
586 static const ber_choice_t CertOrEncCert_choice[] = {
587 { 0, &hf_cmp_certificate , BER_CLASS_CON, 0, 0, dissect_cmp_CMPCertificate },
588 { 1, &hf_cmp_encryptedCert , BER_CLASS_CON, 1, 0, dissect_crmf_EncryptedValue },
589 { 0, NULL, 0, 0, 0, NULL }
593 dissect_cmp_CertOrEncCert(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
594 offset = dissect_ber_choice(actx, tree, tvb, offset,
595 CertOrEncCert_choice, hf_index, ett_cmp_CertOrEncCert,
602 static const ber_sequence_t CertifiedKeyPair_sequence[] = {
603 { &hf_cmp_certOrEncCert , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_CertOrEncCert },
604 { &hf_cmp_privateKey , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_crmf_EncryptedValue },
605 { &hf_cmp_publicationInfo , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_crmf_PKIPublicationInfo },
606 { NULL, 0, 0, 0, NULL }
610 dissect_cmp_CertifiedKeyPair(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
611 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
612 CertifiedKeyPair_sequence, hf_index, ett_cmp_CertifiedKeyPair);
618 static const ber_sequence_t CertResponse_sequence[] = {
619 { &hf_cmp_certReqId , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
620 { &hf_cmp_pkistatusinf , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatusInfo },
621 { &hf_cmp_certifiedKeyPair, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_CertifiedKeyPair },
622 { &hf_cmp_rspInfo , BER_CLASS_UNI, BER_UNI_TAG_OCTETSTRING, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_OCTET_STRING },
623 { NULL, 0, 0, 0, NULL }
627 dissect_cmp_CertResponse(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
628 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
629 CertResponse_sequence, hf_index, ett_cmp_CertResponse);
635 static const ber_sequence_t SEQUENCE_OF_CertResponse_sequence_of[1] = {
636 { &hf_cmp_response_item , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_CertResponse },
640 dissect_cmp_SEQUENCE_OF_CertResponse(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
641 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
642 SEQUENCE_OF_CertResponse_sequence_of, hf_index, ett_cmp_SEQUENCE_OF_CertResponse);
648 static const ber_sequence_t CertRepMessage_sequence[] = {
649 { &hf_cmp_caPubs , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate },
650 { &hf_cmp_response , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_SEQUENCE_OF_CertResponse },
651 { NULL, 0, 0, 0, NULL }
655 dissect_cmp_CertRepMessage(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
656 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
657 CertRepMessage_sequence, hf_index, ett_cmp_CertRepMessage);
665 dissect_cmp_NULL(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
666 offset = dissect_ber_null(implicit_tag, actx, tree, tvb, offset, hf_index);
672 static const ber_sequence_t Challenge_sequence[] = {
673 { &hf_cmp_owf , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
674 { &hf_cmp_witness , BER_CLASS_UNI, BER_UNI_TAG_OCTETSTRING, BER_FLAGS_NOOWNTAG, dissect_cmp_OCTET_STRING },
675 { &hf_cmp_challenge , BER_CLASS_UNI, BER_UNI_TAG_OCTETSTRING, BER_FLAGS_NOOWNTAG, dissect_cmp_OCTET_STRING },
676 { NULL, 0, 0, 0, NULL }
680 dissect_cmp_Challenge(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
681 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
682 Challenge_sequence, hf_index, ett_cmp_Challenge);
688 static const ber_sequence_t POPODecKeyChallContent_sequence_of[1] = {
689 { &hf_cmp_POPODecKeyChallContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_Challenge },
693 dissect_cmp_POPODecKeyChallContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
694 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
695 POPODecKeyChallContent_sequence_of, hf_index, ett_cmp_POPODecKeyChallContent);
701 static const ber_sequence_t POPODecKeyRespContent_sequence_of[1] = {
702 { &hf_cmp_POPODecKeyRespContent_item, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
706 dissect_cmp_POPODecKeyRespContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
707 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
708 POPODecKeyRespContent_sequence_of, hf_index, ett_cmp_POPODecKeyRespContent);
714 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair_sequence_of[1] = {
715 { &hf_cmp_keyPairHist_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_CertifiedKeyPair },
719 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
720 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
721 SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair);
727 static const ber_sequence_t KeyRecRepContent_sequence[] = {
728 { &hf_cmp_pkistatusinf , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatusInfo },
729 { &hf_cmp_newSigCert , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOTCHKTAG, dissect_cmp_CMPCertificate },
730 { &hf_cmp_caCerts , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate },
731 { &hf_cmp_keyPairHist , BER_CLASS_CON, 2, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair },
732 { NULL, 0, 0, 0, NULL }
736 dissect_cmp_KeyRecRepContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
737 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
738 KeyRecRepContent_sequence, hf_index, ett_cmp_KeyRecRepContent);
744 static const ber_sequence_t RevDetails_sequence[] = {
745 { &hf_cmp_certDetails , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_crmf_CertTemplate },
746 { &hf_cmp_crlEntryDetails , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_Extensions },
747 { NULL, 0, 0, 0, NULL }
751 dissect_cmp_RevDetails(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
752 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
753 RevDetails_sequence, hf_index, ett_cmp_RevDetails);
759 static const ber_sequence_t RevReqContent_sequence_of[1] = {
760 { &hf_cmp_RevReqContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_RevDetails },
764 dissect_cmp_RevReqContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
765 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
766 RevReqContent_sequence_of, hf_index, ett_cmp_RevReqContent);
772 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo_sequence_of[1] = {
773 { &hf_cmp_rvrpcnt_status_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatusInfo },
777 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
778 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
779 SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo);
785 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_CertId_sequence_of[1] = {
786 { &hf_cmp_revCerts_item , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_crmf_CertId },
790 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertId(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
791 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
792 SEQUENCE_SIZE_1_MAX_OF_CertId_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertId);
798 static const ber_sequence_t SEQUENCE_SIZE_1_MAX_OF_CertificateList_sequence_of[1] = {
799 { &hf_cmp_crls_item , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_CertificateList },
803 dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertificateList(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
804 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
805 SEQUENCE_SIZE_1_MAX_OF_CertificateList_sequence_of, hf_index, ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertificateList);
811 static const ber_sequence_t RevRepContent_sequence[] = {
812 { &hf_cmp_rvrpcnt_status , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo },
813 { &hf_cmp_revCerts , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertId },
814 { &hf_cmp_crls , BER_CLASS_CON, 1, 0, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CertificateList },
815 { NULL, 0, 0, 0, NULL }
819 dissect_cmp_RevRepContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
820 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
821 RevRepContent_sequence, hf_index, ett_cmp_RevRepContent);
827 static const ber_sequence_t CAKeyUpdAnnContent_sequence[] = {
828 { &hf_cmp_oldWithNew , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_CMPCertificate },
829 { &hf_cmp_newWithOld , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_CMPCertificate },
830 { &hf_cmp_newWithNew , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_CMPCertificate },
831 { NULL, 0, 0, 0, NULL }
835 dissect_cmp_CAKeyUpdAnnContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
836 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
837 CAKeyUpdAnnContent_sequence, hf_index, ett_cmp_CAKeyUpdAnnContent);
845 dissect_cmp_CertAnnContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
846 offset = dissect_cmp_CMPCertificate(implicit_tag, tvb, offset, actx, tree, hf_index);
852 static const ber_sequence_t RevAnnContent_sequence[] = {
853 { &hf_cmp_pkistatus , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatus },
854 { &hf_cmp_certId , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_crmf_CertId },
855 { &hf_cmp_willBeRevokedAt , BER_CLASS_UNI, BER_UNI_TAG_GeneralizedTime, BER_FLAGS_NOOWNTAG, dissect_cmp_GeneralizedTime },
856 { &hf_cmp_badSinceDate , BER_CLASS_UNI, BER_UNI_TAG_GeneralizedTime, BER_FLAGS_NOOWNTAG, dissect_cmp_GeneralizedTime },
857 { &hf_cmp_crlDetails , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_Extensions },
858 { NULL, 0, 0, 0, NULL }
862 dissect_cmp_RevAnnContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
863 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
864 RevAnnContent_sequence, hf_index, ett_cmp_RevAnnContent);
870 static const ber_sequence_t CRLAnnContent_sequence_of[1] = {
871 { &hf_cmp_CRLAnnContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_CertificateList },
875 dissect_cmp_CRLAnnContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
876 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
877 CRLAnnContent_sequence_of, hf_index, ett_cmp_CRLAnnContent);
885 dissect_cmp_PKIConfirmContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
886 offset = dissect_ber_null(implicit_tag, actx, tree, tvb, offset, hf_index);
892 static const ber_sequence_t PKIMessages_sequence_of[1] = {
893 { &hf_cmp_PKIMessages_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIMessage },
897 dissect_cmp_PKIMessages(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
898 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
899 PKIMessages_sequence_of, hf_index, ett_cmp_PKIMessages);
907 dissect_cmp_NestedMessageContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
908 offset = dissect_cmp_PKIMessages(implicit_tag, tvb, offset, actx, tree, hf_index);
914 static const ber_sequence_t GenMsgContent_sequence_of[1] = {
915 { &hf_cmp_GenMsgContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_InfoTypeAndValue },
919 dissect_cmp_GenMsgContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
920 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
921 GenMsgContent_sequence_of, hf_index, ett_cmp_GenMsgContent);
927 static const ber_sequence_t GenRepContent_sequence_of[1] = {
928 { &hf_cmp_GenRepContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_InfoTypeAndValue },
932 dissect_cmp_GenRepContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
933 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
934 GenRepContent_sequence_of, hf_index, ett_cmp_GenRepContent);
940 static const ber_sequence_t ErrorMsgContent_sequence[] = {
941 { &hf_cmp_pKIStatusInfo , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatusInfo },
942 { &hf_cmp_errorCode , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
943 { &hf_cmp_errorDetails , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_PKIFreeText },
944 { NULL, 0, 0, 0, NULL }
948 dissect_cmp_ErrorMsgContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
949 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
950 ErrorMsgContent_sequence, hf_index, ett_cmp_ErrorMsgContent);
956 static const ber_sequence_t CertStatus_sequence[] = {
957 { &hf_cmp_certHash , BER_CLASS_UNI, BER_UNI_TAG_OCTETSTRING, BER_FLAGS_NOOWNTAG, dissect_cmp_OCTET_STRING },
958 { &hf_cmp_certReqId , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
959 { &hf_cmp_statusInfo , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_PKIStatusInfo },
960 { NULL, 0, 0, 0, NULL }
964 dissect_cmp_CertStatus(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
965 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
966 CertStatus_sequence, hf_index, ett_cmp_CertStatus);
972 static const ber_sequence_t CertConfirmContent_sequence_of[1] = {
973 { &hf_cmp_CertConfirmContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_CertStatus },
977 dissect_cmp_CertConfirmContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
978 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
979 CertConfirmContent_sequence_of, hf_index, ett_cmp_CertConfirmContent);
985 static const ber_sequence_t PollReqContent_item_sequence[] = {
986 { &hf_cmp_certReqId , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
987 { NULL, 0, 0, 0, NULL }
991 dissect_cmp_PollReqContent_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_) {
992 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
993 PollReqContent_item_sequence, hf_index, ett_cmp_PollReqContent_item);
999 static const ber_sequence_t PollReqContent_sequence_of[1] = {
1000 { &hf_cmp_PollReqContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PollReqContent_item },
1004 dissect_cmp_PollReqContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1005 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1006 PollReqContent_sequence_of, hf_index, ett_cmp_PollReqContent);
1012 static const ber_sequence_t PollRepContent_item_sequence[] = {
1013 { &hf_cmp_certReqId , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
1014 { &hf_cmp_checkAfter , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
1015 { &hf_cmp_reason , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_cmp_PKIFreeText },
1016 { NULL, 0, 0, 0, NULL }
1020 dissect_cmp_PollRepContent_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_) {
1021 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1022 PollRepContent_item_sequence, hf_index, ett_cmp_PollRepContent_item);
1028 static const ber_sequence_t PollRepContent_sequence_of[1] = {
1029 { &hf_cmp_PollRepContent_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PollRepContent_item },
1033 dissect_cmp_PollRepContent(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1034 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1035 PollRepContent_sequence_of, hf_index, ett_cmp_PollRepContent);
1041 const value_string cmp_PKIBody_vals[] = {
1072 static const ber_choice_t PKIBody_choice[] = {
1073 { 0, &hf_cmp_ir , BER_CLASS_CON, 0, 0, dissect_crmf_CertReqMessages },
1074 { 1, &hf_cmp_ip , BER_CLASS_CON, 1, 0, dissect_cmp_CertRepMessage },
1075 { 2, &hf_cmp_cr , BER_CLASS_CON, 2, 0, dissect_crmf_CertReqMessages },
1076 { 3, &hf_cmp_cp , BER_CLASS_CON, 3, 0, dissect_cmp_CertRepMessage },
1077 { 4, &hf_cmp_p10cr , BER_CLASS_CON, 4, 0, dissect_cmp_NULL },
1078 { 5, &hf_cmp_popdecc , BER_CLASS_CON, 5, 0, dissect_cmp_POPODecKeyChallContent },
1079 { 6, &hf_cmp_popdecr , BER_CLASS_CON, 6, 0, dissect_cmp_POPODecKeyRespContent },
1080 { 7, &hf_cmp_kur , BER_CLASS_CON, 7, 0, dissect_crmf_CertReqMessages },
1081 { 8, &hf_cmp_kup , BER_CLASS_CON, 8, 0, dissect_cmp_CertRepMessage },
1082 { 9, &hf_cmp_krr , BER_CLASS_CON, 9, 0, dissect_crmf_CertReqMessages },
1083 { 10, &hf_cmp_krp , BER_CLASS_CON, 10, 0, dissect_cmp_KeyRecRepContent },
1084 { 11, &hf_cmp_rr , BER_CLASS_CON, 11, 0, dissect_cmp_RevReqContent },
1085 { 12, &hf_cmp_rp , BER_CLASS_CON, 12, 0, dissect_cmp_RevRepContent },
1086 { 13, &hf_cmp_ccr , BER_CLASS_CON, 13, 0, dissect_crmf_CertReqMessages },
1087 { 14, &hf_cmp_ccp , BER_CLASS_CON, 14, 0, dissect_cmp_CertRepMessage },
1088 { 15, &hf_cmp_ckuann , BER_CLASS_CON, 15, 0, dissect_cmp_CAKeyUpdAnnContent },
1089 { 16, &hf_cmp_cann , BER_CLASS_CON, 16, 0, dissect_cmp_CertAnnContent },
1090 { 17, &hf_cmp_rann , BER_CLASS_CON, 17, 0, dissect_cmp_RevAnnContent },
1091 { 18, &hf_cmp_crlann , BER_CLASS_CON, 18, 0, dissect_cmp_CRLAnnContent },
1092 { 19, &hf_cmp_pkiconf , BER_CLASS_CON, 19, 0, dissect_cmp_PKIConfirmContent },
1093 { 20, &hf_cmp_nested , BER_CLASS_CON, 20, 0, dissect_cmp_NestedMessageContent },
1094 { 21, &hf_cmp_genm , BER_CLASS_CON, 21, 0, dissect_cmp_GenMsgContent },
1095 { 22, &hf_cmp_genp , BER_CLASS_CON, 22, 0, dissect_cmp_GenRepContent },
1096 { 23, &hf_cmp_error , BER_CLASS_CON, 23, 0, dissect_cmp_ErrorMsgContent },
1097 { 24, &hf_cmp_certConf , BER_CLASS_CON, 24, 0, dissect_cmp_CertConfirmContent },
1098 { 25, &hf_cmp_pollReq , BER_CLASS_CON, 25, 0, dissect_cmp_PollReqContent },
1099 { 26, &hf_cmp_pollRep , BER_CLASS_CON, 26, 0, dissect_cmp_PollRepContent },
1100 { 0, NULL, 0, 0, 0, NULL }
1104 dissect_cmp_PKIBody(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1108 offset = dissect_ber_choice(actx, tree, tvb, offset,
1109 PKIBody_choice, hf_index, ett_cmp_PKIBody,
1113 if (check_col(actx->pinfo->cinfo, COL_INFO)) {
1114 col_append_fstr(actx->pinfo->cinfo, COL_INFO, " Body=%s", val_to_str(branch_taken, cmp_PKIBody_vals, "unknown"));
1125 dissect_cmp_PKIProtection(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1126 offset = dissect_ber_bitstring(implicit_tag, actx, tree, tvb, offset,
1134 static const ber_sequence_t PKIMessage_sequence[] = {
1135 { &hf_cmp_header , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIHeader },
1136 { &hf_cmp_body , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_PKIBody },
1137 { &hf_cmp_protection , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_cmp_PKIProtection },
1138 { &hf_cmp_extraCerts , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate },
1139 { NULL, 0, 0, 0, NULL }
1143 dissect_cmp_PKIMessage(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1144 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1145 PKIMessage_sequence, hf_index, ett_cmp_PKIMessage);
1151 static const ber_sequence_t ProtectedPart_sequence[] = {
1152 { &hf_cmp_header , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_cmp_PKIHeader },
1153 { &hf_cmp_body , BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_cmp_PKIBody },
1154 { NULL, 0, 0, 0, NULL }
1158 dissect_cmp_ProtectedPart(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1159 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1160 ProtectedPart_sequence, hf_index, ett_cmp_ProtectedPart);
1166 static const ber_sequence_t PBMParameter_sequence[] = {
1167 { &hf_cmp_salt , BER_CLASS_UNI, BER_UNI_TAG_OCTETSTRING, BER_FLAGS_NOOWNTAG, dissect_cmp_OCTET_STRING },
1168 { &hf_cmp_owf , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1169 { &hf_cmp_iterationCount , BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_cmp_INTEGER },
1170 { &hf_cmp_mac , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1171 { NULL, 0, 0, 0, NULL }
1175 dissect_cmp_PBMParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1176 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1177 PBMParameter_sequence, hf_index, ett_cmp_PBMParameter);
1183 static const ber_sequence_t DHBMParameter_sequence[] = {
1184 { &hf_cmp_owf , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1185 { &hf_cmp_mac , BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1186 { NULL, 0, 0, 0, NULL }
1190 dissect_cmp_DHBMParameter(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1191 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1192 DHBMParameter_sequence, hf_index, ett_cmp_DHBMParameter);
1200 dissect_cmp_OOBCert(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1201 offset = dissect_cmp_CMPCertificate(implicit_tag, tvb, offset, actx, tree, hf_index);
1209 dissect_cmp_BIT_STRING(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1210 offset = dissect_ber_bitstring(implicit_tag, actx, tree, tvb, offset,
1218 static const ber_sequence_t OOBCertHash_sequence[] = {
1219 { &hf_cmp_hashAlg , BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_pkix1explicit_AlgorithmIdentifier },
1220 { &hf_cmp_certId , BER_CLASS_CON, 1, BER_FLAGS_OPTIONAL, dissect_crmf_CertId },
1221 { &hf_cmp_hashVal , BER_CLASS_UNI, BER_UNI_TAG_BITSTRING, BER_FLAGS_NOOWNTAG, dissect_cmp_BIT_STRING },
1222 { NULL, 0, 0, 0, NULL }
1226 dissect_cmp_OOBCertHash(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1227 offset = dissect_ber_sequence(implicit_tag, actx, tree, tvb, offset,
1228 OOBCertHash_sequence, hf_index, ett_cmp_OOBCertHash);
1236 dissect_cmp_CAProtEncCertValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1237 offset = dissect_cmp_CMPCertificate(implicit_tag, tvb, offset, actx, tree, hf_index);
1243 static const ber_sequence_t SignKeyPairTypesValue_sequence_of[1] = {
1244 { &hf_cmp_SignKeyPairTypesValue_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1248 dissect_cmp_SignKeyPairTypesValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1249 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1250 SignKeyPairTypesValue_sequence_of, hf_index, ett_cmp_SignKeyPairTypesValue);
1256 static const ber_sequence_t EncKeyPairTypesValue_sequence_of[1] = {
1257 { &hf_cmp_EncKeyPairTypesValue_item, BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_pkix1explicit_AlgorithmIdentifier },
1261 dissect_cmp_EncKeyPairTypesValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1262 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1263 EncKeyPairTypesValue_sequence_of, hf_index, ett_cmp_EncKeyPairTypesValue);
1271 dissect_cmp_PreferredSymmAlgValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1272 offset = dissect_pkix1explicit_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index);
1280 dissect_cmp_CAKeyUpdateInfoValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1281 offset = dissect_cmp_CAKeyUpdAnnContent(implicit_tag, tvb, offset, actx, tree, hf_index);
1289 dissect_cmp_CurrentCRLValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1290 offset = dissect_pkix1explicit_CertificateList(implicit_tag, tvb, offset, actx, tree, hf_index);
1298 dissect_cmp_OBJECT_IDENTIFIER(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1299 offset = dissect_ber_object_identifier(implicit_tag, actx, tree, tvb, offset, hf_index, NULL);
1305 static const ber_sequence_t UnsupportedOIDsValue_sequence_of[1] = {
1306 { &hf_cmp_UnsupportedOIDsValue_item, BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_cmp_OBJECT_IDENTIFIER },
1310 dissect_cmp_UnsupportedOIDsValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1311 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1312 UnsupportedOIDsValue_sequence_of, hf_index, ett_cmp_UnsupportedOIDsValue);
1320 dissect_cmp_KeyPairParamReqValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1321 offset = dissect_ber_object_identifier(implicit_tag, actx, tree, tvb, offset, hf_index, NULL);
1329 dissect_cmp_KeyPairParamRepValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1330 offset = dissect_pkix1explicit_AlgorithmIdentifier(implicit_tag, tvb, offset, actx, tree, hf_index);
1338 dissect_cmp_RevPassphraseValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1339 offset = dissect_crmf_EncryptedValue(implicit_tag, tvb, offset, actx, tree, hf_index);
1347 dissect_cmp_ImplicitConfirmValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1348 offset = dissect_ber_null(implicit_tag, actx, tree, tvb, offset, hf_index);
1356 dissect_cmp_ConfirmWaitTimeValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1357 offset = dissect_ber_GeneralizedTime(implicit_tag, actx, tree, tvb, offset, hf_index);
1365 dissect_cmp_OrigPKIMessageValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1366 offset = dissect_cmp_PKIMessages(implicit_tag, tvb, offset, actx, tree, hf_index);
1372 static const ber_sequence_t SuppLangTagsValue_sequence_of[1] = {
1373 { &hf_cmp_SuppLangTagsValue_item, BER_CLASS_UNI, BER_UNI_TAG_UTF8String, BER_FLAGS_NOOWNTAG, dissect_cmp_UTF8String },
1377 dissect_cmp_SuppLangTagsValue(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
1378 offset = dissect_ber_sequence_of(implicit_tag, actx, tree, tvb, offset,
1379 SuppLangTagsValue_sequence_of, hf_index, ett_cmp_SuppLangTagsValue);
1386 static void dissect_PBMParameter_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1387 asn1_ctx_t asn1_ctx;
1388 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1389 dissect_cmp_PBMParameter(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_PBMParameter_PDU);
1391 static void dissect_DHBMParameter_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1392 asn1_ctx_t asn1_ctx;
1393 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1394 dissect_cmp_DHBMParameter(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_DHBMParameter_PDU);
1396 static void dissect_CAProtEncCertValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1397 asn1_ctx_t asn1_ctx;
1398 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1399 dissect_cmp_CAProtEncCertValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_CAProtEncCertValue_PDU);
1401 static void dissect_SignKeyPairTypesValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1402 asn1_ctx_t asn1_ctx;
1403 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1404 dissect_cmp_SignKeyPairTypesValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_SignKeyPairTypesValue_PDU);
1406 static void dissect_EncKeyPairTypesValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1407 asn1_ctx_t asn1_ctx;
1408 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1409 dissect_cmp_EncKeyPairTypesValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_EncKeyPairTypesValue_PDU);
1411 static void dissect_PreferredSymmAlgValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1412 asn1_ctx_t asn1_ctx;
1413 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1414 dissect_cmp_PreferredSymmAlgValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_PreferredSymmAlgValue_PDU);
1416 static void dissect_CAKeyUpdateInfoValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1417 asn1_ctx_t asn1_ctx;
1418 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1419 dissect_cmp_CAKeyUpdateInfoValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_CAKeyUpdateInfoValue_PDU);
1421 static void dissect_CurrentCRLValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1422 asn1_ctx_t asn1_ctx;
1423 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1424 dissect_cmp_CurrentCRLValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_CurrentCRLValue_PDU);
1426 static void dissect_UnsupportedOIDsValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1427 asn1_ctx_t asn1_ctx;
1428 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1429 dissect_cmp_UnsupportedOIDsValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_UnsupportedOIDsValue_PDU);
1431 static void dissect_KeyPairParamReqValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1432 asn1_ctx_t asn1_ctx;
1433 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1434 dissect_cmp_KeyPairParamReqValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_KeyPairParamReqValue_PDU);
1436 static void dissect_KeyPairParamRepValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1437 asn1_ctx_t asn1_ctx;
1438 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1439 dissect_cmp_KeyPairParamRepValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_KeyPairParamRepValue_PDU);
1441 static void dissect_RevPassphraseValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1442 asn1_ctx_t asn1_ctx;
1443 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1444 dissect_cmp_RevPassphraseValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_RevPassphraseValue_PDU);
1446 static void dissect_ImplicitConfirmValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1447 asn1_ctx_t asn1_ctx;
1448 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1449 dissect_cmp_ImplicitConfirmValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_ImplicitConfirmValue_PDU);
1451 static void dissect_ConfirmWaitTimeValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1452 asn1_ctx_t asn1_ctx;
1453 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1454 dissect_cmp_ConfirmWaitTimeValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_ConfirmWaitTimeValue_PDU);
1456 static void dissect_OrigPKIMessageValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1457 asn1_ctx_t asn1_ctx;
1458 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1459 dissect_cmp_OrigPKIMessageValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_OrigPKIMessageValue_PDU);
1461 static void dissect_SuppLangTagsValue_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_) {
1462 asn1_ctx_t asn1_ctx;
1463 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1464 dissect_cmp_SuppLangTagsValue(FALSE, tvb, 0, &asn1_ctx, tree, hf_cmp_SuppLangTagsValue_PDU);
1468 /*--- End of included file: packet-cmp-fn.c ---*/
1469 #line 84 "packet-cmp-template.c"
1472 dissect_cmp_pdu(tvbuff_t *tvb, proto_tree *tree, asn1_ctx_t *actx)
1474 return dissect_cmp_PKIMessage(FALSE, tvb, 0, actx,tree, -1);
1477 #define CMP_TYPE_PKIMSG 0
1478 #define CMP_TYPE_POLLREP 1
1479 #define CMP_TYPE_POLLREQ 2
1480 #define CMP_TYPE_NEGPOLLREP 3
1481 #define CMP_TYPE_PARTIALMSGREP 4
1482 #define CMP_TYPE_FINALMSGREP 5
1483 #define CMP_TYPE_ERRORMSGREP 6
1484 static const value_string cmp_pdu_types[] = {
1485 { CMP_TYPE_PKIMSG, "pkiMsg" },
1486 { CMP_TYPE_POLLREP, "pollRep" },
1487 { CMP_TYPE_POLLREQ, "pollReq" },
1488 { CMP_TYPE_NEGPOLLREP, "negPollRep" },
1489 { CMP_TYPE_PARTIALMSGREP, "partialMsgRep" },
1490 { CMP_TYPE_FINALMSGREP, "finalMsgRep" },
1491 { CMP_TYPE_ERRORMSGREP, "errorMsgRep" },
1496 static int dissect_cmp_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
1502 proto_item *item=NULL;
1503 proto_item *ti=NULL;
1504 proto_tree *tree=NULL;
1505 proto_tree *tcptrans_tree=NULL;
1506 asn1_ctx_t asn1_ctx;
1509 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1511 col_set_str(pinfo->cinfo, COL_PROTOCOL, "CMP");
1513 col_set_str(pinfo->cinfo, COL_INFO, "PKIXCMP");
1516 item=proto_tree_add_item(parent_tree, proto_cmp, tvb, 0, -1, FALSE);
1517 tree = proto_item_add_subtree(item, ett_cmp);
1520 pdu_len=tvb_get_ntohl(tvb, 0);
1521 pdu_type=tvb_get_guint8(tvb, 4);
1523 if (pdu_type < 10) {
1524 /* RFC2510 TCP transport */
1525 ti = proto_tree_add_item(tree, proto_cmp, tvb, offset, 5, FALSE);
1526 tcptrans_tree = proto_item_add_subtree(ti, ett_cmp);
1527 proto_tree_add_item(tree, hf_cmp_tcptrans_len, tvb, offset, 4, FALSE);
1529 proto_tree_add_item(tree, hf_cmp_tcptrans_type, tvb, offset++, 1, FALSE);
1531 /* post RFC2510 TCP transport - the former "type" field is now "version" */
1532 ti = proto_tree_add_text(tree, tvb, offset, 7, "TCP transport");
1533 tcptrans_tree = proto_item_add_subtree(ti, ett_cmp);
1534 pdu_type=tvb_get_guint8(tvb, 6);
1535 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans_len, tvb, offset, 4, FALSE);
1537 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans10_version, tvb, offset++, 1, FALSE);
1538 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans10_flags, tvb, offset++, 1, FALSE);
1539 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans_type, tvb, offset++, 1, FALSE);
1542 if (check_col (pinfo->cinfo, COL_INFO)) {
1543 col_add_str (pinfo->cinfo, COL_INFO, val_to_str (pdu_type, cmp_pdu_types, "0x%x"));
1547 case CMP_TYPE_PKIMSG:
1548 next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), pdu_len);
1549 dissect_cmp_pdu(next_tvb, tree, &asn1_ctx);
1550 offset += tvb_length_remaining(tvb, offset);
1552 case CMP_TYPE_POLLREP:
1553 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans_poll_ref, tvb, offset, 4, FALSE);
1556 ts.secs = tvb_get_ntohl(tvb, 4);
1558 proto_tree_add_time(tcptrans_tree, hf_cmp_tcptrans_ttcb, tvb, offset, 4, &ts);
1561 case CMP_TYPE_POLLREQ:
1562 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans_poll_ref, tvb, offset, 4, FALSE);
1565 case CMP_TYPE_NEGPOLLREP:
1567 case CMP_TYPE_PARTIALMSGREP:
1568 proto_tree_add_item(tcptrans_tree, hf_cmp_tcptrans_next_poll_ref, tvb, offset, 4, FALSE);
1571 ts.secs = tvb_get_ntohl(tvb, 4);
1573 proto_tree_add_time(tcptrans_tree, hf_cmp_tcptrans_ttcb, tvb, offset, 4, &ts);
1576 next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), pdu_len);
1577 dissect_cmp_pdu(next_tvb, tree, &asn1_ctx);
1578 offset += tvb_length_remaining(tvb, offset);
1580 case CMP_TYPE_FINALMSGREP:
1581 next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), pdu_len);
1582 dissect_cmp_pdu(next_tvb, tree, &asn1_ctx);
1583 offset += tvb_length_remaining(tvb, offset);
1585 case CMP_TYPE_ERRORMSGREP:
1593 static void dissect_cmp_tcp_pdu_no_return(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
1595 dissect_cmp_tcp_pdu(tvb, pinfo, parent_tree);
1598 static guint get_cmp_pdu_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
1603 * Get the length of the CMP-over-TCP packet.
1605 plen = tvb_get_ntohl(tvb, offset);
1611 /* CMP over TCP: RFC2510 section 5.2 and "Transport Protocols for CMP" draft */
1613 dissect_cmp_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
1617 int offset=4; /* RFC2510 TCP transport header length */
1619 /* only attempt to dissect it as CMP over TCP if we have
1622 if (!tvb_bytes_exist(tvb, 0, 5)) {
1626 pdu_len=tvb_get_ntohl(tvb, 0);
1627 pdu_type=tvb_get_guint8(tvb, 4);
1629 if(pdu_type == 10) {
1630 /* post RFC2510 TCP transport */
1631 pdu_type = tvb_get_guint8(tvb, 7);
1632 offset = 7; /* post RFC2510 TCP transport header length */
1633 /* arbitrary limit: assume a CMP over TCP pdu is never >10000 bytes
1635 * It is definitely at least 3 byte for post RFC2510 TCP transport
1637 if((pdu_len<=2)||(pdu_len>10000)){
1641 /* RFC2510 TCP transport */
1642 /* type is between 0 and 6 */
1646 /* arbitrary limit: assume a CMP over TCP pdu is never >10000 bytes
1648 * It is definitely at least 1 byte to accomodate the flags byte
1650 if((pdu_len<=0)||(pdu_len>10000)){
1655 /* type 0 contains a PKI message and must therefore be >= 3 bytes
1656 * long (flags + BER TAG + BER LENGTH
1658 if((pdu_type==0)&&(pdu_len<3)){
1662 tcp_dissect_pdus(tvb, pinfo, parent_tree, cmp_desegment, offset, get_cmp_pdu_len,
1663 dissect_cmp_tcp_pdu_no_return);
1665 return tvb_length(tvb);
1670 dissect_cmp_http(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
1672 proto_item *item=NULL;
1673 proto_tree *tree=NULL;
1674 asn1_ctx_t asn1_ctx;
1676 asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo);
1678 col_set_str(pinfo->cinfo, COL_PROTOCOL, "CMP");
1680 col_set_str(pinfo->cinfo, COL_INFO, "PKIXCMP");
1683 item=proto_tree_add_item(parent_tree, proto_cmp, tvb, 0, -1, FALSE);
1684 tree = proto_item_add_subtree(item, ett_cmp);
1687 return dissect_cmp_pdu(tvb, tree, &asn1_ctx);
1691 /*--- proto_register_cmp ----------------------------------------------*/
1692 void proto_register_cmp(void) {
1694 /* List of fields */
1695 static hf_register_info hf[] = {
1697 { "InfoType", "cmp.type.oid",
1698 FT_STRING, BASE_NONE, NULL, 0,
1699 "Type of InfoTypeAndValue", HFILL }},
1700 { &hf_cmp_tcptrans_len,
1701 { "Length", "cmp.tcptrans.length",
1702 FT_UINT32, BASE_DEC, NULL, 0,
1703 "TCP transport Length of PDU in bytes", HFILL }},
1704 { &hf_cmp_tcptrans_type,
1705 { "Type", "cmp.tcptrans.type",
1706 FT_UINT8, BASE_DEC, VALS(cmp_pdu_types), 0,
1707 "TCP transport PDU Type", HFILL }},
1708 { &hf_cmp_tcptrans_poll_ref,
1709 { "Polling Reference", "cmp.tcptrans.poll_ref",
1710 FT_UINT32, BASE_HEX, NULL, 0,
1711 "TCP transport Polling Reference", HFILL }},
1712 { &hf_cmp_tcptrans_next_poll_ref,
1713 { "Next Polling Reference", "cmp.tcptrans.next_poll_ref",
1714 FT_UINT32, BASE_HEX, NULL, 0,
1715 "TCP transport Next Polling Reference", HFILL }},
1716 { &hf_cmp_tcptrans_ttcb,
1717 { "Time to check Back", "cmp.tcptrans.ttcb",
1718 FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0,
1719 "TCP transport Time to check Back", HFILL }},
1720 { &hf_cmp_tcptrans10_version,
1721 { "Version", "cmp.tcptrans10.version",
1722 FT_UINT8, BASE_DEC, NULL, 0,
1723 "TCP transport version", HFILL }},
1724 { &hf_cmp_tcptrans10_flags,
1725 { "Flags", "cmp.tcptrans10.flags",
1726 FT_UINT8, BASE_DEC, NULL, 0,
1727 "TCP transport flags", HFILL }},
1729 /*--- Included file: packet-cmp-hfarr.c ---*/
1730 #line 1 "packet-cmp-hfarr.c"
1731 { &hf_cmp_PBMParameter_PDU,
1732 { "PBMParameter", "cmp.PBMParameter",
1733 FT_NONE, BASE_NONE, NULL, 0,
1734 "cmp.PBMParameter", HFILL }},
1735 { &hf_cmp_DHBMParameter_PDU,
1736 { "DHBMParameter", "cmp.DHBMParameter",
1737 FT_NONE, BASE_NONE, NULL, 0,
1738 "cmp.DHBMParameter", HFILL }},
1739 { &hf_cmp_CAProtEncCertValue_PDU,
1740 { "CAProtEncCertValue", "cmp.CAProtEncCertValue",
1741 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
1742 "cmp.CAProtEncCertValue", HFILL }},
1743 { &hf_cmp_SignKeyPairTypesValue_PDU,
1744 { "SignKeyPairTypesValue", "cmp.SignKeyPairTypesValue",
1745 FT_UINT32, BASE_DEC, NULL, 0,
1746 "cmp.SignKeyPairTypesValue", HFILL }},
1747 { &hf_cmp_EncKeyPairTypesValue_PDU,
1748 { "EncKeyPairTypesValue", "cmp.EncKeyPairTypesValue",
1749 FT_UINT32, BASE_DEC, NULL, 0,
1750 "cmp.EncKeyPairTypesValue", HFILL }},
1751 { &hf_cmp_PreferredSymmAlgValue_PDU,
1752 { "PreferredSymmAlgValue", "cmp.PreferredSymmAlgValue",
1753 FT_NONE, BASE_NONE, NULL, 0,
1754 "cmp.PreferredSymmAlgValue", HFILL }},
1755 { &hf_cmp_CAKeyUpdateInfoValue_PDU,
1756 { "CAKeyUpdateInfoValue", "cmp.CAKeyUpdateInfoValue",
1757 FT_NONE, BASE_NONE, NULL, 0,
1758 "cmp.CAKeyUpdateInfoValue", HFILL }},
1759 { &hf_cmp_CurrentCRLValue_PDU,
1760 { "CurrentCRLValue", "cmp.CurrentCRLValue",
1761 FT_NONE, BASE_NONE, NULL, 0,
1762 "cmp.CurrentCRLValue", HFILL }},
1763 { &hf_cmp_UnsupportedOIDsValue_PDU,
1764 { "UnsupportedOIDsValue", "cmp.UnsupportedOIDsValue",
1765 FT_UINT32, BASE_DEC, NULL, 0,
1766 "cmp.UnsupportedOIDsValue", HFILL }},
1767 { &hf_cmp_KeyPairParamReqValue_PDU,
1768 { "KeyPairParamReqValue", "cmp.KeyPairParamReqValue",
1769 FT_OID, BASE_NONE, NULL, 0,
1770 "cmp.KeyPairParamReqValue", HFILL }},
1771 { &hf_cmp_KeyPairParamRepValue_PDU,
1772 { "KeyPairParamRepValue", "cmp.KeyPairParamRepValue",
1773 FT_NONE, BASE_NONE, NULL, 0,
1774 "cmp.KeyPairParamRepValue", HFILL }},
1775 { &hf_cmp_RevPassphraseValue_PDU,
1776 { "RevPassphraseValue", "cmp.RevPassphraseValue",
1777 FT_NONE, BASE_NONE, NULL, 0,
1778 "cmp.RevPassphraseValue", HFILL }},
1779 { &hf_cmp_ImplicitConfirmValue_PDU,
1780 { "ImplicitConfirmValue", "cmp.ImplicitConfirmValue",
1781 FT_NONE, BASE_NONE, NULL, 0,
1782 "cmp.ImplicitConfirmValue", HFILL }},
1783 { &hf_cmp_ConfirmWaitTimeValue_PDU,
1784 { "ConfirmWaitTimeValue", "cmp.ConfirmWaitTimeValue",
1785 FT_STRING, BASE_NONE, NULL, 0,
1786 "cmp.ConfirmWaitTimeValue", HFILL }},
1787 { &hf_cmp_OrigPKIMessageValue_PDU,
1788 { "OrigPKIMessageValue", "cmp.OrigPKIMessageValue",
1789 FT_UINT32, BASE_DEC, NULL, 0,
1790 "cmp.OrigPKIMessageValue", HFILL }},
1791 { &hf_cmp_SuppLangTagsValue_PDU,
1792 { "SuppLangTagsValue", "cmp.SuppLangTagsValue",
1793 FT_UINT32, BASE_DEC, NULL, 0,
1794 "cmp.SuppLangTagsValue", HFILL }},
1795 { &hf_cmp_x509v3PKCert,
1796 { "x509v3PKCert", "cmp.x509v3PKCert",
1797 FT_NONE, BASE_NONE, NULL, 0,
1798 "pkix1explicit.Certificate", HFILL }},
1800 { "header", "cmp.header",
1801 FT_NONE, BASE_NONE, NULL, 0,
1802 "cmp.PKIHeader", HFILL }},
1804 { "body", "cmp.body",
1805 FT_UINT32, BASE_DEC, VALS(cmp_PKIBody_vals), 0,
1806 "cmp.PKIBody", HFILL }},
1807 { &hf_cmp_protection,
1808 { "protection", "cmp.protection",
1809 FT_BYTES, BASE_NONE, NULL, 0,
1810 "cmp.PKIProtection", HFILL }},
1811 { &hf_cmp_extraCerts,
1812 { "extraCerts", "cmp.extraCerts",
1813 FT_UINT32, BASE_DEC, NULL, 0,
1814 "cmp.SEQUENCE_SIZE_1_MAX_OF_CMPCertificate", HFILL }},
1815 { &hf_cmp_extraCerts_item,
1816 { "CMPCertificate", "cmp.CMPCertificate",
1817 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
1818 "cmp.CMPCertificate", HFILL }},
1819 { &hf_cmp_PKIMessages_item,
1820 { "PKIMessage", "cmp.PKIMessage",
1821 FT_NONE, BASE_NONE, NULL, 0,
1822 "cmp.PKIMessage", HFILL }},
1824 { "pvno", "cmp.pvno",
1825 FT_INT32, BASE_DEC, VALS(cmp_T_pvno_vals), 0,
1826 "cmp.T_pvno", HFILL }},
1828 { "sender", "cmp.sender",
1829 FT_UINT32, BASE_DEC, NULL, 0,
1830 "pkix1implicit.GeneralName", HFILL }},
1831 { &hf_cmp_recipient,
1832 { "recipient", "cmp.recipient",
1833 FT_UINT32, BASE_DEC, NULL, 0,
1834 "pkix1implicit.GeneralName", HFILL }},
1835 { &hf_cmp_messageTime,
1836 { "messageTime", "cmp.messageTime",
1837 FT_STRING, BASE_NONE, NULL, 0,
1838 "cmp.GeneralizedTime", HFILL }},
1839 { &hf_cmp_protectionAlg,
1840 { "protectionAlg", "cmp.protectionAlg",
1841 FT_NONE, BASE_NONE, NULL, 0,
1842 "pkix1explicit.AlgorithmIdentifier", HFILL }},
1843 { &hf_cmp_senderKID,
1844 { "senderKID", "cmp.senderKID",
1845 FT_BYTES, BASE_NONE, NULL, 0,
1846 "pkix1implicit.KeyIdentifier", HFILL }},
1848 { "recipKID", "cmp.recipKID",
1849 FT_BYTES, BASE_NONE, NULL, 0,
1850 "pkix1implicit.KeyIdentifier", HFILL }},
1851 { &hf_cmp_transactionID,
1852 { "transactionID", "cmp.transactionID",
1853 FT_BYTES, BASE_NONE, NULL, 0,
1854 "cmp.OCTET_STRING", HFILL }},
1855 { &hf_cmp_senderNonce,
1856 { "senderNonce", "cmp.senderNonce",
1857 FT_BYTES, BASE_NONE, NULL, 0,
1858 "cmp.OCTET_STRING", HFILL }},
1859 { &hf_cmp_recipNonce,
1860 { "recipNonce", "cmp.recipNonce",
1861 FT_BYTES, BASE_NONE, NULL, 0,
1862 "cmp.OCTET_STRING", HFILL }},
1864 { "freeText", "cmp.freeText",
1865 FT_UINT32, BASE_DEC, NULL, 0,
1866 "cmp.PKIFreeText", HFILL }},
1867 { &hf_cmp_generalInfo,
1868 { "generalInfo", "cmp.generalInfo",
1869 FT_UINT32, BASE_DEC, NULL, 0,
1870 "cmp.SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue", HFILL }},
1871 { &hf_cmp_generalInfo_item,
1872 { "InfoTypeAndValue", "cmp.InfoTypeAndValue",
1873 FT_NONE, BASE_NONE, NULL, 0,
1874 "cmp.InfoTypeAndValue", HFILL }},
1875 { &hf_cmp_PKIFreeText_item,
1876 { "PKIFreeText item", "cmp.PKIFreeText_item",
1877 FT_STRING, BASE_NONE, NULL, 0,
1878 "cmp.UTF8String", HFILL }},
1881 FT_UINT32, BASE_DEC, NULL, 0,
1882 "crmf.CertReqMessages", HFILL }},
1885 FT_NONE, BASE_NONE, NULL, 0,
1886 "cmp.CertRepMessage", HFILL }},
1889 FT_UINT32, BASE_DEC, NULL, 0,
1890 "crmf.CertReqMessages", HFILL }},
1893 FT_NONE, BASE_NONE, NULL, 0,
1894 "cmp.CertRepMessage", HFILL }},
1896 { "p10cr", "cmp.p10cr",
1897 FT_NONE, BASE_NONE, NULL, 0,
1898 "cmp.NULL", HFILL }},
1900 { "popdecc", "cmp.popdecc",
1901 FT_UINT32, BASE_DEC, NULL, 0,
1902 "cmp.POPODecKeyChallContent", HFILL }},
1904 { "popdecr", "cmp.popdecr",
1905 FT_UINT32, BASE_DEC, NULL, 0,
1906 "cmp.POPODecKeyRespContent", HFILL }},
1909 FT_UINT32, BASE_DEC, NULL, 0,
1910 "crmf.CertReqMessages", HFILL }},
1913 FT_NONE, BASE_NONE, NULL, 0,
1914 "cmp.CertRepMessage", HFILL }},
1917 FT_UINT32, BASE_DEC, NULL, 0,
1918 "crmf.CertReqMessages", HFILL }},
1921 FT_NONE, BASE_NONE, NULL, 0,
1922 "cmp.KeyRecRepContent", HFILL }},
1925 FT_UINT32, BASE_DEC, NULL, 0,
1926 "cmp.RevReqContent", HFILL }},
1929 FT_NONE, BASE_NONE, NULL, 0,
1930 "cmp.RevRepContent", HFILL }},
1933 FT_UINT32, BASE_DEC, NULL, 0,
1934 "crmf.CertReqMessages", HFILL }},
1937 FT_NONE, BASE_NONE, NULL, 0,
1938 "cmp.CertRepMessage", HFILL }},
1940 { "ckuann", "cmp.ckuann",
1941 FT_NONE, BASE_NONE, NULL, 0,
1942 "cmp.CAKeyUpdAnnContent", HFILL }},
1944 { "cann", "cmp.cann",
1945 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
1946 "cmp.CertAnnContent", HFILL }},
1948 { "rann", "cmp.rann",
1949 FT_NONE, BASE_NONE, NULL, 0,
1950 "cmp.RevAnnContent", HFILL }},
1952 { "crlann", "cmp.crlann",
1953 FT_UINT32, BASE_DEC, NULL, 0,
1954 "cmp.CRLAnnContent", HFILL }},
1956 { "pkiconf", "cmp.pkiconf",
1957 FT_NONE, BASE_NONE, NULL, 0,
1958 "cmp.PKIConfirmContent", HFILL }},
1960 { "nested", "cmp.nested",
1961 FT_UINT32, BASE_DEC, NULL, 0,
1962 "cmp.NestedMessageContent", HFILL }},
1964 { "genm", "cmp.genm",
1965 FT_UINT32, BASE_DEC, NULL, 0,
1966 "cmp.GenMsgContent", HFILL }},
1968 { "genp", "cmp.genp",
1969 FT_UINT32, BASE_DEC, NULL, 0,
1970 "cmp.GenRepContent", HFILL }},
1972 { "error", "cmp.error",
1973 FT_NONE, BASE_NONE, NULL, 0,
1974 "cmp.ErrorMsgContent", HFILL }},
1976 { "certConf", "cmp.certConf",
1977 FT_UINT32, BASE_DEC, NULL, 0,
1978 "cmp.CertConfirmContent", HFILL }},
1980 { "pollReq", "cmp.pollReq",
1981 FT_UINT32, BASE_DEC, NULL, 0,
1982 "cmp.PollReqContent", HFILL }},
1984 { "pollRep", "cmp.pollRep",
1985 FT_UINT32, BASE_DEC, NULL, 0,
1986 "cmp.PollRepContent", HFILL }},
1988 { "salt", "cmp.salt",
1989 FT_BYTES, BASE_NONE, NULL, 0,
1990 "cmp.OCTET_STRING", HFILL }},
1993 FT_NONE, BASE_NONE, NULL, 0,
1994 "pkix1explicit.AlgorithmIdentifier", HFILL }},
1995 { &hf_cmp_iterationCount,
1996 { "iterationCount", "cmp.iterationCount",
1997 FT_INT32, BASE_DEC, NULL, 0,
1998 "cmp.INTEGER", HFILL }},
2001 FT_NONE, BASE_NONE, NULL, 0,
2002 "pkix1explicit.AlgorithmIdentifier", HFILL }},
2003 { &hf_cmp_pkistatus,
2004 { "status", "cmp.status",
2005 FT_INT32, BASE_DEC, VALS(cmp_PKIStatus_vals), 0,
2006 "cmp.PKIStatus", HFILL }},
2007 { &hf_cmp_statusString,
2008 { "statusString", "cmp.statusString",
2009 FT_UINT32, BASE_DEC, NULL, 0,
2010 "cmp.PKIFreeText", HFILL }},
2012 { "failInfo", "cmp.failInfo",
2013 FT_BYTES, BASE_NONE, NULL, 0,
2014 "cmp.PKIFailureInfo", HFILL }},
2016 { "hashAlg", "cmp.hashAlg",
2017 FT_NONE, BASE_NONE, NULL, 0,
2018 "pkix1explicit.AlgorithmIdentifier", HFILL }},
2020 { "certId", "cmp.certId",
2021 FT_NONE, BASE_NONE, NULL, 0,
2022 "crmf.CertId", HFILL }},
2024 { "hashVal", "cmp.hashVal",
2025 FT_BYTES, BASE_NONE, NULL, 0,
2026 "cmp.BIT_STRING", HFILL }},
2027 { &hf_cmp_POPODecKeyChallContent_item,
2028 { "Challenge", "cmp.Challenge",
2029 FT_NONE, BASE_NONE, NULL, 0,
2030 "cmp.Challenge", HFILL }},
2032 { "witness", "cmp.witness",
2033 FT_BYTES, BASE_NONE, NULL, 0,
2034 "cmp.OCTET_STRING", HFILL }},
2035 { &hf_cmp_challenge,
2036 { "challenge", "cmp.challenge",
2037 FT_BYTES, BASE_NONE, NULL, 0,
2038 "cmp.OCTET_STRING", HFILL }},
2039 { &hf_cmp_POPODecKeyRespContent_item,
2040 { "POPODecKeyRespContent item", "cmp.POPODecKeyRespContent_item",
2041 FT_INT32, BASE_DEC, NULL, 0,
2042 "cmp.INTEGER", HFILL }},
2044 { "caPubs", "cmp.caPubs",
2045 FT_UINT32, BASE_DEC, NULL, 0,
2046 "cmp.SEQUENCE_SIZE_1_MAX_OF_CMPCertificate", HFILL }},
2047 { &hf_cmp_caPubs_item,
2048 { "CMPCertificate", "cmp.CMPCertificate",
2049 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2050 "cmp.CMPCertificate", HFILL }},
2052 { "response", "cmp.response",
2053 FT_UINT32, BASE_DEC, NULL, 0,
2054 "cmp.SEQUENCE_OF_CertResponse", HFILL }},
2055 { &hf_cmp_response_item,
2056 { "CertResponse", "cmp.CertResponse",
2057 FT_NONE, BASE_NONE, NULL, 0,
2058 "cmp.CertResponse", HFILL }},
2059 { &hf_cmp_certReqId,
2060 { "certReqId", "cmp.certReqId",
2061 FT_INT32, BASE_DEC, NULL, 0,
2062 "cmp.INTEGER", HFILL }},
2063 { &hf_cmp_pkistatusinf,
2064 { "status", "cmp.status",
2065 FT_NONE, BASE_NONE, NULL, 0,
2066 "cmp.PKIStatusInfo", HFILL }},
2067 { &hf_cmp_certifiedKeyPair,
2068 { "certifiedKeyPair", "cmp.certifiedKeyPair",
2069 FT_NONE, BASE_NONE, NULL, 0,
2070 "cmp.CertifiedKeyPair", HFILL }},
2072 { "rspInfo", "cmp.rspInfo",
2073 FT_BYTES, BASE_NONE, NULL, 0,
2074 "cmp.OCTET_STRING", HFILL }},
2075 { &hf_cmp_certOrEncCert,
2076 { "certOrEncCert", "cmp.certOrEncCert",
2077 FT_UINT32, BASE_DEC, VALS(cmp_CertOrEncCert_vals), 0,
2078 "cmp.CertOrEncCert", HFILL }},
2079 { &hf_cmp_privateKey,
2080 { "privateKey", "cmp.privateKey",
2081 FT_NONE, BASE_NONE, NULL, 0,
2082 "crmf.EncryptedValue", HFILL }},
2083 { &hf_cmp_publicationInfo,
2084 { "publicationInfo", "cmp.publicationInfo",
2085 FT_NONE, BASE_NONE, NULL, 0,
2086 "crmf.PKIPublicationInfo", HFILL }},
2087 { &hf_cmp_certificate,
2088 { "certificate", "cmp.certificate",
2089 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2090 "cmp.CMPCertificate", HFILL }},
2091 { &hf_cmp_encryptedCert,
2092 { "encryptedCert", "cmp.encryptedCert",
2093 FT_NONE, BASE_NONE, NULL, 0,
2094 "crmf.EncryptedValue", HFILL }},
2095 { &hf_cmp_newSigCert,
2096 { "newSigCert", "cmp.newSigCert",
2097 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2098 "cmp.CMPCertificate", HFILL }},
2100 { "caCerts", "cmp.caCerts",
2101 FT_UINT32, BASE_DEC, NULL, 0,
2102 "cmp.SEQUENCE_SIZE_1_MAX_OF_CMPCertificate", HFILL }},
2103 { &hf_cmp_caCerts_item,
2104 { "CMPCertificate", "cmp.CMPCertificate",
2105 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2106 "cmp.CMPCertificate", HFILL }},
2107 { &hf_cmp_keyPairHist,
2108 { "keyPairHist", "cmp.keyPairHist",
2109 FT_UINT32, BASE_DEC, NULL, 0,
2110 "cmp.SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair", HFILL }},
2111 { &hf_cmp_keyPairHist_item,
2112 { "CertifiedKeyPair", "cmp.CertifiedKeyPair",
2113 FT_NONE, BASE_NONE, NULL, 0,
2114 "cmp.CertifiedKeyPair", HFILL }},
2115 { &hf_cmp_RevReqContent_item,
2116 { "RevDetails", "cmp.RevDetails",
2117 FT_NONE, BASE_NONE, NULL, 0,
2118 "cmp.RevDetails", HFILL }},
2119 { &hf_cmp_certDetails,
2120 { "certDetails", "cmp.certDetails",
2121 FT_NONE, BASE_NONE, NULL, 0,
2122 "crmf.CertTemplate", HFILL }},
2123 { &hf_cmp_crlEntryDetails,
2124 { "crlEntryDetails", "cmp.crlEntryDetails",
2125 FT_UINT32, BASE_DEC, NULL, 0,
2126 "pkix1explicit.Extensions", HFILL }},
2127 { &hf_cmp_rvrpcnt_status,
2128 { "status", "cmp.status",
2129 FT_UINT32, BASE_DEC, NULL, 0,
2130 "cmp.SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo", HFILL }},
2131 { &hf_cmp_rvrpcnt_status_item,
2132 { "PKIStatusInfo", "cmp.PKIStatusInfo",
2133 FT_NONE, BASE_NONE, NULL, 0,
2134 "cmp.PKIStatusInfo", HFILL }},
2136 { "revCerts", "cmp.revCerts",
2137 FT_UINT32, BASE_DEC, NULL, 0,
2138 "cmp.SEQUENCE_SIZE_1_MAX_OF_CertId", HFILL }},
2139 { &hf_cmp_revCerts_item,
2140 { "CertId", "cmp.CertId",
2141 FT_NONE, BASE_NONE, NULL, 0,
2142 "crmf.CertId", HFILL }},
2144 { "crls", "cmp.crls",
2145 FT_UINT32, BASE_DEC, NULL, 0,
2146 "cmp.SEQUENCE_SIZE_1_MAX_OF_CertificateList", HFILL }},
2147 { &hf_cmp_crls_item,
2148 { "CertificateList", "cmp.CertificateList",
2149 FT_NONE, BASE_NONE, NULL, 0,
2150 "pkix1explicit.CertificateList", HFILL }},
2151 { &hf_cmp_oldWithNew,
2152 { "oldWithNew", "cmp.oldWithNew",
2153 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2154 "cmp.CMPCertificate", HFILL }},
2155 { &hf_cmp_newWithOld,
2156 { "newWithOld", "cmp.newWithOld",
2157 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2158 "cmp.CMPCertificate", HFILL }},
2159 { &hf_cmp_newWithNew,
2160 { "newWithNew", "cmp.newWithNew",
2161 FT_UINT32, BASE_DEC, VALS(cmp_CMPCertificate_vals), 0,
2162 "cmp.CMPCertificate", HFILL }},
2163 { &hf_cmp_willBeRevokedAt,
2164 { "willBeRevokedAt", "cmp.willBeRevokedAt",
2165 FT_STRING, BASE_NONE, NULL, 0,
2166 "cmp.GeneralizedTime", HFILL }},
2167 { &hf_cmp_badSinceDate,
2168 { "badSinceDate", "cmp.badSinceDate",
2169 FT_STRING, BASE_NONE, NULL, 0,
2170 "cmp.GeneralizedTime", HFILL }},
2171 { &hf_cmp_crlDetails,
2172 { "crlDetails", "cmp.crlDetails",
2173 FT_UINT32, BASE_DEC, NULL, 0,
2174 "pkix1explicit.Extensions", HFILL }},
2175 { &hf_cmp_CRLAnnContent_item,
2176 { "CertificateList", "cmp.CertificateList",
2177 FT_NONE, BASE_NONE, NULL, 0,
2178 "pkix1explicit.CertificateList", HFILL }},
2179 { &hf_cmp_CertConfirmContent_item,
2180 { "CertStatus", "cmp.CertStatus",
2181 FT_NONE, BASE_NONE, NULL, 0,
2182 "cmp.CertStatus", HFILL }},
2184 { "certHash", "cmp.certHash",
2185 FT_BYTES, BASE_NONE, NULL, 0,
2186 "cmp.OCTET_STRING", HFILL }},
2187 { &hf_cmp_statusInfo,
2188 { "statusInfo", "cmp.statusInfo",
2189 FT_NONE, BASE_NONE, NULL, 0,
2190 "cmp.PKIStatusInfo", HFILL }},
2192 { "infoType", "cmp.infoType",
2193 FT_OID, BASE_NONE, NULL, 0,
2194 "cmp.T_infoType", HFILL }},
2195 { &hf_cmp_infoValue,
2196 { "infoValue", "cmp.infoValue",
2197 FT_NONE, BASE_NONE, NULL, 0,
2198 "cmp.T_infoValue", HFILL }},
2199 { &hf_cmp_SignKeyPairTypesValue_item,
2200 { "AlgorithmIdentifier", "cmp.AlgorithmIdentifier",
2201 FT_NONE, BASE_NONE, NULL, 0,
2202 "pkix1explicit.AlgorithmIdentifier", HFILL }},
2203 { &hf_cmp_EncKeyPairTypesValue_item,
2204 { "AlgorithmIdentifier", "cmp.AlgorithmIdentifier",
2205 FT_NONE, BASE_NONE, NULL, 0,
2206 "pkix1explicit.AlgorithmIdentifier", HFILL }},
2207 { &hf_cmp_UnsupportedOIDsValue_item,
2208 { "UnsupportedOIDsValue item", "cmp.UnsupportedOIDsValue_item",
2209 FT_OID, BASE_NONE, NULL, 0,
2210 "cmp.OBJECT_IDENTIFIER", HFILL }},
2211 { &hf_cmp_SuppLangTagsValue_item,
2212 { "SuppLangTagsValue item", "cmp.SuppLangTagsValue_item",
2213 FT_STRING, BASE_NONE, NULL, 0,
2214 "cmp.UTF8String", HFILL }},
2215 { &hf_cmp_GenMsgContent_item,
2216 { "InfoTypeAndValue", "cmp.InfoTypeAndValue",
2217 FT_NONE, BASE_NONE, NULL, 0,
2218 "cmp.InfoTypeAndValue", HFILL }},
2219 { &hf_cmp_GenRepContent_item,
2220 { "InfoTypeAndValue", "cmp.InfoTypeAndValue",
2221 FT_NONE, BASE_NONE, NULL, 0,
2222 "cmp.InfoTypeAndValue", HFILL }},
2223 { &hf_cmp_pKIStatusInfo,
2224 { "pKIStatusInfo", "cmp.pKIStatusInfo",
2225 FT_NONE, BASE_NONE, NULL, 0,
2226 "cmp.PKIStatusInfo", HFILL }},
2227 { &hf_cmp_errorCode,
2228 { "errorCode", "cmp.errorCode",
2229 FT_INT32, BASE_DEC, NULL, 0,
2230 "cmp.INTEGER", HFILL }},
2231 { &hf_cmp_errorDetails,
2232 { "errorDetails", "cmp.errorDetails",
2233 FT_UINT32, BASE_DEC, NULL, 0,
2234 "cmp.PKIFreeText", HFILL }},
2235 { &hf_cmp_PollReqContent_item,
2236 { "PollReqContent item", "cmp.PollReqContent_item",
2237 FT_NONE, BASE_NONE, NULL, 0,
2238 "cmp.PollReqContent_item", HFILL }},
2239 { &hf_cmp_PollRepContent_item,
2240 { "PollRepContent item", "cmp.PollRepContent_item",
2241 FT_NONE, BASE_NONE, NULL, 0,
2242 "cmp.PollRepContent_item", HFILL }},
2243 { &hf_cmp_checkAfter,
2244 { "checkAfter", "cmp.checkAfter",
2245 FT_INT32, BASE_DEC, NULL, 0,
2246 "cmp.INTEGER", HFILL }},
2248 { "reason", "cmp.reason",
2249 FT_UINT32, BASE_DEC, NULL, 0,
2250 "cmp.PKIFreeText", HFILL }},
2251 { &hf_cmp_PKIFailureInfo_badAlg,
2252 { "badAlg", "cmp.badAlg",
2253 FT_BOOLEAN, 8, NULL, 0x80,
2255 { &hf_cmp_PKIFailureInfo_badMessageCheck,
2256 { "badMessageCheck", "cmp.badMessageCheck",
2257 FT_BOOLEAN, 8, NULL, 0x40,
2259 { &hf_cmp_PKIFailureInfo_badRequest,
2260 { "badRequest", "cmp.badRequest",
2261 FT_BOOLEAN, 8, NULL, 0x20,
2263 { &hf_cmp_PKIFailureInfo_badTime,
2264 { "badTime", "cmp.badTime",
2265 FT_BOOLEAN, 8, NULL, 0x10,
2267 { &hf_cmp_PKIFailureInfo_badCertId,
2268 { "badCertId", "cmp.badCertId",
2269 FT_BOOLEAN, 8, NULL, 0x08,
2271 { &hf_cmp_PKIFailureInfo_badDataFormat,
2272 { "badDataFormat", "cmp.badDataFormat",
2273 FT_BOOLEAN, 8, NULL, 0x04,
2275 { &hf_cmp_PKIFailureInfo_wrongAuthority,
2276 { "wrongAuthority", "cmp.wrongAuthority",
2277 FT_BOOLEAN, 8, NULL, 0x02,
2279 { &hf_cmp_PKIFailureInfo_incorrectData,
2280 { "incorrectData", "cmp.incorrectData",
2281 FT_BOOLEAN, 8, NULL, 0x01,
2283 { &hf_cmp_PKIFailureInfo_missingTimeStamp,
2284 { "missingTimeStamp", "cmp.missingTimeStamp",
2285 FT_BOOLEAN, 8, NULL, 0x80,
2287 { &hf_cmp_PKIFailureInfo_badPOP,
2288 { "badPOP", "cmp.badPOP",
2289 FT_BOOLEAN, 8, NULL, 0x40,
2291 { &hf_cmp_PKIFailureInfo_certRevoked,
2292 { "certRevoked", "cmp.certRevoked",
2293 FT_BOOLEAN, 8, NULL, 0x20,
2295 { &hf_cmp_PKIFailureInfo_certConfirmed,
2296 { "certConfirmed", "cmp.certConfirmed",
2297 FT_BOOLEAN, 8, NULL, 0x10,
2299 { &hf_cmp_PKIFailureInfo_wrongIntegrity,
2300 { "wrongIntegrity", "cmp.wrongIntegrity",
2301 FT_BOOLEAN, 8, NULL, 0x08,
2303 { &hf_cmp_PKIFailureInfo_badRecipientNonce,
2304 { "badRecipientNonce", "cmp.badRecipientNonce",
2305 FT_BOOLEAN, 8, NULL, 0x04,
2307 { &hf_cmp_PKIFailureInfo_timeNotAvailable,
2308 { "timeNotAvailable", "cmp.timeNotAvailable",
2309 FT_BOOLEAN, 8, NULL, 0x02,
2311 { &hf_cmp_PKIFailureInfo_unacceptedPolicy,
2312 { "unacceptedPolicy", "cmp.unacceptedPolicy",
2313 FT_BOOLEAN, 8, NULL, 0x01,
2315 { &hf_cmp_PKIFailureInfo_unacceptedExtension,
2316 { "unacceptedExtension", "cmp.unacceptedExtension",
2317 FT_BOOLEAN, 8, NULL, 0x80,
2319 { &hf_cmp_PKIFailureInfo_addInfoNotAvailable,
2320 { "addInfoNotAvailable", "cmp.addInfoNotAvailable",
2321 FT_BOOLEAN, 8, NULL, 0x40,
2323 { &hf_cmp_PKIFailureInfo_badSenderNonce,
2324 { "badSenderNonce", "cmp.badSenderNonce",
2325 FT_BOOLEAN, 8, NULL, 0x20,
2327 { &hf_cmp_PKIFailureInfo_badCertTemplate,
2328 { "badCertTemplate", "cmp.badCertTemplate",
2329 FT_BOOLEAN, 8, NULL, 0x10,
2331 { &hf_cmp_PKIFailureInfo_signerNotTrusted,
2332 { "signerNotTrusted", "cmp.signerNotTrusted",
2333 FT_BOOLEAN, 8, NULL, 0x08,
2335 { &hf_cmp_PKIFailureInfo_transactionIdInUse,
2336 { "transactionIdInUse", "cmp.transactionIdInUse",
2337 FT_BOOLEAN, 8, NULL, 0x04,
2339 { &hf_cmp_PKIFailureInfo_unsupportedVersion,
2340 { "unsupportedVersion", "cmp.unsupportedVersion",
2341 FT_BOOLEAN, 8, NULL, 0x02,
2343 { &hf_cmp_PKIFailureInfo_notAuthorized,
2344 { "notAuthorized", "cmp.notAuthorized",
2345 FT_BOOLEAN, 8, NULL, 0x01,
2347 { &hf_cmp_PKIFailureInfo_systemUnavail,
2348 { "systemUnavail", "cmp.systemUnavail",
2349 FT_BOOLEAN, 8, NULL, 0x80,
2351 { &hf_cmp_PKIFailureInfo_systemFailure,
2352 { "systemFailure", "cmp.systemFailure",
2353 FT_BOOLEAN, 8, NULL, 0x40,
2355 { &hf_cmp_PKIFailureInfo_duplicateCertReq,
2356 { "duplicateCertReq", "cmp.duplicateCertReq",
2357 FT_BOOLEAN, 8, NULL, 0x20,
2360 /*--- End of included file: packet-cmp-hfarr.c ---*/
2361 #line 352 "packet-cmp-template.c"
2364 /* List of subtrees */
2365 static gint *ett[] = {
2368 /*--- Included file: packet-cmp-ettarr.c ---*/
2369 #line 1 "packet-cmp-ettarr.c"
2370 &ett_cmp_CMPCertificate,
2371 &ett_cmp_PKIMessage,
2372 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CMPCertificate,
2373 &ett_cmp_PKIMessages,
2375 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_InfoTypeAndValue,
2376 &ett_cmp_PKIFreeText,
2378 &ett_cmp_ProtectedPart,
2379 &ett_cmp_PBMParameter,
2380 &ett_cmp_DHBMParameter,
2381 &ett_cmp_PKIFailureInfo,
2382 &ett_cmp_PKIStatusInfo,
2383 &ett_cmp_OOBCertHash,
2384 &ett_cmp_POPODecKeyChallContent,
2386 &ett_cmp_POPODecKeyRespContent,
2387 &ett_cmp_CertRepMessage,
2388 &ett_cmp_SEQUENCE_OF_CertResponse,
2389 &ett_cmp_CertResponse,
2390 &ett_cmp_CertifiedKeyPair,
2391 &ett_cmp_CertOrEncCert,
2392 &ett_cmp_KeyRecRepContent,
2393 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertifiedKeyPair,
2394 &ett_cmp_RevReqContent,
2395 &ett_cmp_RevDetails,
2396 &ett_cmp_RevRepContent,
2397 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_PKIStatusInfo,
2398 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertId,
2399 &ett_cmp_SEQUENCE_SIZE_1_MAX_OF_CertificateList,
2400 &ett_cmp_CAKeyUpdAnnContent,
2401 &ett_cmp_RevAnnContent,
2402 &ett_cmp_CRLAnnContent,
2403 &ett_cmp_CertConfirmContent,
2404 &ett_cmp_CertStatus,
2405 &ett_cmp_InfoTypeAndValue,
2406 &ett_cmp_SignKeyPairTypesValue,
2407 &ett_cmp_EncKeyPairTypesValue,
2408 &ett_cmp_UnsupportedOIDsValue,
2409 &ett_cmp_SuppLangTagsValue,
2410 &ett_cmp_GenMsgContent,
2411 &ett_cmp_GenRepContent,
2412 &ett_cmp_ErrorMsgContent,
2413 &ett_cmp_PollReqContent,
2414 &ett_cmp_PollReqContent_item,
2415 &ett_cmp_PollRepContent,
2416 &ett_cmp_PollRepContent_item,
2418 /*--- End of included file: packet-cmp-ettarr.c ---*/
2419 #line 358 "packet-cmp-template.c"
2421 module_t *cmp_module;
2423 /* Register protocol */
2424 proto_cmp = proto_register_protocol(PNAME, PSNAME, PFNAME);
2426 /* Register fields and subtrees */
2427 proto_register_field_array(proto_cmp, hf, array_length(hf));
2428 proto_register_subtree_array(ett, array_length(ett));
2430 cmp_module = prefs_register_protocol(proto_cmp, proto_reg_handoff_cmp);
2431 prefs_register_bool_preference(cmp_module, "desegment",
2432 "Reassemble CMP-over-TCP messages spanning multiple TCP segments",
2433 "Whether the CMP-over-TCP dissector should reassemble messages spanning multiple TCP segments. "
2434 "To use this option, you must also enable \"Allow subdissectors to reassemble TCP streams\" in the TCP protocol settings.",
2437 prefs_register_uint_preference(cmp_module, "tcp_alternate_port",
2438 "Alternate TCP port",
2439 "Decode this TCP port\'s traffic as CMP. Set to \"0\" to disable.",
2441 &cmp_alternate_tcp_port);
2443 prefs_register_uint_preference(cmp_module, "http_alternate_port",
2444 "Alternate HTTP port",
2445 "Decode this TCP port\'s traffic as CMP-over-HTTP. Set to \"0\" to disable. "
2446 "Use this if the Content-Type is not set correctly.",
2448 &cmp_alternate_http_port);
2450 prefs_register_uint_preference(cmp_module, "tcp_style_http_alternate_port",
2451 "Alternate TCP-style-HTTP port",
2452 "Decode this TCP port\'s traffic as TCP-transport-style CMP-over-HTTP. Set to \"0\" to disable. "
2453 "Use this if the Content-Type is not set correctly.",
2455 &cmp_alternate_tcp_style_http_port);
2459 /*--- proto_reg_handoff_cmp -------------------------------------------*/
2460 void proto_reg_handoff_cmp(void) {
2461 static gboolean inited = FALSE;
2462 static dissector_handle_t cmp_http_handle;
2463 static dissector_handle_t cmp_tcp_style_http_handle;
2464 static dissector_handle_t cmp_tcp_handle;
2465 static guint cmp_alternate_tcp_port_prev = 0;
2466 static guint cmp_alternate_http_port_prev = 0;
2467 static guint cmp_alternate_tcp_style_http_port_prev = 0;
2470 cmp_http_handle = new_create_dissector_handle(dissect_cmp_http, proto_cmp);
2471 dissector_add_string("media_type", "application/pkixcmp", cmp_http_handle);
2472 dissector_add_string("media_type", "application/x-pkixcmp", cmp_http_handle);
2474 cmp_tcp_style_http_handle = new_create_dissector_handle(dissect_cmp_tcp_pdu, proto_cmp);
2475 dissector_add_string("media_type", "application/pkixcmp-poll", cmp_tcp_style_http_handle);
2476 dissector_add_string("media_type", "application/x-pkixcmp-poll", cmp_tcp_style_http_handle);
2478 cmp_tcp_handle = new_create_dissector_handle(dissect_cmp_tcp, proto_cmp);
2479 dissector_add("tcp.port", TCP_PORT_CMP, cmp_tcp_handle);
2481 oid_add_from_string("Cryptlib-presence-check","1.3.6.1.4.1.3029.3.1.1");
2482 oid_add_from_string("Cryptlib-PKIBoot","1.3.6.1.4.1.3029.3.1.2");
2484 oid_add_from_string("HMAC MD5","1.3.6.1.5.5.8.1.1");
2485 oid_add_from_string("HMAC SHA-1","1.3.6.1.5.5.8.1.2");
2486 oid_add_from_string("HMAC TIGER","1.3.6.1.5.5.8.1.3");
2487 oid_add_from_string("HMAC RIPEMD-160","1.3.6.1.5.5.8.1.4");
2489 oid_add_from_string("sha256WithRSAEncryption","1.2.840.113549.1.1.11");
2492 /*--- Included file: packet-cmp-dis-tab.c ---*/
2493 #line 1 "packet-cmp-dis-tab.c"
2494 register_ber_oid_dissector("1.2.840.113533.7.66.13", dissect_PBMParameter_PDU, proto_cmp, "id-PasswordBasedMac");
2495 register_ber_oid_dissector("1.2.640.113533.7.66.30", dissect_DHBMParameter_PDU, proto_cmp, "id-DHBasedMac");
2496 register_ber_oid_dissector("1.3.6.1.5.5.7.4.1", dissect_CAProtEncCertValue_PDU, proto_cmp, "id-it-caProtEncCert");
2497 register_ber_oid_dissector("1.3.6.1.5.5.7.4.2", dissect_SignKeyPairTypesValue_PDU, proto_cmp, "id-it-signKeyPairTypes");
2498 register_ber_oid_dissector("1.3.6.1.5.5.7.4.3", dissect_EncKeyPairTypesValue_PDU, proto_cmp, "id-it-encKeyPairTypes");
2499 register_ber_oid_dissector("1.3.6.1.5.5.7.4.4", dissect_PreferredSymmAlgValue_PDU, proto_cmp, "id-it-preferredSymmAlg");
2500 register_ber_oid_dissector("1.3.6.1.5.5.7.4.5", dissect_CAKeyUpdateInfoValue_PDU, proto_cmp, "id-it-caKeyUpdateInfo");
2501 register_ber_oid_dissector("1.3.6.1.5.5.7.4.6", dissect_CurrentCRLValue_PDU, proto_cmp, "id-it-currentCRL");
2502 register_ber_oid_dissector("1.3.6.1.5.5.7.4.7", dissect_UnsupportedOIDsValue_PDU, proto_cmp, "id-it-unsupportedOIDs");
2503 register_ber_oid_dissector("1.3.6.1.5.5.7.4.10", dissect_KeyPairParamReqValue_PDU, proto_cmp, "id-it-keyPairParamReq");
2504 register_ber_oid_dissector("1.3.6.1.5.5.7.4.11", dissect_KeyPairParamRepValue_PDU, proto_cmp, "id-it-keyPairParamRep");
2505 register_ber_oid_dissector("1.3.6.1.5.5.7.4.12", dissect_RevPassphraseValue_PDU, proto_cmp, "id-it-revPassphrase");
2506 register_ber_oid_dissector("1.3.6.1.5.5.7.4.13", dissect_ImplicitConfirmValue_PDU, proto_cmp, "id-it-implicitConfirm");
2507 register_ber_oid_dissector("1.3.6.1.5.5.7.4.14", dissect_ConfirmWaitTimeValue_PDU, proto_cmp, "id-it-confirmWaitTime");
2508 register_ber_oid_dissector("1.3.6.1.5.5.7.4.15", dissect_OrigPKIMessageValue_PDU, proto_cmp, "id-it-origPKIMessage");
2509 register_ber_oid_dissector("1.3.6.1.5.5.7.4.16", dissect_SuppLangTagsValue_PDU, proto_cmp, "id-it-suppLangTags");
2512 /*--- End of included file: packet-cmp-dis-tab.c ---*/
2513 #line 430 "packet-cmp-template.c"
2517 /* change alternate TCP port if changed in the preferences */
2518 if (cmp_alternate_tcp_port != cmp_alternate_tcp_port_prev) {
2519 if (cmp_alternate_tcp_port_prev != 0)
2520 dissector_delete("tcp.port", cmp_alternate_tcp_port_prev, cmp_tcp_handle);
2521 if (cmp_alternate_tcp_port != 0)
2522 dissector_add("tcp.port", cmp_alternate_tcp_port, cmp_tcp_handle);
2523 cmp_alternate_tcp_port_prev = cmp_alternate_tcp_port;
2526 /* change alternate HTTP port if changed in the preferences */
2527 if (cmp_alternate_http_port != cmp_alternate_http_port_prev) {
2528 if (cmp_alternate_http_port_prev != 0) {
2529 dissector_delete("tcp.port", cmp_alternate_http_port_prev, NULL);
2530 dissector_delete("http.port", cmp_alternate_http_port_prev, NULL);
2532 if (cmp_alternate_http_port != 0)
2533 http_dissector_add( cmp_alternate_http_port, cmp_http_handle);
2534 cmp_alternate_http_port_prev = cmp_alternate_http_port;
2537 /* change alternate TCP-style-HTTP port if changed in the preferences */
2538 if (cmp_alternate_tcp_style_http_port != cmp_alternate_tcp_style_http_port_prev) {
2539 if (cmp_alternate_tcp_style_http_port_prev != 0) {
2540 dissector_delete("tcp.port", cmp_alternate_tcp_style_http_port_prev, NULL);
2541 dissector_delete("http.port", cmp_alternate_tcp_style_http_port_prev, NULL);
2543 if (cmp_alternate_tcp_style_http_port != 0)
2544 http_dissector_add( cmp_alternate_tcp_style_http_port, cmp_tcp_style_http_handle);
2545 cmp_alternate_tcp_style_http_port_prev = cmp_alternate_tcp_style_http_port;