1、 7 I n t e r n a t i o n a l T e l e c o m m u n i c a t i o n U n i o n ITU-T X.692 TELECOMMUNICATION STANDARDIZATION SECTOR OF ITU (08/2015) SERIES X: DATA NETWORKS, OPEN SYSTEM COMMUNICATIONS AND SECURITY OSI networking and system aspects Abstract Syntax Notation One (ASN.1) Information technolog
2、y ASN.1 encoding rules: Specification of Encoding Control Notation (ECN) Recommendation ITU-T X.692 ITU-T X-SERIES RECOMMENDATIONS DATA NETWORKS, OPEN SYSTEM COMMUNICATIONS AND SECURITY PUBLIC DATA NETWORKS Services and facilities X.1X.19 Interfaces X.20X.49 Transmission, signalling and switching X.
3、50X.89 Network aspects X.90X.149 Maintenance X.150X.179 Administrative arrangements X.180X.199 OPEN SYSTEMS INTERCONNECTION Model and notation X.200X.209 Service definitions X.210X.219 Connection-mode protocol specifications X.220X.229 Connectionless-mode protocol specifications X.230X.239 PICS prof
4、ormas X.240X.259 Protocol Identification X.260X.269 Security Protocols X.270X.279 Layer Managed Objects X.280X.289 Conformance testing X.290X.299 INTERWORKING BETWEEN NETWORKS General X.300X.349 Satellite data transmission systems X.350X.369 IP-based networks X.370X.379 MESSAGE HANDLING SYSTEMS X.40
5、0X.499 DIRECTORY X.500X.599 OSI NETWORKING AND SYSTEM ASPECTS Networking X.600X.629 Efficiency X.630X.639 Quality of service X.640X.649 Naming, Addressing and Registration X.650X.679 Abstract Syntax Notation One (ASN.1) X.680X.699 OSI MANAGEMENT Systems management framework and architecture X.700X.7
6、09 Management communication service and protocol X.710X.719 Structure of management information X.720X.729 Management functions and ODMA functions X.730X.799 SECURITY X.800X.849 OSI APPLICATIONS Commitment, concurrency and recovery X.850X.859 Transaction processing X.860X.879 Remote operations X.880
7、X.889 Generic applications of ASN.1 X.890X.899 OPEN DISTRIBUTED PROCESSING X.900X.999 INFORMATION AND NETWORK SECURITY X.1000X.1099 SECURE APPLICATIONS AND SERVICES X.1100X.1199 CYBERSPACE SECURITY X.1200X.1299 SECURE APPLICATIONS AND SERVICES X.1300X.1399 CYBERSECURITY INFORMATION EXCHANGE X.1500X.
8、1599 CLOUD COMPUTING SECURITY X.1600X.1699 For further details, please refer to the list of ITU-T Recommendations. Rec. ITU-T X.692 (08/2015) i INTERNATIONAL STANDARD ISO/IEC 8825-3 RECOMMENDATION ITU-T X.692 Information technology ASN.1 encoding rules: Specification of Encoding Control Notation (EC
9、N) Summary Recommendation ITU-T X.692 | ISO/IEC 8825-3 defines the Encoding Control Notation (ECN) used to specify encodings (of ASN.1 types) that differ from those provided by standardized encoding rules such as the Basic Encoding Rules (BER) and the Packed Encoding Rules (PER). History Edition Rec
10、ommendation Approval Study Group Unique ID* 1.0 ITU-T X.692 2002-03-08 17 11.1002/1000/5647 1.1 ITU-T X.692 (2002) Annex E 2002-03-08 17 11.1002/1000/6361 1.2 ITU-T X.692 (2002) Amd. 1 2004-08-29 17 11.1002/1000/7292 1.3 ITU-T X.692 (2002) Technical Cor. 1 2005-05-14 17 11.1002/1000/8514 1.4 ITU-T X
11、.692 (2002) Amd. 2 2006-06-13 17 11.1002/1000/8840 2.0 ITU-T X.692 2008-11-13 17 11.1002/1000/9610 2.1 ITU-T X.692 (2008) Cor. 1 2011-10-14 17 11.1002/1000/11380 3.0 ITU-T X.692 2015-08-13 17 11.1002/1000/12485 * To access the Recommendation, type the URL http:/handle.itu.int/ in the address field o
12、f your web browser, followed by the Recommendations unique ID. For example, http:/handle.itu.int/11.1002/1000/11830-en. ii Rec. ITU-T X.692 (08/2015) FOREWORD The International Telecommunication Union (ITU) is the United Nations specialized agency in the field of telecommunications, information and
13、communication technologies (ICTs). The ITU Telecommunication Standardization Sector (ITU-T) is a permanent organ of ITU. ITU-T is responsible for studying technical, operating and tariff questions and issuing Recommendations on them with a view to standardizing telecommunications on a worldwide basi
14、s. The World Telecommunication Standardization Assembly (WTSA), which meets every four years, establishes the topics for study by the ITU-T study groups which, in turn, produce Recommendations on these topics. The approval of ITU-T Recommendations is covered by the procedure laid down in WTSA Resolu
15、tion 1. In some areas of information technology which fall within ITU-Ts purview, the necessary standards are prepared on a collaborative basis with ISO and IEC. NOTE In this Recommendation, the expression “Administration“ is used for conciseness to indicate both a telecommunication administration a
16、nd a recognized operating agency. Compliance with this Recommendation is voluntary. However, the Recommendation may contain certain mandatory provisions (to ensure, e.g., interoperability or applicability) and compliance with the Recommendation is achieved when all of these mandatory provisions are
17、met. The words “shall“ or some other obligatory language such as “must“ and the negative equivalents are used to express requirements. The use of such words does not suggest that compliance with the Recommendation is required of any party. INTELLECTUAL PROPERTY RIGHTSITU draws attention to the possi
18、bility that the practice or implementation of this Recommendation may involve the use of a claimed Intellectual Property Right. ITU takes no position concerning the evidence, validity or applicability of claimed Intellectual Property Rights, whether asserted by ITU members or others outside of the R
19、ecommendation development process. As of the date of approval of this Recommendation, ITU had not received notice of intellectual property, protected by patents, which may be required to implement this Recommendation. However, implementers are cautioned that this may not represent the latest informa
20、tion and are therefore strongly urged to consult the TSB patent database at http:/www.itu.int/ITU-T/ipr/. ITU 2015 All rights reserved. No part of this publication may be reproduced, by any means whatsoever, without the prior written permission of ITU. Rec. ITU-T X.692 (08/2015) iii CONTENTS Page In
21、troduction x Information technology ASN.1 encoding rules: Specification of Encoding Control Notation (ECN) 1 1 Scope . 1 2 Normative references. 1 2.1 Identical Recommendations | International Standards . 1 2.2 Additional references . 2 3 Definitions . 2 3.1 ASN.1 definitions . 2 3.2 ECN-specific de
22、finitions 2 4 Abbreviations 5 5 Definition of ECN syntax 5 6 Encoding conventions and notation . 5 7 The ECN character set . 5 8 ECN lexical items 6 8.1 Encoding object references 6 8.2 Encoding object set references . 6 8.3 Encoding class references 7 8.4 Reserved word items 7 8.5 Reserved encoding
23、 class name items . 7 8.6 Non-ECN item . 7 9 ECN Concepts . 8 9.1 Encoding Control Notation (ECN) specifications 8 9.2 Encoding classes 8 9.3 Encoding structures 9 9.4 Encoding objects 9 9.5 Encoding object sets . 9 9.6 Defining new encoding classes 10 9.7 Defining encoding objects 11 9.8 Differenti
24、al encoding-decoding 11 9.9 Encoders options in encodings . 12 9.10 Properties of encoding objects . 12 9.11 Parameterization . 12 9.12 Governors . 13 9.13 General aspects of encodings . 13 9.14 Identification of information elements . 14 9.15 Reference fields and determinants . 14 9.16 Replacement
25、classes and structures 14 9.17 Mapping abstract values onto fields of encoding structures . 15 9.18 Transforms and transform composites . 16 9.19 Contents of Encoding Definition Modules . 16 9.20 Contents of the Encoding Link Module . 17 9.21 Defining encodings for primitive encoding classes 17 9.22
26、 Application of encodings . 19 9.23 Combined encoding object set . 19 9.24 Application point 19 9.25 Conditional encodings 20 9.26 Other conditions for applying encodings . 20 9.27 Encoding control for the open type 21 9.28 Changes to ASN.1 Recommendations | International Standards 21 iv Rec. ITU-T
27、X.692 (08/2015) 10 Identifying encoding classes, encoding objects, and encoding object sets 21 11 Encoding ASN.1 types 24 11.1 General . 24 11.2 Built-in encoding classes used for implicitly generated encoding structures . 25 11.3 Simplification and expansion of ASN.1 notation for encoding purposes
28、. 25 11.4 The implicitly generated encoding structure 27 12 The Encoding Link Module (ELM) . 28 12.1 Structure of the ELM 28 12.2 Encoding types . 28 13 Application of encodings . 29 13.1 General . 29 13.2 The combined encoding object set and its application . 29 14 The Encoding Definition Module (E
29、DM) . 32 15 The renames clause 33 15.1 Explicitly generated and exported structures 33 15.2 Name changes 34 15.3 Specifying the region for name changes 35 16 Encoding class assignments. 36 16.1 General . 36 16.2 Encoding structure definition . 39 16.3 Alternative encoding structure . 42 16.4 Repetit
30、ion encoding structure . 43 16.5 Concatenation encoding structure 43 17 Encoding object assignments. 44 17.1 General . 44 17.2 Encoding with a defined syntax . 44 17.3 Encoding with encoding object sets . 45 17.4 Encoding using value mappings . 46 17.5 Encoding an encoding structure . 46 17.6 Differ
31、ential encoding-decoding 48 17.7 Encoding options 49 17.8 Non-ECN definition of encoding objects . 50 18 Encoding object set assignments . 50 18.1 General . 50 18.2 Built-in encoding object sets 51 19 Mapping values . 52 19.1 General . 52 19.2 Mapping by explicit values 53 19.3 Mapping by matching f
32、ields . 54 19.4 Mapping by #TRANSFORM encoding objects 55 19.5 Mapping by abstract value ordering . 56 19.6 Mapping by value distribution . 57 19.7 Mapping integer values to bits . 58 20 Defining encoding objects using defined syntax . 59 21 Types used in defined syntax specification . 60 21.1 The U
33、nit type . 60 21.2 The EncodingSpaceSize type . 60 21.3 The EncodingSpaceDetermination type 61 21.4 The UnusedBitsDetermination type . 61 21.5 The OptionalityDetermination type 62 21.6 The AlternativeDetermination type 63 21.7 The RepetitionSpaceDetermination type . 63 21.8 The Justification type 64
34、 Rec. ITU-T X.692 (08/2015) v 21.9 The Padding type 65 21.10 The Pattern and Non-Null-Pattern types . 65 21.11 The RangeCondition type 66 21.12 The Comparison type . 66 21.13 The SizeRangeCondition type 67 21.14 The ReversalSpecification type . 67 21.15 The ResultSize type . 68 21.16 The HandleValue
35、Set type 68 21.17 The IntegerMapping type . 69 22 Commonly used encoding property groups . 69 22.1 Replacement specification 69 22.1.1 Encoding properties, syntax and purpose . 69 22.1.2 Specification restrictions 70 22.1.3 Encoder actions 71 22.1.4 Decoder actions 72 22.2 Pre-alignment and padding
36、specification . 72 22.2.1 Encoding properties, syntax and purpose . 72 22.2.2 Specification constraints 72 22.2.3 Encoder actions 73 22.2.4 Decoder actions 73 22.3 Start pointer specification . 73 22.3.1 Encoding properties, syntax and purpose . 73 22.3.2 Specification constraints 73 22.3.3 Encoder
37、actions 73 22.3.4 Decoder actions 74 22.4 Encoding space specification . 74 22.4.1 Encoding properties, syntax and purpose . 74 22.4.2 Specification restrictions 75 22.4.3 Encoder actions 75 22.4.4 Decoder actions 76 22.5 Optionality determination 76 22.5.1 Encoding properties, syntax and purpose .
38、76 22.5.2 Specification restrictions 76 22.5.3 Encoder actions 77 22.5.4 Decoder actions 77 22.6 Alternative determination . 78 22.6.1 Encoding properties, syntax and purpose . 78 22.6.2 Specification restrictions 78 22.6.3 Encoder actions 79 22.6.4 Decoder actions 79 22.7 Repetition space specifica
39、tion 79 22.7.1 Encoding properties, syntax and purpose . 79 22.7.2 Specification constraints 80 22.7.3 Encoder actions 81 22.7.4 Decoder actions 82 22.8 Value padding and justification 82 22.8.1 Encoding properties, syntax, and purpose 82 22.8.2 Specification restrictions 83 22.8.3 Encoder actions 8
40、3 22.8.4 Decoder actions 84 22.9 Identification handle specification . 84 22.9.1 Encoding properties, syntax and purpose . 84 22.9.2 Specification constraints 85 22.9.3 Encoders actions . 85 22.9.4 Decoders actions 85 22.10 Concatenation specification . 86 22.10.1 Encoding properties, syntax and pur
41、pose . 86 22.10.2 Specification constraints 86 22.10.3 Encoder actions 86 22.10.4 Decoder actions 87 vi Rec. ITU-T X.692 (08/2015) 22.11 Contained type encoding specification . 87 22.11.1 Encoding properties, syntax and purpose . 87 22.11.2 Encoder actions 87 22.11.3 Decoder actions 87 22.12 Bit rev
42、ersal specification 87 22.12.1 Encoding properties, syntax, and purpose 87 22.12.2 Specification constraints 88 22.12.3 Encoder actions 88 22.12.4 Decoder actions 88 23 Defined syntax specification for bit-field and constructor classes 88 23.1 Defining encoding objects for classes in the alternative
43、s category 88 23.1.1 The defined syntax . 88 23.1.2 Purpose and restrictions . 89 23.1.3 Encoder actions 89 23.1.4 Decoder actions 90 23.2 Defining encoding objects for classes in the bitstring category . 90 23.2.1 The defined syntax . 90 23.2.2 Model for the encoding of classes in the bitstring cat
44、egory . 91 23.2.3 Purpose and restrictions . 91 23.2.4 Encoder actions 92 23.2.5 Decoder actions 92 23.3 Defining encoding objects for classes in the boolean category 92 23.3.1 The defined syntax . 92 23.3.2 Purpose and restrictions . 94 23.3.3 Encoder actions 94 23.3.4 Decoder actions 94 23.4 Defin
45、ing encoding objects for classes in the characterstring category . 95 23.4.1 The defined syntax . 95 23.4.2 Model for the encoding of classes in the characterstring category . 95 23.4.3 Purpose and restrictions . 96 23.4.4 Encoder actions 96 23.4.5 Decoder actions 97 23.5 Defining encoding objects f
46、or classes in the concatenation category 97 23.5.1 The defined syntax . 97 23.5.2 Purpose and restrictions . 98 23.5.3 Encoder actions 99 23.5.4 Decoder actions 99 23.6 Defining encoding objects for classes in the integer category . 99 23.6.1 The defined syntax . 99 23.6.2 Purpose and restrictions .
47、 99 23.6.3 Encoder actions 100 23.6.4 Decoder actions 100 23.7 Defining encoding objects for the #CONDITIONAL-INT class . 100 23.7.1 The defined syntax . 100 23.7.2 Purpose and restrictions . 101 23.7.3 Encoder actions 102 23.7.4 Decoder actions 103 23.8 Defining encoding objects for classes in the
48、null category 103 23.8.1 The defined syntax . 103 23.8.2 Purpose and restrictions . 105 23.8.3 Encoder actions 105 23.8.4 Decoder actions 105 23.9 Defining encoding objects for classes in the octetstring category 105 23.9.1 The defined syntax . 105 23.9.2 Model for the encoding of classes in the oct
49、etstring category 106 23.9.3 Purpose and restrictions . 106 23.9.4 Encoder actions 107 23.9.5 Decoder actions 107 23.10 Defining encoding objects for classes in the open type category . 108 23.10.1 The defined syntax . 108 23.10.2 Model for the encoding of classes in the open type category . 109 Rec. ITU-T X.692 (08/2015) vii 23.10.3 Purpose and restrictions . 109 23.10.4 Encoder actions 109 23.10.5 Decoder actions 110 23.11 Defining encoding objects for classes in the optionality category . 110 23.11.1 The defined syntax . 110 23.11.2