ASN.1 Compiler for C# and Encoder/Decoder

ASN.1 Compiler for C#

The ASN.1 compiler for C# is a compiled (not interpreted) executable, therefore, it is capable of extremely fast ASN.1 compilation. The compiler accepts one or more input files, where each contains one or more ASN.1 modules, it verifies that the ASN.1 schema is valid, and generates the following:

  • C# classes to be included in your application
  • Informative diagnostic messages for any invalid ASN.1. The OSS compiler makes every attempt to recover from errors. Giving you messages for each error encountered means fewer recompilations to correct an invalid spec.
  • Optional XSL stylesheets and/or DTD for XML encodings
  • An optional ASN.1 output listing
  • A simple directory structure
  • C# instantiations of all ASN.1 values
  • Only the C# classes (based on the ASN.1 types) that you select - modules, PDUs, metadata (i.e. tags, names, constraints). Your application is leaner, thus your development time is reduced.
ASN.1 Compiler for C# and ASN.1 Encoder/Decoder workflow

Key features of the ASN.1 Compiler for C#

Does your application need to do automatic decoding? Handle multiple ASN.1 versions? Work in a multi-threading environment? Does your spec contain values, extensible types and information object sets? Then you need the full featured OSS compiler. It generates valid C# code no matter what spec you use (RRC, S1/X2, RANAP, NBAP are just a few of the specs that our customers use that our compiler handles with no problem).

  • Support of the latest ASN.1 standards
  • Full support for contents constraints. Our ASN.1/C# compiler is comprehensive - not a tag or constraint is left behind.
  • Handle even the most unusual ASN.1 specifications.
  • Work with third party IDEs such as Microsoft Visual Studio.
  • Automate the sample application process enabling you to try out our tools quickly with a minimum of effort.

No matter what your application needs, a little or a lot, OSS provides it.

For a complete list of features, see Features shared across all OSS ASN.1 Tools.

ASN.1 Encoder/Decoder

The OSS Encoder/Decoder consists of a class called "<Encoding Rule>Codec, of which the essential methods are Encode() and Decode().

TLV Print Utility

This utility, included with the ASN.1 Tools for C# takes a BER or DER encoding in ASCII or binary format from an input file and writes it to an output file in one of three different type-length-value (TLV) formats.

The Encode() method takes data placed by your application program in the compiler-generated C# classes, and converts it to a string of bytes encoded according to BER, DER, PER, UPER, CPER, CUPER, OER, COER, XER, CXER, E-XER, or JSON. The Decode() method takes a string of bytes that have been encoded according to BER, DER, PER, UPER, CPER, CUPER, OER, COER, XER, CXER, E-XER, or JSON and performs the inverse operation of the encoder, resulting in a C# object that you can easily manipulate.

Key features of the ASN.1 Encoder/Decoder API

  • Full support of BER, DER, PER, UPER, CPER, CUPER, OER, COER, XER, CXER, E-XER, and JSON encoding rules
  • Powerful, flexible diagnostic and recovery capabilities
  • Methods for validating encodings, copying, and comparing decoded messages
  • Convenient mechanisms for debugging and printing ASN.1 values using ToString() or the ValueNotationFormatter class
  • Custom printing capabilities - print it your way!
  • Debug BER encodings (OSSTLV).
  • Debug PER encodings (ASN.1 Studio).

Take the next step

  1. Download a 30 Day Free Trial of our ASN.1/C# Tools.
  2. Get familiar with the ASN.1 compiler for C# and the encoder/decoder by exploring the Getting Started topics.
  3. See a simple sample application.
  4. If you have questions regarding how to use the ASN.1/C# Tools, check out the Knowledge Center section or visit the Contact Info section.

Standards Conformance

Our ASN.1 compiler for C# and the ASN.1 encoders/decoders are fully compliant with all ASN.1 standards. We support: 2021, 2015, 2008, 2002, 1997, 1994, and 1990. For a complete list, see the Standards Conformance page.

Quick Links


Resources
icon

More information about how to create, compile and link your ASN.1 application using the ASN.1/C# Tools.


Free Trial
download

Download the ASN.1/C# Tools today!




24x7 Tech Support

contact

We are here: 24 hours a day, 7 days a week.

  • Phone: 1-888-OSS-2761 (USA and Canada)
  • Phone: 1-732-302-9669 (International)
  • Fax: 1-732-302-0023
  • Email: support@oss.com

Quickly receive answers to your support questions.