OnWorks favicon

asn1c - Online in the Cloud

Run asn1c in OnWorks free hosting provider over Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

This is the command asn1c that can be run in the OnWorks free hosting provider using one of our multiple free online workstations such as Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator



asn1c - ASN.1 Compiler


asn1c [-E [-F] | -P | -R]
[-Sdir] [-X]
[-Wdebug-...] [-foption] [-gen-option] [-pdu={all|auto|Type}]


asn1c compiles ASN.1 specifications into a set of target language (C/C++) encoders and
decoders for BER, DER, PER, XER and other encoding rules.


Overall Options
-E -F -P -R -S directory -X

Warning Options
-Werror -Wdebug-lexer -Wdebug-fixer -Wdebug-compiler

Language Options
-fbless-SIZE -fcompound-names -findirect-choice -fknown-extern-type=<name>
-fnative-types -fno-constraints -fno-include-deps -funnamed-unions -fskeletons-copy

Codecs Generation Options
-gen-PER -pdu={all|auto|Type}

Output Options
-print-constraints -print-lines


-E Stop after the parsing stage and print the reconstructed ASN.1 specification code
to the standard output.

-F Used together with -E, instructs the compiler to stop after the ASN.1 syntax tree
fixing stage and dump the reconstructed ASN.1 specification to the standard output.

-P Dump the compiled output to the standard output instead of creating the target
language files on disk.

-R Restrict the compiler to generate only the ASN.1 tables, omitting the usual support

-S directory
Use the specified directory with ASN.1 skeleton files.

-X Generate an XML DTD schema for the specified ASN.1 files.


Treat warnings as errors; abort if any warning is produced.

Enable lexer debugging during the ASN.1 parsing stage.

Enable ASN.1 syntax tree fixer debugging during the fixing stage.

Enable debugging during the actual compile time.


Allow SIZE() constraint for INTEGER, ENUMERATED, and other types for which this
constraint is normally prohibited by the standard. This is a violation of ASN.1
standard, and the compiler may fail to produce a meaningful code.

Using this option prevents name collisions in the target source code by using
complex names for target language structures. (Name collisions may occur if the
ASN.1 module reuses the same identifiers in multiple contexts).

When generating code for a CHOICE type, compile the CHOICE members as indirect
pointers instead of declaring them inline. Consider using this option together with
-fno-include-deps to prevent circular references.

Pretend the specified type is known. The compiler will assume the target language
source files for the given type have been provided manually.

Use the native machine's data types (int, double) whenever possible, instead of the
compound INTEGER_t, ENUMERATED_t and REAL_t types.

Do not generate ASN.1 subtype constraint checking code. This may make a shorter

Do not generate courtesy #include lines for non-critical type dependencies. Helps
prevent namespace collisions.

Enable unnamed unions in the definitions of target language's structures.

Copy support files (skeletons) rather than symlink them.


Generate Packed Encoding Rules (PER) support code.

Create a PDU table for specified types, or discover Protocol Data Units
automatically. In case of -pdu=all, all ASN.1 types defined in all modules will
form a PDU table. In case of -pdu=auto, all types not referenced by any other type
will form a PDU table. If Type is an ASN.1 type identifier, it is added to a PDU
table. The last form may be specified multiple times to add any number of PDUs.


When -EF are also specified, this option forces the compiler to explain its
internal understanding of subtype constraints.

Generate "-- #line" comments in -E output.

Use asn1c online using onworks.net services

Free Servers & Workstations

Download Windows & Linux apps

  • 1
    OfficeFloor provides inversion of
    coupling control, with its: - dependency
    injection - continuation injection -
    thread injection For more information
    visit the...
    Download OfficeFloor
  • 2
    DivKit is an open source Server-Driven
    UI (SDUI) framework. It allows you to
    roll out server-sourced updates to
    different app versions. Also, it can be
    used fo...
    Download DivKit
  • 3
    Utility to convert between various
    subscription format. Shadowrocket users
    should use ss, ssr or v2ray as target.
    You can add &remark= to
    Telegram-liked HT...
    Download subconverter
  • 4
    SWASH is a general-purpose numerical
    tool for simulating unsteady,
    non-hydrostatic, free-surface,
    rotational flow and transport phenomena
    in coastal waters as ...
    Download SWASH
  • 5
    VBA-M (Archived - Now on Github)
    VBA-M (Archived - Now on Github)
    Project has moved to
    Features:Cheat creationsave statesmulti
    system, supports gba, gbc, gb, sgb,
    Download VBA-M (Archived - Now on Github)
  • 6
    Linux System Optimizer and Monitoring
    Github Repository:
    Audience: End Users/Desktop. User
    interface: Qt. Programming La...
    Download Stacer
  • More »

Linux commands