Have separate proto_construct_match_selected_string() and
[obnox/wireshark/wip.git] / asn1 / acse / acse.asn
1 -- ACSE definition from 
2 --   http://www.itu.int/ITU-T/asn1/database/itu-t/x/x227bis/1998/ACSE-1.html
3 -- and modified to pass through asn2wrs
4 --
5 --
6 -- Module ACSE-1 (X.227bis:09/1998)
7 ACSE-1 {joint-iso-itu-t association-control(2) modules(0) acse1(1) version1(1)}
8 --  ACSE-1 refers to ACSE version 1
9 DEFINITIONS ::=
10 BEGIN
11
12 IMPORTS
13   Name, RelativeDistinguishedName
14     FROM InformationFramework {joint-iso-itu-t ds(5) module(1)
15       informationFramework(1) 3};
16
17 --  The data types Name and RelativeDistinguishedName are imported from
18 --  ITU-T Rec. X.501 | ISO/IEC 9594-2.
19
20
21 -- Workaround for bug in asn2wrs in the .cnf file
22 -- to handle the lack of support for tagged assignments.
23 -- remove that workaround once asn2wrs learns how to handle
24 -- tagged assignments.
25 EXTERNAL  ::=  [UNIVERSAL 8] IMPLICIT SEQUENCE
26      {
27       direct-reference  OBJECT IDENTIFIER OPTIONAL,
28       indirect-reference  INTEGER OPTIONAL,
29       data-value-descriptor  ObjectDescriptor  OPTIONAL,
30       encoding  CHOICE
31                   {single-ASN1-type  [0] ANY,
32                    octet-aligned     [1] IMPLICIT OCTET STRING,
33                    arbitrary         [2] IMPLICIT BIT STRING}
34      }
35
36 --  object identifier assignments
37 acse-as-id OBJECT IDENTIFIER ::=
38   {joint-iso-itu-t association-control(2) abstract-syntax(1) apdus(0)
39    version1(1)}
40
41 --  may be used to reference the abstract syntax of the ACSE APDUs.
42 aCSE-id OBJECT IDENTIFIER ::=
43   {joint-iso-itu-t association-control(2) ase-id(3) acse-ase(1) version(1)}
44
45 --  may be used to identify the Association Control ASE.
46 --  top level CHOICE
47 ACSE-apdu ::= CHOICE {
48 --asn2wrs bug
49 --  aarq  AARQ-apdu,
50   aarq  [APPLICATION 0] IMPLICIT AARQ-apdu,
51 --asn2wrs bug
52 --  aare  AARE-apdu,
53   aare  [APPLICATION 1] IMPLICIT AARE-apdu,
54 --asn2wrs bug
55 --  rlrq  RLRQ-apdu,
56   rlrq  [APPLICATION 2] IMPLICIT RLRQ-apdu,
57 --asn2wrs bug
58 --  rlre  RLRE-apdu,
59   rlre  [APPLICATION 3] IMPLICIT RLRE-apdu,
60 --asn2wrs bug
61 --  abrt  ABRT-apdu,
62   abrt  [APPLICATION 4] IMPLICIT ABRT-apdu,
63   ...,
64   --  Extensions for higher level association FU
65 --asn2wrs bug
66 --  adt   A-DT-apdu,
67   adt   [APPLICATION 5] IMPLICIT A-DT-apdu,
68 --asn2wrs bug
69 --  acrq  ACRQ-apdu,
70   acrq  [APPLICATION 6] IMPLICIT ACRQ-apdu,
71 --asn2wrs bug
72 --  acrp  ACRP-apdu
73   acrp  [APPLICATION 7] IMPLICIT ACRP-apdu
74 }
75
76 AARQ-apdu ::= [APPLICATION 0] IMPLICIT SEQUENCE {
77   protocol-version
78     [0] IMPLICIT BIT STRING {version1(0)} DEFAULT {version1},
79   aSO-context-name                  [1]  ASO-context-name,
80   called-AP-title                   [2]  AP-title OPTIONAL,
81   called-AE-qualifier               [3]  AE-qualifier OPTIONAL,
82   called-AP-invocation-identifier   [4]  AP-invocation-identifier OPTIONAL,
83   called-AE-invocation-identifier   [5]  AE-invocation-identifier OPTIONAL,
84   calling-AP-title                  [6]  AP-title OPTIONAL,
85   calling-AE-qualifier              [7]  AE-qualifier OPTIONAL,
86   calling-AP-invocation-identifier  [8]  AP-invocation-identifier OPTIONAL,
87   calling-AE-invocation-identifier  [9]  AE-invocation-identifier OPTIONAL,
88   --  The following field shall not be present if only the Kernel is used.
89   sender-acse-requirements          [10] IMPLICIT ACSE-requirements OPTIONAL,
90   --  The following field shall only be present if the Authentication functional unit is selected.
91   mechanism-name                    [11] IMPLICIT Mechanism-name OPTIONAL,
92   --  The following field shall only be present if the Authentication functional unit is selected.
93   calling-authentication-value      [12] EXPLICIT Authentication-value OPTIONAL,
94   aSO-context-name-list
95     [13] IMPLICIT ASO-context-name-list OPTIONAL,
96   --  The above field shall only be present if the Application Context Negotiation functional unit is selected.
97   implementation-information        [29] IMPLICIT Implementation-data OPTIONAL,
98   ...,
99   --  Extensions for higher level association FU
100   p-context-definition-list         [14]  Syntactic-context-list OPTIONAL,
101   called-asoi-tag                   [15] IMPLICIT ASOI-tag OPTIONAL,
102   calling-asoi-tag                  [16] IMPLICIT ASOI-tag OPTIONAL,
103   --  End of extensions for higher level association FU
104 --  ...,
105   user-information                  [30] IMPLICIT Association-data OPTIONAL
106 }
107
108 AARE-apdu ::= [APPLICATION 1] IMPLICIT SEQUENCE {
109   protocol-version
110     [0] IMPLICIT BIT STRING {version1(0)} DEFAULT {version1},
111   aSO-context-name                     [1]  ASO-context-name,
112   result                               [2]  Associate-result,
113   result-source-diagnostic             [3]  Associate-source-diagnostic,
114   responding-AP-title                  [4]  AP-title OPTIONAL,
115   responding-AE-qualifier              [5]  AE-qualifier OPTIONAL,
116   responding-AP-invocation-identifier  [6]  AP-invocation-identifier OPTIONAL,
117   responding-AE-invocation-identifier  [7]  AE-invocation-identifier OPTIONAL,
118   --  The following field shall not be present if only the Kernel is used.
119   responder-acse-requirements          [8] IMPLICIT ACSE-requirements OPTIONAL,
120   --  The following field shall only be present if the Authentication functional unit is selected.
121   mechanism-name                       [9] IMPLICIT Mechanism-name OPTIONAL,
122   --  This following field shall only be present if the Authentication functional unit is selected.
123   responding-authentication-value
124     [10] EXPLICIT Authentication-value OPTIONAL,
125   aSO-context-name-list
126     [11] IMPLICIT ASO-context-name-list OPTIONAL,
127   --  The above field shall only be present if the Application Context Negotiation functional unit is selected.
128   implementation-information
129     [29] IMPLICIT Implementation-data OPTIONAL,
130   ...,
131   --  Extensions for higher level association FU
132   p-context-result-list
133     [12] IMPLICIT P-context-result-list OPTIONAL,
134   called-asoi-tag                      [13] IMPLICIT ASOI-tag OPTIONAL,
135   calling-asoi-tag                     [14] IMPLICIT ASOI-tag OPTIONAL,
136   --  End of extensions for higher level association FU
137 --  ...,
138   user-information                     [30] IMPLICIT Association-data OPTIONAL
139 }
140
141 RLRQ-apdu ::= [APPLICATION 2] IMPLICIT SEQUENCE {
142   reason              [0] IMPLICIT Release-request-reason OPTIONAL,
143   ...,
144   --  Extensions for higher level association FU
145   aso-qualifier       [13]  ASO-qualifier OPTIONAL,
146   asoi-identifier     [14] IMPLICIT ASOI-identifier OPTIONAL,
147   --  End of extensions for higher level association FU
148 --  ...,
149   user-information    [30] IMPLICIT Association-data OPTIONAL
150 }
151
152 RLRE-apdu ::= [APPLICATION 3] IMPLICIT SEQUENCE {
153   reason              [0] IMPLICIT Release-response-reason OPTIONAL,
154   ...,
155   --  Extensions for higher level association FU
156   aso-qualifier       [13]  ASO-qualifier OPTIONAL,
157   asoi-identifier     [14] IMPLICIT ASOI-identifier OPTIONAL,
158   --  End of extensions for higher level association FU
159 --  ...,
160   user-information    [30] IMPLICIT Association-data OPTIONAL
161 }
162
163 ABRT-apdu ::= [APPLICATION 4] IMPLICIT SEQUENCE {
164   abort-source        [0] IMPLICIT ABRT-source,
165   abort-diagnostic    [1] IMPLICIT ABRT-diagnostic OPTIONAL,
166   --  This field shall not be present if only the Kernel is used.
167   ...,
168   --  Extensions for higher level association FU
169   aso-qualifier       [13]  ASO-qualifier OPTIONAL,
170   asoi-identifier     [14] IMPLICIT ASOI-identifier OPTIONAL,
171   --  End of extensions for higher level association FU
172 --  ...,
173   user-information    [30] IMPLICIT Association-data OPTIONAL
174 }
175
176 A-DT-apdu ::= [APPLICATION 5] IMPLICIT SEQUENCE {
177   aso-qualifier    [0]  ASO-qualifier OPTIONAL,
178   asoi-identifier  [1] IMPLICIT ASOI-identifier OPTIONAL,
179   ...,
180 --  ...,
181   a-user-data      [30]  User-Data
182 }
183
184 ACRQ-apdu ::= [APPLICATION 6] IMPLICIT SEQUENCE {
185   aso-qualifier              [0]  ASO-qualifier OPTIONAL,
186   asoi-identifier            [1] IMPLICIT ASOI-identifier OPTIONAL,
187   aSO-context-name           [3] IMPLICIT ASO-context-name OPTIONAL,
188   aSO-context-name-list      [4] IMPLICIT ASO-context-name-list OPTIONAL,
189   p-context-definition-list  [5]  Syntactic-context-list OPTIONAL,
190   ...,
191 --  ...,
192   user-information           [30] IMPLICIT User-information OPTIONAL
193 }
194
195 ACRP-apdu ::= [APPLICATION 7] IMPLICIT SEQUENCE {
196   aso-qualifier          [0]  ASO-qualifier OPTIONAL,
197   asoi-identifier        [1] IMPLICIT ASOI-identifier OPTIONAL,
198   aSO-context-name       [3] IMPLICIT ASO-context-name-list OPTIONAL,
199   p-context-result-list  [4] IMPLICIT P-context-result-list OPTIONAL,
200   ...,
201 --  ...,
202   user-information       [30] IMPLICIT User-information OPTIONAL
203 }
204
205 ABRT-diagnostic ::= ENUMERATED {
206   no-reason-given(1), protocol-error(2),
207   authentication-mechanism-name-not-recognized(3),
208   authentication-mechanism-name-required(4), authentication-failure(5),
209   authentication-required(6), ...
210   }
211
212 ABRT-source ::= INTEGER {acse-service-user(0), acse-service-provider(1)
213 }(0..1, ...)
214
215 ACSE-requirements ::= BIT STRING {
216   authentication(0), aSO-context-negotiation(1), higher-level-association(2),
217   nested-association(3)}
218
219 Application-context-name ::= ASO-context-name
220
221 ASO-context-name ::= OBJECT IDENTIFIER
222
223 --  Application-entity title productions follow (not in alphabetical order).
224 AP-title ::= CHOICE {
225   ap-title-form1  AP-title-form1,
226   ap-title-form2  AP-title-form2,
227   ...,
228   ap-title-form3  AP-title-form3
229 }
230
231 AE-qualifier ::= ASO-qualifier
232
233 ASO-qualifier ::= CHOICE {
234   aso-qualifier-form1  ASO-qualifier-form1,
235   aso-qualifier-form2  ASO-qualifier-form2,
236   ...,
237   aso-qualifier-form3  ASO-qualifier-form3,
238 -- an alternative used by some systems from the days when ASO-qualifier 
239 -- was an ANY
240   aso-qualifier-form-any-octets  ASO-qualifier-form-octets 
241 }
242
243 --  When both AP-title and AE-qualifier data values are present in an AARQ or AARE APDU, both must
244 --  have the same form to allow the construction of an AE-title as discussed in itu-t Rec. X.665 |
245 --  ISO/IEC 9834-6
246 AP-title-form1 ::=
247   Name
248
249 --  The value assigned to AP-title-form1 is The Directory Name of an application-process title.
250 ASO-qualifier-form1 ::=
251   RelativeDistinguishedName
252
253 --  The value assigned to AE-qualifier-form1 is the relative distinguished name of a particular
254 --  application-entity of the application-process identified by AP-title-form1.
255 AP-title-form2 ::= OBJECT IDENTIFIER
256
257 ASO-qualifier-form2 ::= INTEGER
258
259 AP-title-form3 ::= PrintableString
260
261 ASO-qualifier-form3 ::= PrintableString
262
263 ASO-qualifier-form-octets ::= OCTET STRING
264
265 AE-title ::= CHOICE {
266   ae-title-form1  AE-title-form1,
267   ae-title-form2  AE-title-form2,
268   ...
269 }
270
271 --  As defined in ITU-T Rec. X.650 | ISO/IEC 7498-3, an application-entity title is composed of an application process
272 --  title and an application-entity qualifier. The ACSE protocol provides for the transfer of an application-entity title
273 --  value by the transfer of its component values. However, the following data type is provided for International
274 --  Standards that reference a single syntactic structure for AE titles.
275 AE-title-form1 ::=
276   Name
277
278 --  For access to The Directory (see ITU-T Rec. X.500 series | ISO/IEC 9594), an AE title has AE-title-form1. This value
279 --  can be constructed from AP-title-form1 and AE-qualifier-form1 values contained in an AARQ or AARE APDU.
280 --  A discussion of forming an AE-title-form1 from AP-title-form1 and AE-qualifier form1 may be found in itu-t
281 --  Rec X.665 | ISO/IEC 9834-6.
282 AE-title-form2 ::= OBJECT IDENTIFIER
283
284 --  A discussion of forming an AE-title-form2 from AP-title-form2 and AE-qualifier-form2 may be found in
285 --  itu-t Rec. X.665 | ISO/IEC 9834-6.
286 AE-invocation-identifier ::= INTEGER
287
288 AP-invocation-identifier ::= INTEGER
289
290 ASOI-identifier ::= INTEGER(1..128, ...)
291
292 ASOI-tag ::=
293   SEQUENCE SIZE (0..7, ...) OF
294     SEQUENCE {qualifier   [0]  ASO-qualifier OPTIONAL,
295               identifier  [1]  ASOI-identifier OPTIONAL}
296
297 --  End of Application-entity title productions
298 ASO-context-name-list ::= SEQUENCE OF ASO-context-name
299
300 Syntactic-context-list ::= CHOICE {
301   context-list          [0]  Context-list,
302   default-contact-list  [1]  Default-Context-List
303 }
304
305 Context-list ::=
306   SEQUENCE OF
307     SEQUENCE {pci                Presentation-context-identifier,
308               abstract-syntax    Abstract-syntax-name,
309 -- bug in asn2wrs
310 --              transfer-syntaxes  SEQUENCE OF Transfer-syntax-name}
311               transfer-syntaxes  SEQUENCE OF TransferSyntaxName}
312
313 Default-Context-List ::=
314   SEQUENCE OF
315     SEQUENCE {abstract-syntax-name  [0] IMPLICIT Abstract-syntax-name OPTIONAL,
316 -- bug in asn2wrs
317 --              transfer-syntax-name  [1] IMPLICIT Transfer-syntax-name
318               transfer-syntax-name  [1] IMPLICIT TransferSyntaxName
319     }
320
321 Abstract-syntax-name ::= OBJECT IDENTIFIER
322
323 P-context-result-list ::=
324   SEQUENCE OF
325     SEQUENCE {result                [0] IMPLICIT Result,
326               concrete-syntax-name  [1] IMPLICIT Concrete-syntax-name OPTIONAL,
327               provider-reason
328                 [2] IMPLICIT INTEGER {reason-not-specified(0),
329                                       abstract-syntax-not-supported(1),
330                                       proposed-transfer-syntaxes-not-supported(2),
331                                       local-limit-on-DCS-exceeded(3)} OPTIONAL
332     }
333
334 Result ::= INTEGER {acceptance(0), user-rejection(1), provider-rejection(2)}
335
336 --bug in asn2wrs
337 --Concrete-syntax-name ::= Transfer-syntax-name
338 Concrete-syntax-name ::= TransferSyntaxName
339
340 --bug in asn2wrs
341 --Transfer-syntax-name ::= OBJECT IDENTIFIER
342 TransferSyntaxName ::= OBJECT IDENTIFIER
343
344 Associate-result ::= INTEGER {
345   accepted(0), rejected-permanent(1), rejected-transient(2)}(0..2, ...)
346
347 Associate-source-diagnostic ::= CHOICE {
348   acse-service-user
349     [1]  INTEGER {null(0), no-reason-given(1),
350                   application-context-name-not-supported(2),
351                   calling-AP-title-not-recognized(3),
352                   calling-AP-invocation-identifier-not-recognized(4),
353                   calling-AE-qualifier-not-recognized(5),
354                   calling-AE-invocation-identifier-not-recognized(6),
355                   called-AP-title-not-recognized(7),
356                   called-AP-invocation-identifier-not-recognized(8),
357                   called-AE-qualifier-not-recognized(9),
358                   called-AE-invocation-identifier-not-recognized(10),
359                   authentication-mechanism-name-not-recognized(11),
360                   authentication-mechanism-name-required(12),
361                   authentication-failure(13), authentication-required(14)}
362                                                                     (0..14, ...),
363   acse-service-provider
364     [2]  INTEGER {null(0), no-reason-given(1), no-common-acse-version(2)}
365                                                                     (0..2, ...)
366 }
367
368 User-information ::= Association-data
369
370 Association-data ::= SEQUENCE OF EXTERNAL
371
372 Simply-encoded-data ::= OCTET STRING
373
374 User-Data ::= CHOICE {
375   user-information     User-information,
376   simply-encoded-data  Simply-encoded-data,
377   fully-encoded-data   [0]  PDV-list
378 }
379
380 --  see ITU-T Rec. X.226 | ISO/IEC 8823-1.
381 PDV-list ::= SEQUENCE {
382 --bug in asn2wrs
383 --  transfer-syntax-name             Transfer-syntax-name OPTIONAL,
384   transfer-syntax-name             TransferSyntaxName OPTIONAL,
385   presentation-context-identifier  Presentation-context-identifier,
386   presentation-data-values
387     CHOICE {simple-ASN1-type
388               [0]  ANY
389                      (CONSTRAINED BY {
390                         
391                         --  Type corresponding to presentation context identifier
392                         }),
393             octet-aligned     [1] IMPLICIT OCTET STRING,
394             arbitrary         [2] IMPLICIT BIT STRING}
395   --  see ITU-T Rec. X.226 | ISO/IEC 8823-1.
396 }
397
398 Presentation-context-identifier ::= INTEGER
399
400 Authentication-value-other ::= SEQUENCE {
401   other-mechanism-name     OBJECT IDENTIFIER,
402   other-mechanism-value    ANY
403 }
404
405 Authentication-value ::= CHOICE {
406   charstring  [0] IMPLICIT GraphicString,
407   bitstring   [1] IMPLICIT BIT STRING,
408   external    [2] IMPLICIT EXTERNAL,
409   other
410     [3] IMPLICIT Authentication-value-other
411 }
412
413 --  The abstract syntax of (calling/responding) authentication-value is determined by the authentication mechanism used
414 --  during association establishment. The authentication mechanism is either explicitly denoted by the &id field (of type
415 --  OBJECT IDENTIFIER) for a mechanism belonging to the class MECHANISM-NAME, or it is known implicitly by
416 --  prior agreement between the communicating partners. If the "other" component is chosen, then the
417 --  "mechanism-name" component must be present in accordance with ITU-T Rec. X.680 | ISO/IEC 8824-1. If the value
418 --  "mechanism-name" occurs in the AARQ-apdu or the AARE-apdu, then that value must be the same as the value for
419 --  "other-mechanism-name".
420 Implementation-data ::= GraphicString
421
422 Mechanism-name ::= OBJECT IDENTIFIER
423
424 Release-request-reason ::= INTEGER {normal(0), urgent(1), user-defined(30)
425 }
426
427 Release-response-reason ::= INTEGER {
428   normal(0), not-finished(1), user-defined(30)}
429
430 END
431
432 -- Generated by Asnp, the ASN.1 pretty-printer of France Telecom R&D
433