epan/dissectors/pidl/ C99 drsuapi
[wireshark-sm.git] / epan / dissectors / asn1 / pkinit / PKINIT.asn
blobdfe2138163fd34661818da3bde6964e67692a668
1 --NOTE: we have to accommodate BOTH existing users of early drafts, such as
2 --packetcable as well as new users once the protocol is standardized.
3 --
4 --This asn1 file is based on draft-ietf-cat-kerberos-pk-init-20.txt
5 --but has been modified to accommodate the Wireshark asn2wrs compiler
6 --and our environment
7 --
8 --new structures are uncommented and added on demand as they are required
9 --
10 --Copyright (C) The Internet Society (2004).  This document is subject
11 --to the rights, licenses and restrictions contained in BCP 78, and
12 --except as set forth therein, the authors retain all their rights.
15 --This document and the information contained herein are provided on an
16 --"AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
17 --OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET
18 --ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,
19 --INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE
20 --INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
21 --WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
24 KerberosV5-PK-INIT-SPEC {
25            iso(1) identified-organization(3) dod(6) internet(1)
26            security(5) kerberosV5(2) modules(4) pkinit(5) }
27 DEFINITIONS EXPLICIT TAGS ::=
28 BEGIN
31     IMPORTS
32     SubjectPublicKeyInfo, AlgorithmIdentifier, Name
33         FROM PKIX1Explicit88 { iso (1) identified-organization (3)
34             dod (6) internet (1) security (5) mechanisms (5)
35             pkix (7) id-mod (0) id-pkix1-explicit (18) }
37     KerberosTime, TYPED-DATA, PrincipalName, Realm, EncryptionKey
38         FROM KerberosV5Spec2 { iso(1) identified-organization(3)
39             dod(6) internet(1) security(5) kerberosV5(2) modules(4)
40             krb5spec2(2) } ;
42     ContentInfo, IssuerAndSerialNumber
43         FROM CryptographicMessageSyntax { iso(1) member-body(2)
44             us(840) rsadsi(113549) pkcs(1) pkcs-9(9) smime(16)
45             modules(0) cms(1) }
48 --    id-pkinit  OBJECT IDENTIFIER ::=
49 --      { iso (1) org (3) dod (6) internet (1) security (5)
50 --        kerberosv5 (2) pkinit (3) }
53 --    id-pkauthdata  OBJECT IDENTIFIER ::= { id-pkinit 1 }
54 --    id-pkdhkeydata OBJECT IDENTIFIER ::= { id-pkinit 2 }
55 --    id-pkrkeydata  OBJECT IDENTIFIER ::= { id-pkinit 3 }
56 --    id-pkekuoid    OBJECT IDENTIFIER ::= { id-pkinit 4 }
57 --    id-pkkdcekuoid OBJECT IDENTIFIER ::= { id-pkinit 5 }
60 --    pa-pk-as-req INTEGER ::=                 TBD
61 --    pa-pk-as-rep INTEGER ::=                 TBD
62 --    pa-pk-ocsp-req INTEGER ::=               TBD
63 --    pa-pk-ocsp-rep INTEGER ::=               TBD
66 --    ad-initial-verified-cas INTEGER ::=      TBD
69 --    td-dh-parameters INTEGER ::=             TBD
70 --    td-trusted-certifiers INTEGER ::=        104
71 --    td-certificate-index INTEGER ::=         105
74 id-pkinit-kdf  OBJECT IDENTIFIER ::= { id-pkinit 6 }
76 id-pkinit-kdf-ah-sha1 OBJECT IDENTIFIER
77     ::= { id-pkinit-kdf sha1(1) }
78     -- SP800-56A ASN.1 structured hash-based KDF using SHA-1
80 id-pkinit-kdf-ah-sha256 OBJECT IDENTIFIER
81     ::= { id-pkinit-kdf sha256(2) }
82     -- SP800-56A ASN.1 structured hash-based KDF using SHA-256
84 id-pkinit-kdf-ah-sha512 OBJECT IDENTIFIER
85     ::= { id-pkinit-kdf sha512(3) }
86     -- SP800-56A ASN.1 structured hash-based KDF using SHA-512
88 id-pkinit-kdf-ah-sha384 OBJECT IDENTIFIER
89     ::= { id-pkinit-kdf sha384(4) }
90     -- SP800-56A ASN.1 structured hash-based KDF using SHA-384
92 PA-PK-AS-REQ ::= SEQUENCE {
93     signedAuthPack          [0] ContentInfo,
94     trustedCertifiers       [1] SEQUENCE OF TrustedCA OPTIONAL,
95     kdcCert                 [2] IssuerAndSerialNumber OPTIONAL,
96     ...
100 TrustedCA ::= CHOICE {
101     caName                  [0] Name,
102     issuerAndSerial         [2] IssuerAndSerialNumber,
103     ...
106 DHNonce ::= OCTET STRING
108 -- RFC-8636 "PKINIT Algorithm Agility"
109 -- object identifier of a key-derivation function
110 KDFAlgorithmId ::= SEQUENCE {
111     kdf-id                  [0] OBJECT IDENTIFIER,
112     ...
115 AuthPack ::= SEQUENCE {
116     pkAuthenticator         [0] PKAuthenticator,
117     clientPublicValue       [1] SubjectPublicKeyInfo OPTIONAL,
118     supportedCMSTypes       [2] SEQUENCE OF AlgorithmIdentifier
119                                 OPTIONAL,
120     clientDHNonce           [3] DHNonce OPTIONAL,
121     -- supportedKDFs added by RFC-8636 "PKINIT Algorithm Agility"
122     supportedKDFs           [4] SEQUENCE OF KDFAlgorithmId OPTIONAL,
123     ...
127 PKAuthenticator ::= SEQUENCE {
128     cusec                   [0] INTEGER,
129     ctime                   [1] KerberosTime,
130     nonce                   [2] INTEGER (0..4294967295),
131     -- paChecksum              [3] Checksum, # changed during draft-ietf-cat-kerberos-pk-init* from Checksum to OCTET STRING OPTIONAL
132     paChecksum              [3] OCTET STRING OPTIONAL,
133     -- freshnessToken added by RFC-8070 "PKINIT Freshness Extension"
134     freshnessToken          [4] OCTET STRING OPTIONAL,
135     ...
139 --    TrustedCertifiers ::= SEQUENCE OF Name
142 --    CertificateIndex ::= IssuerAndSerialNumber
145 KRB5PrincipalName ::= SEQUENCE {
146     realm                   [0] Realm,
147     principalName           [1] PrincipalName
151 --    InitialVerifiedCAs ::= SEQUENCE OF SEQUENCE {
152 --        ca                      [0] Name,
153 --        validated               [1] BOOLEAN,
154 --        ...
155 --    }
158 PA-PK-AS-REP ::= CHOICE {
159    dhInfo                  [0] DHRepInfo,
160    -- Selected when Diffie-Hellman key exchange is
161    -- used.
162    encKeyPack              [1] ContentInfo,
163    -- RFC-4556 has this as "IMPLICIT OCTET STRING", with a comment
164    -- this "contains a CMS type ContentInfo encoded according to
165    -- [RFC3852]." Define it this way instead so that Wireshark can
166    -- properly dissect it.
167    ...
171 DHRepInfo ::= SEQUENCE {
172    dhSignedData            [0] ContentInfo,
173    -- RFC-4556 has this as "IMPLICIT OCTET STRING", with a comment
174    -- this "contains a CMS type ContentInfo encoded according to
175    -- [RFC3852]." Define it this way instead so that Wireshark can
176    -- properly dissect it.
177    serverDHNonce           [1] DHNonce OPTIONAL,
178    -- Present if and only if dhKeyExpiration is
179    -- present in the KDCDHKeyInfo.
180    kdf                     [2] KDFAlgorithmId OPTIONAL,
181    -- The KDF picked by the KDC.
182    -- (added by RFC-8636 "PKINIT Algorithm Agility")
183    ...
184    }
186 KDCDHKeyInfo ::= SEQUENCE {
187     subjectPublicKey        [0] BIT STRING,
188     nonce                   [1] INTEGER,
189     dhKeyExpiration         [2] KerberosTime OPTIONAL,
190     ...
194 --    ReplyKeyPack ::= SEQUENCE {
195 --        replyKey                [0] EncryptionKey,
196 --        nonce                   [1] INTEGER (0..4294967295),
197 --        ...
198 --    }
200 -- Windows compat glue --
202 PKAuthenticator-Win2k ::= SEQUENCE {
203         kdcName                 [0] PrincipalName,
204         kdcRealm                [1] Realm,
205         cusec                   [2] INTEGER (0..4294967295),
206         ctime                   [3] KerberosTime,
207         nonce                   [4] INTEGER (-2147483648..2147483647),
208         ...
211 PA-PK-AS-REQ-Win2k ::= SEQUENCE {
212         signed-auth-pack        [0] ContentInfo,
213         trusted-certifiers      [2] SEQUENCE OF TrustedCA OPTIONAL,
214         kdc-cert                [3] IMPLICIT OCTET STRING OPTIONAL,
215         encryption-cert         [4] IMPLICIT OCTET STRING OPTIONAL,
216         ...
219 PA-PK-AS-REP-Win2k ::= PA-PK-AS-REP