ASN.1 is similar to a high-level programming language. Unlike other high-level languages, ASN.1 has no executable statements. It includes only language constructs required to define types and values.
ASN.1 defines a number of built-in types. Users of ASN.1 can then define their own types based on the built-in types provided by the language. The ASN.1 standard defines four categories of types that are commonly used in defining application interfaces such as XOM and XDS:
· ASN.1 Simple Types
· ASN.1 Useful Types
· ASN.1 Character String Types
· ASN.1 Type Constructors
ASN.1 simple types are Bit String, Boolean, Integer, Null, Object Identifier, Octet String, and Real. The following table shows the relationship of OM syntaxes (syntaxes defined in XOM API) to ASN.1 simple types. (Refer to Information Syntaxes for the complete set of tables for the four categories of ASN.1 types.) As shown in the table, for every ASN.1 type except Real, there is an OM syntax that is functionally equivalent to it. The simple types are listed in the first column of the table; the corresponding syntaxes are listed in the second column.
Syntax for the Simple ASN.1 Types
ASN.1 Type | OM Syntax |
Bit String | String(OM_S_BIT_STRING) |
Boolean | OM_S_BOOLEAN |
Integer | OM_S_INTEGER |
Null | OM_S_NULL |
Object Identifier | String(OM_S_OBJECT_IDENTIFIER_STRING) |
Octet String | String(OM_S_OCTET_STRING) |
Real | None (A future edition of XOM can define a syntax corresponding to this type.) |