About autober

autober is a language for generating BER decoders. It's different from an ASN.1 compiler in that it's much simpler and it only deals with BER encoded messages. It is intended for smartcard and RFID applications where much of the data stored on these devices is, in-fact, BER encoded TLV data. The language is designed to be very similar to the template definitions found in the specifications for smartcard and RFID applications.

As an example, here is the autober definition for the EF.DG2 file found on ICAO-9303 machine readable travel documents aka. "ePassport".

/* Biometric data from EF.DG2 file in ICAO9303 compliant e-passport */
0x7f61 bio_group 'Biometric Information Group Template' {
	0x2 uint8_t num_instances;
	0x7f60 bio_inf[] 'Biometric \'Information\' Template' {
		0xa1 bio_hdr 'Biometric Header Template' {
			0x80 uint16_t vers;
			0x81 OPTIONAL octet[1-3] type;
			0x82 OPTIONAL uint8_t subtype;
			0x83 OPTIONAL octet[7] date;
			0x85 OPTIONAL octet[8] validity;
			0x86 OPTIONAL octet[2] creator_pid;
			0x87 octet[2] format_owner;
			0x88 octet[2] format_type;
		union bdb 'Biometric Data Block' {
			0x5f2e blob bdb_nc;
			0x7f2e NOCONSTRUCT blob bdb_c;

As you can see this 20 lines of definition almost exactly maps to the description given in the documentation. The equivalent C code for parsing this structure is on the order of several hundred lines and, to be honest, my hand-written effort had several errors that I only discovered during the development of this tool. You can see the example source code and header file produced for this template definition.

Autober can now generate working code, at least for this example. There are still a few features I would like to add to make the language a bit more useful for general purpose development.

Planned features

The Software

autober is released under the terms of the GNU GPL v3.
Version 0.1 autober-0.1.tar.gz
Version 0.0 autober-0.0.tar.gz.

You can follow development using git by issuing the following command:

git clone git://

Valid HTML 3.2!

Copyright (c) Spanish Inquisition 1478-1834. All rights reversed.