ASN.1
Previous: UTCTime Up: Useful Types Next: Character String Types


EXTERNAL

  Type EXTERNAL takes values that communicate both data and how the data should be interpreted. The type of the data need not be an ASN.1 type. EXTERNAL is used, for example in the Association Control Service Element (ACSE) that is common to all OSI applications (See a later Chapter), to model a variable whose type is either unspecified or specified elsewhere. There is no restriction on the notation to specify the type.

ISO 8824 contains the following definition of the EXTERNAL type:

  EXTERNAL  ::=  [UNIVERSAL 8] IMPLICIT SEQUENCE
     {
      direct-reference  OBJECT IDENTIFIER OPTIONAL,
      indirect-reference  INTEGER OPTIONAL,
      data-value-descriptor  ObjectDescriptor  OPTIONAL,
      encoding  CHOICE
                  {single-ASN1-type  [0] ANY,
                   octet-aligned     [1] IMPLICIT OCTET STRING,
                   arbitrary         [2] IMPLICIT BIT STRING}
     }

Because abstract syntax names are transferred as OBJECT IDENTIFIER names and Presentation Context Identifiers (PCI) as INTEGER names, Presentation layer negotiation makes at least one of ``direct-reference'' or ``indirect-reference'' mandatory. Each abstract syntax name identified by the calling P-user (sender) is given a PCI. Its transfer syntax is then negotiated, connection is established, and data values and their PCIs (for interpretation of the data values) are then transmitted.

When the data value is an instance of a single ASN.1 data type, the standard encoding rules for that data type apply. Otherwise, the sender has a choice of ``octet-aligned'' or ``arbitrary'' if the data value is an integral number of octets, but can use only ``arbitrary'' if the data value is not an integral multiple of octets.

For example, suppose that, during negotiation, the PCI of 7 is assigned to a string type defined by a non-ASN.1 standard and that

String ::= EXTERNAL

is a definition in ASN.1. Then an instance of String is

    {
     indirect-reference   7,
     encoding    arbitrary   BIT STRING
        '27ABC63'H
    }

where ``arbitrary' is chosen for encoding and the hexadecimal string is a representation of the actual string transmitted.


This site was developed from:
Computer Networks and Open Systems
An Application Development Perspective

by
Lillian N. Cassel
Richard H. Austing

Jones & Bartlett Publisher
ISBN 0-7637-1122-5

This site is hosted by:


Real World ASN.1 and XML Solutions