What is ASN.1 and it's pros/cons?

asn.1

Solution

It's a serialization standard defined by ISO.

Yes, although the smallest space a value will occupy is (afaik) 5 bits.

I don't know of a full one, although I'm not claiming to be all knowing.

Hard to answer in a neutral way, but as far as I've experienced mainly complexity, getting close to a full implementation is hard.

See 4. ASN.1 is fairly space efficient (protobuf may give it a run for its money) but also would seem fairly complex as compared to most other serialization methods. In the end, complexity often loses (as also often "pay for read specifications" do)

Problem

I was looking for very generic, strict and platform independent serialization framework. And I discovered something called ASN.1. It looks like something related to serialization, but I couldn't understand actually what it is. I read Wikipedia article and ITU article but still, it's hard to know. I have many questions. Maybe I need some overall differential description of ASN.1. - What is ASN.1? - Does this define strict datatypes? (such as 32-bit integer, 1-bit boolean, etc.) - Is there reference implementation in C/C++? - Why this doesn't look popular as like Apache Thrift, Protocol Buffers or other serialization stuffs? - What's pros/cons of ASN.1 when compared to other serialization frameworks?

Original source