Topic Path: Symbol Reference > Files > IdASN1Util.pas

Constants and functions for ASN.1 support.

IdASN1Util.pas contains constants and functions used to implement Abstract Syntax Notation version 1 (ASN.1) encoding and decoding. 

The term ASN.1 “Abstract Syntax Notation One” is commonly used to specify both the formal notation and the associated encoding rules defined to exchange structured data between heterogeneous systems independently of a given hardware, or programming language, or programming language compiler. The formal notation is used to specify data-structures at an abstract level. 

ASN.1 encoding rules are used to represent the values of these data-structures to be transferred over a computer or telecommunication network. Several encoding rules are standardized: Packed Encoding Rules (PER), Basic Encoding Rules (BER), Distinguished Encoding Rules (DER), XML Encoding Rules (XER). 

The ASN.1 formal notation intrinsically ensures the completeness and the preciseness of the data specifications. Moreover, it facilitates the readability and the understandability of the data specification by avoiding ambiguous definitions. 

The need for Abstract Syntax Notation 1 (ASN.1) arises because different computer systems represent information in different ways. For example, one computer can use EBCDIC character representation while another can use ASCII. To transfer a file of characters from one system to another, common representation must be used during the transfer. This transfer can be one representation or the other, or some mutually agreed upon representation negotiated by the two systems. Similarly, floating-point values, integers, and other types of data can be stored internally in different ways. To exchange information, a common format must be agreed to before information can be exchanged. 

The translation of EBCDIC to ASCII characters can seem like a trivial problem, but that leaves the larger issue of mapping between the many diverse representations that can exist within a network environment. To address this need, the ISO standards committee defined ASN.1 and Basic Encoding Rules. 

ASN.1 is based on the idea that the aspects of transferred information that are preserved are type, length, and value. Data types are collections of values distinguished for some reason, such as characters, integers, and floating-point values. Records and structure types become more complex when they combine several types into a single structure. 

ASN.1 provides a way to group types into abstract syntaxes. An abstract syntax is a named group of types. The standard defines abstract syntax as the notation rules that are independent of the encoding technique used to represent them. Abstract syntax does not specify how to represent values of types, but merely defines the types that make up the group of types. 

Abstract syntaxes are not enough to define how values of the data types in a specific abstract syntax are to be represented during communications. For this reason, ISO further defines a transfer syntax for each abstract syntax. A transfer syntax is a set of rules for encoding values of some specified group of types.

Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.