OSI Application Developer's Toolkit OSS ASN.1 Tools Reference Manual

*HyperReader

  CONTENTS

  Title Page

  Copyright Page

  Preface

  1      Introduction

  1.1     Overview

  1.2     Components of the OSS ASN.1 Tools

  1.3     Product Foundation

  1.4     Product Customization Features

  1.5     Application Considerations

  1.6     Differences in Sample Code

  2      Getting Started

  3      Command-Line Compiler Parameters

  3.1     Function

  3.2     Syntax

  3.3     Examples of Compiler Invocation

  3.4     Parameter Reference
    3.4.1      C  |  C++
    3.4.2      CODEFILE < CFileName >/NOCODEFILE
    3.4.3      CONTROLFILE < CFileName >/NOCONTROLFILE
    3.4.4      DEBUG/NODEBUG
    3.4.5      DECODEONLY/ENCODEONLY
    3.4.6      EXTERNALNAME controlTableExternalName
    3.4.7      HEADERFILE < headerFileName >/NOHEADERFILE
    3.4.8      IGNORESUPPRESS
    3.4.9      INFORMATORY/NOINFORMATORY
    3.4.10     LISTINGFILE < listingFileName >/NOLISTINGFILE
    3.4.11     MODLISTINGFILE < listingFileName >/NOMODLISTINGFILE
    3.4.12     PEDANTIC/NOPEDANTIC
    3.4.13     PREFIX < prefix >
    3.4.14     SHORTENNAMES/NOSHORTENNAMES
    3.4.15     SORT/NOSORT
    3.4.16     SUPPRESS messageNumber
    3.4.17     SYNTAXONLY
    3.4.18     UNIQUEPDU/NOUNIQUEPDU
    3.4.19     VERBOSE
    3.4.20     WARNING/NOWARNING

  3.5     Command Line Help

  4      COMPILER DIRECTIVES

  4.1     Function

  4.2     Specifying Directives

  4.3     Placement of Directives

  4.4     Use of Directives with ASN.1 Macros

  4.5     Directives Reference
    4.5.1      Array (global and local)
    4.5.2      CODESEG (global and local) (OS/2 and MS-DOS only)
    4.5.3      COPYRIGHT (global)
    4.5.4      DECODEONLY/ENCODEONLY (local)
    4.5.5      DEFINITE/INDEFINITE (global and local)
    4.5.6      DLINKED (global and local)
    4.5.7      EXTENSIBLE/INEXTENSIBLE (global and local)
    4.5.8      FLOAT/DOUBLE/LONGDOUBLE (global and local)
    4.5.9      INCLUDES (global)
    4.5.10     LINKED (global and local)
    4.5.11     NULLTERM (global and local)
    4.5.12     OBJECTID (global and local)
    4.5.13     PADDED (global and local)
    4.5.14     PDU/NOPDU (global and local)
    4.5.15     POINTER/NOPOINTER (global and local)
    4.5.16     ROOT (global)
    4.5.17     SHORT/INT/LONG/LONGLONG (global and local)
    4.5.18     SUPPRESS (global and module)
    4.5.19     UNBOUNDED (global and local)
    4.5.20     USERFIELD (local)
    4.5.21     VALUE/NOVALUE (global, module, and local)
    4.5.22     VARYING (global and local)

  5      CONFIGURATION FILES

  5.1     ASN1DFLT Default Configuration File

  5.2     INCLUDES Configuration File

  5.3     Sample Configuration File

  6      THE OSS MACRO EXPANDER/SYNTAX CHECKER

  6.1     Function

  6.2     Invoking the OSS Macro Expander/Syntax Checker

  6.3     Examples Without Macros

  6.4     Expansion of ASN.1 Macro Notation
    6.4.1      Method of Expansion

  6.5     Restrictions on the Macro Notation

  6.6     Examples with Macros

  7      OSS Language Translator/Encoding Analyzer

  7.1     Function

  7.2     Invoking the OSS Language Translator/Encoding Analyzer

  7.3     Examples

  8      RESTRICTIONS

  8.1     Record Size

  8.2     Item Size

  8.3     Integer Size

  8.4     Checking of User-Specified Values

  9      REPRESENTATION OF ASN.1 NOTATIONS IN C

  9.1     Translation Rules for C Representations
    9.1.1      General rules for types
    9.1.2      Effect of ASN.1 modifiers
    9.1.3      Recursive ASN.1 types

  9.2     Variable Name Generation
    9.2.1      General Method
    9.2.2      Exceptional Cases
      9.2.2.1      Handling names that are too long
      9.2.2.2      Disambiguation of Names

  9.3     Effect of Subtypes on Generated Data Types
    9.3.1      SingleValue Subtype
    9.3.2      ValueRange Subtype
    9.3.3      SizeConstraint Subtype
    9.3.4      AlphabetLimitation Subtype
    9.3.5      Contained Subtype
    9.3.6      Inner Subtype

  9.4     Representation of ASN.1 Macro Notation in C

  9.5     Representation of ASN.1 Value Notation in C

  9.6     Representation of ASN.1 Type Notation in C
    9.6.1      ANY / ANY DEFINED BY
    9.6.2      BIT STRING
    9.6.3      BOOLEAN
    9.6.4      CharacterString Types
    9.6.5      CHOICE
    9.6.6      ENUMERATED
    9.6.7      EXTERNAL
    9.6.8      GeneralizedTime
    9.6.9      INTEGER
    9.6.10     NULL
    9.6.11     ObjectDescriptor
    9.6.12     OBJECT IDENTIFIER
    9.6.13     OCTET STRING
    9.6.14     REAL
    9.6.15     Selection
    9.6.16     SEQUENCE
    9.6.17     SEQUENCE OF
    9.6.18     SET
    9.6.19     SET OF
    9.6.20     Tagged
    9.6.21     UTCTime

  10     ENCODING AND DECODING

  10.1    Function

  10.2    Handling Huge PDU's in the Space-Optimized Encoder/Decoder

  10.3    The Space-Optimized Encoder
    10.3.1     Calling the Encoder
    10.3.2     Encoder Parameters
    10.3.3     Encoder Return Codes

  10.4    The Space-Optimized Decoder
    10.4.1     Calling the Decoder
    10.4.2     Decoder Parameters
    10.4.3     Decoder Return Codes

  10.5    The Time-Optimized Encoder/Decoder

  10.6    Using OSAK Buffers with the Encoder/Decoder
    10.6.1     Testing/Marking a Pointer to an OSAK Buffer List
    10.6.2     Link-editing with the OSAK Buffer Library
    10.6.3     Using OSAK Buffers with the Encoder
    10.6.4     Using OSAK Buffers with the Decoder

  10.7    Memory Management and I/O Variables

  10.8    Printing Unencoded or Decoded Data

  10.9    Debugging Output

  10.10   Encoder/Decoder Special Handling Of Types

  11     Error Message Reference

  11.1    Command Line Error Messages

  11.2    Compiler Error Messages

  A   Configuration Directives

  B   The Encoder/Decoder Memory Manager

  B.1     Function

  B.2     The Memory Manager and Memory Objects

  B.3     Referencing Pointers

  B.4     Error Recovery

  B.5     Encoding

  B.6     Decoding

  B.7     Memory Management Functions
    B.7.1      Encoder Input Memory Management Functions
    B.7.2      Encoder Output Memory Management Functions
    B.7.3      Encoder Miscellaneous Memory Management Functions
    B.7.4      Decoder Input Memory Management Functions
    B.7.5      Decoder Output Memory Management Functions
    B.7.6      Decoder Miscellaneous Memory Management Functions
    B.7.7      Encoder/Decoder General Memory Management Functions
    B.7.8      Encoder/Decoder High-level Memory Management Functions
    B.7.9      Encoder/Decoder Low-level Memory Management Functions

  B.8     Encoder/Decoder Error Handler

  TABLES

  10-1       Run-time libraries categorized by operating system and memory manager