ASN.1 is an actively used interface design language created in 1984. Abstract Syntax Notation One (ASN.1) is an interface description language for defining data structures that can be serialized and deserialized in a standard, cross-platform way. It's broadly used in telecommunications and computer networking, and especially in cryptography. Protocol developers define data structures in ASN.1 modules, which are generally a section of a broader standards document written in the ASN.1 language. Read more on Wikipedia...

35Years Old 20Users 0Jobs
  • ASN.1 ranks in the top 10% of languages
  • the ASN.1 wikipedia page
  • ASN.1 first appeared in 1984
  • file extensions for ASN.1 include asn and asn1
  • See also: protobuf, thrift, ascii, json, xml
  • I have 70 facts about ASN.1. what would you like to know? email me and let me know how I can help.

Example code from the web:

FooProtocol DEFINITIONS ::= BEGIN

    FooQuestion ::= SEQUENCE {
        trackingNumber INTEGER,
        question       IA5String
    }

    FooAnswer ::= SEQUENCE {
        questionNumber INTEGER,
        answer         BOOLEAN
    }

END

Example code from Linguist:

MyShopPurchaseOrders DEFINITIONS AUTOMATIC TAGS ::= BEGIN

PurchaseOrder ::= SEQUENCE {
dateOfOrder	DATE,
customer   	CustomerInfo,
items      	ListOfItems
}

CustomerInfo ::= SEQUENCE {
companyName	   VisibleString (SIZE (3..50)),
billingAddress	Address,
contactPhone   NumericString (SIZE (7..12))
}

Address::= SEQUENCE {
street	 VisibleString (SIZE (5 .. 50)) OPTIONAL,
city	   VisibleString (SIZE (2..30)),
state	  VisibleString (SIZE(2) ^ FROM ("A".."Z")),
zipCode	NumericString (SIZE(5 | 9))
}

ListOfItems ::= SEQUENCE (SIZE (1..100)) OF Item

Item ::= SEQUENCE {
itemCode	       INTEGER (1..99999),
color          	VisibleString ("Black" | "Blue" | "Brown"),
power          	INTEGER (110 | 220),
deliveryTime   	INTEGER (8..12 | 14..19),
quantity	       INTEGER (1..1000),
unitPrice	      REAL (1.00 .. 9999.00),
isTaxable	      BOOLEAN
}
END

Example code from Wikipedia:

<FooQuestion>
    <trackingNumber>5</trackingNumber>
    <question>Anybody there?</question>
</FooQuestion>

Trending Repos

repo stars description

Last updated December 4th, 2019

Edit ASN.1